File: Mathlib/Order/Height.lean

full_name: Set.subchain
code: /-- The set of strictly ascending lists of `α` contained in a `Set α`. -/
def subchain : Set (List α) 
goal: Set (List α)

full_name: Set.nil_mem_subchain
code: @[simp] -- porting note: new `simp`
theorem nil_mem_subchain : [] ∈ s.subchain 
goal: [] ∈ s.subchain

full_name: Set.cons_mem_subchain_iff
code: theorem cons_mem_subchain_iff :
    (a::l) ∈ s.subchain ↔ a ∈ s ∧ l ∈ s.subchain ∧ ∀ b ∈ l.head?, a < b 
goal: a :: l ∈ s.subchain ↔ a ∈ s ∧ l ∈ s.subchain ∧ ∀ b ∈ l.head?, a < b

full_name: Set.singleton_mem_subchain_iff
code: @[simp]
theorem singleton_mem_subchain_iff : [a] ∈ s.subchain ↔ a ∈ s 
goal: [a] ∈ s.subchain ↔ a ∈ s

full_name: Set.instNonemptyElemListSubchain
code: instance : Nonempty s.subchain 
goal: Nonempty ↑s.subchain

full_name: Set.chainHeight
code: /-- The maximal length of a strictly ascending sequence in a partial order. -/
noncomputable def chainHeight : ℕ∞ 
goal: ℕ∞

full_name: Set.chainHeight_eq_iSup_subtype
code: theorem chainHeight_eq_iSup_subtype : s.chainHeight = ⨆ l : s.subchain, ↑l.1.length 
goal: s.chainHeight = ⨆ l, ↑(↑l).length

full_name: Set.exists_chain_of_le_chainHeight
code: theorem exists_chain_of_le_chainHeight {n : ℕ} (hn : ↑n ≤ s.chainHeight) :
    ∃ l ∈ s.subchain, length l = n 
goal: ∃ l ∈ s.subchain, l.length = n

full_name: Set.le_chainHeight_TFAE
code: theorem le_chainHeight_TFAE (n : ℕ) :
    TFAE [↑n ≤ s.chainHeight, ∃ l ∈ s.subchain, length l = n, ∃ l ∈ s.subchain, n ≤ length l] 
goal: [↑n ≤ s.chainHeight, ∃ l ∈ s.subchain, l.length = n, ∃ l ∈ s.subchain, n ≤ l.length].TFAE

full_name: Set.le_chainHeight_iff
code: theorem le_chainHeight_iff {n : ℕ} : ↑n ≤ s.chainHeight ↔ ∃ l ∈ s.subchain, length l = n 
goal: ↑n ≤ s.chainHeight ↔ ∃ l ∈ s.subchain, l.length = n

full_name: Set.length_le_chainHeight_of_mem_subchain
code: theorem length_le_chainHeight_of_mem_subchain (hl : l ∈ s.subchain) : ↑l.length ≤ s.chainHeight 
goal: ↑l.length ≤ s.chainHeight

full_name: Set.chainHeight_eq_top_iff
code: theorem chainHeight_eq_top_iff : s.chainHeight = ⊤ ↔ ∀ n, ∃ l ∈ s.subchain, length l = n 
goal: s.chainHeight = ⊤ ↔ ∀ (n : ℕ), ∃ l ∈ s.subchain, l.length = n

full_name: Set.one_le_chainHeight_iff
code: @[simp]
theorem one_le_chainHeight_iff : 1 ≤ s.chainHeight ↔ s.Nonempty 
goal: 1 ≤ s.chainHeight ↔ s.Nonempty

full_name: Set.chainHeight_eq_zero_iff
code: @[simp]
theorem chainHeight_eq_zero_iff : s.chainHeight = 0 ↔ s = ∅ 
goal: s.chainHeight = 0 ↔ s = ∅

full_name: Set.chainHeight_empty
code: @[simp]
theorem chainHeight_empty : (∅ : Set α).chainHeight = 0 
goal: ∅.chainHeight = 0

full_name: Set.chainHeight_of_isEmpty
code: @[simp]
theorem chainHeight_of_isEmpty [IsEmpty α] : s.chainHeight = 0 
goal: s.chainHeight = 0

full_name: Set.le_chainHeight_add_nat_iff
code: theorem le_chainHeight_add_nat_iff {n m : ℕ} :
    ↑n ≤ s.chainHeight + m ↔ ∃ l ∈ s.subchain, n ≤ length l + m 
goal: ↑n ≤ s.chainHeight + ↑m ↔ ∃ l ∈ s.subchain, n ≤ l.length + m

full_name: Set.chainHeight_add_le_chainHeight_add
code: theorem chainHeight_add_le_chainHeight_add (s : Set α) (t : Set β) (n m : ℕ) :
    s.chainHeight + n ≤ t.chainHeight + m ↔
      ∀ l ∈ s.subchain, ∃ l' ∈ t.subchain, length l + n ≤ length l' + m 
goal: s.chainHeight + ↑n ≤ t.chainHeight + ↑m ↔ ∀ l ∈ s.subchain, ∃ l' ∈ t.subchain, l.length + n ≤ l'.length + m

full_name: Set.chainHeight_le_chainHeight_TFAE
code: theorem chainHeight_le_chainHeight_TFAE (s : Set α) (t : Set β) :
    TFAE [s.chainHeight ≤ t.chainHeight, ∀ l ∈ s.subchain, ∃ l' ∈ t.subchain, length l = length l',
      ∀ l ∈ s.subchain, ∃ l' ∈ t.subchain, length l ≤ length l'] 
goal: [s.chainHeight ≤ t.chainHeight, ∀ l ∈ s.subchain, ∃ l' ∈ t.subchain, l.length = l'.length,
    ∀ l ∈ s.subchain, ∃ l' ∈ t.subchain, l.length ≤ l'.length].TFAE

full_name: Set.chainHeight_le_chainHeight_iff
code: theorem chainHeight_le_chainHeight_iff {t : Set β} :
    s.chainHeight ≤ t.chainHeight ↔ ∀ l ∈ s.subchain, ∃ l' ∈ t.subchain, length l = length l' 
goal: s.chainHeight ≤ t.chainHeight ↔ ∀ l ∈ s.subchain, ∃ l' ∈ t.subchain, l.length = l'.length

full_name: Set.chainHeight_le_chainHeight_iff_le
code: theorem chainHeight_le_chainHeight_iff_le {t : Set β} :
    s.chainHeight ≤ t.chainHeight ↔ ∀ l ∈ s.subchain, ∃ l' ∈ t.subchain, length l ≤ length l' 
goal: s.chainHeight ≤ t.chainHeight ↔ ∀ l ∈ s.subchain, ∃ l' ∈ t.subchain, l.length ≤ l'.length

full_name: Set.chainHeight_mono
code: theorem chainHeight_mono (h : s ⊆ t) : s.chainHeight ≤ t.chainHeight 
goal: s.chainHeight ≤ t.chainHeight

full_name: Set.chainHeight_image
code: theorem chainHeight_image (f : α → β) (hf : ∀ {x y}, x < y ↔ f x < f y) (s : Set α) :
    (f '' s).chainHeight = s.chainHeight 
goal: (f '' s).chainHeight = s.chainHeight

full_name: Set.chainHeight_dual
code: @[simp]
theorem chainHeight_dual : (ofDual ⁻¹' s).chainHeight = s.chainHeight 
goal: (⇑OrderDual.ofDual ⁻¹' s).chainHeight = s.chainHeight

full_name: Set.chainHeight_eq_iSup_Ici
code: theorem chainHeight_eq_iSup_Ici : s.chainHeight = ⨆ i ∈ s, (s ∩ Set.Ici i).chainHeight 
goal: s.chainHeight = ⨆ i ∈ s, (s ∩ Set.Ici i).chainHeight

full_name: Set.chainHeight_eq_iSup_Iic
code: theorem chainHeight_eq_iSup_Iic : s.chainHeight = ⨆ i ∈ s, (s ∩ Set.Iic i).chainHeight 
goal: s.chainHeight = ⨆ i ∈ s, (s ∩ Set.Iic i).chainHeight

full_name: Set.chainHeight_insert_of_forall_gt
code: theorem chainHeight_insert_of_forall_gt (a : α) (hx : ∀ b ∈ s, a < b) :
    (insert a s).chainHeight = s.chainHeight + 1 
goal: (insert a s).chainHeight = s.chainHeight + 1

full_name: Set.chainHeight_insert_of_forall_lt
code: theorem chainHeight_insert_of_forall_lt (a : α) (ha : ∀ b ∈ s, b < a) :
    (insert a s).chainHeight = s.chainHeight + 1 
goal: (insert a s).chainHeight = s.chainHeight + 1

full_name: Set.chainHeight_union_le
code: theorem chainHeight_union_le : (s ∪ t).chainHeight ≤ s.chainHeight + t.chainHeight 
goal: (s ∪ t).chainHeight ≤ s.chainHeight + t.chainHeight

full_name: Set.chainHeight_union_eq
code: theorem chainHeight_union_eq (s t : Set α) (H : ∀ a ∈ s, ∀ b ∈ t, a < b) :
    (s ∪ t).chainHeight = s.chainHeight + t.chainHeight 
goal: (s ∪ t).chainHeight = s.chainHeight + t.chainHeight

full_name: Set.wellFoundedGT_of_chainHeight_ne_top
code: theorem wellFoundedGT_of_chainHeight_ne_top (s : Set α) (hs : s.chainHeight ≠ ⊤) :
    WellFoundedGT s 
goal: WellFoundedGT ↑s

full_name: Set.wellFoundedLT_of_chainHeight_ne_top
code: theorem wellFoundedLT_of_chainHeight_ne_top (s : Set α) (hs : s.chainHeight ≠ ⊤) :
    WellFoundedLT s 
goal: WellFoundedLT ↑s