Theory of Computing Systems

, Volume 51, Issue 3, pp 313–329 | Cite as

Proofs, Programs, Processes

  • Ulrich Berger
  • Monika Seisenberger


The objective of this paper is to provide a theoretical foundation for program extraction from inductive and coinductive proofs geared to practical applications. The novelties consist in the addition of inductive and coinductive definitions to a realizability interpretation for first-order proofs, a soundness proof for this system, and applications to the synthesis of non-trivial provably correct programs in the area of exact real number computation. We show that realizers, although per se untyped, can be assigned polymorphic recursive types and hence represent valid programs in a lazy functional programming language such as Haskell. Programs extracted from proofs using coinduction can be understood as perpetual processes producing infinite streams of data. Typical applications of such processes are computations in exact real arithmetic. As an example we show how to extract a program computing the average of two real numbers w.r.t. the binary signed digit representation.


Program extraction Realizability Coinduction Verified programs Exact real number computation 


Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.


  1. 1.
    Benl, H., Berger, U., Schwichtenberg, H., Seisenberger, M., Zuber, W.: Proof theory at work: Program development in the Minlog system. In: Bibel, W., Schmitt, P.H. (eds.) Automated Deduction—A Basis for Applications. Applied Logic Series, vol. II, pp. 41–71. Kluwer, Dordrecht (1998) Google Scholar
  2. 2.
    Berger, U.: From coinductive proofs to exact real arithmetic: theory and applications. Log. Methods Comput. Sci. 7(1), (2011) Google Scholar
  3. 3.
    Bertot, Y.: Affine functions and series with co-inductive real numbers. Math. Struct. Comput. Sci. 17, 37–63 (2007) MathSciNetzbMATHCrossRefGoogle Scholar
  4. 4.
    Berger, U.: From coinductive proofs to exact real arithmetic. In: Grädel, E., Kahle, R. (eds.) Computer Science Logic. Lecture Notes in Comput. Sci., vol. 5771 pp. 132–146. Springer, Berlin (2009) CrossRefGoogle Scholar
  5. 5.
    Berger, U.: Realisability for induction and coinduction with applications to constructive analysis. J. Univers. Comput. Sci. 16(18), 2535–2555 (2010) zbMATHGoogle Scholar
  6. 6.
    Buchholz, W., Feferman, F., Pohlers, W., Sieg, W.: Iterated Inductive Definitions and Subsystems of Analysis: Recent Proof–Theoretical Studies. Lecture Notes in Mathematics, vol. 897. Springer, Berlin (1981) zbMATHGoogle Scholar
  7. 7.
    Berger, U., Hou, T.: Coinduction for exact real number computation. Theory Comput. Syst. 43, 394–409 (2008) MathSciNetzbMATHCrossRefGoogle Scholar
  8. 8.
    Berger, U., Seisenberger, M.: Proofs, programs, processes. In: Ferreira, F., Löwe, B., Mayordomo, E., Gomes, L.M. (eds.) Programs, Proofs, Processes, 6th Conference on Computability in Europe, CiE 2010, Ponta Delgada, Azores, Portugal, June 30–July 4, 2010. Proceedings of Lecture Notes in Comput. Sci., vol. 6158, pp. 39–48. (2010) Google Scholar
  9. 9.
    Ciaffaglione, A., Di Gianantonio, P.: A certified, corecursive implementation of exact real numbers. Theor. Comput. Sci. 351, 39–51 (2006) zbMATHCrossRefGoogle Scholar
  10. 10.
    The Coq Proof Assistant.
  11. 11.
    Edalat, A., Heckmann, R.: Computing with real numbers: I. The LFT approach to real number computation; II. A domain framework for computational geometry. In: Barthe, G., Dybjer, P., Pinto, L., Saraiva, J. (eds.) Applied Semantics—Lecture Notes from the International Summer School, Caminha, Portugal, pp. 193–267. Springer, Berlin (2002) Google Scholar
  12. 12.
    Ghani, N., Hancock, P., Pattinson, D.: Continuous functions on final coalgebras. Electron. Notes Theor. Comput. Sci. 164, 141–155 (2006) MathSciNetCrossRefGoogle Scholar
  13. 13.
    Geuvers, H., Niqui, M., Spitters, B., Wiedijk, F.: Constructive analysis, types and exact real numbers. Math. Struct. Comput. Sci. 17(1), 3–36 (2007) MathSciNetzbMATHCrossRefGoogle Scholar
  14. 14.
    Hernest, M.D., Oliva, P.: Hybrid functional interpretations. In: Beckmann, A., Dimitracopoulos, C., Löwe, B. (eds.) CiE 2008: Logic and Theory of Algorithms. Lecture Notes in Comput. Sci., vol. 5028, pp. 251–260. Springer, Berlin (2008) CrossRefGoogle Scholar
  15. 15.
    Krivine, J.-L.: Dependent choice, ‘quote’ and the clock. Theor. Comput. Sci. 308, 259–276 (2003) MathSciNetzbMATHCrossRefGoogle Scholar
  16. 16.
  17. 17.
    Miranda-Perea, F.: Realizability for monotone clausular (co)inductive definitions. Electron. Notes Theor. Comput. Sci. 123, 179–193 (2005) MathSciNetCrossRefGoogle Scholar
  18. 18.
    Marcial-Romero, J.R., Escardo, M.H.: Semantics of a sequential language for exact real-number computation. Theor. Comput. Sci. 379(1–2), 120–141 (2007) MathSciNetzbMATHCrossRefGoogle Scholar
  19. 19.
    Niqui, M.: Coinductive formal reasoning in exact real arithmetic. Log. Methods Comput. Sci. 4(3–6), 1–40 (2008) MathSciNetGoogle Scholar
  20. 20.
    Plume, D.: A calculator for exact real number computation. Master’s thesis, University of Edinburgh, 1998 Google Scholar
  21. 21.
    Ratiu, D., Trifonov, T.: Exploring the computational content of the infinite pigeonhole principle. J. Logic Comput. doi: 10.1093/logcom/exq011
  22. 22.
    Schwichtenberg, H.: Realizability interpretation of proofs in constructive analysis. Theory Comput. Syst. 43(3–4), 583–602 (2008) MathSciNetzbMATHCrossRefGoogle Scholar
  23. 23.
    Tatsuta, M.: Realizability of monotone coinductive definitions and its application to program synthesis. In: Parikh, R. (ed.) Mathematics of Program Construction. Lecture Notes in Mathematics, vol. 1422, pp. 338–364. Springer, Berlin (1998) CrossRefGoogle Scholar

Copyright information

© Springer Science+Business Media, LLC 2011

Authors and Affiliations

  1. 1.Swansea UniversityWalesUK

Personalised recommendations