Recently I've started exploring lambda calculus, and currently I'm tackling the next exercise:
Prove that if $M =_{\beta\eta} N$, then $FV(M) = FV(N)$,
Where $FV(P)$ stands for free variables in the term $P$. Obviously, $\eta$-conversion doesn't affect on the free variables, since $\lambda x.Mx =_\eta M$ exactly when $x \notin FV(M)$, and $FV(\lambda x.Mx) = FV(M)$ when the same condition holds.
But what about $\beta$-reduction? It's obvious, that if $M \to_\beta N$, then $FV(N) \subseteq FV(M)$. It's also known that $\beta$-reduction can eliminate free variables, as said here or here. How then it might be possible that $FV(M) = FV(N)$ for the stated condition? The simple example $(\lambda x.y)z \to_\beta y$, and thus $(\lambda x.y)z =_\beta y$ breaks the statement. Maybe there's a typo in the exercise?
Or maybe I don't quite understand the difference between $\beta$-reduction and $\beta$-equivalence: as far as I understand, if $M \to_\beta N$, then $M =_\beta N$, and the latter, the $\beta$-equivalence, just means (by Church-Rosser) that $\exists L$ such that $M \twoheadrightarrow_\beta L$ and $N \twoheadrightarrow_\beta L$. But this facts, as I suppose, can't help me to resolve the issue.
Seems obvious that there exists such $M$ and $N$, that $M \twoheadrightarrow_\beta N$, but the converse doesn't hold. And still it's said that $M =_\beta N$. Thus $\to_\beta \subset \twoheadrightarrow_\beta \subset =_\beta$ should hold. Then, again, I don't get how the statement in the exercise above holds.
Can anyone give a hint? Thanks in advance!
Докажите, что из M =βη N следует FV (M) = FV (N), which is precisely the statement above.Also, can you give an example of the hypothesis with which the statement is true? The only I can find is something like
– Pavel Snopov May 19 '22 at 07:35any λ-term with syntax λx.M should have x in FV(M), so the caseλx.yis not applicable anymore