Deriving the Y-Combinator
Feb 28, 2026
Not that Y-combinator.
Haskell Curry’s “paradoxical” -combinator gives a fixed-point for every single term in the untyped -calculus. (Recall that in the untyped -calculus, as there is no notion of a term having type “function” or “variable,” every term may be regarded being allowed to have terms applied to it, which is in fact the crux of the derivation.)
Notions
For our purposes, our untyped -calculus will be a standard -theory, in the equational theoretic sense, in that it consists of the standard rules of the lambda calculus with the -conversion rule.
A lambda abstraction is a term of the form . A combinator is a lambda abstraction with no free terms.
A fixed point of a term is simply any term such that . Additionally, if there exists a combinator such that for any terms and we have , i.e. is a fixed point of , then we say is a fixed-point combinator.
The Y
We proceed to derive the -combinator as the proof of this theorem.
Let be any term. We basically are trying to solve for some term in the equation
Since appears in both sides, and it is not clear (nor true) that every term has the same fixed point, it’s pretty obvious our solution is going to contain the term itself . Therefore, we should search for a fixed-point combinator. We can first naively try the combinator that is the term itself. Let be arbitrary (free) and instead write
This doesn’t actually help us solve the problem at all, but it gives a hint, namely, we see . If only the left side was , then we would be done!
The key trick is to use self-reference. Write the combinator that gives
and see that . A fixed point! Now what could be? obviously works. Now just write out and bind and you recover the classical -combinator!
🎊 🎊 🎊