next up previous contents
Next: Life without types Up: The (untyped) lambda calculus Previous: The (untyped) lambda calculus   Contents

Syntax

The set of lambda expressions is generated by what we would, in modern day computer science terminology, call a context-free grammar.

Let Var be a countably infinite set of variables. We define the set $\Lambda$ of lambda expressions as follows:


\begin{displaymath}
\Lambda = x \mid \lambda x.M \mid M M'
\end{displaymath}

where $x \in Var$ and $M,M' \in \Lambda$.

Thus, the syntax of lambda expressions contains two ways to generate new expressions from old ones. The construction $\lambda x.M$ is called abstraction, while the construction $M M'$ is called application.

The intention is that $\lambda x.M$ is an expression representing a function of $x$ whose body (or rule for computation) is given by $M$. Thus, $\lambda x.M$ ``abstracts'' the computation rule described in M to operate on arbitrary input values $x$. This is analogous to writing $f(x) = M$ without having to assign an unnecessary ``name'' $f$ to the function (after all, $f(x) = M$ and $g(x) = M$ are clearly the same function, so the names $f$ and $g$ carry no significance.)

The expression $M M'$ is intended to represent the action of ``applying'' the function encoded by $M$ to the argument $M'$.


next up previous contents
Next: Life without types Up: The (untyped) lambda calculus Previous: The (untyped) lambda calculus   Contents
Madhavan Mukund 2004-04-29