On the Representation of Imperative Programs in a Logical Framework
Research on formal verification of imperative programs using some form of representing them in a type theory has been done for years. Generally, the different approaches include a verification conditions generator, which from an annotated program including variants and invariants for while–loops and using a Hoare logic–like specification, produces some propositions to be proved in a logical framework, expressing the program correctness and termination.
In this paper we present a direct use of Coq  to model imperative programs. This method, and the fact that it is not possible to have not–ending programs in Coq, should allow a more deep understanding of imperative programs semantics , and people without big knowledge on type theory could use this theorem prover to verify imperative programs properties. This approach is based on using a fixed–point equality theorem  that represents the appropriate reduction rule to be used in our model.
In our approach no Hoare logic rules are used for verification of program specifications. This verification is achieved, in a pure constructive setting, directly with the type theory model.
KeywordsType Theory Reduction Rule Logical Framework Proof Assistant Inductive Type
Unable to display preview. Download preview PDF.
- 1.Aczel, P.: Introduction to Inductive definitions. In: Barwise, J. (ed.) Handbook of Mathematical Logic, North Holland (1997)Google Scholar
- 2.Balaa, A.: Fonctions récursives générales dans le calcul des constructions. PhD. Theése. Université de Nice–Sophia Antipolis (2002)Google Scholar
- 5.Bove, A.: Simple General Recursion in Type Theory. Technical Report. Chalmers University of Technology, Goteborg (2000)Google Scholar
- 6.Coquand, T.: An Introduction to Type Theory. Notes of the FPCL summer school, Glasgow (1989)Google Scholar
- 7.Coquand, T., Pauling-Mohring, C.: Inductively defined types. In: Martin-Löf, P., Mints, G. (eds.) COLOG-1988. LNCS, vol. 417, Springer, Heidelberg (1990)Google Scholar
- 8.Filliâtre, J.-C.: Why: a multi-language multi-prover verification tool, Research Report, LRI, 1366 (March 2003)Google Scholar
- 9.Barthe, G., Forest, J., Pichardie, D., Rusu, V.: Defining and reasoning about recursive functions: a practical tool for the Coq proof assistantGoogle Scholar
- 10.Nipkow, T.: Winskell is (almost) right: Towards a mechanised semantics test–book. In: Chandru, V., Vinay, V. (eds.) Foundations of Software Technology and Theoretical Computer Science. LNCS, vol. 1180, Springer, Heidelberg (1996)Google Scholar
- 11.Pauling-Mohring, C.: Inductive Definitions in the System Coq–Rules and Properties. In: Bezem, M., Groote, J.F. (eds.) TLCA 1993. LNCS, vol. 664, Springer, Heidelberg (1993)Google Scholar
- 12.Nordström, B.: Terminating General Recursion. BIT, vol. 28 (1988)Google Scholar
- 14.Werner, B., Paulin Mohrin, C.: ENSTA: Course Notes (1995)Google Scholar
- 15.Winskell, G.: The Formal Semantics of Programming Languages, an introduction. Foundatios of computing. The MIT Press, Cambridge (1993)Google Scholar