Abstract
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 [3] 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 [15], 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 [2] 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.
Supported by: MEC, Spain, Project TIN2005-08986. FARMHANDS.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
References
Aczel, P.: Introduction to Inductive definitions. In: Barwise, J. (ed.) Handbook of Mathematical Logic, North Holland (1997)
Balaa, A.: Fonctions récursives générales dans le calcul des constructions. PhD. Theése. Université de Nice–Sophia Antipolis (2002)
Bertot, I., Castéran, P.: Interactive Theorem Proving and Program Development. Springer, Heidelberg (2004)
Bertot, I., Capretta, V., Barman, K.: Type–Theoretic Functional Semantics. In: Carreño, V.A., Muñoz, C.A., Tahar, S. (eds.) TPHOLs 2002. LNCS, vol. 2410, pp. 83–97. Springer, Heidelberg (2002)
Bove, A.: Simple General Recursion in Type Theory. Technical Report. Chalmers University of Technology, Goteborg (2000)
Coquand, T.: An Introduction to Type Theory. Notes of the FPCL summer school, Glasgow (1989)
Coquand, T., Pauling-Mohring, C.: Inductively defined types. In: Martin-Löf, P., Mints, G. (eds.) COLOG-1988. LNCS, vol. 417, Springer, Heidelberg (1990)
Filliâtre, J.-C.: Why: a multi-language multi-prover verification tool, Research Report, LRI, 1366 (March 2003)
Barthe, G., Forest, J., Pichardie, D., Rusu, V.: Defining and reasoning about recursive functions: a practical tool for the Coq proof assistant
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)
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)
Nordström, B.: Terminating General Recursion. BIT, vol. 28 (1988)
Pfenning, F., Pauling-Mohring, C.: Inductively defined types in the Calculus of Constructions. In: Schmidt, D.A., Main, M.G., Melton, A.C., Mislove, M.W. (eds.) Mathematical Foundations of Programming Semantics. LNCS, vol. 442, Springer, Heidelberg (1990)
Werner, B., Paulin Mohrin, C.: ENSTA: Course Notes (1995)
Winskell, G.: The Formal Semantics of Programming Languages, an introduction. Foundatios of computing. The MIT Press, Cambridge (1993)
Author information
Authors and Affiliations
Editor information
Rights and permissions
Copyright information
© 2007 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Nistal, J.L.F., Brañas, E.F., Ferro, A.B., Cabrero Souto, D. (2007). On the Representation of Imperative Programs in a Logical Framework. In: Moreno Díaz, R., Pichler, F., Quesada Arencibia, A. (eds) Computer Aided Systems Theory – EUROCAST 2007. EUROCAST 2007. Lecture Notes in Computer Science, vol 4739. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-540-75867-9_26
Download citation
DOI: https://doi.org/10.1007/978-3-540-75867-9_26
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-75866-2
Online ISBN: 978-3-540-75867-9
eBook Packages: Computer ScienceComputer Science (R0)