Document Open Access Logo

Combinatory Logic and Lambda Calculus Are Equal, Algebraically

Authors Thorsten Altenkirch , Ambrus Kaposi , Artjoms Šinkarovs , Tamás Végh

Thumbnail PDF


  • Filesize: 0.67 MB
  • 19 pages

Document Identifiers

Author Details

Thorsten Altenkirch
  • School of Computer Science, University of Nottingham, UK
Ambrus Kaposi
  • Eötvös Loránd University, Budapest, Hungary
Artjoms Šinkarovs
  • Heriot-Watt University, Edinburgh, UK
Tamás Végh
  • Eötvös Loránd University, Budapest, Hungary

Cite AsGet BibTex

Thorsten Altenkirch, Ambrus Kaposi, Artjoms Šinkarovs, and Tamás Végh. Combinatory Logic and Lambda Calculus Are Equal, Algebraically. In 8th International Conference on Formal Structures for Computation and Deduction (FSCD 2023). Leibniz International Proceedings in Informatics (LIPIcs), Volume 260, pp. 24:1-24:19, Schloss Dagstuhl - Leibniz-Zentrum für Informatik (2023)


It is well-known that extensional lambda calculus is equivalent to extensional combinatory logic. In this paper we describe a formalisation of this fact in Cubical Agda. The distinguishing features of our formalisation are the following: (i) Both languages are defined as generalised algebraic theories, the syntaxes are intrinsically typed and quotiented by conversion; we never mention preterms or break the quotients in our construction. (ii) Typing is a parameter, thus the un(i)typed and simply typed variants are special cases of the same proof. (iii) We define syntaxes as quotient inductive-inductive types (QIITs) in Cubical Agda; we prove the equivalence and (via univalence) the equality of these QIITs; we do not rely on any axioms, the conversion functions all compute and can be experimented with.

Subject Classification

ACM Subject Classification
  • Theory of computation → Type theory
  • Combinatory logic
  • lambda calculus
  • quotient inductive types
  • Cubical Agda


  • Access Statistics
  • Total Accesses (updated on a weekly basis)
    PDF Downloads


  1. Thorsten Altenkirch and Ambrus Kaposi. Normalisation by evaluation for dependent types. In Delia Kesner and Brigitte Pientka, editors, 1st International Conference on Formal Structures for Computation and Deduction, FSCD 2016, June 22-26, 2016, Porto, Portugal, volume 52 of LIPIcs, pages 6:1-6:16. Schloss Dagstuhl - Leibniz-Zentrum für Informatik, 2016. URL:
  2. Thorsten Altenkirch and Ambrus Kaposi. Type theory in type theory using quotient inductive types. In Rastislav Bodík and Rupak Majumdar, editors, Proceedings of the 43rd Annual ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, POPL 2016, St. Petersburg, FL, USA, January 20 - 22, 2016, pages 18-29. ACM, 2016. URL:
  3. Thorsten Altenkirch, Ambrus Kaposi, Artjoms Šinkarovs, and Tamás Végh. The Münchhausen method and combinatory type theory. In Delia Kesner and Pierre-Marie Pédrot, editors, 28th International Conference on Types for Proofs and Programs (TYPES 2022). University of Nantes, 2022. URL:
  4. Robert Atkey. Syntax and semantics of quantitative type theory. In Anuj Dawar and Erich Grädel, editors, Proceedings of the 33rd Annual ACM/IEEE Symposium on Logic in Computer Science, LICS 2018, Oxford, UK, July 09-12, 2018, pages 56-65. ACM, 2018. URL:
  5. Hendrik Pieter Barendregt. The lambda calculus - its syntax and semantics, volume 103 of Studies in logic and the foundations of mathematics. North-Holland, 1985. Google Scholar
  6. Katalin Bimbó. Combinatory Logic: Pure, Applied and Typed. Taylor & Francis, 2011. Google Scholar
  7. Martin W. Bunder, J. Roger Hindley, and Jonathan P. Seldin. On adding ξ to weak equality in combinatory logic. J. Symb. Log., 54(2):590-607, 1989. URL:
  8. John Cartmell. Generalised algebraic theories and contextual categories. Ann. Pure Appl. Log., 32:209-243, 1986. URL:
  9. Simon Castellan, Pierre Clairambault, and Peter Dybjer. Categories with families: Unityped, simply typed, and dependently typed. CoRR, abs/1904.00827, 2019. URL:
  10. Haskell B. Curry, Robert Feys, and William Craig. Combinatory logic, volume i. Philosophical Review, 68(4):548-550, 1959. URL:
  11. J. Roger Hindley and Jonathan P. Seldin. Lambda-Calculus and Combinators: An Introduction. Cambridge University Press, USA, 2 edition, 2008. Google Scholar
  12. J. M. E. Hyland. Classical lambda calculus in modern dress. Math. Struct. Comput. Sci., 27(5):762-781, 2017. URL:
  13. Ambrus Kaposi. Formalisation of type checking into algebraic syntax., 2018.
  14. Ambrus Kaposi, András Kovács, and Thorsten Altenkirch. Constructing quotient inductive-inductive types. Proc. ACM Program. Lang., 3(POPL):2:1-2:24, 2019. URL:
  15. András Kovács. Type-Theoretic Signatures for Algebraic Theories and Inductive Types. PhD thesis, Eötvös Loránd University, Hungary, 2022. URL:
  16. J. Lambek and P. J. Scott. Introduction to Higher Order Categorical Logic. Cambridge University Press, USA, 1986. Google Scholar
  17. Conor McBride. Outrageous but meaningful coincidences: dependent type-safe syntax and evaluation. In Bruno C. d. S. Oliveira and Marcin Zalewski, editors, Proceedings of the ACM SIGPLAN Workshop on Generic Programming, WGP 2010, Baltimore, MD, USA, September 27-29, 2010, pages 1-12. ACM, 2010. URL:
  18. The Univalent Foundations Program. Homotopy Type Theory: Univalent Foundations of Mathematics. Institute for Advanced Study, 2013. URL:
  19. Jonathan P. Seldin. The search for a reduction in combinatory logic equivalent to λβ-reduction. Theor. Comput. Sci., 412(37):4905-4918, 2011. URL:
  20. Jonathan P. Seldin. The search for a reduction in combinatory logic equivalent to λβ-reduction, part II. Theor. Comput. Sci., 663:34-58, 2017. URL:
  21. Peter Selinger. The lambda calculus is algebraic. J. Funct. Program., 12(6):549-566, 2002. URL:
  22. Wouter Swierstra. A correct-by-construction conversion to combinators, 2021. swier004/publications/2021-jfp-submission-2.pdf. URL:
  23. William W Tait. Variable-free formalization of the Curry-Howard Theory. In Twenty Five Years of Constructive Type Theory. Oxford University Press, October 1998. URL:
  24. Andrea Vezzosi, Anders Mörtberg, and Andreas Abel. Cubical agda: A dependently typed programming language with univalence and higher inductive types. J. Funct. Program., 31:e8, 2021. URL:
  25. Philip Wadler, Wen Kokke, and Jeremy G. Siek. Programming Language Foundations in Agda. August 2022. URL:
Questions / Remarks / Feedback

Feedback for Dagstuhl Publishing

Thanks for your feedback!

Feedback submitted

Could not send message

Please try again later or send an E-mail