Documentation

SphereEversion.Indexing

Indexing types #

This file introduces IndexType : ℕ → Type such that IndexType 0 = ℕ and IndexType (N+1) = Fin (N+1). Each IndexType N has a total order and and inductive principle together with supporting lemmas.

def IndexType (n : ) :

Our model indexing type depending on n : ℕ is if n = 0 and Fin n otherwise

Equations
Instances For
    @[simp]
    @[simp]
    theorem indexType_succ (n : ) :
    IndexType (n + 1) = Fin (n + 1)
    @[simp]
    theorem indexType_of_zero_lt {n : } (h : 0 < n) :
    theorem Set.countable_iff_exists_nonempty_indexType_equiv {α : Type u_1} {s : Set α} (hne : s.Nonempty) :
    s.Countable ∃ (n : ), Nonempty (IndexType n s)
    theorem IndexType.not_lt_zero {n : } (j : IndexType n) :
    ¬j < 0
    theorem IndexType.zero_le {n : } (i : IndexType n) :
    0 i
    Equations
    Instances For
      theorem IndexType.succ_eq {n : } (i : IndexType n) :
      i.succ = i IsMax i
      theorem IndexType.lt_succ {n : } (i : IndexType n) (h : ¬IsMax i) :
      i < i.succ
      theorem IndexType.le_max {n : } {i : IndexType n} (h : IsMax i) (j : IndexType n) :
      j i
      theorem IndexType.le_of_lt_succ {n : } (i : IndexType n) {j : IndexType n} (h : i < j.succ) :
      i j
      theorem IndexType.exists_castSucc_eq {n : } (i : IndexType (n + 1)) (hi : ¬IsMax i) :
      ∃ (i' : Fin n), i'.castSucc = i
      theorem IndexType.toNat_succ {n : } (i : IndexType n) (hi : ¬IsMax i) :
      theorem IndexType.induction_from {n : } {P : IndexType nProp} {i₀ : IndexType n} (h₀ : P i₀) (ih : ii₀, ¬IsMax iP iP i.succ) (i : IndexType n) :
      i i₀P i
      theorem IndexType.induction {n : } {P : IndexType nProp} (h₀ : P 0) (ih : ∀ (i : IndexType n), ¬IsMax iP iP i.succ) (i : IndexType n) :
      P i
      theorem IndexType.exists_by_induction {n : } {α : Type u_1} (P : IndexType nαProp) (Q : IndexType nααProp) (h₀ : ∃ (a : α), P 0 a) (ih : ∀ (n_1 : IndexType n) (a : α), P n_1 a¬IsMax n_1∃ (a' : α), P n_1.succ a' Q n_1 a a') :
      ∃ (f : IndexType nα), ∀ (n_1 : IndexType n), P n_1 (f n_1) (¬IsMax n_1Q n_1 (f n_1) (f n_1.succ))