File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -10,6 +10,7 @@ public import Mathlib.Algebra.Order.Monoid.Defs
1010public import Mathlib.Algebra.Order.Monoid.Unbundled.ExistsOfLE
1111public import Mathlib.Algebra.NeZero
1212public import Mathlib.Order.BoundedOrder.Basic
13+ public import Mathlib.Order.Interval.Set.Defs
1314
1415/-!
1516# Canonically ordered monoids
@@ -137,6 +138,10 @@ end LE
137138section Preorder
138139variable [Preorder α] [CanonicallyOrderedMul α] {a b : α}
139140
141+ @[to_additive]
142+ instance isEmpty_Iio_one : IsEmpty (Set.Iio (1 : α)) :=
143+ ⟨fun ⟨a, ha⟩ ↦ not_le_of_gt ha (isBot_one a)⟩
144+
140145@ [to_additive (attr := simp) not_lt_zero] lemma not_lt_one : ¬ a < 1 := (one_le a).not_gt
141146
142147@ [deprecated (since := "2025-12-03" )] alias not_neg := not_lt_zero
Original file line number Diff line number Diff line change @@ -259,13 +259,26 @@ theorem lt_one_iff [CanonicallyOrderedAdd α] : x < 1 ↔ x = 0 := by
259259theorem le_one_iff [CanonicallyOrderedAdd α] : x ≤ 1 ↔ x = 0 ∨ x = 1 := by
260260 rw [le_iff_lt_or_eq, lt_one_iff]
261261
262+ @[simp]
263+ theorem Iio_one [CanonicallyOrderedAdd α] : Set.Iio (1 : α) = {0 } := by
264+ ext; simp
265+
266+ theorem Iic_one [CanonicallyOrderedAdd α] : Set.Iic (1 : α) = {0 , 1 } := by
267+ ext; simp [le_one_iff]
268+
262269@[simp]
263270theorem lt_two_iff : x < 2 ↔ x ≤ 1 := by
264271 rw [← one_add_one_eq_two, lt_add_one_iff]
265272
266273theorem le_two_iff [CanonicallyOrderedAdd α] : x ≤ 2 ↔ x = 0 ∨ x = 1 ∨ x = 2 := by
267274 rw [le_iff_lt_or_eq, lt_two_iff, le_one_iff, or_assoc]
268275
276+ theorem Iio_two [CanonicallyOrderedAdd α] : Set.Iio (2 : α) = {0 , 1 } := by
277+ ext; simp [le_one_iff]
278+
279+ theorem Iic_two [CanonicallyOrderedAdd α] : Set.Iic (2 : α) = {0 , 1 , 2 } := by
280+ ext; simp [le_two_iff]
281+
269282end AddMonoidWithOne
270283
271284section Sub
Original file line number Diff line number Diff line change @@ -343,14 +343,10 @@ instance : OrderBot Ordinal where
343343theorem bot_eq_zero : (⊥ : Ordinal) = 0 :=
344344 rfl
345345
346- instance instIsEmptyIioZero : IsEmpty (Iio (0 : Ordinal)) := by
347- simp [← bot_eq_zero]
348-
349346@ [deprecated nonpos_iff_eq_zero (since := "2025-11-21" )]
350347protected theorem le_zero {o : Ordinal} : o ≤ 0 ↔ o = 0 :=
351348 le_bot_iff
352349
353-
354350@ [deprecated not_neg (since := "2025-11-21" )]
355351protected theorem not_lt_zero (o : Ordinal) : ¬o < 0 :=
356352 not_lt_bot
You can’t perform that action at this time.
0 commit comments