poset_height
def
The height of a finite partial order α: one less than the maximum cardinality of a chain in α, i.e. the largest n such that α admits a strictly increasing map Fin (n+1) → α. Equals 0 for an empty order and for an antichain.
Statement
noncomputable def poset_height (α : Type*) [PartialOrder α] [Fintype α] : ℕ
- Source
- step towards op314_poset_tower_two_cancellation
- Verified
- 25 Oct 2026
- Axioms
- none listed
- Built on 2
- TotalPreorderA total preorder: a preorder where
≤is total (complete). This is weaker thanLinearOrder— it does NOT require antisymmetry or… - LinearOrder.toTotalPreorderEvery
LinearOrderis aTotalPreorder.
- TotalPreorderA total preorder: a preorder where
Lean source view module on GitHub
/-- Height of a finite partial order: the supremum of the n for which there is a strictly increasing family Fin (n+1) → α, i.e. one less than the size of a longest chain. -/ noncomputable def poset_height (α : Type*) [PartialOrder α] [Fintype α] : ℕ := sSup {n : ℕ | ∃ f : Fin (n+1) → α, StrictMono f}