File: Mathlib/Algebra/Order/Ring/WithTop.lean

full_name: WithTop.instMulZeroClass
code: instance instMulZeroClass : MulZeroClass (WithTop α) 
goal: MulZeroClass (WithTop α)

full_name: WithTop.coe_mul
code: @[simp, norm_cast] lemma coe_mul (a b : α) : (↑(a * b) : WithTop α) = a * b 
goal: ↑(a * b) = ↑a * ↑b

full_name: WithTop.mul_top'
code: lemma mul_top' : ∀ (a : WithTop α), a * ⊤ = if a = 0 then 0 else ⊤
  
goal: a * ⊤ = if a = 0 then 0 else ⊤

full_name: WithTop.mul_top
code: @[simp] lemma mul_top (h : a ≠ 0) : a * ⊤ = ⊤ 
goal: a * ⊤ = ⊤

full_name: WithTop.top_mul'
code: lemma top_mul' : ∀ (b : WithTop α), ⊤ * b = if b = 0 then 0 else ⊤
  
goal: ⊤ * b = if b = 0 then 0 else ⊤

full_name: WithTop.top_mul
code: @[simp] lemma top_mul (hb : b ≠ 0) : ⊤ * b = ⊤ 
goal: ⊤ * b = ⊤

full_name: WithTop.top_mul_top
code: @[simp] lemma top_mul_top : (⊤ * ⊤ : WithTop α) = ⊤ 
goal: ⊤ * ⊤ = ⊤

full_name: WithTop.mul_def
code: lemma mul_def (a b : WithTop α) :
    a * b = if a = 0 ∨ b = 0 then 0 else WithTop.map₂ (· * ·) a b 
goal: a * b = if a = 0 ∨ b = 0 then 0 else WithTop.map₂ (fun x x_1 => x * x_1) a b

full_name: WithTop.mul_eq_top_iff
code: lemma mul_eq_top_iff : a * b = ⊤ ↔ a ≠ 0 ∧ b = ⊤ ∨ a = ⊤ ∧ b ≠ 0 
goal: a * b = ⊤ ↔ a ≠ 0 ∧ b = ⊤ ∨ a = ⊤ ∧ b ≠ 0

full_name: WithTop.mul_coe_eq_bind
code: lemma mul_coe_eq_bind {b : α} (hb : b ≠ 0) : ∀ a, (a * b : WithTop α) = a.bind fun a ↦ ↑(a * b)
  
goal: a * ↑b = Option.bind a fun a => some (a * b)

full_name: WithTop.coe_mul_eq_bind
code: lemma coe_mul_eq_bind {a : α} (ha : a ≠ 0) : ∀ b, (a * b : WithTop α) = b.bind fun b ↦ ↑(a * b)
  
goal: ↑a * b = Option.bind b fun b => some (a * b)

full_name: WithTop.untop'_zero_mul
code: @[simp] lemma untop'_zero_mul (a b : WithTop α) : (a * b).untop' 0 = a.untop' 0 * b.untop' 0 
goal: WithTop.untop' 0 (a * b) = WithTop.untop' 0 a * WithTop.untop' 0 b

full_name: WithTop.mul_lt_top'
code: theorem mul_lt_top' [LT α] {a b : WithTop α} (ha : a < ⊤) (hb : b < ⊤) : a * b < ⊤ 
goal: a * b < ⊤

full_name: WithTop.mul_lt_top
code: theorem mul_lt_top [LT α] {a b : WithTop α} (ha : a ≠ ⊤) (hb : b ≠ ⊤) : a * b < ⊤ 
goal: a * b < ⊤

full_name: WithTop.instNoZeroDivisors
code: instance instNoZeroDivisors [NoZeroDivisors α] : NoZeroDivisors (WithTop α) 
goal: NoZeroDivisors (WithTop α)

full_name: WithTop.instMulZeroOneClass
code: /-- `Nontrivial α` is needed here as otherwise we have `1 * ⊤ = ⊤` but also `0 * ⊤ = 0`. -/
instance instMulZeroOneClass [MulZeroOneClass α] [Nontrivial α] : MulZeroOneClass (WithTop α) 
goal: MulZeroOneClass (WithTop α)

full_name: MonoidWithZeroHom.withTopMap_apply
code: /-- A version of `WithTop.map` for `MonoidWithZeroHom`s. -/
@[simps (config := .asFn)]
protected def _root_.MonoidWithZeroHom.withTopMap {R S : Type*} [MulZeroOneClass R] [DecidableEq R]
    [Nontrivial R] [MulZeroOneClass S] [DecidableEq S] [Nontrivial S] (f : R →*₀ S)
    (hf : Function.Injective f) : WithTop R →*₀ WithTop S 
goal: ⇑(f.withTopMap hf) = WithTop.map ⇑f

full_name: MonoidWithZeroHom.withTopMap
code: /-- A version of `WithTop.map` for `MonoidWithZeroHom`s. -/
@[simps (config := .asFn)]
protected def _root_.MonoidWithZeroHom.withTopMap {R S : Type*} [MulZeroOneClass R] [DecidableEq R]
    [Nontrivial R] [MulZeroOneClass S] [DecidableEq S] [Nontrivial S] (f : R →*₀ S)
    (hf : Function.Injective f) : WithTop R →*₀ WithTop S 
goal: WithTop R →*₀ WithTop S

full_name: WithTop.instSemigroupWithZero
code: instance instSemigroupWithZero [SemigroupWithZero α] [NoZeroDivisors α] :
    SemigroupWithZero (WithTop α) 
goal: SemigroupWithZero (WithTop α)

full_name: WithTop.instMonoidWithZero
code: instance instMonoidWithZero : MonoidWithZero (WithTop α) 
goal: MonoidWithZero (WithTop α)

full_name: WithTop.coe_pow
code: @[simp, norm_cast] lemma coe_pow (a : α) (n : ℕ) : (↑(a ^ n) : WithTop α) = a ^ n 
goal: ↑(a ^ n) = ↑a ^ n

full_name: WithTop.top_pow
code: theorem top_pow {n : ℕ} (n_pos : 0 < n) : (⊤ : WithTop α) ^ n = ⊤ 
goal: ⊤ ^ n = ⊤

full_name: WithTop.instCommMonoidWithZero
code: instance instCommMonoidWithZero [CommMonoidWithZero α] [NoZeroDivisors α] [Nontrivial α] :
    CommMonoidWithZero (WithTop α) 
goal: CommMonoidWithZero (WithTop α)

full_name: _private.Mathlib.Algebra.Order.Ring.WithTop.0.WithTop.distrib'
code: private theorem distrib' (a b c : WithTop α) : (a + b) * c = a * c + b * c 
goal: (a + b) * c = a * c + b * c

full_name: WithTop.commSemiring
code: /-- This instance requires `CanonicallyOrderedCommSemiring` as it is the smallest class
that derives from both `NonAssocNonUnitalSemiring` and `CanonicallyOrderedAddCommMonoid`, both
of which are required for distributivity. -/
instance commSemiring [Nontrivial α] : CommSemiring (WithTop α) 
goal: CommSemiring (WithTop α)

full_name: WithTop.instCanonicallyOrderedCommSemiringOfNontrivial
code: instance [Nontrivial α] : CanonicallyOrderedCommSemiring (WithTop α) 
goal: CanonicallyOrderedCommSemiring (WithTop α)

full_name: RingHom.withTopMap_apply
code: /-- A version of `WithTop.map` for `RingHom`s. -/
@[simps (config := .asFn)]
protected def _root_.RingHom.withTopMap {R S : Type*} [CanonicallyOrderedCommSemiring R]
    [DecidableEq R] [Nontrivial R] [CanonicallyOrderedCommSemiring S] [DecidableEq S] [Nontrivial S]
    (f : R →+* S) (hf : Function.Injective f) : WithTop R →+* WithTop S 
goal: ⇑(f.withTopMap hf) = (↑(f.toMonoidWithZeroHom.withTopMap hf)).toFun

full_name: RingHom.withTopMap
code: /-- A version of `WithTop.map` for `RingHom`s. -/
@[simps (config := .asFn)]
protected def _root_.RingHom.withTopMap {R S : Type*} [CanonicallyOrderedCommSemiring R]
    [DecidableEq R] [Nontrivial R] [CanonicallyOrderedCommSemiring S] [DecidableEq S] [Nontrivial S]
    (f : R →+* S) (hf : Function.Injective f) : WithTop R →+* WithTop S 
goal: WithTop R →+* WithTop S

full_name: WithBot.instMulZeroClass
code: instance : MulZeroClass (WithBot α) 
goal: MulZeroClass (WithBot α)

full_name: WithBot.coe_mul
code: @[simp, norm_cast] lemma coe_mul (a b : α) : (↑(a * b) : WithBot α) = a * b 
goal: ↑(a * b) = ↑a * ↑b

full_name: WithBot.mul_bot'
code: lemma mul_bot' : ∀ (a : WithBot α), a * ⊥ = if a = 0 then 0 else ⊥
  
goal: a * ⊥ = if a = 0 then 0 else ⊥

full_name: WithBot.mul_bot
code: @[simp] lemma mul_bot (h : a ≠ 0) : a * ⊥ = ⊥ 
goal: a * ⊥ = ⊥

full_name: WithBot.bot_mul'
code: lemma bot_mul' : ∀ (b : WithBot α), ⊥ * b = if b = 0 then 0 else ⊥
  
goal: ⊥ * b = if b = 0 then 0 else ⊥

full_name: WithBot.bot_mul
code: @[simp] lemma bot_mul (hb : b ≠ 0) : ⊥ * b = ⊥ 
goal: ⊥ * b = ⊥

full_name: WithBot.bot_mul_bot
code: @[simp] lemma bot_mul_bot : (⊥ * ⊥ : WithBot α) = ⊥ 
goal: ⊥ * ⊥ = ⊥

full_name: WithBot.mul_def
code: lemma mul_def (a b : WithBot α) :
    a * b = if a = 0 ∨ b = 0 then 0 else WithBot.map₂ (· * ·) a b 
goal: a * b = if a = 0 ∨ b = 0 then 0 else WithBot.map₂ (fun x x_1 => x * x_1) a b

full_name: WithBot.mul_eq_bot_iff
code: lemma mul_eq_bot_iff : a * b = ⊥ ↔ a ≠ 0 ∧ b = ⊥ ∨ a = ⊥ ∧ b ≠ 0 
goal: a * b = ⊥ ↔ a ≠ 0 ∧ b = ⊥ ∨ a = ⊥ ∧ b ≠ 0

full_name: WithBot.mul_coe_eq_bind
code: lemma mul_coe_eq_bind {b : α} (hb : b ≠ 0) : ∀ a, (a * b : WithBot α) = a.bind fun a ↦ ↑(a * b)
  
goal: a * ↑b = Option.bind a fun a => some (a * b)

full_name: WithBot.coe_mul_eq_bind
code: lemma coe_mul_eq_bind {a : α} (ha : a ≠ 0) : ∀ b, (a * b : WithBot α) = b.bind fun b ↦ ↑(a * b)
  
goal: ↑a * b = Option.bind b fun b => some (a * b)

full_name: WithBot.unbot'_zero_mul
code: @[simp]
lemma unbot'_zero_mul (a b : WithBot α) : (a * b).unbot' 0 = a.unbot' 0 * b.unbot' 0 
goal: WithBot.unbot' 0 (a * b) = WithBot.unbot' 0 a * WithBot.unbot' 0 b

full_name: WithBot.bot_lt_mul'
code: theorem bot_lt_mul' [LT α] {a b : WithBot α} (ha : ⊥ < a) (hb : ⊥ < b) : ⊥ < a * b 
goal: ⊥ < a * b

full_name: WithBot.bot_lt_mul
code: theorem bot_lt_mul [LT α] {a b : WithBot α} (ha : a ≠ ⊥) (hb : b ≠ ⊥) : ⊥ < a * b 
goal: ⊥ < a * b

full_name: WithBot.instNoZeroDivisors
code: instance instNoZeroDivisors [NoZeroDivisors α] : NoZeroDivisors (WithBot α) 
goal: NoZeroDivisors (WithBot α)

full_name: WithBot.instMulZeroOneClass
code: /-- `Nontrivial α` is needed here as otherwise we have `1 * ⊥ = ⊥` but also `= 0 * ⊥ = 0`. -/
instance instMulZeroOneClass [MulZeroOneClass α] [Nontrivial α] : MulZeroOneClass (WithBot α) 
goal: MulZeroOneClass (WithBot α)

full_name: WithBot.instSemigroupWithZero
code: instance instSemigroupWithZero [SemigroupWithZero α] [NoZeroDivisors α] :
    SemigroupWithZero (WithBot α) 
goal: SemigroupWithZero (WithBot α)

full_name: WithBot.instMonoidWithZero
code: instance instMonoidWithZero : MonoidWithZero (WithBot α) 
goal: MonoidWithZero (WithBot α)

full_name: WithBot.coe_pow
code: @[simp, norm_cast] lemma coe_pow (a : α) (n : ℕ) : (↑(a ^ n) : WithBot α) = a ^ n 
goal: ↑(a ^ n) = ↑a ^ n

full_name: WithBot.commMonoidWithZero
code: instance commMonoidWithZero [CommMonoidWithZero α] [NoZeroDivisors α] [Nontrivial α] :
    CommMonoidWithZero (WithBot α) 
goal: CommMonoidWithZero (WithBot α)

full_name: WithBot.commSemiring
code: instance commSemiring [CanonicallyOrderedCommSemiring α] [Nontrivial α] :
    CommSemiring (WithBot α) 
goal: CommSemiring (WithBot α)

full_name: WithBot.instPosMulMono
code: instance [MulZeroClass α] [Preorder α] [PosMulMono α] : PosMulMono (WithBot α) 
goal: PosMulMono (WithBot α)

full_name: WithBot.instMulPosMono
code: instance [MulZeroClass α] [Preorder α] [MulPosMono α] : MulPosMono (WithBot α) 
goal: MulPosMono (WithBot α)

full_name: WithBot.instPosMulStrictMono
code: instance [MulZeroClass α] [Preorder α] [PosMulStrictMono α] : PosMulStrictMono (WithBot α) 
goal: PosMulStrictMono (WithBot α)

full_name: WithBot.instMulPosStrictMono
code: instance [MulZeroClass α] [Preorder α] [MulPosStrictMono α] : MulPosStrictMono (WithBot α) 
goal: MulPosStrictMono (WithBot α)

full_name: WithBot.instPosMulReflectLT
code: instance [MulZeroClass α] [Preorder α] [PosMulReflectLT α] : PosMulReflectLT (WithBot α) 
goal: PosMulReflectLT (WithBot α)

full_name: WithBot.instMulPosReflectLT
code: instance [MulZeroClass α] [Preorder α] [MulPosReflectLT α] : MulPosReflectLT (WithBot α) 
goal: MulPosReflectLT (WithBot α)

full_name: WithBot.instPosMulReflectLE
code: instance [MulZeroClass α] [Preorder α] [PosMulReflectLE α] : PosMulReflectLE (WithBot α) 
goal: PosMulReflectLE (WithBot α)

full_name: WithBot.instMulPosReflectLE
code: instance [MulZeroClass α] [Preorder α] [MulPosReflectLE α] : MulPosReflectLE (WithBot α) 
goal: MulPosReflectLE (WithBot α)

full_name: WithBot.orderedCommSemiring
code: instance orderedCommSemiring [CanonicallyOrderedCommSemiring α] [Nontrivial α] :
    OrderedCommSemiring (WithBot α) 
goal: OrderedCommSemiring (WithBot α)