Lecture 8: $λlxr$-calculus vs. $λ$-calculus
Teacher: Delia Kesner
From $λlxr$ to $λ$-calculus: $B$ translation
From $λlrx$ to $λ$-calculus:
- erase epxlicit weakenings
- perform contractions via meta-theoretic substitution
Example:
\[B(λx. W_x (y)) = λx.y\\ B(λx. y C_x^{x_1, x_2}(x_1 x_2)) = λx. y(xx)\]\[M ≡ N ⟹ B(M) ≡ B(N)\]
For contraction:
\[C_w^{yz}(t)[x/u] ≡ C_w^{yz}(t[x/u]) \qquad x≠w\\ \bar t \lbrace y ← w \rbrace \lbrace z ← w \rbrace \lbrace x ← \bar u \rbrace = \bar t \lbrace x ← \bar u \rbrace \lbrace y ← w \rbrace \lbrace z ← w \rbrace\]\[M ⟶_B N ⟹ B(M) ⟶_β^\ast B(N)\]
Examples:
2.a:
\[t = x[y/II] ⟶ x[y/z[z/I]] = t'\\ B(t) = x \quad \boxed{=} \quad x = B(t')\]2.b:
\[t = II ⟶_B z[z/I] = t'\\ B(t) = II \quad \boxed{⟶_β^1} \quad I = B(t')\]2.c:
\[t = C^{yz}_x(yz)[x/II] ⟶_B C^{yz}_x(yz)[x/z[z/I]] = t'\\ B(t) = (II)(II) \quad \boxed{⟶_β^2} \quad II = B(t')\]Indeed:
\[B(C^{yz}_x(yz)[x/z[z/I]]) = (yz) \lbrace y ← x \rbrace \lbrace z ← x \rbrace \lbrace x ← z \lbrace z ← I \rbrace \rbrace\\ = (xx) \lbrace x ← I \rbrace = II\]3:
\[t= W_x(u)[x/v] ⟶_{Weak_1} W_{fv(v)}(u) = t' \qquad x ∉ fv(u)\\ B(t) = B(u) \lbrace x ← B(v) \rbrace \quad \boxed{=} \quad B(u) = B(t') \qquad x ∉ fv(B(u)) ⊆ fv(u)\]4:
\[t = C_x^{y,z}(v) [x/u] ⟶_{cont_1} C_φ^{Δ, \Pi} (v[u/u_1][z/u_2]) = t' \qquad φ, u_1, u_2 = fv(u), R_Δ^φ(u), R_\Pi^φ(u)\\ B(t) = \underbrace{B(v) \lbrace y ← x \rbrace \lbrace z ← x \rbrace \lbrace x ← \bar u \rbrace}_{ = B(v) \lbrace y ← \bar u \rbrace \lbrace z ← \bar u \rbrace = B(v) \lbrace y ← B(u)\rbrace \lbrace z ← B(u)\rbrace} \quad \boxed{=} \quad \underbrace{B(v) \lbrace y ← u_1 \rbrace \lbrace z ← u_2 \rbrace \underbrace{\lbrace Δ ← φ\rbrace}_{\text{meta-notation}} \lbrace \Pi ← φ \rbrace}_{= B(v) \lbrace y ← B(u_1) \rbrace \lbrace z ← B(u_2) \lbrace \Pi ← φ\rbrace \rbrace = B(v) \lbrace y ← B(u)\rbrace \lbrace z ← B(u)\rbrace} = B(t')\]From $λ$ to $λlxr$: $A$ translation
\[A(λx.yy) = λx. W_x (C_y^{z,z'}(zz'))\]Key point: in $λ$-calculus, when reducing from $t$ to $t’$, you can lose variables. But in $λlxr$, there’s no variable lost ⟹ mismatch between $λ$-calculus and $λlxr$:
\[λ: \qquad t ⟶_β t' ⟹ fv(t') ⊆ fv(t)\\ λlxr: \qquad t ⟶_{λlxr} t' ⟹ fv(t')=fv(t)\]Example:
\[t = (λx.y)z ⟶_β y=t' \text{ and } A(t) = (λx. W_x (y))z ⟶^+_{λlxr} W_z(A(y))\]Composition of translations
Now, what happens if you compose $A$ and $B$?
- $B(A(t)) = t$: easy
- But: \(t ⟶_{xt}^\ast W_\Pi(A(B(t)))\)
Example:
$W_z((λx.W_x(y))z’)$ is in $λlxr$, but not in the image of $A$ (because no translated term begins with a weakening).
\[t = (λx.W_x(y)) W_z(z') ⟶_{xt}^\ast W_z((λx.W_x(y))z')\\ B(t) = (λx.y)z'\\ A(B(t)) = (λx. W_x(y)) z'\]Confluence
What we want:
\[\begin{xy} \xymatrix{ & t ≡ t' \ar[ld]_{\ast}^{λlxr} \ar[rd]^{\ast}_{λlxr} & \\ \ar@{.>}[rd]_{\ast} & & \ar@{.>}[ld]^{\ast}\\ & u ≡ u' & } \end{xy}\]Lemma: $xt$-normal form of $t$: $W_{fv(t) \backslash fv(B(t))} (A(B(t)))$
Confluence: with interpretation method (Tait/Martin-Löf’s parallel reduction not enough here):
\[\begin{xy} \xymatrix{ && t ≡ t' \ar[ld]^{λlxr}_\ast \ar[rd]_{λlxr}^\ast & \\ & t_1 \ar@{->}[dd]^{s}_\ast \ar@{->}[ldd]^{xt}_\ast & & t_2 \ar@{->}[dd]_{s}^\ast\\ && B(t) = B(t') \ar[ld]^{β}_\ast \ar[rd]_{β}^\ast & \\ W_{fv(t_1) \backslash fv \, B(t_1)} A(B(t_1)) \ar@{.>}[rrdd]_{λlxr}^\ast & B(t_1) \ar@{.>}[rd]_{β}^\ast & & B(t_2) \ar@{.>}[ld]^{β}_\ast \\ && t_3 \\ && W_{fv(t_1) \backslash fv \, B(t_1)} W_{B(t_1) \backslash t_3} A(t_3) ≡ W_{fv(t_2) \backslash fv \, B(t_2)} W_{B(t_2) \backslash t_3} A(t_3) } \end{xy}\]cf. picture (not finished)
Preservation of typing
\[y:B, x:A ⊢ x:A \qquad \leadsto \qquad x:A ⊢ W_y(x): A\]Difference between $λs$-calculus and $λlxr$-calculus:
- from $λ$ to $λs$: easy, but from $λs$ to Proof nets: difficult
- from $λ$ to $λlxr$: difficult, but from $λlxr$ to Proof nets: easy
digraph {
rankdir=LR;
λ -> λs[label="easy"];
λs -> "Proof nets"[label="hard"];
λ -> λlxr[label="hard"];
λlxr -> "Proof nets"[label="easy"];
}
How do $λs$ and $λlxr$ compare?
- in $λlxr$: three resources: w(eakening), c(contraction), and [_/_] (substitution)
But we can do without any one of them (e.g. you could consider only w and c, etc…) ⟹ you get a cube of possibilities: the cube of resources (Delia Kesner, Fabien Renaud)
NB: Doing without w and c in $λlxr$ is not sufficient to get $λs$ ⟶ structural $λ$-calculus (B. Accotoli and Kesner)
\[t_{[x,x]}[x/u] ⟶ t_{[x,x']}[x/u][x'/u]\\ C[x][x/u] ⟶ C[u][x/u]\]But in the latter example: if the context $C$ is $z[z/y[y/x]]$, substitution go through two boxes: that never happens in Girard’s proof nets (and in this course, we stick with Girard’s proof nets).
Leave a comment