Documentation

Formalizations.SetTheory.Ordinal.Gentzen.TwoPow

Choice-free 2 ^ α and the cut-elimination inequalities below ε₀ #

The height-doubling map twoPow' (2 ^ α) and the inequalities L1–L5 of Gentzen's cut elimination on Mathlib's ONote, stated with the syntactic order slt / sle and the syntactic normal form SNF of Formalizations.SetTheory.Ordinal.Gentzen.Acc, without Ordinal or repr. Writing α = ω·γ + m, twoPow' α = ω ^ γ · 2 ^ m. Syntactic addition sadd is Mathlib's ONote.add (as data), and ssucc is the syntactic successor.

All results before the bridge section depend only on propext. (Mathlib's ONote.opow and the core lemma Nat.pow_lt_pow_right depend on Classical.choice; they are not used.) The bridge section, which does use choice, proves that twoPow', sadd and ssucc denote 2 ^ α, α + β and α + 1, and that twoPow' agrees with Mathlib's ONote.opow, hence with Gentzen.Ordinals.twoPow.

Main results #

References #

Constructive facts about cmp #

theorem Gentzen.TwoPow.natCmp_of_lt {m n : ℕ} (h : m < n) :
theorem Gentzen.TwoPow.two_pow_lt {i j : ℕ} (h : i < j) :
2 ^ i < 2 ^ j

2^i < 2^j for i < j (own proof; Nat.pow_lt_pow_right pulls Classical.choice).

theorem Gentzen.TwoPow.cmp_swap' (a b : ONote) :
(a.cmp b).swap = b.cmp a
theorem Gentzen.TwoPow.exp_slt {γ γ' x y : ONote} {c d : ℕ+} (h : Acc.slt γ γ') :
Acc.slt (γ.oadd c x) (γ'.oadd d y)
theorem Gentzen.TwoPow.coef_slt {γ x y : ONote} {c d : ℕ+} (h : ↑c < ↑d) :
Acc.slt (γ.oadd c x) (γ.oadd d y)

Syntactic order sle, max, numerals #

Weak syntactic order.

Equations
Instances For

    Max via cmp.

    Equations
    Instances For
      theorem Gentzen.TwoPow.smax_of_lt {a b : ONote} (h : a.cmp b = Ordering.lt) :
      smax a b = b
      theorem Gentzen.TwoPow.smax_of_eq {a b : ONote} (h : a.cmp b = Ordering.eq) :
      smax a b = a
      theorem Gentzen.TwoPow.smax_of_gt {a b : ONote} (h : a.cmp b = Ordering.gt) :
      smax a b = a
      theorem Gentzen.TwoPow.coef_sle {γ : ONote} {c d : ℕ+} (h : ↑c ≤ ↑d) :
      theorem Gentzen.TwoPow.num_slt {i j : ℕ} :
      i < j → Acc.slt (num i) (num j)

      Syntactic addition, successor, and 2^α #

      Syntactic addition: Mathlib's ONote.add (data only; choice-free as a definition).

      Equations
      Instances For

        "Left predecessor" of a nonzero exponent: 1 + dec e = e.

        Equations
        Instances For

          2 ^ m as a positive natural.

          Equations
          Instances For

            2 ^ α = ω ^ γ · 2 ^ m where α = ω·γ + m.

            Equations
            Instances For
              theorem Gentzen.TwoPow.ssplit_inf (g z x : ONote) (m n : ℕ+) :
              ssplit ((g.oadd m z).oadd n x) = ((dec (g.oadd m z)).oadd n (ssplit x).1, (ssplit x).2)

              SNF closure #

              theorem Gentzen.TwoPow.dec_slt {e e' : ONote} :
              Acc.SNF e → Acc.SNF e' → e ≠ ONote.zero → Acc.slt e e' → Acc.slt (dec e) (dec e')
              theorem Gentzen.TwoPow.topBelow_ssplit {g z x : ONote} {m n : ℕ+} (h : Acc.SNF ((g.oadd m z).oadd n x)) :
              Acc.topBelow (ssplit x).1 (dec (g.oadd m z))
              theorem Gentzen.TwoPow.SNF_addAux {e : ONote} (n : ℕ+) (he : Acc.SNF e) {o : ONote} :
              Acc.SNF o → Acc.SNF (e.addAux n o)
              theorem Gentzen.TwoPow.SNF_sadd {a b : ONote} :
              Acc.SNF a → Acc.SNF b → Acc.SNF (sadd a b)
              theorem Gentzen.TwoPow.SNF_smax {a b : ONote} (ha : Acc.SNF a) (hb : Acc.SNF b) :

              L3: monotonicity #

              theorem Gentzen.TwoPow.ssplit_mono (a b : ONote) :
              Acc.SNF a → Acc.SNF b → Acc.slt a b → Acc.slt (ssplit a).1 (ssplit b).1 ∨ (ssplit a).1 = (ssplit b).1 ∧ (ssplit a).2 < (ssplit b).2

              The split (γ, m) is lexicographically monotone.

              theorem Gentzen.TwoPow.twoPow'_slt {a b : ONote} (ha : Acc.SNF a) (hb : Acc.SNF b) (h : Acc.slt a b) :

              L3 (strict).

              theorem Gentzen.TwoPow.twoPow'_sle {a b : ONote} (ha : Acc.SNF a) (hb : Acc.SNF b) (h : sle a b) :

              L3 (weak).

              L4: commutes with smax #

              theorem Gentzen.TwoPow.twoPow'_smax {a b : ONote} (ha : Acc.SNF a) (hb : Acc.SNF b) :

              Addition of the special shapes #

              theorem Gentzen.TwoPow.sadd_lt {γa γb x : ONote} {ca cb : ℕ+} (h : γa.cmp γb = Ordering.lt) :
              sadd (γa.oadd ca ONote.zero) (γb.oadd cb x) = γb.oadd cb x
              theorem Gentzen.TwoPow.sadd_eq {γa γb x : ONote} {ca cb : ℕ+} (h : γa.cmp γb = Ordering.eq) :
              sadd (γa.oadd ca ONote.zero) (γb.oadd cb x) = γa.oadd (ca + cb) x
              theorem Gentzen.TwoPow.sadd_gt {γa γb x : ONote} {ca cb : ℕ+} (h : γa.cmp γb = Ordering.gt) :
              sadd (γa.oadd ca ONote.zero) (γb.oadd cb x) = γa.oadd ca (γb.oadd cb x)
              theorem Gentzen.TwoPow.pow2_succ (m : ℕ) :
              ↑(pow2 (m + 1)) = 2 ^ m + 2 ^ m
              theorem Gentzen.TwoPow.le_fin_part {a : ONote} {j : ℕ+} (ha : Acc.SNF a) (hγ : (ssplit a).1 = ONote.zero) (h : sle (ONote.zero.oadd j ONote.zero) a) :
              ↑j ≤ (ssplit a).2

              If a is finite (γ = 0) and j ≤ a, then j ≤ m.

              L1, L2, L5 #

              theorem Gentzen.TwoPow.twoPow'_add_num_lt {a : ONote} {j : ℕ+} (hfin : (ssplit a).1 = ONote.zero → ↑j < 2 ^ (ssplit a).2) :

              Generic form: 2^α + j < 2^(α+1) when j < 2^m in the finite case.

              theorem Gentzen.TwoPow.L1 {a : ONote} (ha : Acc.SNF a) (h : sle one' a) :

              L1. False at a = 0 (2^0 + 1 = 2^1).

              theorem Gentzen.TwoPow.L2 {a : ONote} (ha : Acc.SNF a) (h : sle two' a) :

              L2. False at a = 1 (2^1 + 2 = 2^2).

              L5. 2^α + 2 < 2^(α+2) for every α.

              Two-premise cut bound #

              theorem Gentzen.TwoPow.sum_bound_right {γa γb : ONote} {ma mb : ℕ} (h : Acc.slt γa γb ∨ γa = γb ∧ ma ≤ mb) :
              sle (sadd (γa.oadd (pow2 ma) ONote.zero) (γb.oadd (pow2 mb) ONote.zero)) (γb.oadd (pow2 (mb + 1)) ONote.zero)
              theorem Gentzen.TwoPow.sum_bound_left {γa γb : ONote} {ma mb : ℕ} (h : Acc.slt γb γa ∨ γb = γa ∧ mb ≤ ma) :
              sle (sadd (γa.oadd (pow2 ma) ONote.zero) (γb.oadd (pow2 mb) ONote.zero)) (γa.oadd (pow2 (ma + 1)) ONote.zero)
              theorem Gentzen.TwoPow.twoPow'_add_le {a b : ONote} (ha : Acc.SNF a) (hb : Acc.SNF b) :
              sle (sadd (twoPow' a) (twoPow' b)) (twoPow' (ssucc (smax a b)))

              Cut with premises of heights a, b: 2^a + 2^b ≤ 2^(max a b + 1).

              Counterexamples at the excluded points (choice-free, by evaluation) #

              L1 fails at a = 0: 2^0 + 1 = 2 = 2^1.

              L2 fails at a = 1: 2^1 + 2 = 4 = 2^2.

              Bridge to Ordinal (uses choice): these are the right functions #

              theorem Gentzen.TwoPow.repr_sadd (a b : ONote) [a.NF] [b.NF] :
              (sadd a b).repr = a.repr + b.repr
              theorem Gentzen.TwoPow.repr_ssucc (a : ONote) :
              a.NF → (ssucc a).repr = a.repr + 1
              theorem Gentzen.TwoPow.repr_num (k : ℕ) :
              (num k).repr = ↑k
              theorem Gentzen.TwoPow.repr_twoPow' (a : ONote) (h : a.NF) :
              (twoPow' a).repr = 2 ^ a.repr

              twoPow' denotes 2 ^ α.

              theorem Gentzen.TwoPow.twoPow'_eq_opow (a : ONote) [h : a.NF] :
              twoPow' a = ↑2 ^ a

              twoPow' agrees with Mathlib's ONote.opow (hence with Gentzen.Ordinals.twoPow, whose underlying notation is ONote.ofNat 2 ^ a).

              theorem Gentzen.TwoPow.ssucc_eq_add_one (a : ONote) [h : a.NF] :
              ssucc a = a + 1

              Checks on samples (by decide) #

              Samples: 0, 1, 2, ω, ω+1, ω·2, ω^ω.

              Equations
              Instances For