Cartesian calculus of substitutions

Substitution extension by a type

Given Δ ⊢𝛾 :Γ and Γ ⊢𝐴, we can define the extension 𝛾.𝐴 of 𝛾 by 𝐴 as

Δ.𝐴[𝛾]⊢𝛾.𝐴=(𝛾∘𝐩).𝐪:Γ.𝐴.

with the derivation

Δ⊢𝛾:ΓΔ⊢𝛾:ΓΓ⊢𝐴Δ⊢𝐴[𝛾]Δ.𝐴[𝛾]⊢𝐩Γ,𝐴[𝛾]:ΔΔ.𝐴[𝛾]⊢𝛾∘𝐩Γ,𝐴[𝛾]:ΓΓ⊢𝐴Δ⊢𝛾:ΓΓ⊢𝐴Δ⊢𝐴[𝛾]Δ.𝐴[𝛾]⊢𝐪Γ,𝐴[𝛾]:𝐴[𝛾∘𝐩](V)Δ.𝐴[𝛾]⊢(𝛾∘𝐩Γ,𝐴[𝛾]).𝐪Γ,𝐴[𝛾]:Γ.𝐴(E)

Properties

The following are derivable:

  1. Ξ⊢𝛿:ΔΔ⊢𝛾:ΓΞ⊢𝑎:𝐴[𝛾∘𝛿]Ξ⊢𝛾.𝐴∘𝛿.𝑎=(𝛾∘𝛿).𝑎:Γ.𝐴(⇒)
  2. Ξ⊢𝛿:ΔΔ⊢𝛾:ΓΓ⊢𝐴Ξ.𝐴[𝛾∘𝛿]⊢𝛾.𝐴∘𝛿.𝐴[𝛾]=(𝛾∘𝛿).𝐴:Γ.𝐴(⇒)
  3. Γ⊢𝐴Γ.𝐴⊢𝐢𝐝.𝐴=𝐢𝐝:Γ.𝐴(⇒)
Proof of 1–3

For ^P1, expanding definitions and using ^P2 gives

𝛾.𝐴∘𝛿.𝑎=(𝛾∘𝐩).𝐪∘𝛿.𝑎=(𝛾∘𝐩∘𝛿.𝑎).𝐪[𝛿.𝑎]=(𝛾∘𝛿).𝑎

completing the proof of ^P1.

Applying this result to ^P2 gives

𝛾.𝐴∘𝛿.𝐴[𝛾]=𝛾.𝐴∘(𝛿∘𝐩).𝐪=(𝛾∘𝛿∘𝐩).𝐪=(𝛾∘𝛿).𝐴

proving ^P2.

For ^P3 we have 𝐢𝐝.𝐴 =(𝐢𝐝 ∘𝐩).𝐪 =𝐩.𝐪 =(𝐩 ∘𝐢𝐝).𝐪[𝐢𝐝] =𝐢𝐝 by 𝜂𝐩𝐪.


#state/tidy | #lang/en | #SemBr