Simply typed lambda calculus
The simply typed lambda calculus ( ), a form of type theory, is a typed interpretation of the lambda calculus with only one type constructor ( ) that builds function types.[src] It is the canonical and simplest example of a typed lambda calculus.[src] The simply typed lambda calculus was originally introduced by Alonzo Church in 1940 as an attempt to avoid paradoxical use of the untyped lambda calculus.[src] The term simple type is also used to refer to extensions of the simply typed lambda calculus with constructs such as products, coproducts or natural numbers (System T) or even full recursion (like PCF).[src] In contrast, systems that introduce polymorphic types (like System F) or dependent types (like the Logical Framework) are not considered simply typed.[src] The simple types, except for full recursion, are still considered simple because the Church encodings of such structures can be done using only \to and suitable type variables, while polymorphism and dependency cannot.[src]
The simply typed lambda calculus ( ), a form of type theory, is a typed interpretation of the lambda calculus with only one type constructor ( ) that builds function types.[src] It is the canonical and simplest example of a typed lambda calculus.[src] The simply typed lambda calculus was originally introduced by Alonzo Church in 1940 as an attempt to avoid paradoxical use of the untyped lambda calculus.[src] The term simple type is also used to refer to extensions of the simply typed lambda calculus with constructs such as products, coproducts or natural numbers (System T) or even full recursion (like PCF).[src] In contrast, systems that introduce polymorphic types (like System F) or dependent types (like the Logical Framework) are not considered simply typed.[src] The simple types, except for full recursion, are still considered simple because the Church encodings of such structures can be done using only \to and suitable type variables, while polymorphism and dependency cannot.[src] \tau \;{{:}{:=}}\; \tau \to \tau \mid T \quad \mathrm{where} \quad T \in B .[src] For example, , generates an infinite set of types starting with , , , , , , , ..., , ...[src] A set of term constants is also fixed for the base types.[src] For example, it might be assumed that one of the base types is , and its term constants could be the natural numbers.[src] The syntax of the simply typed lambda calculus is essentially that of the lambda calculus itself.[src] The term x\mathbin{:}\tau denotes that the variable x is of type .[src] The term syntax, in Backus–Naur form, is variable reference, abstractions, application, or constant: e \;{{:}{:=}}\; x \mid \lambda x\mathbin{:}\tau.e \mid e \, e \mid c where c is a term constant.[src] A variable reference x is bound if it is inside of an abstraction binding .[src] A term is closed if there are no unbound variables.[src] In comparison, the syntax of untyped lambda calculus has no such typing or term constants: e \;{{:}{:=}}\; x \mid \lambda x.e \mid e \, e Whereas in typed lambda calculus every abstraction (i.e.[src] function) must specify the type of its argument.[src] o(\iota \to \iota \to \iota) = 1 o((\iota \to \iota) \to \iota) = 2 (\lambda x\mathbin{:}\sigma.t)\,u =_{\beta} t[x:=u] holds in context \Gamma whenever \Gamma,x\mathbin{:}\sigma \vdash t\mathbin{:}\tau and , while the equation for eta reduction \lambda x\mathbin{:}\sigma.t\,x =_\eta t holds whenever \Gamma\vdash t{:}\sigma \to \tau and x does not appear free in .[src] The advantage of typed lambda calculus is that STLC allows potentially nonterminating computations to be cut short (that is, reduced).[src] \pi_1(s\mathbin{:}\sigma,t\mathbin{:}\tau) = s\mathbin{:}\sigma \pi_2(s\mathbin{:}\sigma,t\mathbin{:}\tau) = t\mathbin{:}\tau (\pi_1(u\mathbin{:}\sigma\times\tau) , \pi_2(u\mathbin{:}\sigma\times\tau)) =u\mathbin{:}\sigma\times\tau t\mathbin{:}1 = () This last is read as "if t has type 1, then it reduces to nil".[src] The above can then be turned into a category by taking the types as the objects.[src] The morphisms \sigma\to\tau are equivalence classes of pairs (x\mathbin{:}\sigma, t\mathbin{:}\tau) where x is a variable (of type ) and t is a term (of type ), having no free variables in it, except for (optionally) x.[src] The set of terms in the language is the closure of this set of terms under the operations of abstraction and application.[src] This correspondence can be extended to include "language homomorphisms" and functors between the category of Cartesian closed categories, and the category of simply typed lambda theories.[src] Part of this correspondence can be extended to closed symmetric monoidal categories by using a linear type system.[src] To check that e has type , it suffices to synthesize type .[src] If e checks against type , then the explicitly annotated term (e\mathbin{:}\tau) synthesizes .[src] Because of these last two rules coercing between synthesis and checking, it is easy to see that any well-typed but unannotated term can be checked in the bidirectional system, so long as we insert "enough" type annotations.[src] And in fact, annotations are needed only at β-redexes.[src]
35 sentences · 35 cited inline · 0 references stored
References
No reference rows published for this article.
Cite this article
MLA
"Simply typed lambda calculus." encyclopegia.org, 2026, https://encyclopegia.org/wiki/simply-typed-lambda-calculus. Accessed 04 December 2026.
Chicago
"Simply typed lambda calculus." encyclopegia.org. Accessed December 4, 2026. https://encyclopegia.org/wiki/simply-typed-lambda-calculus.
APA
encyclopegia.org. (2026). Simply typed lambda calculus. Retrieved December 4, 2026, from https://encyclopegia.org/wiki/simply-typed-lambda-calculus
Accessed December 4, 2026 · CC BY-SA 4.0 · citation page · JSON