==========================
= =
= §3.1 Majorizability =
= =
==========================
Chuangjie Xu, July 2019
Updated in February 2020
We construct majorants of T-terms via the monadic translation whose
correctness is guaranteed by the Fundamental Theorem of Logical Relation.
References
□ W. A. Howard. Hereditarily majorizable functionals of finite type.
In Metamathematical investigation of intuitionistic Arithmetic and
Analysis, volume 344 of Lecture Notes in Mathematics, pages
454–461. Springer, Berlin, 1973.
\begin{code}
{-# OPTIONS --without-K --safe #-}
open import Preliminaries
open import T
open import TAuxiliaries
module Majorizability where
\end{code}
■ A nucleus for majorizability
\begin{code}
Jι : Ty
Jι = ι
η : {Γ : Cxt} → T Γ (ι ⇾ Jι)
η = Lam ν₀
κ : {Γ : Cxt} → T Γ ((ι ⇾ Jι) ⇾ Jι ⇾ Jι)
κ = Φ
κ-spec : {i j : ℕ} → i ≤ j
→ {Γ : Cxt} (γ : ⟦ Γ ⟧ˣ)
→ (g : ℕ → ℕ) → g i ≤ ⟦ κ ⟧ᵐ γ g j
κ-spec = Φ-spec
open import GentzenTranslation Jι η κ
\end{code}
■ Howard's majorizability relation
\begin{code}
_⊲ι_ : ⟦ ι ⟧ʸ → ⟦ Jι ⟧ʸ → Set
_⊲ι_ = _≤_
⊲η : {Γ : Cxt} (γ : ⟦ Γ ⟧ˣ) (n : ⟦ ι ⟧ʸ) → n ⊲ι ⟦ η ⟧ᵐ γ n
⊲η _ n = ≤refl
⊲κ : {Γ : Cxt} (γ : ⟦ Γ ⟧ˣ) {f : ⟦ ι ⇾ ι ⟧ʸ} {g : ⟦ ι ⇾ Jι ⟧ʸ}
→ (∀ i → f i ⊲ι g i) → ∀ {n a} → n ⊲ι a → f n ⊲ι ⟦ κ ⟧ᵐ γ g a
⊲κ γ {f} {g} ζ {x} θ = ≤trans (ζ x) (κ-spec θ γ g)
open import LogicalRelation Jι η κ _⊲ι_ ⊲η ⊲κ
_⊲_ : {ρ : Ty} → ⟦ ρ ⟧ʸ → ⟦ ⟨ ρ ⟩ᴶ ⟧ʸ → Set
_⊲_ = _R_
\end{code}
■ Corollary: Every closed T term is majorized by its translation.
\begin{code}
Cor[Maj] : {ρ : Ty} (t : T ε ρ) → ⟦ t ⟧ ⊲ ⟦ t ᴶ ⟧
Cor[Maj] t = FTLR t ⋆
\end{code}