Published online by Cambridge University Press: 29 May 2025
14.1 The formal system
The beauty of the λ-calculus is that it achieves Turing completeness - all computable functions are definable in it - with a very simple syntax. The basic operators of the λ-calculus, in its pure form, are λ-abstraction, for forming functions, and application, for applying a function to an argument. A λ-abstraction has the form λx. M: in the body M of the function, the variable x is a place-holder for the argument. (We stick to the standard λ-calculus terminology, and call x a variable, rather than a name.) Letting x and y range over the set of λ-calculus variables, the set Λ of λ-terms is defined by the grammar
In λx. M, the initial x is a static binder, binding all free occurrences of x in M. As we have already met static binders in previous chapters, we omit the definitions of α-conversion, free variable, substitution, etc. We identify α-convertible terms, and therefore write M = N if M and N are α-convertible. A λ-term is closed if it contains no free variables. The set of free variables of a term M is written fv(M). The subset of A containing only the closed terms is Λ0.
To avoid too many brackets, we assume that application associates to the left, so that MNL should be read (MN)L, and that the scope of a A extends as far as possible to the right, so that λx.MN should be read λx. (MN). We also abbreviate λx1 …. λxn.M to λx1 … xn.M, or λx. M if the length of x is not important. We follow Barendregt [Bar84] and Hindlev and Seldin [HS86] in notations and terminology for the λ-calculus.
The basic computational step of the λ-calculus is β-reduction:
in which the placeholder x is replaced by the argument N in the body M of the function. An expression of the form (λx.M)N is called a β-redex, and the derivative is its contractum.
To save this book to your Kindle, first ensure no-reply@cambridge.org is added to your Approved Personal Document E-mail List under your Personal Document Settings on the Manage Your Content and Devices page of your Amazon account. Then enter the ‘name’ part of your Kindle email address below. Find out more about saving to your Kindle.
Note you can select to save to either the @free.kindle.com or @kindle.com variations. ‘@free.kindle.com’ emails are free but can only be saved to your device when it is connected to wi-fi. ‘@kindle.com’ emails can be delivered even when you are not connected to wi-fi, but note that service fees apply.
Find out more about the Kindle Personal Document Service.
To save content items to your account, please confirm that you agree to abide by our usage policies. If this is the first time you use this feature, you will be asked to authorise Cambridge Core to connect with your account. Find out more about saving content to Dropbox.
To save content items to your account, please confirm that you agree to abide by our usage policies. If this is the first time you use this feature, you will be asked to authorise Cambridge Core to connect with your account. Find out more about saving content to Google Drive.