Skip to main content
Top

2017 | OriginalPaper | Chapter

Programming and Proving with Classical Types

Authors : Cristina Matache, Victor B. F. Gomes, Dominic P. Mulligan

Published in: Programming Languages and Systems

Publisher: Springer International Publishing

Activate our intelligent search to find suitable subject content or patents.

search-config
loading …

Abstract

The propositions-as-types correspondence is ordinarily presented as linking the metatheory of typed \(\lambda \)-calculi and the proof theory of intuitionistic logic. Griffin observed that this correspondence could be extended to classical logic through the use of control operators. This observation set off a flurry of further research, leading to the development of Parigot’s \(\lambda \mu \)-calculus. In this work, we use the \(\lambda \mu \)-calculus as the foundation for a system of proof terms for classical first-order logic. In particular, we define an extended call-by-value \(\lambda \mu \)-calculus with a type system in correspondence with full classical logic. We extend the language with polymorphic types, add a host of data types in ‘direct style’, and prove several metatheoretical properties. All of our proofs and definitions are mechanised in Isabelle/HOL, and we automatically obtain an interpreter for a system of proof terms cum programming language—called \(\mu \)ML—using Isabelle’s code generation mechanism. Atop our proof terms, we build a prototype LCF-style interactive theorem prover—called \(\mu \)TP—for classical first-order logic, capable of synthesising \(\mu \)ML programs from completed tactic-driven proofs. We present example closed \(\mu \)ML programs with classical tautologies for types, including some inexpressible as closed programs in the original \(\lambda \mu \)-calculus, and some example tactic-driven \(\mu \)TP proofs of classical tautologies.

Dont have a licence yet? Then find out more about our products and how to get one now:

Springer Professional "Wirtschaft+Technik"

Online-Abonnement

Mit Springer Professional "Wirtschaft+Technik" erhalten Sie Zugriff auf:

  • über 102.000 Bücher
  • über 537 Zeitschriften

aus folgenden Fachgebieten:

  • Automobil + Motoren
  • Bauwesen + Immobilien
  • Business IT + Informatik
  • Elektrotechnik + Elektronik
  • Energie + Nachhaltigkeit
  • Finance + Banking
  • Management + Führung
  • Marketing + Vertrieb
  • Maschinenbau + Werkstoffe
  • Versicherung + Risiko

Jetzt Wissensvorsprung sichern!

Springer Professional "Technik"

Online-Abonnement

Mit Springer Professional "Technik" erhalten Sie Zugriff auf:

  • über 67.000 Bücher
  • über 390 Zeitschriften

aus folgenden Fachgebieten:

  • Automobil + Motoren
  • Bauwesen + Immobilien
  • Business IT + Informatik
  • Elektrotechnik + Elektronik
  • Energie + Nachhaltigkeit
  • Maschinenbau + Werkstoffe




 

Jetzt Wissensvorsprung sichern!

Springer Professional "Wirtschaft"

Online-Abonnement

Mit Springer Professional "Wirtschaft" erhalten Sie Zugriff auf:

  • über 67.000 Bücher
  • über 340 Zeitschriften

aus folgenden Fachgebieten:

  • Bauwesen + Immobilien
  • Business IT + Informatik
  • Finance + Banking
  • Management + Führung
  • Marketing + Vertrieb
  • Versicherung + Risiko




Jetzt Wissensvorsprung sichern!

Footnotes
1
Strictly speaking, our evaluation strategy is a call-by-weak-head-normal-form. A pure call-by-value \(\lambda \mu \)-calculus could get stuck when evaluating an application whose argument is a \(\mu \)-abstraction, which is undesirable. We retain the terminology call-by-value since it gives a better intuition of the desired behaviour.
 
3
Note that formulae are currently manually constructed, due to the lack of a parser.
 
Literature
[AHS04]
go back to reference Ariola, Z.M., Herbelin, H., Sabry, A.: A type-theoretic foundation of continuations and prompts. In: ICFP (2004) Ariola, Z.M., Herbelin, H., Sabry, A.: A type-theoretic foundation of continuations and prompts. In: ICFP (2004)
[BB94]
go back to reference Barbanera, F., Berardi, S.: A symmetric lambda calculus for “classical” program extraction. In: TACS (1994) Barbanera, F., Berardi, S.: A symmetric lambda calculus for “classical” program extraction. In: TACS (1994)
[BB95]
[BBS97]
go back to reference Barbanera, F., Berardi, S., Schivalocchi, M.: “Classical” programming-with-proofs in \(\lambda _{\sf Sym\sf ^{\sf PA}}\): an analysis of non-confluence. In: TACS (1997) Barbanera, F., Berardi, S., Schivalocchi, M.: “Classical” programming-with-proofs in \(\lambda _{\sf Sym\sf ^{\sf PA}}\): an analysis of non-confluence. In: TACS (1997)
[Ber03]
go back to reference Berghofer, S.: Proofs, programs and executable specifications in higher order logic. Ph.D. thesis, Technical University Munich, Germany (2003) Berghofer, S.: Proofs, programs and executable specifications in higher order logic. Ph.D. thesis, Technical University Munich, Germany (2003)
[BHS97]
go back to reference Barthe, G., Hatcliff, J., Sørensen, M.H.: A notion of classical pure type system. Electron. Notes Theor. Comput. Sci. 6, 4–59 (1997)MathSciNetCrossRefMATH Barthe, G., Hatcliff, J., Sørensen, M.H.: A notion of classical pure type system. Electron. Notes Theor. Comput. Sci. 6, 4–59 (1997)MathSciNetCrossRefMATH
[BU02]
go back to reference Barthe, G., Uustalu, T.: CPS translating inductive and coinductive types. In: PEPM (2002) Barthe, G., Uustalu, T.: CPS translating inductive and coinductive types. In: PEPM (2002)
[BW05]
go back to reference Barendregt, H., Wiedijk, F.: The challenge of computer mathematics. Philos. Trans. A 363, 2005 (1835)MATH Barendregt, H., Wiedijk, F.: The challenge of computer mathematics. Philos. Trans. A 363, 2005 (1835)MATH
[CP11]
go back to reference Crolard, T., Polonowski, E.: A program logic for higher-order procedural variables and non-local jumps. CoRR, abs/1112.1554 (2011) Crolard, T., Polonowski, E.: A program logic for higher-order procedural variables and non-local jumps. CoRR, abs/1112.1554 (2011)
[dB72]
go back to reference de Bruijn, N.G.: Lambda calculus notation with nameless dummies, a tool for automatic formula manipulation, with application to the Church-Rosser theorem. Indagationes Mathematicae 75(5), 381–392 (1972)MathSciNetCrossRefMATH de Bruijn, N.G.: Lambda calculus notation with nameless dummies, a tool for automatic formula manipulation, with application to the Church-Rosser theorem. Indagationes Mathematicae 75(5), 381–392 (1972)MathSciNetCrossRefMATH
[dG94a]
go back to reference de Groote, P.: A CPS-translation of the lambda-\(\mu \)-calculus. In: CAAP (1994) de Groote, P.: A CPS-translation of the lambda-\(\mu \)-calculus. In: CAAP (1994)
[dG98]
go back to reference de Groote, P.: An environment machine for the \(\lambda \mu \)-calculus. Math. Struct. Comput. Sci. 8(6), 637–669 (1998)MathSciNetCrossRef de Groote, P.: An environment machine for the \(\lambda \mu \)-calculus. Math. Struct. Comput. Sci. 8(6), 637–669 (1998)MathSciNetCrossRef
[FFKD87]
go back to reference Felleisen, M., Friedman, D.P., Kohlbecker, E.E., Duba, B.F.: A syntactic theory of sequential control. Theor. Comput. Sci. 52, 205–237 (1987)MathSciNetCrossRefMATH Felleisen, M., Friedman, D.P., Kohlbecker, E.E., Duba, B.F.: A syntactic theory of sequential control. Theor. Comput. Sci. 52, 205–237 (1987)MathSciNetCrossRefMATH
[Gir71]
go back to reference Girard, J.-Y.: Une extension de l’interprétation de Gödel à l’analyse et son application à l’élimination des coupures dans l’analyse et la théorie des types. In: Proceedings of the Second Scandinavian Logic Symposium (1971) Girard, J.-Y.: Une extension de l’interprétation de Gödel à l’analyse et son application à l’élimination des coupures dans l’analyse et la théorie des types. In: Proceedings of the Second Scandinavian Logic Symposium (1971)
[GKM13]
[Göd58]
[Gor91]
go back to reference Gordon, M.J.C.: Introduction to the HOL system. In: HOL (1991) Gordon, M.J.C.: Introduction to the HOL system. In: HOL (1991)
[Gri90]
go back to reference Griffin, T.: A formulae-as-types notion of control. In: POPL (1990) Griffin, T.: A formulae-as-types notion of control. In: POPL (1990)
[HH14]
go back to reference Huet, G.P., Herbelin, H.: 30 years of research and development around Coq. In: POPL (2014) Huet, G.P., Herbelin, H.: 30 years of research and development around Coq. In: POPL (2014)
[Kri16]
go back to reference Krivine, J-L.: Bar recursion in classical realisability: dependent choice and continuum hypothesis. In: CSL pp. 25:1–25:11 (2016) Krivine, J-L.: Bar recursion in classical realisability: dependent choice and continuum hypothesis. In: CSL pp. 25:1–25:11 (2016)
[MGM17]
go back to reference Matache, C., Gomes, V.B.F., Mulligan, D.P.: The \(\lambda \mu \)-calculus. Archive of Formal Proofs (2017) Matache, C., Gomes, V.B.F., Mulligan, D.P.: The \(\lambda \mu \)-calculus. Archive of Formal Proofs (2017)
[Mur91]
go back to reference Murthy, C.R.: An evaluation semantics for classical proofs. In: LICS (1991) Murthy, C.R.: An evaluation semantics for classical proofs. In: LICS (1991)
[OS97]
go back to reference Ong, C.-H.L., Stewart, C.A.: A Curry-Howard foundation for functional computation with control. In: POPL. ACM Press (1997) Ong, C.-H.L., Stewart, C.A.: A Curry-Howard foundation for functional computation with control. In: POPL. ACM Press (1997)
[Par93b]
go back to reference Parigot, M.: Strong normalization for second order classical natural deduction. In: LICS (1993) Parigot, M.: Strong normalization for second order classical natural deduction. In: LICS (1993)
[Par97]
[PRG17]
go back to reference Pottier, F., Régis-Gianas, Y.: The Menhir parser generator (2017) Pottier, F., Régis-Gianas, Y.: The Menhir parser generator (2017)
[Py98]
go back to reference Py, W.: Confluence en \(\lambda \mu \)-calcul. Ph.D. thesis (1998) Py, W.: Confluence en \(\lambda \mu \)-calcul. Ph.D. thesis (1998)
[RS94]
go back to reference Rehof, J., Sørensen, M.H.: The \(\lambda _{\Delta }\)-calculus. In: TACS (1994) Rehof, J., Sørensen, M.H.: The \(\lambda _{\Delta }\)-calculus. In: TACS (1994)
Metadata
Title
Programming and Proving with Classical Types
Authors
Cristina Matache
Victor B. F. Gomes
Dominic P. Mulligan
Copyright Year
2017
DOI
https://doi.org/10.1007/978-3-319-71237-6_11

Premium Partner