Β reduce a redex - Lambda Calculus.

In summary, the substitution is necessary because the free $y$ in $\lambda y.\,yx$ would become bound if it was substituted into $\lambda y.\,yx$ instead of $x$.
  • #1
JamesBwoii
74
0
As far as I understand it to reduce the formula is:

$(\lambda x.M)N -> β M[N\x]$

Where:

$β M[N\x]$ means M with every free x replaced by N.

I'm stuck on this one though.

$(\lambda x. \lambda y.yx)(\lambda x.xy)$

I know that the answer should be $\lambda z.z(\lambda x.xy)$ but I can't get it.
 
Technology news on Phys.org
  • #2
The substituted term $\lambda x.\,xy$ has a free variable $y$. If it is substituted into $\lambda y.\,yx$ instead of $x$, that free $y$ would become bound, which is wrong. Therefore, the bound $y$ in $\lambda y.\,yx$ has to be renamed first, say, to $z$; then $x$ can be replaced with $\lambda x.\,xy$.

See Wikipedia for the definition of substitution and an example where renaming is necessary. Here are two other examples (renaming is required at some point in finding the normal form, not necessarily during the first reduction).

\((\lambda x.xx)(\lambda yz.yz)\)
\(\lambda xy.(\lambda z.(\lambda x.zx)(\lambda y.zy))(xy)\)

Edit: Does your course really use backslash to denote substitutions? If so, use the [m]\backslash[/m] command in math mode, e.g., $(\lambda x.\,M)N\to_{\beta} M[N\backslash x]$.
 
  • #3
Evgeny.Makarov said:
The substituted term $\lambda x.\,xy$ has a free variable $y$. If it is substituted into $\lambda y.\,yx$ instead of $x$, that free $y$ would become bound, which is wrong. Therefore, the bound $y$ in $\lambda y.\,yx$ has to be renamed first, say, to $z$; then $x$ can be replaced with $\lambda x.\,xy$.

See Wikipedia for the definition of substitution and an example where renaming is necessary. Here are two other examples (renaming is required at some point in finding the normal form, not necessarily during the first reduction).

\((\lambda x.xx)(\lambda yz.yz)\)
\(\lambda xy.(\lambda z.(\lambda x.zx)(\lambda y.zy))(xy)\)

Edit: Does your course really use backslash to denote substitutions? If so, use the [m]\backslash[/m] command in math mode, e.g., $(\lambda x.\,M)N\to_{\beta} M[N\backslash x]$.

Thank you, I understand it now. :)
 

Related to Β reduce a redex - Lambda Calculus.

1. What is a redex in Lambda Calculus?

A redex (reducible expression) in Lambda Calculus is a term that can be reduced to a simpler form by applying a specific set of rules, known as beta reduction. It is denoted by the symbol β.

2. How is beta reduction used to reduce a redex?

Beta reduction is applied by replacing the redex with its corresponding function and argument, and then simplifying the resulting expression. This process is repeated until there are no more redexes that can be reduced.

3. What is the purpose of reducing redexes in Lambda Calculus?

The reduction of redexes allows for the evaluation of expressions in Lambda Calculus, which is essential for performing computations. It also helps to simplify complex expressions and better understand the behavior of functions.

4. Can all redexes be reduced?

No, not all redexes can be reduced. There are certain rules and restrictions in Lambda Calculus that dictate when a redex can be reduced and when it cannot. For example, a redex cannot be reduced if it is part of a lambda abstraction or if it is already in its simplest form.

5. Are there any alternative methods for reducing redexes in Lambda Calculus?

Yes, there are other reduction strategies such as alpha and eta reduction, which are based on different rules and can result in different outcomes. However, beta reduction is the most commonly used method for reducing redexes in Lambda Calculus.

Similar threads

  • Beyond the Standard Models
Replies
3
Views
441
  • Quantum Physics
Replies
5
Views
930
Replies
3
Views
645
  • Introductory Physics Homework Help
Replies
5
Views
499
  • Calculus and Beyond Homework Help
Replies
2
Views
855
  • Calculus and Beyond Homework Help
Replies
1
Views
735
Replies
2
Views
4K
Replies
2
Views
2K
Replies
2
Views
696
  • Calculus and Beyond Homework Help
Replies
9
Views
1K
Back
Top