Theorem: WithZero.covariantClass_add_le
File: Mathlib/Algebra/Order/Monoid/WithZero/Defs.lean

tactic: refine ⟨fun a b c hbc => ?_⟩
state_before: α : Type u
inst✝² : AddZeroClass α
inst✝¹ : Preorder α
inst✝ : CovariantClass α α (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
h : ∀ (a : α), 0 ≤ a
⊢ CovariantClass (WithZero α) (WithZero α) (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1

tactic: induction a using WithZero.recZeroCoe
state_before: α : Type u
inst✝² : AddZeroClass α
inst✝¹ : Preorder α
inst✝ : CovariantClass α α (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
h : ∀ (a : α), 0 ≤ a
a b c : WithZero α
hbc : b ≤ c
⊢ a + b ≤ a + c

tactic: induction b using WithZero.recZeroCoe
state_before: case h₂
α : Type u
inst✝² : AddZeroClass α
inst✝¹ : Preorder α
inst✝ : CovariantClass α α (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
h : ∀ (a : α), 0 ≤ a
b c : WithZero α
hbc : b ≤ c
a✝ : α
⊢ ↑a✝ + b ≤ ↑a✝ + c

tactic: rwa [zero_add, zero_add]
state_before: case h₁
α : Type u
inst✝² : AddZeroClass α
inst✝¹ : Preorder α
inst✝ : CovariantClass α α (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
h : ∀ (a : α), 0 ≤ a
b c : WithZero α
hbc : b ≤ c
⊢ 0 + b ≤ 0 + c

tactic: rw [add_zero]
state_before: case h₂.h₁
α : Type u
inst✝² : AddZeroClass α
inst✝¹ : Preorder α
inst✝ : CovariantClass α α (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
h : ∀ (a : α), 0 ≤ a
c : WithZero α
a✝ : α
hbc : 0 ≤ c
⊢ ↑a✝ + 0 ≤ ↑a✝ + c

tactic: induction c using WithZero.recZeroCoe
state_before: case h₂.h₁
α : Type u
inst✝² : AddZeroClass α
inst✝¹ : Preorder α
inst✝ : CovariantClass α α (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
h : ∀ (a : α), 0 ≤ a
c : WithZero α
a✝ : α
hbc : 0 ≤ c
⊢ ↑a✝ ≤ ↑a✝ + c

tactic: rw [add_zero]
state_before: case h₂.h₁.h₁
α : Type u
inst✝² : AddZeroClass α
inst✝¹ : Preorder α
inst✝ : CovariantClass α α (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
h : ∀ (a : α), 0 ≤ a
a✝ : α
hbc : 0 ≤ 0
⊢ ↑a✝ ≤ ↑a✝ + 0

tactic: rw [← coe_add, coe_le_coe]
state_before: case h₂.h₁.h₂
α : Type u
inst✝² : AddZeroClass α
inst✝¹ : Preorder α
inst✝ : CovariantClass α α (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
h : ∀ (a : α), 0 ≤ a
a✝¹ a✝ : α
hbc : 0 ≤ ↑a✝
⊢ ↑a✝¹ ≤ ↑a✝¹ + ↑a✝

tactic: exact le_add_of_nonneg_right (h _)
state_before: case h₂.h₁.h₂
α : Type u
inst✝² : AddZeroClass α
inst✝¹ : Preorder α
inst✝ : CovariantClass α α (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
h : ∀ (a : α), 0 ≤ a
a✝¹ a✝ : α
hbc : 0 ≤ ↑a✝
⊢ a✝¹ ≤ a✝¹ + a✝

tactic: rcases WithBot.coe_le_iff.1 hbc with ⟨c, rfl, hbc'⟩
state_before: case h₂.h₂
α : Type u
inst✝² : AddZeroClass α
inst✝¹ : Preorder α
inst✝ : CovariantClass α α (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
h : ∀ (a : α), 0 ≤ a
c : WithZero α
a✝¹ a✝ : α
hbc : ↑a✝ ≤ c
⊢ ↑a✝¹ + ↑a✝ ≤ ↑a✝¹ + c

tactic: refine le_trans ?_ (le_of_eq <| coe_add _ _)
state_before: case h₂.h₂.intro.intro
α : Type u
inst✝² : AddZeroClass α
inst✝¹ : Preorder α
inst✝ : CovariantClass α α (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
h : ∀ (a : α), 0 ≤ a
a✝¹ a✝ c : α
hbc' : a✝ ≤ c
hbc : ↑a✝ ≤ ↑c
⊢ ↑a✝¹ + ↑a✝ ≤ ↑a✝¹ + ↑c

tactic: rw [← coe_add, coe_le_coe]
state_before: case h₂.h₂.intro.intro
α : Type u
inst✝² : AddZeroClass α
inst✝¹ : Preorder α
inst✝ : CovariantClass α α (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
h : ∀ (a : α), 0 ≤ a
a✝¹ a✝ c : α
hbc' : a✝ ≤ c
hbc : ↑a✝ ≤ ↑c
⊢ ↑a✝¹ + ↑a✝ ≤ ↑(a✝¹ + c)

tactic: exact add_le_add_left hbc' _
state_before: case h₂.h₂.intro.intro
α : Type u
inst✝² : AddZeroClass α
inst✝¹ : Preorder α
inst✝ : CovariantClass α α (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
h : ∀ (a : α), 0 ≤ a
a✝¹ a✝ c : α
hbc' : a✝ ≤ c
hbc : ↑a✝ ≤ ↑c
⊢ a✝¹ + a✝ ≤ a✝¹ + c