Skip to content

Commit

Permalink
feat(set_theory/ordinal_arithmetic): le_one_iff (#11847)
Browse files Browse the repository at this point in the history
  • Loading branch information
vihdzp committed Feb 9, 2022
1 parent 2726e23 commit b8fb8e5
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/set_theory/ordinal_arithmetic.lean
Expand Up @@ -183,6 +183,15 @@ instance : nontrivial ordinal.{u} :=
theorem zero_lt_one : (0 : ordinal) < 1 :=
lt_iff_le_and_ne.2 ⟨ordinal.zero_le _, ne.symm $ ordinal.one_ne_zero⟩

theorem le_one_iff {a : ordinal} : a ≤ 1 ↔ a = 0 ∨ a = 1 :=
begin
refine ⟨λ ha, _, _⟩,
{ rcases eq_or_lt_of_le ha with rfl | ha,
exacts [or.inr rfl, or.inl (lt_one_iff_zero.1 ha)], },
{ rintro (rfl | rfl),
exacts [le_of_lt zero_lt_one, le_refl _], }
end

/-! ### The predecessor of an ordinal -/

/-- The ordinal predecessor of `o` is `o'` if `o = succ o'`,
Expand Down

0 comments on commit b8fb8e5

Please sign in to comment.