A Combinatorial Testing Framework for Intuitionistic Propositional Theorem Provers

  • Paul TarauEmail author
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 11372)


Proving a theorem in intuitionistic propositional logic, with implication as its single connective, is known as one of the simplest to state PSPACE-complete problem. At the same time, via the Curry-Howard isomorphism, it is instrumental to find lambda terms that may inhabit a given type.

However, as hundreds of papers witness it, all starting with Gentzen’s LJ calculus, conceptual simplicity has not come in this case with comparable computational counterparts. Implementing such theorem provers faces challenges related not only to soundness and completeness but also too termination and scalability problems.

In search for an efficient but minimalist theorem prover, on the two sides of the Curry-Howard isomorphism, we design a combinatorial testing framework using types inferred for lambda terms as well as all-term and random term generators.

We choose Prolog as our meta-language. Being derived from essentially the same formalisms as those we are covering, it reduces the semantic gap and results in surprisingly concise and efficient declarative implementations. Our implementation is available at:


Curry-Howard isomorphism Propositional implicational intuitionistic logic Type inference and type inhabitation Simply typed lambda terms Logic programming Propositional theorem provers Combinatorial testing algorithms 



This research has been supported by NSF grant 1423324. We thank the reviewers of PADL’19 for their constructive comments and suggestions for improvement.


  1. 1.
    Howard, W.: The formulae-as-types notion of construction. In: Seldin, J., Hindley, J. (eds.) To H.B. Curry: Essays on Combinatory Logic, Lambda Calculus and Formalism, pp. 479–490. Academic Press, London (1980)Google Scholar
  2. 2.
    Wadler, P.: Propositions as types. Commun. ACM 58, 75–84 (2015)CrossRefGoogle Scholar
  3. 3.
    Statman, R.: Intuitionistic propositional logic is polynomial-space complete. Theor. Comput. Sci. 9, 67–72 (1979)MathSciNetCrossRefGoogle Scholar
  4. 4.
    The Coq development team: The Coq proof assistant reference manual (2018) Version 8.8.0Google Scholar
  5. 5.
    Kostrzycka, Z., Zaionc, M.: Asymptotic densities in logic and type theory. Studia Logica 88(3), 385–403 (2008)MathSciNetCrossRefGoogle Scholar
  6. 6.
    Bendkowski, M., Grygiel, K., Tarau, P.: Random generation of closed simply typed \(\lambda \)-terms: a synergy between logic programming and Boltzmann samplers. TPLP 18(1), 97–119 (2018)MathSciNetzbMATHGoogle Scholar
  7. 7.
    Claessen, K., Hughes, J.: QuickCheck: a lightweight tool for random testing of haskell programs. SIGPLAN Not. 46(4), 53–64 (2011)CrossRefGoogle Scholar
  8. 8.
    Palka, M.H., Claessen, K., Russo, A., Hughes, J.: Testing an optimising compiler by generating random lambda terms. In: Proceedings of the 6th International Workshop on Automation of Software Test, AST 2011, pp. 91–97. ACM, New York (2011)Google Scholar
  9. 9.
    Szabo, M.E.: The collected papers of Gerhard Gentzen. Philos. Sci. 39(1), 91 (1972)Google Scholar
  10. 10.
    Dyckhoff, R.: Contraction-free sequent calculi for intuitionistic logic. J. Symbolic Logic 57(3), 795–807 (1992)MathSciNetCrossRefGoogle Scholar
  11. 11.
    Dyckhoff, R.: Intuitionistic decision procedures since Gentzen. In: Kahle, R., Strahm, T., Studer, T. (eds.) Advances in Proof Theory. PCSAL, vol. 28, pp. 245–267. Springer, Cham (2016). Scholar
  12. 12.
    Hudelmaier, J.: A PROLOG Program for Intuitionistic Logic. SNS-Bericht-. Universität Tübingen (1988)Google Scholar
  13. 13.
    Hudelmaier, J.: An O(n log n)-space decision procedure for intuitionistic propositional logic. J. Logic Comput. 3(1), 63–75 (1993)MathSciNetCrossRefGoogle Scholar
  14. 14.
    Tarau, P.: A hiking trip through the orders of magnitude: deriving efficient generators for closed simply-typed lambda terms and normal forms. In: Hermenegildo, M.V., Lopez-Garcia, P. (eds.) LOPSTR 2016. LNCS, vol. 10184, pp. 240–255. Springer, Cham (2017). Scholar
  15. 15.
    Genitrini, A., Kozik, J., Zaionc, M.: Intuitionistic vs. classical tautologies, quantitative comparison. In: Miculan, M., Scagnetto, I., Honsell, F. (eds.) TYPES 2007. LNCS, vol. 4941, pp. 100–109. Springer, Heidelberg (2008). Scholar
  16. 16.
    Rémy, J.L.: Un procédé itératif de dénombrement d’arbres binaires et son application à leur génération aléatoire. RAIRO - Theoretical Informatics and Applications - Informatique Théorique et Applications 19(2), 179–195 (1985)CrossRefGoogle Scholar
  17. 17.
    Knuth, D.E.: The Art of Computer Programming, Volume 4, Fascicle 4: Generating All Trees-History of Combinatorial Generation (Art of Computer Programming). Addison-Wesley Professional, Upper Saddle River (2006)Google Scholar
  18. 18.
    Tarau, P.: Declarative algorithms for generation, counting and random sampling of term algebras. In: Proceedings of SAC 2018, ACM Symposium on Applied Computing, PL track. ACM, Pau, April 2018Google Scholar
  19. 19.
    Stam, A.: Generation of a random partition of a finite set by an urn model. J. Comb. Theory Ser. A 35(2), 231–240 (1983)MathSciNetCrossRefGoogle Scholar
  20. 20.
    Raths, T., Otten, J., Kreitz, C.: The ILTP problem library for intuitionistic logic: release v1.1. J. Autom. Reasoning 38, 261–271 (2007)CrossRefGoogle Scholar
  21. 21.
    Herbelin, H.: A \(\lambda \)-calculus structure isomorphic to Gentzen-style sequent calculus structure. In: Pacholski, L., Tiuryn, J. (eds.) CSL 1994. LNCS, vol. 933, pp. 61–75. Springer, Heidelberg (1995). Scholar
  22. 22.
    Ben-Yelles, C.B.: Type assignment in the lambda-calculus: syntax and semantics. PhD thesis, University College of Swansea (1979)Google Scholar
  23. 23.
    Hindley, J.R.: Basic Simple Type Theory. Cambridge University Press, New York (1997)CrossRefGoogle Scholar
  24. 24.
    Gabbay, D.M., Reyle, U.: N-Prolog: an extension of prolog with hypothetical implications I. J. Logic Program. 1(4), 319–355 (1984)MathSciNetCrossRefGoogle Scholar
  25. 25.
    Gabbay, D.M.: N-Prolog: an extension of prolog with hypothetical implication II. Logical foundations, and negation as failure. J. Logic Program. 2(4), 251–283 (1985)MathSciNetCrossRefGoogle Scholar
  26. 26.
    Miller, D., Nadathur, G.: Programming with Higher-Order Logic. Cambridge University Press, New York (2012)CrossRefGoogle Scholar
  27. 27.
    Tarau, P., Dahl, V., Fall, A.: Backtrackable state with linear affine implication and assumption grammars. In: Jaffar, J., Yap, R.H.C. (eds.) ASIAN 1996. LNCS, vol. 1179, pp. 53–63. Springer, Heidelberg (1996). Scholar
  28. 28.
    Gabbay, D., Olivetti, N.: Goal-oriented deductions. In: Gabbay, D.M., Guenthner, F. (eds.) Handbook of Philosophical Logic. Handbook of Philosophical Logic, vol. 9, pp. 199–285. Springer, Dordrecht (2002). Scholar

Copyright information

© Springer Nature Switzerland AG 2019

Authors and Affiliations

  1. 1.Department of Computer Science and EngineeringUniversity of North TexasDentonUSA

Personalised recommendations