The Mathlib Handbook

The volumes of the handbook are not written yet. This site shows the map of Mathlib that they will follow, at Mathlib 4472534b60.

The areas / V04. Order and lattices

Mathlib.Algebra.Order.Monoid.Unbundled.WithTop

237 declarations. Mathlib docs · Source

Adjoining top/bottom elements to ordered monoids.

instance WithTop.zero E0 #

{α : Type u} → [Zero α] → Zero (WithTop α)

instance WithTop.one E0 #

{α : Type u} → [One α] → One (WithTop α)

theorem WithTop.coe_zero E0 #

∀ {α : Type u} [inst : Zero α], ↑0 = 0

theorem WithTop.coe_one E0 #

∀ {α : Type u} [inst : One α], ↑1 = 1

theorem WithTop.coe_eq_zero E0 #

∀ {α : Type u} [inst : Zero α] {a : α}, ↑a = 0 ↔ a = 0

theorem WithTop.coe_eq_one E0 #

∀ {α : Type u} [inst : One α] {a : α}, ↑a = 1 ↔ a = 1

theorem WithTop.coe_ne_zero E0 #

∀ {α : Type u} [inst : Zero α] {a : α}, ↑a ≠ 0 ↔ a ≠ 0

theorem WithTop.coe_ne_one E0 #

∀ {α : Type u} [inst : One α] {a : α}, ↑a ≠ 1 ↔ a ≠ 1

theorem WithTop.one_eq_coe E0 #

∀ {α : Type u} [inst : One α] {a : α}, 1 = ↑a ↔ a = 1

theorem WithTop.zero_eq_coe E0 #

∀ {α : Type u} [inst : Zero α] {a : α}, 0 = ↑a ↔ a = 0

theorem WithTop.top_ne_zero E0 #

∀ {α : Type u} [inst : Zero α], ⊤ ≠ 0

theorem WithTop.top_ne_one E0 #

∀ {α : Type u} [inst : One α], ⊤ ≠ 1

theorem WithTop.one_ne_top E0 #

∀ {α : Type u} [inst : One α], 1 ≠ ⊤

theorem WithTop.zero_ne_top E0 #

∀ {α : Type u} [inst : Zero α], 0 ≠ ⊤

theorem WithTop.untop_zero E0 #

∀ {α : Type u} [inst : Zero α], WithTop.untop 0 ⋯ = 0

theorem WithTop.untop_one E0 #

∀ {α : Type u} [inst : One α], WithTop.untop 1 ⋯ = 1

theorem WithTop.untopD_zero E0 #

∀ {α : Type u} [inst : Zero α] (d : α), WithTop.untopD d 0 = 0

theorem WithTop.untopD_one E0 #

∀ {α : Type u} [inst : One α] (d : α), WithTop.untopD d 1 = 1

theorem WithTop.coe_nonneg E0 #

∀ {α : Type u} [inst : Zero α] [inst_1 : LE α] {a : α}, 0 ≤ ↑a ↔ 0 ≤ a

theorem WithTop.one_le_coe E0 #

∀ {α : Type u} [inst : One α] [inst_1 : LE α] {a : α}, 1 ≤ ↑a ↔ 1 ≤ a

theorem WithTop.coe_le_zero E0 #

∀ {α : Type u} [inst : Zero α] [inst_1 : LE α] {a : α}, ↑a ≤ 0 ↔ a ≤ 0

theorem WithTop.coe_le_one E0 #

∀ {α : Type u} [inst : One α] [inst_1 : LE α] {a : α}, ↑a ≤ 1 ↔ a ≤ 1

theorem WithTop.one_lt_coe E0 #

∀ {α : Type u} [inst : One α] [inst_1 : LT α] {a : α}, 1 < ↑a ↔ 1 < a

theorem WithTop.coe_pos E0 #

∀ {α : Type u} [inst : Zero α] [inst_1 : LT α] {a : α}, 0 < ↑a ↔ 0 < a

theorem WithTop.coe_lt_one E0 #

∀ {α : Type u} [inst : One α] [inst_1 : LT α] {a : α}, ↑a < 1 ↔ a < 1

theorem WithTop.coe_lt_zero E0 #

∀ {α : Type u} [inst : Zero α] [inst_1 : LT α] {a : α}, ↑a < 0 ↔ a < 0

theorem WithTop.map_zero E0 #

∀ {α : Type u} [inst : Zero α] {β : Type u_1} (f : α → β), WithTop.map f 0 = ↑(f 0)

theorem WithTop.map_one E0 #

∀ {α : Type u} [inst : One α] {β : Type u_1} (f : α → β), WithTop.map f 1 = ↑(f 1)

theorem WithTop.map_eq_one_iff E0 #

∀ {β : Type v} {α : Type u_1} {f : α → β} {v : WithTop α} [inst : One β], WithTop.map f v = 1 ↔ ∃ x, v = ↑x ∧ f x = 1

theorem WithTop.map_eq_zero_iff E0 #

∀ {β : Type v} {α : Type u_1} {f : α → β} {v : WithTop α} [inst : Zero β], WithTop.map f v = 0 ↔ ∃ x, v = ↑x ∧ f x = 0

theorem WithTop.one_eq_map_iff E0 #

∀ {β : Type v} {α : Type u_1} {f : α → β} {v : WithTop α} [inst : One β], 1 = WithTop.map f v ↔ ∃ x, v = ↑x ∧ f x = 1

theorem WithTop.zero_eq_map_iff E0 #

∀ {β : Type v} {α : Type u_1} {f : α → β} {v : WithTop α} [inst : Zero β], 0 = WithTop.map f v ↔ ∃ x, v = ↑x ∧ f x = 0

instance WithTop.zeroLEOneClass E0 #

∀ {α : Type u} [inst : One α] [inst_1 : Zero α] [inst_2 : LE α] [ZeroLEOneClass α], ZeroLEOneClass (WithTop α)

instance WithTop.instIsBotOneClass E0 #

∀ {α : Type u} [inst : One α] [inst_1 : LE α] [IsBotOneClass α], IsBotOneClass (WithTop α)

instance WithTop.instIsBotZeroClass E0 #

∀ {α : Type u} [inst : Zero α] [inst_1 : LE α] [IsBotZeroClass α], IsBotZeroClass (WithTop α)

instance WithTop.add E0 #

{α : Type u} → [Add α] → Add (WithTop α)

theorem WithTop.coe_add E0 #

∀ {α : Type u} [inst : Add α] (a b : α), ↑(a + b) = ↑a + ↑b

theorem WithTop.top_add E0 #

∀ {α : Type u} [inst : Add α] (x : WithTop α), ⊤ + x = ⊤

theorem WithTop.add_top E0 #

∀ {α : Type u} [inst : Add α] (x : WithTop α), x + ⊤ = ⊤

theorem WithTop.add_eq_top E0 #

∀ {α : Type u} [inst : Add α] {x y : WithTop α}, x + y = ⊤ ↔ x = ⊤ ∨ y = ⊤

theorem WithTop.add_ne_top E1 #

∀ {α : Type u} [inst : Add α] {x y : WithTop α}, x + y ≠ ⊤ ↔ x ≠ ⊤ ∧ y ≠ ⊤

theorem WithTop.add_lt_top E0 #

∀ {α : Type u} [inst : Add α] {x y : WithTop α} [inst_1 : LT α], x + y < ⊤ ↔ x < ⊤ ∧ y < ⊤

theorem WithTop.add_eq_coe E0 #

∀ {α : Type u} [inst : Add α] {a b : WithTop α} {c : α}, a + b = ↑c ↔ ∃ a' b', ↑a' = a ∧ ↑b' = b ∧ a' + b' = c

theorem WithTop.add_coe_eq_top_iff E0 #

∀ {α : Type u} [inst : Add α] {x : WithTop α} {b : α}, x + ↑b = ⊤ ↔ x = ⊤

theorem WithTop.coe_add_eq_top_iff E0 #

∀ {α : Type u} [inst : Add α] {y : WithTop α} {a : α}, ↑a + y = ⊤ ↔ y = ⊤

theorem IsAddLeftRegular.withTop E1 #

∀ {α : Type u} [inst : Add α] {a : α}, IsAddLeftRegular a → IsAddLeftRegular ↑a

theorem IsAddRightRegular.withTop E1 #

∀ {α : Type u} [inst : Add α] {a : α}, IsAddRightRegular a → IsAddRightRegular ↑a

theorem AddLECancellable.withTop E1 #

∀ {α : Type u} [inst : Add α] {a : α} [inst_1 : LE α], AddLECancellable a → AddLECancellable ↑a

theorem WithTop.add_right_inj E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithTop α} [IsRightCancelAdd α], z ≠ ⊤ → (x + z = y + z ↔ x = y)

theorem WithTop.add_right_cancel E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithTop α} [IsRightCancelAdd α], z ≠ ⊤ → x + z = y + z → x = y

theorem WithTop.add_left_inj E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithTop α} [IsLeftCancelAdd α], x ≠ ⊤ → (x + y = x + z ↔ y = z)

theorem WithTop.add_left_cancel E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithTop α} [IsLeftCancelAdd α], x ≠ ⊤ → x + y = x + z → y = z

instance WithTop.addLeftMono E0 #

∀ {α : Type u} [inst : Add α] [inst_1 : LE α] [AddLeftMono α], AddLeftMono (WithTop α)

instance WithTop.addRightMono E0 #

∀ {α : Type u} [inst : Add α] [inst_1 : LE α] [AddRightMono α], AddRightMono (WithTop α)

instance WithTop.addLeftReflectLT E0 #

∀ {α : Type u} [inst : Add α] [inst_1 : LT α] [AddLeftReflectLT α], AddLeftReflectLT (WithTop α)

instance WithTop.addRightReflectLT E0 #

∀ {α : Type u} [inst : Add α] [inst_1 : LT α] [AddRightReflectLT α], AddRightReflectLT (WithTop α)

theorem WithTop.le_of_add_le_add_left E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithTop α} [inst_1 : LE α] [AddLeftReflectLE α], x ≠ ⊤ → x + y ≤ x + z → y ≤ z

theorem WithTop.le_of_add_le_add_right E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithTop α} [inst_1 : LE α] [AddRightReflectLE α], z ≠ ⊤ → x + z ≤ y + z → x ≤ y

theorem WithTop.add_lt_add_left E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithTop α} [inst_1 : LT α] [AddLeftStrictMono α], x ≠ ⊤ → y < z → x + y < x + z

theorem WithTop.add_lt_add_right E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithTop α} [inst_1 : LT α] [AddRightStrictMono α], z ≠ ⊤ → x < y → x + z < y + z

theorem WithTop.add_lt_add E1 #

∀ {α : Type u} [inst : Add α] {w x y z : WithTop α} [inst_1 : Preorder α] [AddLeftStrictMono α] [AddRightStrictMono α],
  x < z → y < w → x + y < z + w

theorem WithTop.add_le_add_iff_left E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithTop α} [inst_1 : LE α] [AddLeftMono α] [AddLeftReflectLE α],
  x ≠ ⊤ → (x + y ≤ x + z ↔ y ≤ z)

theorem WithTop.add_le_add_iff_right E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithTop α} [inst_1 : LE α] [AddRightMono α] [AddRightReflectLE α],
  z ≠ ⊤ → (x + z ≤ y + z ↔ x ≤ y)

theorem WithTop.add_lt_add_iff_left E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithTop α} [inst_1 : LT α] [AddLeftStrictMono α] [AddLeftReflectLT α],
  x ≠ ⊤ → (x + y < x + z ↔ y < z)

theorem WithTop.add_lt_add_iff_right E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithTop α} [inst_1 : LT α] [AddRightStrictMono α] [AddRightReflectLT α],
  z ≠ ⊤ → (x + z < y + z ↔ x < y)

theorem WithTop.add_lt_add_of_le_of_lt E1 #

∀ {α : Type u} [inst : Add α] {w x y z : WithTop α} [inst_1 : Preorder α] [AddLeftStrictMono α] [AddRightMono α],
  w ≠ ⊤ → w ≤ y → x < z → w + x < y + z

theorem WithTop.add_lt_add_of_lt_of_le E1 #

∀ {α : Type u} [inst : Add α] {w x y z : WithTop α} [inst_1 : Preorder α] [AddLeftMono α] [AddRightStrictMono α],
  x ≠ ⊤ → w < y → x ≤ z → w + x < y + z

theorem WithTop.addLECancellable_of_ne_top E1 #

∀ {α : Type u} [inst : Add α] {x : WithTop α} [inst_1 : LE α] [AddLeftReflectLE α], x ≠ ⊤ → AddLECancellable x

theorem WithTop.addLECancellable_of_lt_top E1 #

∀ {α : Type u} [inst : Add α] {x : WithTop α} [inst_1 : Preorder α] [AddLeftReflectLE α], x < ⊤ → AddLECancellable x

theorem WithTop.addLECancellable_coe E0 #

∀ {α : Type u} [inst : Add α] [inst_1 : LE α] [AddLeftReflectLE α] (a : α), AddLECancellable ↑a

theorem WithTop.addLECancellable_iff_ne_top E1 #

∀ {α : Type u} [inst : Add α] {x : WithTop α} [Nonempty α] [inst_2 : Preorder α] [AddLeftReflectLE α],
  AddLECancellable x ↔ x ≠ ⊤

theorem WithTop.map_add E0 #

∀ {α : Type u} {β : Type v} [inst : Add α] {F : Type u_1} [inst_1 : Add β] [inst_2 : FunLike F α β] [AddHomClass F α β]
  (f : F) (a b : WithTop α), WithTop.map (⇑f) (a + b) = WithTop.map (⇑f) a + WithTop.map (⇑f) b

instance WithTop.addSemigroup E0 #

{α : Type u} → [AddSemigroup α] → AddSemigroup (WithTop α)

instance WithTop.addCommSemigroup E0 #

{α : Type u} → [AddCommSemigroup α] → AddCommSemigroup (WithTop α)

instance WithTop.addZeroClass E0 #

{α : Type u} → [AddZeroClass α] → AddZeroClass (WithTop α)

instance WithTop.addMonoid E0 #

{α : Type u} → [AddMonoid α] → AddMonoid (WithTop α)

theorem WithTop.coe_nsmul E0 #

∀ {α : Type u} [inst : AddMonoid α] (a : α) (n : ℕ), ↑(n • a) = n • ↑a

def WithTop.addHom E1 #

{α : Type u} → [inst : AddMonoid α] → α →+ WithTop α

Coercion from α to WithTop α as an AddMonoidHom.

theorem WithTop.coe_addHom E0 #

∀ {α : Type u} [inst : AddMonoid α], ⇑WithTop.addHom = WithTop.some

instance WithTop.addCommMonoid E0 #

{α : Type u} → [AddCommMonoid α] → AddCommMonoid (WithTop α)

instance WithTop.natCast E0 #

{α : Type u} → [NatCast α] → NatCast (WithTop α)

instance WithTop.addMonoidWithOne E0 #

{α : Type u} → [AddMonoidWithOne α] → AddMonoidWithOne (WithTop α)

theorem WithTop.coe_natCast E0 #

∀ {α : Type u} [inst : AddMonoidWithOne α] (n : ℕ), ↑↑n = ↑n

theorem WithTop.top_ne_natCast E0 #

∀ {α : Type u} [inst : AddMonoidWithOne α] (n : ℕ), ⊤ ≠ ↑n

theorem WithTop.natCast_ne_top E0 #

∀ {α : Type u} [inst : AddMonoidWithOne α] (n : ℕ), ↑n ≠ ⊤

theorem WithTop.natCast_lt_top E0 #

∀ {α : Type u} [inst : AddMonoidWithOne α] [inst_1 : LT α] (n : ℕ), ↑n < ⊤

theorem WithTop.coe_ofNat E0 #

∀ {α : Type u} [inst : AddMonoidWithOne α] (n : ℕ) [inst_1 : n.AtLeastTwo], ↑(OfNat.ofNat n) = OfNat.ofNat n

theorem WithTop.coe_eq_ofNat E0 #

∀ {α : Type u} [inst : AddMonoidWithOne α] (n : ℕ) [inst_1 : n.AtLeastTwo] (m : α),
  ↑m = OfNat.ofNat n ↔ m = OfNat.ofNat n

theorem WithTop.ofNat_eq_coe E0 #

∀ {α : Type u} [inst : AddMonoidWithOne α] (n : ℕ) [inst_1 : n.AtLeastTwo] (m : α),
  OfNat.ofNat n = ↑m ↔ OfNat.ofNat n = m

theorem WithTop.ofNat_ne_top E0 #

∀ {α : Type u} [inst : AddMonoidWithOne α] (n : ℕ) [inst_1 : n.AtLeastTwo], OfNat.ofNat n ≠ ⊤

theorem WithTop.top_ne_ofNat E0 #

∀ {α : Type u} [inst : AddMonoidWithOne α] (n : ℕ) [inst_1 : n.AtLeastTwo], ⊤ ≠ OfNat.ofNat n

theorem WithTop.map_ofNat E0 #

∀ {α : Type u} {β : Type v} [inst : AddMonoidWithOne α] {f : α → β} (n : ℕ) [inst_1 : n.AtLeastTwo],
  WithTop.map f (OfNat.ofNat n) = ↑(f (OfNat.ofNat n))

theorem WithTop.map_natCast E0 #

∀ {α : Type u} {β : Type v} [inst : AddMonoidWithOne α] {f : α → β} (n : ℕ), WithTop.map f ↑n = ↑(f ↑n)

theorem WithTop.map_eq_ofNat_iff E0 #

∀ {α : Type u} {β : Type v} [inst : AddMonoidWithOne α] {f : β → α} {n : ℕ} [inst_1 : n.AtLeastTwo] {a : WithTop β},
  WithTop.map f a = OfNat.ofNat n ↔ ∃ x, a = ↑x ∧ f x = ↑n

theorem WithTop.ofNat_eq_map_iff E0 #

∀ {α : Type u} {β : Type v} [inst : AddMonoidWithOne α] {f : β → α} {n : ℕ} [inst_1 : n.AtLeastTwo] {a : WithTop β},
  OfNat.ofNat n = WithTop.map f a ↔ ∃ x, a = ↑x ∧ f x = ↑n

theorem WithTop.map_eq_natCast_iff E0 #

∀ {α : Type u} {β : Type v} [inst : AddMonoidWithOne α] {f : β → α} {n : ℕ} {a : WithTop β},
  WithTop.map f a = ↑n ↔ ∃ x, a = ↑x ∧ f x = ↑n

theorem WithTop.natCast_eq_map_iff E0 #

∀ {α : Type u} {β : Type v} [inst : AddMonoidWithOne α] {f : β → α} {n : ℕ} {a : WithTop β},
  ↑n = WithTop.map f a ↔ ∃ x, a = ↑x ∧ f x = ↑n

instance WithTop.charZero E0 #

∀ {α : Type u} [inst : AddMonoidWithOne α] [CharZero α], CharZero (WithTop α)

instance WithTop.addCommMonoidWithOne E0 #

{α : Type u} → [AddCommMonoidWithOne α] → AddCommMonoidWithOne (WithTop α)

instance WithTop.existsAddOfLE E0 #

∀ {α : Type u} [inst : LE α] [inst_1 : Add α] [ExistsAddOfLE α], ExistsAddOfLE (WithTop α)

theorem WithTop.one_lt_top E0 #

∀ {α : Type u} [inst : One α] [inst_1 : LT α], 1 < ⊤

theorem WithTop.top_pos E0 #

∀ {α : Type u} [inst : Zero α] [inst_1 : LT α], 0 < ⊤

def OneHom.withTopMap E1 #

{M : Type u_1} → {N : Type u_2} → [inst : One M] → [inst_1 : One N] → OneHom M N → OneHom (WithTop M) (WithTop N)

A version of WithTop.map for OneHoms.

theorem OneHom.withTopMap_apply E0 #

∀ {M : Type u_1} {N : Type u_2} [inst : One M] [inst_1 : One N] (f : OneHom M N), ⇑f.withTopMap = WithTop.map ⇑f

theorem ZeroHom.withTopMap_apply E0 #

∀ {M : Type u_1} {N : Type u_2} [inst : Zero M] [inst_1 : Zero N] (f : ZeroHom M N), ⇑f.withTopMap = WithTop.map ⇑f

def ZeroHom.withTopMap E1 #

{M : Type u_1} → {N : Type u_2} → [inst : Zero M] → [inst_1 : Zero N] → ZeroHom M N → ZeroHom (WithTop M) (WithTop N)

A version of WithTop.map for ZeroHoms

def AddHom.withTopMap E1 #

{M : Type u_1} → {N : Type u_2} → [inst : Add M] → [inst_1 : Add N] → (M →ₙ+ N) → WithTop M →ₙ+ WithTop N

A version of WithTop.map for AddHoms.

theorem AddHom.withTopMap_apply E0 #

∀ {M : Type u_1} {N : Type u_2} [inst : Add M] [inst_1 : Add N] (f : M →ₙ+ N), ⇑f.withTopMap = WithTop.map ⇑f

def AddMonoidHom.withTopMap E1 #

{M : Type u_1} →
  {N : Type u_2} → [inst : AddZeroClass M] → [inst_1 : AddZeroClass N] → (M →+ N) → WithTop M →+ WithTop N

A version of WithTop.map for AddMonoidHoms.

theorem AddMonoidHom.withTopMap_apply E0 #

∀ {M : Type u_1} {N : Type u_2} [inst : AddZeroClass M] [inst_1 : AddZeroClass N] (f : M →+ N),
  ⇑f.withTopMap = WithTop.map ⇑f

instance WithBot.zero E0 #

{α : Type u} → [Zero α] → Zero (WithBot α)

instance WithBot.one E0 #

{α : Type u} → [One α] → One (WithBot α)

theorem WithBot.coe_one E0 #

∀ {α : Type u} [inst : One α], ↑1 = 1

theorem WithBot.coe_zero E0 #

∀ {α : Type u} [inst : Zero α], ↑0 = 0

theorem WithBot.coe_eq_one E0 #

∀ {α : Type u} [inst : One α] {a : α}, ↑a = 1 ↔ a = 1

theorem WithBot.coe_eq_zero E0 #

∀ {α : Type u} [inst : Zero α] {a : α}, ↑a = 0 ↔ a = 0

theorem WithBot.zero_eq_coe E0 #

∀ {α : Type u} [inst : Zero α] {a : α}, 0 = ↑a ↔ a = 0

theorem WithBot.one_eq_coe E0 #

∀ {α : Type u} [inst : One α] {a : α}, 1 = ↑a ↔ a = 1

theorem WithBot.bot_ne_zero E0 #

∀ {α : Type u} [inst : Zero α], ⊥ ≠ 0

theorem WithBot.bot_ne_one E0 #

∀ {α : Type u} [inst : One α], ⊥ ≠ 1

theorem WithBot.one_ne_bot E0 #

∀ {α : Type u} [inst : One α], 1 ≠ ⊥

theorem WithBot.zero_ne_bot E0 #

∀ {α : Type u} [inst : Zero α], 0 ≠ ⊥

theorem WithBot.unbot_one E0 #

∀ {α : Type u} [inst : One α], WithBot.unbot 1 ⋯ = 1

theorem WithBot.unbot_zero E0 #

∀ {α : Type u} [inst : Zero α], WithBot.unbot 0 ⋯ = 0

theorem WithBot.unbotD_one E0 #

∀ {α : Type u} [inst : One α] (d : α), WithBot.unbotD d 1 = 1

theorem WithBot.unbotD_zero E0 #

∀ {α : Type u} [inst : Zero α] (d : α), WithBot.unbotD d 0 = 0

theorem WithBot.coe_nonneg E0 #

∀ {α : Type u} [inst : Zero α] {a : α} [inst_1 : LE α], 0 ≤ ↑a ↔ 0 ≤ a

theorem WithBot.one_le_coe E0 #

∀ {α : Type u} [inst : One α] {a : α} [inst_1 : LE α], 1 ≤ ↑a ↔ 1 ≤ a

theorem WithBot.coe_le_zero E0 #

∀ {α : Type u} [inst : Zero α] {a : α} [inst_1 : LE α], ↑a ≤ 0 ↔ a ≤ 0

theorem WithBot.coe_le_one E0 #

∀ {α : Type u} [inst : One α] {a : α} [inst_1 : LE α], ↑a ≤ 1 ↔ a ≤ 1

theorem WithBot.one_lt_coe E0 #

∀ {α : Type u} [inst : One α] {a : α} [inst_1 : LT α], 1 < ↑a ↔ 1 < a

theorem WithBot.coe_pos E0 #

∀ {α : Type u} [inst : Zero α] {a : α} [inst_1 : LT α], 0 < ↑a ↔ 0 < a

theorem WithBot.coe_lt_one E0 #

∀ {α : Type u} [inst : One α] {a : α} [inst_1 : LT α], ↑a < 1 ↔ a < 1

theorem WithBot.coe_lt_zero E0 #

∀ {α : Type u} [inst : Zero α] {a : α} [inst_1 : LT α], ↑a < 0 ↔ a < 0

theorem WithBot.bot_neg E0 #

∀ {α : Type u} [inst : Zero α] [inst_1 : LT α], ⊥ < 0

theorem WithBot.bot_lt_one E0 #

∀ {α : Type u} [inst : One α] [inst_1 : LT α], ⊥ < 1

theorem WithBot.map_one E0 #

∀ {α : Type u} [inst : One α] {β : Type u_1} (f : α → β), WithBot.map f 1 = ↑(f 1)

theorem WithBot.map_zero E0 #

∀ {α : Type u} [inst : Zero α] {β : Type u_1} (f : α → β), WithBot.map f 0 = ↑(f 0)

theorem WithBot.map_eq_one_iff E0 #

∀ {β : Type v} {α : Type u_1} {f : α → β} {v : WithBot α} [inst : One β], WithBot.map f v = 1 ↔ ∃ x, v = ↑x ∧ f x = 1

theorem WithBot.map_eq_zero_iff E0 #

∀ {β : Type v} {α : Type u_1} {f : α → β} {v : WithBot α} [inst : Zero β], WithBot.map f v = 0 ↔ ∃ x, v = ↑x ∧ f x = 0

theorem WithBot.zero_eq_map_iff E0 #

∀ {β : Type v} {α : Type u_1} {f : α → β} {v : WithBot α} [inst : Zero β], 0 = WithBot.map f v ↔ ∃ x, v = ↑x ∧ f x = 0

theorem WithBot.one_eq_map_iff E0 #

∀ {β : Type v} {α : Type u_1} {f : α → β} {v : WithBot α} [inst : One β], 1 = WithBot.map f v ↔ ∃ x, v = ↑x ∧ f x = 1

instance WithBot.zeroLEOneClass E0 #

∀ {α : Type u} [inst : One α] [inst_1 : Zero α] [inst_2 : LE α] [ZeroLEOneClass α], ZeroLEOneClass (WithBot α)

theorem WithBot.lt_one_iff_eq_bot E1 #

∀ {α : Type u} [inst : One α] [inst_1 : Preorder α] [IsBotOneClass α] {a : WithBot α}, a < 1 ↔ a = ⊥

theorem WithBot.lt_zero_iff_eq_bot E1 #

∀ {α : Type u} [inst : Zero α] [inst_1 : Preorder α] [IsBotZeroClass α] {a : WithBot α}, a < 0 ↔ a = ⊥

instance WithBot.add E0 #

{α : Type u} → [Add α] → Add (WithBot α)

theorem WithBot.coe_add E0 #

∀ {α : Type u} [inst : Add α] (a b : α), ↑(a + b) = ↑a + ↑b

theorem WithBot.bot_add E0 #

∀ {α : Type u} [inst : Add α] (x : WithBot α), ⊥ + x = ⊥

theorem WithBot.add_bot E0 #

∀ {α : Type u} [inst : Add α] (x : WithBot α), x + ⊥ = ⊥

theorem WithBot.add_eq_bot E0 #

∀ {α : Type u} [inst : Add α] {x y : WithBot α}, x + y = ⊥ ↔ x = ⊥ ∨ y = ⊥

theorem WithBot.add_ne_bot E1 #

∀ {α : Type u} [inst : Add α] {x y : WithBot α}, x + y ≠ ⊥ ↔ x ≠ ⊥ ∧ y ≠ ⊥

theorem WithBot.bot_lt_add E0 #

∀ {α : Type u} [inst : Add α] {x y : WithBot α} [inst_1 : LT α], ⊥ < x + y ↔ ⊥ < x ∧ ⊥ < y

theorem WithBot.add_eq_coe E0 #

∀ {α : Type u} [inst : Add α] {a b : WithBot α} {c : α}, a + b = ↑c ↔ ∃ a' b', ↑a' = a ∧ ↑b' = b ∧ a' + b' = c

theorem WithBot.add_coe_eq_bot_iff E0 #

∀ {α : Type u} [inst : Add α] {x : WithBot α} {b : α}, x + ↑b = ⊥ ↔ x = ⊥

theorem WithBot.coe_add_eq_bot_iff E0 #

∀ {α : Type u} [inst : Add α] {y : WithBot α} {a : α}, ↑a + y = ⊥ ↔ y = ⊥

theorem IsAddLeftRegular.withBot E1 #

∀ {α : Type u} [inst : Add α] {a : α}, IsAddLeftRegular a → IsAddLeftRegular ↑a

theorem IsAddRightRegular.withBot E1 #

∀ {α : Type u} [inst : Add α] {a : α}, IsAddRightRegular a → IsAddRightRegular ↑a

theorem AddLECancellable.withBot E1 #

∀ {α : Type u} [inst : Add α] {a : α} [inst_1 : LE α], AddLECancellable a → AddLECancellable ↑a

theorem WithBot.add_right_inj E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithBot α} [IsRightCancelAdd α], z ≠ ⊥ → (x + z = y + z ↔ x = y)

theorem WithBot.add_right_cancel E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithBot α} [IsRightCancelAdd α], z ≠ ⊥ → x + z = y + z → x = y

theorem WithBot.add_left_inj E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithBot α} [IsLeftCancelAdd α], x ≠ ⊥ → (x + y = x + z ↔ y = z)

theorem WithBot.add_left_cancel E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithBot α} [IsLeftCancelAdd α], x ≠ ⊥ → x + y = x + z → y = z

instance WithBot.addLeftMono E0 #

∀ {α : Type u} [inst : Add α] [inst_1 : LE α] [AddLeftMono α], AddLeftMono (WithBot α)

instance WithBot.addRightMono E0 #

∀ {α : Type u} [inst : Add α] [inst_1 : LE α] [AddRightMono α], AddRightMono (WithBot α)

instance WithBot.addLeftReflectLT E0 #

∀ {α : Type u} [inst : Add α] [inst_1 : LT α] [AddLeftReflectLT α], AddLeftReflectLT (WithBot α)

instance WithBot.addRightReflectLT E0 #

∀ {α : Type u} [inst : Add α] [inst_1 : LT α] [AddRightReflectLT α], AddRightReflectLT (WithBot α)

theorem WithBot.le_of_add_le_add_left E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithBot α} [inst_1 : LE α] [AddLeftReflectLE α], x ≠ ⊥ → x + y ≤ x + z → y ≤ z

theorem WithBot.le_of_add_le_add_right E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithBot α} [inst_1 : LE α] [AddRightReflectLE α], z ≠ ⊥ → x + z ≤ y + z → x ≤ y

theorem WithBot.add_lt_add_left E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithBot α} [inst_1 : LT α] [AddLeftStrictMono α], x ≠ ⊥ → y < z → x + y < x + z

theorem WithBot.add_lt_add_right E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithBot α} [inst_1 : LT α] [AddRightStrictMono α], z ≠ ⊥ → x < y → x + z < y + z

theorem WithBot.add_le_add_iff_left E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithBot α} [inst_1 : LE α] [AddLeftMono α] [AddLeftReflectLE α],
  x ≠ ⊥ → (x + y ≤ x + z ↔ y ≤ z)

theorem WithBot.add_le_add_iff_right E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithBot α} [inst_1 : LE α] [AddRightMono α] [AddRightReflectLE α],
  z ≠ ⊥ → (x + z ≤ y + z ↔ x ≤ y)

theorem WithBot.add_lt_add_iff_left E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithBot α} [inst_1 : LT α] [AddLeftStrictMono α] [AddLeftReflectLT α],
  x ≠ ⊥ → (x + y < x + z ↔ y < z)

theorem WithBot.add_lt_add_iff_right E1 #

∀ {α : Type u} [inst : Add α] {x y z : WithBot α} [inst_1 : LT α] [AddRightStrictMono α] [AddRightReflectLT α],
  z ≠ ⊥ → (x + z < y + z ↔ x < y)

theorem WithBot.add_lt_add_of_le_of_lt E1 #

∀ {α : Type u} [inst : Add α] {w x y z : WithBot α} [inst_1 : Preorder α] [AddLeftStrictMono α] [AddRightMono α],
  w ≠ ⊥ → w ≤ y → x < z → w + x < y + z

theorem WithBot.add_lt_add_of_lt_of_le E1 #

∀ {α : Type u} [inst : Add α] {w x y z : WithBot α} [inst_1 : Preorder α] [AddLeftMono α] [AddRightStrictMono α],
  x ≠ ⊥ → w < y → x ≤ z → w + x < y + z

theorem WithBot.addLECancellable_of_ne_bot E1 #

∀ {α : Type u} [inst : Add α] {x : WithBot α} [inst_1 : LE α] [AddLeftReflectLE α], x ≠ ⊥ → AddLECancellable x

theorem WithBot.addLECancellable_of_lt_bot E1 #

∀ {α : Type u} [inst : Add α] {x : WithBot α} [inst_1 : Preorder α] [AddLeftReflectLE α], x < ⊥ → AddLECancellable x

theorem WithBot.addLECancellable_coe E0 #

∀ {α : Type u} [inst : Add α] [inst_1 : LE α] [AddLeftReflectLE α] (a : α), AddLECancellable ↑a

theorem WithBot.addLECancellable_iff_ne_bot E1 #

∀ {α : Type u} [inst : Add α] {x : WithBot α} [Nonempty α] [inst_2 : Preorder α] [AddLeftReflectLE α],
  AddLECancellable x ↔ x ≠ ⊥

theorem WithBot.add_le_add_iff_right' E1 #

∀ {α : Type u_1} [inst : Add α] [inst_1 : LE α] [AddRightMono α] [AddRightReflectLE α] {a b c : WithBot (WithTop α)},
  c ≠ ⊥ → c ≠ ⊤ → (a + c ≤ b + c ↔ a ≤ b)

Addition in WithBot (WithTop α) is right cancellative provided the element being cancelled is not ⊤ or ⊥.

theorem WithBot.map_add E0 #

∀ {α : Type u} {β : Type v} [inst : Add α] {F : Type u_1} [inst_1 : Add β] [inst_2 : FunLike F α β] [AddHomClass F α β]
  (f : F) (a b : WithBot α), WithBot.map (⇑f) (a + b) = WithBot.map (⇑f) a + WithBot.map (⇑f) b

instance WithBot.addSemigroup E0 #

{α : Type u} → [AddSemigroup α] → AddSemigroup (WithBot α)

instance WithBot.addCommSemigroup E0 #

{α : Type u} → [AddCommSemigroup α] → AddCommSemigroup (WithBot α)

instance WithBot.addZeroClass E0 #

{α : Type u} → [AddZeroClass α] → AddZeroClass (WithBot α)

instance WithBot.addMonoid E0 #

{α : Type u} → [AddMonoid α] → AddMonoid (WithBot α)

def WithBot.addHom E1 #

{α : Type u} → [inst : AddMonoid α] → α →+ WithBot α

Coercion from α to WithBot α as an AddMonoidHom.

theorem WithBot.coe_addHom E0 #

∀ {α : Type u} [inst : AddMonoid α], ⇑WithBot.addHom = WithBot.some

theorem WithBot.coe_nsmul E0 #

∀ {α : Type u} [inst : AddMonoid α] (a : α) (n : ℕ), ↑(n • a) = n • ↑a

instance WithBot.addCommMonoid E0 #

{α : Type u} → [AddCommMonoid α] → AddCommMonoid (WithBot α)

instance WithBot.instNatCast E0 #

{α : Type u} → [NatCast α] → NatCast (WithBot α)

theorem WithTop.untopD_natCast E0 #

∀ {α : Type u} [inst : NatCast α] (d : α) (n : ℕ), WithTop.untopD d ↑n = ↑n

theorem WithBot.unbotD_natCast E0 #

∀ {α : Type u} [inst : NatCast α] (d : α) (n : ℕ), WithBot.unbotD d ↑n = ↑n

theorem WithBot.unbotD_ofNat E0 #

∀ {α : Type u} [inst : NatCast α] (d : α) (n : ℕ) [inst_1 : n.AtLeastTwo],
  WithBot.unbotD d (OfNat.ofNat n) = OfNat.ofNat n

theorem WithTop.untopD_ofNat E0 #

∀ {α : Type u} [inst : NatCast α] (d : α) (n : ℕ) [inst_1 : n.AtLeastTwo],
  WithTop.untopD d (OfNat.ofNat n) = OfNat.ofNat n

instance WithBot.addMonoidWithOne E0 #

{α : Type u} → [AddMonoidWithOne α] → AddMonoidWithOne (WithBot α)

theorem WithBot.coe_natCast E0 #

∀ {α : Type u} [inst : AddMonoidWithOne α] (n : ℕ), ↑↑n = ↑n

theorem WithBot.natCast_ne_bot E0 #

∀ {α : Type u} [inst : AddMonoidWithOne α] (n : ℕ), ↑n ≠ ⊥

theorem WithBot.bot_ne_natCast E0 #

∀ {α : Type u} [inst : AddMonoidWithOne α] (n : ℕ), ⊥ ≠ ↑n

theorem WithBot.coe_ofNat E0 #

∀ {α : Type u} [inst : AddMonoidWithOne α] (n : ℕ) [inst_1 : n.AtLeastTwo], ↑(OfNat.ofNat n) = OfNat.ofNat n

theorem WithBot.coe_eq_ofNat E0 #

∀ {α : Type u} [inst : AddMonoidWithOne α] (n : ℕ) [inst_1 : n.AtLeastTwo] (m : α),
  ↑m = OfNat.ofNat n ↔ m = OfNat.ofNat n

theorem WithBot.ofNat_eq_coe E0 #

∀ {α : Type u} [inst : AddMonoidWithOne α] (n : ℕ) [inst_1 : n.AtLeastTwo] (m : α),
  OfNat.ofNat n = ↑m ↔ OfNat.ofNat n = m

theorem WithBot.ofNat_ne_bot E0 #

∀ {α : Type u} [inst : AddMonoidWithOne α] (n : ℕ) [inst_1 : n.AtLeastTwo], OfNat.ofNat n ≠ ⊥

theorem WithBot.bot_ne_ofNat E0 #

∀ {α : Type u} [inst : AddMonoidWithOne α] (n : ℕ) [inst_1 : n.AtLeastTwo], ⊥ ≠ OfNat.ofNat n

theorem WithBot.map_ofNat E0 #

∀ {α : Type u} {β : Type v} [inst : AddMonoidWithOne α] {f : α → β} (n : ℕ) [inst_1 : n.AtLeastTwo],
  WithBot.map f (OfNat.ofNat n) = ↑(f (OfNat.ofNat n))

theorem WithBot.map_natCast E0 #

∀ {α : Type u} {β : Type v} [inst : AddMonoidWithOne α] {f : α → β} (n : ℕ), WithBot.map f ↑n = ↑(f ↑n)

theorem WithBot.map_eq_ofNat_iff E0 #

∀ {α : Type u} {β : Type v} [inst : AddMonoidWithOne α] {f : β → α} {n : ℕ} [inst_1 : n.AtLeastTwo] {a : WithBot β},
  WithBot.map f a = OfNat.ofNat n ↔ ∃ x, a = ↑x ∧ f x = ↑n

theorem WithBot.ofNat_eq_map_iff E0 #

∀ {α : Type u} {β : Type v} [inst : AddMonoidWithOne α] {f : β → α} {n : ℕ} [inst_1 : n.AtLeastTwo] {a : WithBot β},
  OfNat.ofNat n = WithBot.map f a ↔ ∃ x, a = ↑x ∧ f x = ↑n

theorem WithBot.map_eq_natCast_iff E0 #

∀ {α : Type u} {β : Type v} [inst : AddMonoidWithOne α] {f : β → α} {n : ℕ} {a : WithBot β},
  WithBot.map f a = ↑n ↔ ∃ x, a = ↑x ∧ f x = ↑n

theorem WithBot.natCast_eq_map_iff E0 #

∀ {α : Type u} {β : Type v} [inst : AddMonoidWithOne α] {f : β → α} {n : ℕ} {a : WithBot β},
  ↑n = WithBot.map f a ↔ ∃ x, a = ↑x ∧ f x = ↑n

theorem WithBot.bot_lt_natCast E0 #

∀ {α : Type u} [inst : AddMonoidWithOne α] [inst_1 : LT α] (n : ℕ), ⊥ < ↑n

instance WithBot.charZero E0 #

∀ {α : Type u} [inst : AddMonoidWithOne α] [CharZero α], CharZero (WithBot α)

instance WithBot.addCommMonoidWithOne E0 #

{α : Type u} → [AddCommMonoidWithOne α] → AddCommMonoidWithOne (WithBot α)

def OneHom.withBotMap E1 #

{M : Type u_1} → {N : Type u_2} → [inst : One M] → [inst_1 : One N] → OneHom M N → OneHom (WithBot M) (WithBot N)

A version of WithBot.map for OneHoms.

def ZeroHom.withBotMap E1 #

{M : Type u_1} → {N : Type u_2} → [inst : Zero M] → [inst_1 : Zero N] → ZeroHom M N → ZeroHom (WithBot M) (WithBot N)

A version of WithBot.map for ZeroHoms

theorem ZeroHom.withBotMap_apply E0 #

∀ {M : Type u_1} {N : Type u_2} [inst : Zero M] [inst_1 : Zero N] (f : ZeroHom M N), ⇑f.withBotMap = WithBot.map ⇑f

theorem OneHom.withBotMap_apply E0 #

∀ {M : Type u_1} {N : Type u_2} [inst : One M] [inst_1 : One N] (f : OneHom M N), ⇑f.withBotMap = WithBot.map ⇑f

def AddHom.withBotMap E1 #

{M : Type u_1} → {N : Type u_2} → [inst : Add M] → [inst_1 : Add N] → (M →ₙ+ N) → WithBot M →ₙ+ WithBot N

A version of WithBot.map for AddHoms.

theorem AddHom.withBotMap_apply E0 #

∀ {M : Type u_1} {N : Type u_2} [inst : Add M] [inst_1 : Add N] (f : M →ₙ+ N), ⇑f.withBotMap = WithBot.map ⇑f

def AddMonoidHom.withBotMap E1 #

{M : Type u_1} →
  {N : Type u_2} → [inst : AddZeroClass M] → [inst_1 : AddZeroClass N] → (M →+ N) → WithBot M →+ WithBot N

A version of WithBot.map for AddMonoidHoms.

theorem AddMonoidHom.withBotMap_apply E0 #

∀ {M : Type u_1} {N : Type u_2} [inst : AddZeroClass M] [inst_1 : AddZeroClass N] (f : M →+ N),
  ⇑f.withBotMap = WithBot.map ⇑f

def AddEquiv.withBotCongr E1 #

{α : Type u} → {β : Type v} → [inst : Add α] → [inst_1 : Add β] → α ≃+ β → WithBot α ≃+ WithBot β

A AddEquiv version of Equiv.withBotCongr.

theorem AddEquiv.withTopCongr_apply E0 #

∀ {α : Type u} {β : Type v} [inst : Add α] [inst_1 : Add β] (e : α ≃+ β) (a : WithTop α),
  e.withTopCongr a = WithTop.map (⇑e) a

theorem AddEquiv.withBotCongr_apply E0 #

∀ {α : Type u} {β : Type v} [inst : Add α] [inst_1 : Add β] (e : α ≃+ β) (a : WithBot α),
  e.withBotCongr a = WithBot.map (⇑e) a

def AddEquiv.withTopCongr E1 #

{α : Type u} → {β : Type v} → [inst : Add α] → [inst_1 : Add β] → α ≃+ β → WithTop α ≃+ WithTop β

A AddEquiv version of Equiv.withTopCongr.

theorem AddEquiv.coe_withBotCongr E0 #

∀ {α : Type u} {β : Type v} [inst : Add α] [inst_1 : Add β] (e : α ≃+ β), ⇑e.withBotCongr = WithBot.map ⇑e

theorem AddEquiv.coe_withTopCongr E0 #

∀ {α : Type u} {β : Type v} [inst : Add α] [inst_1 : Add β] (e : α ≃+ β), ⇑e.withTopCongr = WithTop.map ⇑e

theorem AddEquiv.withTopCongr_toEquiv E0 #

∀ {α : Type u} {β : Type v} [inst : Add α] [inst_1 : Add β] (e : α ≃+ β), ↑e.withTopCongr = (↑e).withTopCongr

theorem AddEquiv.withBotCongr_toEquiv E0 #

∀ {α : Type u} {β : Type v} [inst : Add α] [inst_1 : Add β] (e : α ≃+ β), ↑e.withBotCongr = (↑e).withBotCongr

theorem AddEquiv.withBotCongr_toAddHom E0 #

∀ {α : Type u} {β : Type v} [inst : Add α] [inst_1 : Add β] (e : α ≃+ β), ↑e.withBotCongr = (↑e).withBotMap

theorem AddEquiv.withTopCongr_toAddHom E0 #

∀ {α : Type u} {β : Type v} [inst : Add α] [inst_1 : Add β] (e : α ≃+ β), ↑e.withTopCongr = (↑e).withBotMap

theorem AddEquiv.withBotCongr_refl E0 #

∀ {α : Type u} [inst : Add α], (AddEquiv.refl α).withBotCongr = AddEquiv.refl (WithBot α)

theorem AddEquiv.withTopCongr_refl E0 #

∀ {α : Type u} [inst : Add α], (AddEquiv.refl α).withTopCongr = AddEquiv.refl (WithTop α)

theorem AddEquiv.withBotCongr_symm E0 #

∀ {α : Type u} {β : Type v} [inst : Add α] [inst_1 : Add β] (e : α ≃+ β), e.withBotCongr.symm = e.symm.withBotCongr

theorem AddEquiv.withTopCongr_symm E0 #

∀ {α : Type u} {β : Type v} [inst : Add α] [inst_1 : Add β] (e : α ≃+ β), e.withTopCongr.symm = e.symm.withTopCongr

theorem AddEquiv.withTopCongr_trans E0 #

∀ {α : Type u} {β : Type v} {γ : Type u_1} [inst : Add α] [inst_1 : Add β] [inst_2 : Add γ] (e₁ : α ≃+ β) (e₂ : β ≃+ γ),
  (e₁.trans e₂).withTopCongr = e₁.withTopCongr.trans e₂.withTopCongr

theorem AddEquiv.withBotCongr_trans E0 #

∀ {α : Type u} {β : Type v} {γ : Type u_1} [inst : Add α] [inst_1 : Add β] [inst_2 : Add γ] (e₁ : α ≃+ β) (e₂ : β ≃+ γ),
  (e₁.trans e₂).withBotCongr = e₁.withBotCongr.trans e₂.withBotCongr