ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
Theorem: Asymptotics.isBigO_neg_right
File: Mathlib/Analysis/Asymptotics/Asymptotics.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
G : Type u_5
E' : Type u_6
F' : Type u_7
G' : Type u_8
E'' : Type u_9
F'' : Type u_10
G'' : Type u_11
E''' : Type u_12
R : Type u_13
R' : Type u_14
𝕜 : Type u_15
𝕜' : Type u_16
inst✝¹³ : Norm E
inst✝¹² : Norm F
inst✝¹¹ : Norm G
inst✝¹⁰ : SeminormedAddCommGroup E'
inst✝⁹ : SeminormedAddCommGroup F'
inst✝⁸ : SeminormedAddCommGroup G'
inst✝⁷ : NormedAddCommGroup E''
inst✝⁶ : NormedAddCommGroup F''
inst✝⁵ : NormedAddCommGroup G''
inst✝⁴ : SeminormedRing R
inst✝³ : SeminormedAddGroup E'''
inst✝² : SeminormedRing R'
inst✝¹ : NormedDivisionRing 𝕜
inst✝ : NormedDivisionRing 𝕜'
c c' c₁ c₂ : ℝ
f : α → E
g : α → F
k : α → G
f' : α → E'
g' : α → F'
k' : α → G'
f'' : α → E''
g'' : α → F''
k'' : α → G''
l l' : Filter α
⊢ (f =O[l] fun x => -g' x) ↔ f =O[l] g'
state_after: α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
G : Type u_5
E' : Type u_6
F' : Type u_7
G' : Type u_8
E'' : Type u_9
F'' : Type u_10
G'' : Type u_11
E''' : Type u_12
R : Type u_13
R' : Type u_14
𝕜 : Type u_15
𝕜' : Type u_16
inst✝¹³ : Norm E
inst✝¹² : Norm F
inst✝¹¹ : Norm G
inst✝¹⁰ : SeminormedAddCommGroup E'
inst✝⁹ : SeminormedAddCommGroup F'
inst✝⁸ : SeminormedAddCommGroup G'
inst✝⁷ : NormedAddCommGroup E''
inst✝⁶ : NormedAddCommGroup F''
inst✝⁵ : NormedAddCommGroup G''
inst✝⁴ : SeminormedRing R
inst✝³ : SeminormedAddGroup E'''
inst✝² : SeminormedRing R'
inst✝¹ : NormedDivisionRing 𝕜
inst✝ : NormedDivisionRing 𝕜'
c c' c₁ c₂ : ℝ
f : α → E
g : α → F
k : α → G
f' : α → E'
g' : α → F'
k' : α → G'
f'' : α → E''
g'' : α → F''
k'' : α → G''
l l' : Filter α
⊢ (∃ c, IsBigOWith c l f fun x => -g' x) ↔ ∃ c, IsBigOWith c l f g'
tactic: simp only [IsBigO_def]
state_before: α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
G : Type u_5
E' : Type u_6
F' : Type u_7
G' : Type u_8
E'' : Type u_9
F'' : Type u_10
G'' : Type u_11
E''' : Type u_12
R : Type u_13
R' : Type u_14
𝕜 : Type u_15
𝕜' : Type u_16
inst✝¹³ : Norm E
inst✝¹² : Norm F
inst✝¹¹ : Norm G
inst✝¹⁰ : SeminormedAddCommGroup E'
inst✝⁹ : SeminormedAddCommGroup F'
inst✝⁸ : SeminormedAddCommGroup G'
inst✝⁷ : NormedAddCommGroup E''
inst✝⁶ : NormedAddCommGroup F''
inst✝⁵ : NormedAddCommGroup G''
inst✝⁴ : SeminormedRing R
inst✝³ : SeminormedAddGroup E'''
inst✝² : SeminormedRing R'
inst✝¹ : NormedDivisionRing 𝕜
inst✝ : NormedDivisionRing 𝕜'
c c' c₁ c₂ : ℝ
f : α → E
g : α → F
k : α → G
f' : α → E'
g' : α → F'
k' : α → G'
f'' : α → E''
g'' : α → F''
k'' : α → G''
l l' : Filter α
⊢ (∃ c, IsBigOWith c l f fun x => -g' x) ↔ ∃ c, IsBigOWith c l f g'
state_after: no goals
tactic: exact exists_congr fun _ => isBigOWith_neg_right
Theorem: Nat.coprime_self_add_left
File: Mathlib/Data/Nat/GCD/Basic.lean

Proof steps:
state_before: m n : ℕ
⊢ (m + n).Coprime m ↔ n.Coprime m
state_after: no goals
tactic: rw [Coprime, Coprime, gcd_self_add_left]
Theorem: Lists.Equiv.trans
File: Mathlib/SetTheory/Lists.lean

Proof steps:
state_before: α : Type u_1
⊢ ∀ {l₁ l₂ l₃ : Lists α}, l₁ ~ l₂ → l₂ ~ l₃ → l₁ ~ l₃
state_after: α : Type u_1
trans : Lists α → Prop := fun l₁ => ∀ ⦃l₂ l₃ : Lists α⦄, l₁ ~ l₂ → l₂ ~ l₃ → l₁ ~ l₃
⊢ ∀ {l₁ l₂ l₃ : Lists α}, l₁ ~ l₂ → l₂ ~ l₃ → l₁ ~ l₃
tactic: let trans := fun l₁ : Lists α => ∀ ⦃l₂ l₃⦄, l₁ ~ l₂ → l₂ ~ l₃ → l₁ ~ l₃
state_before: α : Type u_1
trans : Lists α → Prop := fun l₁ => ∀ ⦃l₂ l₃ : Lists α⦄, l₁ ~ l₂ → l₂ ~ l₃ → l₁ ~ l₃
⊢ ∀ {l₁ l₂ l₃ : Lists α}, l₁ ~ l₂ → l₂ ~ l₃ → l₁ ~ l₃
state_after: α : Type u_1
trans : Lists α → Prop := fun l₁ => ∀ ⦃l₂ l₃ : Lists α⦄, l₁ ~ l₂ → l₂ ~ l₃ → l₁ ~ l₃
⊢ PProd (∀ (l₁ : Lists α), trans l₁) (∀ (l : Lists' α true), ∀ l' ∈ l.toList, trans l')
tactic: suffices PProd (∀ l₁, trans l₁) (∀ (l : Lists' α true), ∀ l' ∈ l.toList, trans l') by exact this.1
state_before: α : Type u_1
trans : Lists α → Prop := fun l₁ => ∀ ⦃l₂ l₃ : Lists α⦄, l₁ ~ l₂ → l₂ ~ l₃ → l₁ ~ l₃
⊢ PProd (∀ (l₁ : Lists α), trans l₁) (∀ (l : Lists' α true), ∀ l' ∈ l.toList, trans l')
state_after: case C0
α : Type u_1
trans : Lists α → Prop := fun l₁ => ∀ ⦃l₂ l₃ : Lists α⦄, l₁ ~ l₂ → l₂ ~ l₃ → l₁ ~ l₃
⊢ ∀ (a : α), trans (atom a)

case C1
α : Type u_1
trans : Lists α → Prop := fun l₁ => ∀ ⦃l₂ l₃ : Lists α⦄, l₁ ~ l₂ → l₂ ~ l₃ → l₁ ~ l₃
⊢ ∀ (l : Lists' α true), (∀ l' ∈ l.toList, trans l') → trans (of' l)

case D0
α : Type u_1
trans : Lists α → Prop := fun l₁ => ∀ ⦃l₂ l₃ : Lists α⦄, l₁ ~ l₂ → l₂ ~ l₃ → l₁ ~ l₃
⊢ ∀ l' ∈ Lists'.nil.toList, trans l'

case D1
α : Type u_1
trans : Lists α → Prop := fun l₁ => ∀ ⦃l₂ l₃ : Lists α⦄, l₁ ~ l₂ → l₂ ~ l₃ → l₁ ~ l₃
⊢ ∀ (a : Lists α) (l : Lists' α true), trans a → (∀ l' ∈ l.toList, trans l') → ∀ l' ∈ (Lists'.cons a l).toList, trans l'
tactic: apply inductionMut
Theorem: Matrix.linfty_opNNNorm_diagonal
File: Mathlib/Analysis/Matrix.lean

Proof steps:
state_before: R : Type u_1
l : Type u_2
m : Type u_3
n : Type u_4
α : Type u_5
β : Type u_6
ι : Type u_7
inst✝⁵ : Fintype l
inst✝⁴ : Fintype m
inst✝³ : Fintype n
inst✝² : Unique ι
inst✝¹ : SeminormedAddCommGroup α
inst✝ : DecidableEq m
v : m → α
⊢ ‖diagonal v‖₊ = ‖v‖₊
state_after: R : Type u_1
l : Type u_2
m : Type u_3
n : Type u_4
α : Type u_5
β : Type u_6
ι : Type u_7
inst✝⁵ : Fintype l
inst✝⁴ : Fintype m
inst✝³ : Fintype n
inst✝² : Unique ι
inst✝¹ : SeminormedAddCommGroup α
inst✝ : DecidableEq m
v : m → α
⊢ (Finset.univ.sup fun i => ∑ j : m, ‖diagonal v i j‖₊) = Finset.univ.sup fun b => ‖v b‖₊
tactic: rw [linfty_opNNNorm_def, Pi.nnnorm_def]
state_before: R : Type u_1
l : Type u_2
m : Type u_3
n : Type u_4
α : Type u_5
β : Type u_6
ι : Type u_7
inst✝⁵ : Fintype l
inst✝⁴ : Fintype m
inst✝³ : Fintype n
inst✝² : Unique ι
inst✝¹ : SeminormedAddCommGroup α
inst✝ : DecidableEq m
v : m → α
⊢ (Finset.univ.sup fun i => ∑ j : m, ‖diagonal v i j‖₊) = Finset.univ.sup fun b => ‖v b‖₊
state_after: case e_f.h
R : Type u_1
l : Type u_2
m : Type u_3
n : Type u_4
α : Type u_5
β : Type u_6
ι : Type u_7
inst✝⁵ : Fintype l
inst✝⁴ : Fintype m
inst✝³ : Fintype n
inst✝² : Unique ι
inst✝¹ : SeminormedAddCommGroup α
inst✝ : DecidableEq m
v : m → α
i : m
⊢ ∑ j : m, ‖diagonal v i j‖₊ = ‖v i‖₊
tactic: congr 1 with i : 1
state_before: case e_f.h
R : Type u_1
l : Type u_2
m : Type u_3
n : Type u_4
α : Type u_5
β : Type u_6
ι : Type u_7
inst✝⁵ : Fintype l
inst✝⁴ : Fintype m
inst✝³ : Fintype n
inst✝² : Unique ι
inst✝¹ : SeminormedAddCommGroup α
inst✝ : DecidableEq m
v : m → α
i : m
⊢ ∑ j : m, ‖diagonal v i j‖₊ = ‖v i‖₊
state_after: case e_f.h.refine_1
R : Type u_1
l : Type u_2
m : Type u_3
n : Type u_4
α : Type u_5
β : Type u_6
ι : Type u_7
inst✝⁵ : Fintype l
inst✝⁴ : Fintype m
inst✝³ : Fintype n
inst✝² : Unique ι
inst✝¹ : SeminormedAddCommGroup α
inst✝ : DecidableEq m
v : m → α
i j : m
_hj : j ∈ Finset.univ
hij : j ≠ i
⊢ ‖diagonal v i j‖₊ = 0

case e_f.h.refine_2
R : Type u_1
l : Type u_2
m : Type u_3
n : Type u_4
α : Type u_5
β : Type u_6
ι : Type u_7
inst✝⁵ : Fintype l
inst✝⁴ : Fintype m
inst✝³ : Fintype n
inst✝² : Unique ι
inst✝¹ : SeminormedAddCommGroup α
inst✝ : DecidableEq m
v : m → α
i : m
⊢ ‖diagonal v i i‖₊ = ‖v i‖₊
tactic: refine (Finset.sum_eq_single_of_mem _ (Finset.mem_univ i) fun j _hj hij => ?_).trans ?_
Theorem: properlyDiscontinuousSMul_iff_properSMul
File: Mathlib/Topology/Algebra/ProperAction.lean

Proof steps:
state_before: G : Type u_1
X : Type u_2
Y : Type u_3
Z : Type u_4
inst✝⁹ : Group G
inst✝⁸ : MulAction G X
inst✝⁷ : MulAction G Y
inst✝⁶ : TopologicalSpace G
inst✝⁵ : TopologicalSpace X
inst✝⁴ : TopologicalSpace Y
inst✝³ : TopologicalSpace Z
inst✝² : T2Space X
inst✝¹ : DiscreteTopology G
inst✝ : ContinuousConstSMul G X
compactlyGenerated : ∀ (s : Set (X × X)), IsClosed s ↔ ∀ ⦃K : Set (X × X)⦄, IsCompact K → IsClosed (s ∩ K)
⊢ ProperlyDiscontinuousSMul G X ↔ ProperSMul G X
state_after: case mp
G : Type u_1
X : Type u_2
Y : Type u_3
Z : Type u_4
inst✝⁹ : Group G
inst✝⁸ : MulAction G X
inst✝⁷ : MulAction G Y
inst✝⁶ : TopologicalSpace G
inst✝⁵ : TopologicalSpace X
inst✝⁴ : TopologicalSpace Y
inst✝³ : TopologicalSpace Z
inst✝² : T2Space X
inst✝¹ : DiscreteTopology G
inst✝ : ContinuousConstSMul G X
compactlyGenerated : ∀ (s : Set (X × X)), IsClosed s ↔ ∀ ⦃K : Set (X × X)⦄, IsCompact K → IsClosed (s ∩ K)
⊢ ProperlyDiscontinuousSMul G X → ProperSMul G X

case mpr
G : Type u_1
X : Type u_2
Y : Type u_3
Z : Type u_4
inst✝⁹ : Group G
inst✝⁸ : MulAction G X
inst✝⁷ : MulAction G Y
inst✝⁶ : TopologicalSpace G
inst✝⁵ : TopologicalSpace X
inst✝⁴ : TopologicalSpace Y
inst✝³ : TopologicalSpace Z
inst✝² : T2Space X
inst✝¹ : DiscreteTopology G
inst✝ : ContinuousConstSMul G X
compactlyGenerated : ∀ (s : Set (X × X)), IsClosed s ↔ ∀ ⦃K : Set (X × X)⦄, IsCompact K → IsClosed (s ∩ K)
⊢ ProperSMul G X → ProperlyDiscontinuousSMul G X
tactic: constructor
Theorem: Cardinal.sum_le_iSup
File: Mathlib/SetTheory/Cardinal/Basic.lean

Proof steps:
state_before: α β ι : Type u
f : ι → Cardinal.{u}
⊢ sum f ≤ #ι * iSup f
state_after: α β ι : Type u
f : ι → Cardinal.{u}
⊢ sum f ≤ lift.{u, u} #ι * iSup f
tactic: rw [← lift_id #ι]
state_before: α β ι : Type u
f : ι → Cardinal.{u}
⊢ sum f ≤ lift.{u, u} #ι * iSup f
state_after: no goals
tactic: exact sum_le_iSup_lift f
Theorem: RingHom.eq_liftOfRightInverse
File: Mathlib/RingTheory/Ideal/Maps.lean

Proof steps:
state_before: A : Type u_1
B : Type u_2
C : Type u_3
inst✝² : Ring A
inst✝¹ : Ring B
inst✝ : Ring C
f : A →+* B
f_inv : B → A
hf : Function.RightInverse f_inv ⇑f
g : A →+* C
hg : ker f ≤ ker g
h : B →+* C
hh : h.comp f = g
⊢ h = (f.liftOfRightInverse f_inv hf) ⟨g, hg⟩
state_after: A : Type u_1
B : Type u_2
C : Type u_3
inst✝² : Ring A
inst✝¹ : Ring B
inst✝ : Ring C
f : A →+* B
f_inv : B → A
hf : Function.RightInverse f_inv ⇑f
g : A →+* C
hg : ker f ≤ ker g
h : B →+* C
hh : h.comp f = g
⊢ h = (f.liftOfRightInverse f_inv hf) ⟨h.comp f, ⋯⟩
tactic: simp_rw [← hh]
state_before: A : Type u_1
B : Type u_2
C : Type u_3
inst✝² : Ring A
inst✝¹ : Ring B
inst✝ : Ring C
f : A →+* B
f_inv : B → A
hf : Function.RightInverse f_inv ⇑f
g : A →+* C
hg : ker f ≤ ker g
h : B →+* C
hh : h.comp f = g
⊢ h = (f.liftOfRightInverse f_inv hf) ⟨h.comp f, ⋯⟩
state_after: no goals
tactic: exact ((f.liftOfRightInverse f_inv hf).apply_symm_apply _).symm
Theorem: completedRiemannZeta₀_one
File: Mathlib/NumberTheory/Harmonic/ZetaAsymp.lean

Proof steps:
state_before: ⊢ completedRiemannZeta₀ 1 = (↑γ - Complex.log (4 * ↑π)) / 2 + 1
state_after: this : completedRiemannZeta 1 = completedRiemannZeta₀ 1 - 1 / 1 - 1 / (1 - 1)
⊢ completedRiemannZeta₀ 1 = (↑γ - Complex.log (4 * ↑π)) / 2 + 1
tactic: have := completedRiemannZeta_eq 1
state_before: this : completedRiemannZeta 1 = completedRiemannZeta₀ 1 - 1 / 1 - 1 / (1 - 1)
⊢ completedRiemannZeta₀ 1 = (↑γ - Complex.log (4 * ↑π)) / 2 + 1
state_after: this : completedRiemannZeta 1 + 1 = completedRiemannZeta₀ 1
⊢ completedRiemannZeta₀ 1 = (↑γ - Complex.log (4 * ↑π)) / 2 + 1
tactic: rw [sub_self, div_zero, div_one, sub_zero, eq_sub_iff_add_eq] at this
state_before: this : completedRiemannZeta 1 + 1 = completedRiemannZeta₀ 1
⊢ completedRiemannZeta₀ 1 = (↑γ - Complex.log (4 * ↑π)) / 2 + 1
state_after: no goals
tactic: rw [← this, completedRiemannZeta_one]
Theorem: CategoryTheory.coevaluation_comp_leftAdjointMate
File: Mathlib/CategoryTheory/Monoidal/Rigid/Basic.lean

Proof steps:
state_before: C : Type u₁
inst✝³ : Category.{v₁, u₁} C
inst✝² : MonoidalCategory C
X Y : C
inst✝¹ : HasLeftDual X
inst✝ : HasLeftDual Y
f : X ⟶ Y
⊢ η_ (ᘁY) Y ≫ (ᘁf) ▷ Y = η_ (ᘁX) X ≫ ᘁX ◁ f
state_after: C : Type u₁
inst✝³ : Category.{v₁, u₁} C
inst✝² : MonoidalCategory C
X Y : C
inst✝¹ : HasLeftDual X
inst✝ : HasLeftDual Y
f : X ⟶ Y
⊢ (tensorRightHomEquiv (𝟙_ C) (ᘁY) Y ᘁX).symm (η_ (ᘁY) Y ≫ (ᘁf) ▷ Y) =
    (tensorRightHomEquiv (𝟙_ C) (ᘁY) Y ᘁX).symm (η_ (ᘁX) X ≫ ᘁX ◁ f)
tactic: apply_fun (tensorRightHomEquiv _ (ᘁY) Y _).symm
state_before: C : Type u₁
inst✝³ : Category.{v₁, u₁} C
inst✝² : MonoidalCategory C
X Y : C
inst✝¹ : HasLeftDual X
inst✝ : HasLeftDual Y
f : X ⟶ Y
⊢ (tensorRightHomEquiv (𝟙_ C) (ᘁY) Y ᘁX).symm (η_ (ᘁY) Y ≫ (ᘁf) ▷ Y) =
    (tensorRightHomEquiv (𝟙_ C) (ᘁY) Y ᘁX).symm (η_ (ᘁX) X ≫ ᘁX ◁ f)
state_after: no goals
tactic: simp
Theorem: legendreSym.quadratic_reciprocity_three_mod_four
File: Mathlib/NumberTheory/LegendreSymbol/QuadraticReciprocity.lean

Proof steps:
state_before: p q : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : Fact (Nat.Prime q)
hp : p % 4 = 3
hq : q % 4 = 3
⊢ legendreSym q ↑p = -legendreSym p ↑q
state_after: p q : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : Fact (Nat.Prime q)
hp : p % 4 = 3
hq : q % 4 = 3
nop : ∀ {n : ℕ}, n % 4 = 3 → (-1) ^ (n / 2) = -1 := @neg_one_pow_div_two_of_three_mod_four
⊢ legendreSym q ↑p = -legendreSym p ↑q
tactic: let nop := @neg_one_pow_div_two_of_three_mod_four
state_before: p q : ℕ
inst✝¹ : Fact (Nat.Prime p)
inst✝ : Fact (Nat.Prime q)
hp : p % 4 = 3
hq : q % 4 = 3
nop : ∀ {n : ℕ}, n % 4 = 3 → (-1) ^ (n / 2) = -1 := @neg_one_pow_div_two_of_three_mod_four
⊢ legendreSym q ↑p = -legendreSym p ↑q
state_after: no goals
tactic: rw [quadratic_reciprocity', pow_mul, nop hp, nop hq, neg_one_mul] <;>
  rwa [← Prime.mod_two_eq_one_iff_ne_two, odd_of_mod_four_eq_three]
Theorem: AddValuation.map_add'
File: Mathlib/RingTheory/Valuation/Basic.lean

Proof steps:
state_before: K : Type u_1
F : Type u_2
R : Type u_3
inst✝³ : DivisionRing K
Γ₀ : Type u_4
Γ'₀ : Type u_5
inst✝² : Ring R
inst✝¹ : LinearOrderedAddCommMonoidWithTop Γ₀
inst✝ : LinearOrderedAddCommMonoidWithTop Γ'₀
v : AddValuation R Γ₀
x y z : R
⊢ ∀ (x y : R), v x ≤ v (x + y) ∨ v y ≤ v (x + y)
state_after: K : Type u_1
F : Type u_2
R : Type u_3
inst✝³ : DivisionRing K
Γ₀ : Type u_4
Γ'₀ : Type u_5
inst✝² : Ring R
inst✝¹ : LinearOrderedAddCommMonoidWithTop Γ₀
inst✝ : LinearOrderedAddCommMonoidWithTop Γ'₀
v : AddValuation R Γ₀
x✝ y✝ z x y : R
⊢ v x ≤ v (x + y) ∨ v y ≤ v (x + y)
tactic: intro x y
state_before: K : Type u_1
F : Type u_2
R : Type u_3
inst✝³ : DivisionRing K
Γ₀ : Type u_4
Γ'₀ : Type u_5
inst✝² : Ring R
inst✝¹ : LinearOrderedAddCommMonoidWithTop Γ₀
inst✝ : LinearOrderedAddCommMonoidWithTop Γ'₀
v : AddValuation R Γ₀
x✝ y✝ z x y : R
⊢ v x ≤ v (x + y) ∨ v y ≤ v (x + y)
state_after: K : Type u_1
F : Type u_2
R : Type u_3
inst✝³ : DivisionRing K
Γ₀ : Type u_4
Γ'₀ : Type u_5
inst✝² : Ring R
inst✝¹ : LinearOrderedAddCommMonoidWithTop Γ₀
inst✝ : LinearOrderedAddCommMonoidWithTop Γ'₀
v : AddValuation R Γ₀
x✝ y✝ z x y : R
⊢ v (x + y) ≥ min (v x) (v y)
tactic: rw [← @min_le_iff _ _ (v x) (v y) (v (x+y)), ← ge_iff_le]
state_before: K : Type u_1
F : Type u_2
R : Type u_3
inst✝³ : DivisionRing K
Γ₀ : Type u_4
Γ'₀ : Type u_5
inst✝² : Ring R
inst✝¹ : LinearOrderedAddCommMonoidWithTop Γ₀
inst✝ : LinearOrderedAddCommMonoidWithTop Γ'₀
v : AddValuation R Γ₀
x✝ y✝ z x y : R
⊢ v (x + y) ≥ min (v x) (v y)
state_after: no goals
tactic: apply map_add
Theorem: List.sum_toFinset_count_eq_length
File: Mathlib/Algebra/BigOperators/Group/Finset.lean

Proof steps:
state_before: ι : Type u_1
κ : Type u_2
α : Type u_3
β : Type u_4
γ : Type u_5
s s₁ s₂ : Finset α
a : α
f g : α → β
inst✝ : DecidableEq α
l : List α
⊢ ∑ a ∈ l.toFinset, count a l = l.length
state_after: no goals
tactic: simpa [List.map_const'] using (Finset.sum_list_map_count l fun _ => (1 : ℕ)).symm
Theorem: Num.dvd_to_nat
File: Mathlib/Data/Num/Lemmas.lean

Proof steps:
state_before: m n : Num
x✝ : ↑m ∣ ↑n
k : ℕ
e : ↑n = ↑m * k
⊢ n = m * ↑k
state_after: m n : Num
x✝ : ↑m ∣ ↑n
k : ℕ
e : ↑n = ↑m * k
⊢ ↑(↑m * k) = m * ↑k
tactic: rw [← of_to_nat n, e]
state_before: m n : Num
x✝ : ↑m ∣ ↑n
k : ℕ
e : ↑n = ↑m * k
⊢ ↑(↑m * k) = m * ↑k
state_after: no goals
tactic: simp
state_before: m n : Num
x✝ : m ∣ n
k : Num
e : n = m * k
⊢ ↑n = ↑m * ↑k
state_after: no goals
tactic: simp [e, mul_to_nat]
Theorem: Cardinal.mk_list_eq_sum_pow
File: Mathlib/SetTheory/Cardinal/Basic.lean

Proof steps:
state_before: α✝ β : Type u
c : Cardinal.{?u.186702}
α : Type u
⊢ #((n : ℕ) × Vector α n) = sum fun n => #α ^ n
state_after: no goals
tactic: simp
Theorem: Algebra.TensorProduct.liftEquiv_apply
File: Mathlib/RingTheory/TensorProduct/Basic.lean

Proof steps:
state_before: R : Type uR
S : Type uS
A : Type uA
B : Type uB
C : Type uC
D : Type uD
E : Type uE
F : Type uF
inst✝¹⁴ : CommSemiring R
inst✝¹³ : CommSemiring S
inst✝¹² : Algebra R S
inst✝¹¹ : Semiring A
inst✝¹⁰ : Algebra R A
inst✝⁹ : Algebra S A
inst✝⁸ : IsScalarTower R S A
inst✝⁷ : Semiring B
inst✝⁶ : Algebra R B
inst✝⁵ : Semiring C
inst✝⁴ : Algebra R C
inst✝³ : Algebra S C
inst✝² : Semiring D
inst✝¹ : Algebra R D
inst✝ : IsScalarTower R S C
fg : { fg // ∀ (x : A) (y : B), Commute (fg.1 x) (fg.2 y) }
⊢ (fun f' => ⟨(f'.comp includeLeft, (AlgHom.restrictScalars R f').comp includeRight), ⋯⟩)
      ((fun fg => lift (↑fg).1 (↑fg).2 ⋯) fg) =
    fg
state_after: no goals
tactic: ext <;> simp
state_before: R : Type uR
S : Type uS
A : Type uA
B : Type uB
C : Type uC
D : Type uD
E : Type uE
F : Type uF
inst✝¹⁴ : CommSemiring R
inst✝¹³ : CommSemiring S
inst✝¹² : Algebra R S
inst✝¹¹ : Semiring A
inst✝¹⁰ : Algebra R A
inst✝⁹ : Algebra S A
inst✝⁸ : IsScalarTower R S A
inst✝⁷ : Semiring B
inst✝⁶ : Algebra R B
inst✝⁵ : Semiring C
inst✝⁴ : Algebra R C
inst✝³ : Algebra S C
inst✝² : Semiring D
inst✝¹ : Algebra R D
inst✝ : IsScalarTower R S C
f' : A ⊗[R] B →ₐ[S] C
⊢ (fun fg => lift (↑fg).1 (↑fg).2 ⋯)
      ((fun f' => ⟨(f'.comp includeLeft, (AlgHom.restrictScalars R f').comp includeRight), ⋯⟩) f') =
    f'
state_after: no goals
tactic: ext <;> simp
Theorem: AkraBazziRecurrence.bi_min_div_two_lt_one
File: Mathlib/Computability/AkraBazzi/AkraBazzi.lean

Proof steps:
state_before: α : Type u_1
inst✝¹ : Fintype α
inst✝ : Nonempty α
T : ℕ → ℝ
g : ℝ → ℝ
a b : α → ℝ
r : α → ℕ → ℕ
R : AkraBazziRecurrence T g a b r
⊢ b (min_bi b) / 2 < 1
state_after: α : Type u_1
inst✝¹ : Fintype α
inst✝ : Nonempty α
T : ℕ → ℝ
g : ℝ → ℝ
a b : α → ℝ
r : α → ℕ → ℕ
R : AkraBazziRecurrence T g a b r
gt_zero : 0 < b (min_bi b)
⊢ b (min_bi b) / 2 < 1
tactic: have gt_zero : 0 < b (min_bi b) := R.b_pos (min_bi b)
state_before: α : Type u_1
inst✝¹ : Fintype α
inst✝ : Nonempty α
T : ℕ → ℝ
g : ℝ → ℝ
a b : α → ℝ
r : α → ℕ → ℕ
R : AkraBazziRecurrence T g a b r
gt_zero : 0 < b (min_bi b)
⊢ b (min_bi b) / 2 < 1
state_after: no goals
tactic: calc b (min_bi b) / 2 < b (min_bi b) := by aesop (add safe apply div_two_lt_of_pos)
                      _ < 1 := R.b_lt_one _
Theorem: CategoryTheory.shiftFunctorAdd_zero_add_inv_app
File: Mathlib/CategoryTheory/Shift/Basic.lean

Proof steps:
state_before: C : Type u
A : Type u_1
inst✝² : Category.{v, u} C
inst✝¹ : AddMonoid A
inst✝ : HasShift C A
a : A
X : C
⊢ (shiftFunctor C a).obj ((𝟭 C).obj X) = (shiftFunctor C (0 + a)).obj X
state_after: C : Type u
A : Type u_1
inst✝² : Category.{v, u} C
inst✝¹ : AddMonoid A
inst✝ : HasShift C A
a : A
X : C
⊢ (shiftFunctor C a).obj X = (shiftFunctor C (0 + a)).obj X
tactic: dsimp
state_before: C : Type u
A : Type u_1
inst✝² : Category.{v, u} C
inst✝¹ : AddMonoid A
inst✝ : HasShift C A
a : A
X : C
⊢ (shiftFunctor C a).obj X = (shiftFunctor C (0 + a)).obj X
state_after: no goals
tactic: rw [zero_add]
state_before: C : Type u
A : Type u_1
inst✝² : Category.{v, u} C
inst✝¹ : AddMonoid A
inst✝ : HasShift C A
a : A
X : C
⊢ (shiftFunctorAdd C 0 a).inv.app X = (shiftFunctor C a).map ((shiftFunctorZero C A).hom.app X) ≫ eqToHom ⋯
state_after: no goals
tactic: simp [← shiftFunctorAdd'_zero_add_inv_app, shiftFunctorAdd']
Theorem: CategoryTheory.Mat_.embedding_obj_X
File: Mathlib/CategoryTheory/Preadditive/Mat.lean

Proof steps:
state_before: C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : Preadditive C
x✝ : C
⊢ { obj := fun X => mk PUnit.{1} fun x => X, map := fun {X Y} f x x => f }.map (𝟙 x✝) =
    𝟙 ({ obj := fun X => mk PUnit.{1} fun x => X, map := fun {X Y} f x x => f }.obj x✝)
state_after: case H.unit
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : Preadditive C
x✝ : C
j✝ : ({ obj := fun X => mk PUnit.{1} fun x => X, map := fun {X Y} f x x => f }.obj x✝).ι
⊢ { obj := fun X => mk PUnit.{1} fun x => X, map := fun {X Y} f x x => f }.map (𝟙 x✝) PUnit.unit j✝ =
    𝟙 ({ obj := fun X => mk PUnit.{1} fun x => X, map := fun {X Y} f x x => f }.obj x✝) PUnit.unit j✝
tactic: ext ⟨⟩
state_before: case H.unit
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : Preadditive C
x✝ : C
j✝ : ({ obj := fun X => mk PUnit.{1} fun x => X, map := fun {X Y} f x x => f }.obj x✝).ι
⊢ { obj := fun X => mk PUnit.{1} fun x => X, map := fun {X Y} f x x => f }.map (𝟙 x✝) PUnit.unit j✝ =
    𝟙 ({ obj := fun X => mk PUnit.{1} fun x => X, map := fun {X Y} f x x => f }.obj x✝) PUnit.unit j✝
state_after: no goals
tactic: simp
state_before: C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : Preadditive C
X✝ Y✝ Z✝ : C
x✝¹ : X✝ ⟶ Y✝
x✝ : Y✝ ⟶ Z✝
⊢ { obj := fun X => mk PUnit.{1} fun x => X, map := fun {X Y} f x x => f }.map (x✝¹ ≫ x✝) =
    { obj := fun X => mk PUnit.{1} fun x => X, map := fun {X Y} f x x => f }.map x✝¹ ≫
      { obj := fun X => mk PUnit.{1} fun x => X, map := fun {X Y} f x x => f }.map x✝
state_after: case H.unit
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : Preadditive C
X✝ Y✝ Z✝ : C
x✝¹ : X✝ ⟶ Y✝
x✝ : Y✝ ⟶ Z✝
j✝ : ({ obj := fun X => mk PUnit.{1} fun x => X, map := fun {X Y} f x x => f }.obj Z✝).ι
⊢ { obj := fun X => mk PUnit.{1} fun x => X, map := fun {X Y} f x x => f }.map (x✝¹ ≫ x✝) PUnit.unit j✝ =
    ({ obj := fun X => mk PUnit.{1} fun x => X, map := fun {X Y} f x x => f }.map x✝¹ ≫
        { obj := fun X => mk PUnit.{1} fun x => X, map := fun {X Y} f x x => f }.map x✝)
      PUnit.unit j✝
tactic: ext ⟨⟩
state_before: case H.unit
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : Preadditive C
X✝ Y✝ Z✝ : C
x✝¹ : X✝ ⟶ Y✝
x✝ : Y✝ ⟶ Z✝
j✝ : ({ obj := fun X => mk PUnit.{1} fun x => X, map := fun {X Y} f x x => f }.obj Z✝).ι
⊢ { obj := fun X => mk PUnit.{1} fun x => X, map := fun {X Y} f x x => f }.map (x✝¹ ≫ x✝) PUnit.unit j✝ =
    ({ obj := fun X => mk PUnit.{1} fun x => X, map := fun {X Y} f x x => f }.map x✝¹ ≫
        { obj := fun X => mk PUnit.{1} fun x => X, map := fun {X Y} f x x => f }.map x✝)
      PUnit.unit j✝
state_after: no goals
tactic: simp
Theorem: List.Sublist.reverse
File: .lake/packages/batteries/Batteries/Data/List/Lemmas.lean

Proof steps:
state_before: α✝ : Type u_1
l₁✝ l₂ l₁ l₂✝ : List α✝
a✝ : α✝
h : l₁ <+ l₂✝
⊢ l₁.reverse <+ (a✝ :: l₂✝).reverse
state_after: α✝ : Type u_1
l₁✝ l₂ l₁ l₂✝ : List α✝
a✝ : α✝
h : l₁ <+ l₂✝
⊢ l₁.reverse <+ l₂✝.reverse ++ [a✝]
tactic: rw [reverse_cons]
state_before: α✝ : Type u_1
l₁✝ l₂ l₁ l₂✝ : List α✝
a✝ : α✝
h : l₁ <+ l₂✝
⊢ l₁.reverse <+ l₂✝.reverse ++ [a✝]
state_after: no goals
tactic: exact sublist_append_of_sublist_left h.reverse
state_before: α✝ : Type u_1
l₁ l₂ l₁✝ l₂✝ : List α✝
a✝ : α✝
h : l₁✝ <+ l₂✝
⊢ (a✝ :: l₁✝).reverse <+ (a✝ :: l₂✝).reverse
state_after: α✝ : Type u_1
l₁ l₂ l₁✝ l₂✝ : List α✝
a✝ : α✝
h : l₁✝ <+ l₂✝
⊢ l₁✝.reverse ++ [a✝] <+ l₂✝.reverse ++ [a✝]
tactic: rw [reverse_cons, reverse_cons]
state_before: α✝ : Type u_1
l₁ l₂ l₁✝ l₂✝ : List α✝
a✝ : α✝
h : l₁✝ <+ l₂✝
⊢ l₁✝.reverse ++ [a✝] <+ l₂✝.reverse ++ [a✝]
state_after: no goals
tactic: exact h.reverse.append_right _
Theorem: lipschitzWith_sup_right
File: Mathlib/Analysis/Normed/Order/Lattice.lean

Proof steps:
state_before: α : Type u_1
inst✝ : NormedLatticeAddCommGroup α
z x y : α
⊢ dist (x ⊔ z) (y ⊔ z) ≤ ↑1 * dist x y
state_after: α : Type u_1
inst✝ : NormedLatticeAddCommGroup α
z x y : α
⊢ ‖x ⊔ z - y ⊔ z‖ ≤ ‖x - y‖
tactic: rw [NNReal.coe_one, one_mul, dist_eq_norm, dist_eq_norm]
state_before: α : Type u_1
inst✝ : NormedLatticeAddCommGroup α
z x y : α
⊢ ‖x ⊔ z - y ⊔ z‖ ≤ ‖x - y‖
state_after: no goals
tactic: exact norm_sup_sub_sup_le_norm x y z
Theorem: Poly.sumsq_nonneg
File: Mathlib/NumberTheory/Dioph.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
x : α → ℕ
p : Poly α
ps : List (Poly α)
⊢ 0 ≤ (sumsq (p :: ps)) x
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
x : α → ℕ
p : Poly α
ps : List (Poly α)
⊢ 0 ≤ (p * p + sumsq ps) x
tactic: rw [sumsq]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
x : α → ℕ
p : Poly α
ps : List (Poly α)
⊢ 0 ≤ (p * p + sumsq ps) x
state_after: no goals
tactic: exact add_nonneg (mul_self_nonneg _) (sumsq_nonneg _ ps)