Computer Science ›› 2019, Vol. 46 ›› Issue (7): 139-145.doi: 10.11896/j.issn.1002-137X.2019.07.022

• Software & Database Technology • Previous Articles     Next Articles

Matrix Formalization Based on Coq Record

MA Zhen-wei1,CHEN Gang1,2   

  1. (College of Computer Science and Technology,Nanjing University of Aeronautics and Astronautics,Nanjing 210000,China)1
    (Beijing Jinghang Research Institute of Computing and Communication,Beijing 100074,China)2
  • Received:2018-06-01 Online:2019-07-15 Published:2019-07-15

Abstract: Matrix has a wide range of applications in engineering systems,and the correctness of matrix operations has an important impact on the reliability of engineering systems.Coq is a powerful higher-order theorem prover based on the type λ calculus.Although the Coq type system can describe variable-sized dynamic data types well,there is a lack of satisfactory description mechanisms for data types such as fixed-size vectors and matrices.At present,there is no vector library or matrix library in the Coq library,so it is more difficult to use Coq to formally verify the theorem or algorithm involving the matrix.In order to solve these problems,this paper proposed a matrix implementation method based on Record type,defined a set of basic matrix functions and proved their basic properties.The verification of the flight control transformation matrix can be done easily by using the matrix types and related lemmas provided in this paper.Compared with other matrix implementation methods,this method is not only relatively simple to implement,but also simpler and more convenient to use.

Key words: Coq, Formal verification, Matrix, Record type, Theorem proving

CLC Number: 

  • TP311
[1]吴森堂.飞行控制系统[M].北京:北京航空航天大学出版社,2013.
[2]Cook M V.Flight Dynamic Principles[M].British:Butterworth-Heinemann,2007:20-33.
[3]CHLIPALA A.Certified Programming with Dependent Types:A Pragmatic Introduction to the Coq Proof Assistant[M].The MIT Press,2011.
[4]TEAM T C D.The Coq Proof Assistant Reference Manual -- Version V8.7.1[C]∥INRIA.2016.
[5]NIPKOW T,WENZEL M,PAULSON L C.Isabelle/HOL:a proof assistant for higher-order logic[C]∥Springer-Verlag,2002:xiii-xiv.
[6]SHI Z,SONG X,ZHANG J,et al.Formalization of Matrix Theo- ry in HOL4[J].Advances in Mechanical Engineering,2014,56(5):1-14.
[7]HARRISON J.A HOL theory of euclidean space[C]∥International Conference on Theorem Proving in Higher Order Logics.Springer-Verlag,2005:114-129.
[8]MCBRIDE C.Epigram:Practical Programming with Dependent Types[M]∥Advanced Functional Programming.Springer Berlin Heidelberg,2005:130-170.
[9]MAGAUD N.Programming with Dependent Types in Coq:a Study of Square Matrices[C]∥Unpublished.2005.
[10] WILSON S,FLEURIOT J,SMAILL A.Inductive Proof Automation for Coq[R].England:The University of Edinburgh,2010:3-9.
[11] DENES M,BERTOT Y.Experiments with computable matrices in the Coq system[R].France:INRIA,2011:2-27.
[12] MULLEN E,PERNSTEINER S,WILCOX J R,et al.Euf:minimizing the Coq extraction TCB[C]∥The ACM Sigplan International Conference.ACM,2018:172-185.
[13] SOZEAU M,TABAREAU N.Universe Polymorphism in Coq[M]∥Interactive Theorem Proving.Cham:Springer,2014:499-514.
[14] ZILIANI B,SOZEAU M.A unification algorithm for Coq featuring universe polymorphism and overloading[C]∥ACM Sigplan International Conference on Functional Programming.ACM,2015:179-191.
[15] KREBBERS R,SPITTERS B.Type classes for efficient exact real arithmetic in Coq[J].Logical Methods in Computer Science,2013,9(1):51-59.
[16] BOLDO S,LELAY C,MELQUIOND G.Coquelicot:A User- Friendly Library of Real Analysis for Coq[J].Mathematics in Computer Science,2015,9(1):41-62.
[1] LI Bin, WAN Yuan. Unsupervised Multi-view Feature Selection Based on Similarity Matrix Learning and Matrix Alignment [J]. Computer Science, 2022, 49(8): 86-96.
[2] JIAN Qi-rui, CHEN Ze-mao, WU Xiao-kang. Authentication and Key Agreement Protocol for UAV Communication [J]. Computer Science, 2022, 49(8): 306-313.
[3] QI Xiu-xiu, WANG Jia-hao, LI Wen-xiong, ZHOU Fan. Fusion Algorithm for Matrix Completion Prediction Based on Probabilistic Meta-learning [J]. Computer Science, 2022, 49(7): 18-24.
[4] HE Yi-chen, MAO Yi-jun, XIE Xian-fen, GU Wan-rong. Matrix Transformation and Factorization Based on Graph Partitioning by Vertex Separator for Recommendation [J]. Computer Science, 2022, 49(6A): 272-279.
[5] LIU Yun, DONG Shou-jie. Acceleration Algorithm of Multi-channel Video Image Stitching Based on CUDA Kernel Function [J]. Computer Science, 2022, 49(6A): 441-446.
[6] HUANG Hua-wei, LI Chun-hua. Security Analysis of A Key Exchange Protocol Based on Tropical Semi-ring [J]. Computer Science, 2022, 49(6A): 571-574.
[7] WEI Peng, MA Yu-liang, YUAN Ye, WU An-biao. Study on Temporal Influence Maximization Driven by User Behavior [J]. Computer Science, 2022, 49(6): 119-126.
[8] LIANG Zhen-zhen, XU Ming. Key Agreement Scheme Based on Ocean Acoustic Channel [J]. Computer Science, 2022, 49(6): 356-362.
[9] TANG Chao-chen, QIU Hong-bing, LIU Xin, TANG Qing-hua. Angle Estimation of Coherent MIMO Radar Under the Condition of Non-uniform Noise [J]. Computer Science, 2022, 49(5): 262-265.
[10] GAO Yue, FU Xiang-ling, OUYANG Tian-xiong, CHEN Song-ling, YAN Chen-wei. EEG Emotion Recognition Based on Spatiotemporal Self-Adaptive Graph ConvolutionalNeural Network [J]. Computer Science, 2022, 49(4): 30-36.
[11] WANG Yi-han, HAO Shi-jie, HAN Xu, HONG Ri-chang. Low-light Image Enhancement Model with Low Rank Approximation [J]. Computer Science, 2022, 49(1): 187-193.
[12] DONG Xiao-mei, WANG Rui, ZOU Xin-kai. Survey on Privacy Protection Solutions for Recommended Applications [J]. Computer Science, 2021, 48(9): 21-35.
[13] ZHANG Jie, YUE Shao-hua, WANG Gang, LIU Jia-yi, YAO Xiao-qiang. Multi-agent System Based on Stackelberg and Edge Laplace Matrix [J]. Computer Science, 2021, 48(8): 253-262.
[14] YANG Hong-xin, SONG Bao-yan, LIU Ting-ting, DU Yue-feng, LI Xiao-guang. Tensor Completion Method Based on Coupled Random Projection [J]. Computer Science, 2021, 48(8): 66-71.
[15] YANG Xing-li. Survey for Performance Measure Index of Classification Learning Algorithm [J]. Computer Science, 2021, 48(8): 209-219.
Viewed
Full text


Abstract

Cited

  Shared   
  Discussed   
No Suggested Reading articles found!