ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
Theorem: Homotopy.prevD_succ_cochainComplex
File: Mathlib/Algebra/Homology/Homotopy.lean

Proof steps:
state_before: ι : Type u_1
V : Type u
inst✝¹ : Category.{v, u} V
inst✝ : Preadditive V
c : ComplexShape ι
C D E : HomologicalComplex V c
f✝ g : C ⟶ D
h k : D ⟶ E
i✝ : ι
P Q : CochainComplex V ℕ
f : (i j : ℕ) → P.X i ⟶ Q.X j
i : ℕ
⊢ (prevD (i + 1)) f = f (i + 1) i ≫ Q.d i (i + 1)
state_after: ι : Type u_1
V : Type u
inst✝¹ : Category.{v, u} V
inst✝ : Preadditive V
c : ComplexShape ι
C D E : HomologicalComplex V c
f✝ g : C ⟶ D
h k : D ⟶ E
i✝ : ι
P Q : CochainComplex V ℕ
f : (i j : ℕ) → P.X i ⟶ Q.X j
i : ℕ
⊢ f (i + 1) ((ComplexShape.up ℕ).prev (i + 1)) ≫ Q.d ((ComplexShape.up ℕ).prev (i + 1)) (i + 1) =
    f (i + 1) i ≫ Q.d i (i + 1)
tactic: dsimp [prevD]
state_before: ι : Type u_1
V : Type u
inst✝¹ : Category.{v, u} V
inst✝ : Preadditive V
c : ComplexShape ι
C D E : HomologicalComplex V c
f✝ g : C ⟶ D
h k : D ⟶ E
i✝ : ι
P Q : CochainComplex V ℕ
f : (i j : ℕ) → P.X i ⟶ Q.X j
i : ℕ
⊢ f (i + 1) ((ComplexShape.up ℕ).prev (i + 1)) ≫ Q.d ((ComplexShape.up ℕ).prev (i + 1)) (i + 1) =
    f (i + 1) i ≫ Q.d i (i + 1)
state_after: ι : Type u_1
V : Type u
inst✝¹ : Category.{v, u} V
inst✝ : Preadditive V
c : ComplexShape ι
C D E : HomologicalComplex V c
f✝ g : C ⟶ D
h k : D ⟶ E
i✝ : ι
P Q : CochainComplex V ℕ
f : (i j : ℕ) → P.X i ⟶ Q.X j
i : ℕ
this : (ComplexShape.up ℕ).prev (i + 1) = i
⊢ f (i + 1) ((ComplexShape.up ℕ).prev (i + 1)) ≫ Q.d ((ComplexShape.up ℕ).prev (i + 1)) (i + 1) =
    f (i + 1) i ≫ Q.d i (i + 1)
tactic: have : (ComplexShape.up ℕ).prev (i + 1) = i := CochainComplex.prev_nat_succ i
state_before: ι : Type u_1
V : Type u
inst✝¹ : Category.{v, u} V
inst✝ : Preadditive V
c : ComplexShape ι
C D E : HomologicalComplex V c
f✝ g : C ⟶ D
h k : D ⟶ E
i✝ : ι
P Q : CochainComplex V ℕ
f : (i j : ℕ) → P.X i ⟶ Q.X j
i : ℕ
this : (ComplexShape.up ℕ).prev (i + 1) = i
⊢ f (i + 1) ((ComplexShape.up ℕ).prev (i + 1)) ≫ Q.d ((ComplexShape.up ℕ).prev (i + 1)) (i + 1) =
    f (i + 1) i ≫ Q.d i (i + 1)
state_after: no goals
tactic: congr 2
Theorem: NNRat.den_inv_of_ne_zero
File: Mathlib/Algebra/Order/Field/Rat.lean

Proof steps:
state_before: q : ℚ≥0
hq : q ≠ 0
⊢ q⁻¹.den = q.num
state_after: q : ℚ≥0
hq : q ≠ 0
⊢ (↑q.den).natAbs.Coprime q.num
tactic: rw [inv_def, divNat, den, coe_mk, Rat.divInt_ofNat, ← Rat.mk_eq_mkRat _ _ (num_ne_zero.mpr hq)]
state_before: q : ℚ≥0
hq : q ≠ 0
⊢ (↑q.den).natAbs.Coprime q.num
state_after: no goals
tactic: simpa using q.coprime_num_den.symm
Theorem: SimpleGraph.edist_ne_top_iff_reachable
File: Mathlib/Combinatorics/SimpleGraph/Metric.lean

Proof steps:
state_before: V : Type u_1
G : SimpleGraph V
u v w : V
⊢ G.edist u v ≠ ⊤ ↔ G.Reachable u v
state_after: V : Type u_1
G : SimpleGraph V
u v w : V
h : G.Reachable u v
⊢ G.edist u v ≠ ⊤
tactic: refine ⟨reachable_of_edist_ne_top, fun h ↦ ?_⟩
state_before: V : Type u_1
G : SimpleGraph V
u v w : V
h : G.Reachable u v
⊢ G.edist u v ≠ ⊤
state_after: V : Type u_1
G : SimpleGraph V
u v w : V
h : G.Reachable u v
hx : G.edist u v = ⊤
⊢ False
tactic: by_contra hx
state_before: V : Type u_1
G : SimpleGraph V
u v w : V
h : G.Reachable u v
hx : G.edist u v = ⊤
⊢ False
state_after: V : Type u_1
G : SimpleGraph V
u v w : V
h : G.Reachable u v
hx : G.Walk u v → False
⊢ False
tactic: simp only [edist, iInf_eq_top, ENat.coe_ne_top] at hx
state_before: V : Type u_1
G : SimpleGraph V
u v w : V
h : G.Reachable u v
hx : G.Walk u v → False
⊢ False
state_after: no goals
tactic: exact h.elim hx
Theorem: List.mem_finRange
File: Mathlib/Data/List/Range.lean

Proof steps:
state_before: α : Type u
n : ℕ
a : Fin n
⊢ ⟨↑a, ⋯⟩ = a
state_after: case mk
α : Type u
n val✝ : ℕ
isLt✝ : val✝ < n
⊢ ⟨↑⟨val✝, isLt✝⟩, ⋯⟩ = ⟨val✝, isLt✝⟩
tactic: cases a
state_before: case mk
α : Type u
n val✝ : ℕ
isLt✝ : val✝ < n
⊢ ⟨↑⟨val✝, isLt✝⟩, ⋯⟩ = ⟨val✝, isLt✝⟩
state_after: no goals
tactic: rfl
Theorem: CategoryTheory.Localization.Construction.WhiskeringLeftEquivalence.unitIso_hom
File: Mathlib/CategoryTheory/Localization/Construction.lean

Proof steps:
state_before: C : Type uC
inst✝¹ : Category.{uC', uC} C
W : MorphismProperty C
D : Type uD
inst✝ : Category.{uD', uD} D
G : C ⥤ D
hG : W.IsInvertedBy G
⊢ 𝟭 (W.Localization ⥤ D) = functor W D ⋙ inverse W D
state_after: case refine_1
C : Type uC
inst✝¹ : Category.{uC', uC} C
W : MorphismProperty C
D : Type uD
inst✝ : Category.{uD', uD} D
G✝ : C ⥤ D
hG : W.IsInvertedBy G✝
G : W.Localization ⥤ D
⊢ (𝟭 (W.Localization ⥤ D)).obj G = (functor W D ⋙ inverse W D).obj G

case refine_2
C : Type uC
inst✝¹ : Category.{uC', uC} C
W : MorphismProperty C
D : Type uD
inst✝ : Category.{uD', uD} D
G : C ⥤ D
hG : W.IsInvertedBy G
G₁ G₂ : W.Localization ⥤ D
τ : G₁ ⟶ G₂
⊢ (𝟭 (W.Localization ⥤ D)).map τ = eqToHom ⋯ ≫ (functor W D ⋙ inverse W D).map τ ≫ eqToHom ⋯
tactic: refine Functor.ext (fun G => ?_) fun G₁ G₂ τ => ?_
Theorem: SimpleGraph.neighborSet_snd_subgraphOfAdj
File: Mathlib/Combinatorics/SimpleGraph/Subgraph.lean

Proof steps:
state_before: ι : Sort u_1
V : Type u
W : Type v
G : SimpleGraph V
G' : SimpleGraph W
v w : V
hvw : G.Adj v w
⊢ (G.subgraphOfAdj hvw).neighborSet w = {v}
state_after: ι : Sort u_1
V : Type u
W : Type v
G : SimpleGraph V
G' : SimpleGraph W
v w : V
hvw : G.Adj v w
⊢ (G.subgraphOfAdj ⋯).neighborSet w = {v}
tactic: rw [subgraphOfAdj_symm hvw.symm]
state_before: ι : Sort u_1
V : Type u
W : Type v
G : SimpleGraph V
G' : SimpleGraph W
v w : V
hvw : G.Adj v w
⊢ (G.subgraphOfAdj ⋯).neighborSet w = {v}
state_after: no goals
tactic: exact neighborSet_fst_subgraphOfAdj hvw.symm
Theorem: jacobiTheta₂'_neg_left
File: Mathlib/NumberTheory/ModularForms/JacobiTheta/TwoVariable.lean

Proof steps:
state_before: z τ : ℂ
⊢ jacobiTheta₂' (-z) τ = -jacobiTheta₂' z τ
state_after: z τ : ℂ
⊢ ∑' (c : ℤ), jacobiTheta₂'_term ((Equiv.neg ℤ) c) (-z) τ = ∑' (b : ℤ), -jacobiTheta₂'_term b z τ
tactic: rw [jacobiTheta₂', jacobiTheta₂', ← tsum_neg, ← (Equiv.neg ℤ).tsum_eq]
state_before: z τ : ℂ
⊢ ∑' (c : ℤ), jacobiTheta₂'_term ((Equiv.neg ℤ) c) (-z) τ = ∑' (b : ℤ), -jacobiTheta₂'_term b z τ
state_after: case e_f.h
z τ : ℂ
n : ℤ
⊢ jacobiTheta₂'_term ((Equiv.neg ℤ) n) (-z) τ = -jacobiTheta₂'_term n z τ
tactic: congr 1 with n
state_before: case e_f.h
z τ : ℂ
n : ℤ
⊢ jacobiTheta₂'_term ((Equiv.neg ℤ) n) (-z) τ = -jacobiTheta₂'_term n z τ
state_after: case e_f.h
z τ : ℂ
n : ℤ
⊢ 2 * ↑π * I * ↑((Equiv.neg ℤ) n) * cexp (2 * ↑π * I * ↑((Equiv.neg ℤ) n) * -z + ↑π * I * ↑((Equiv.neg ℤ) n) ^ 2 * τ) =
    -(2 * ↑π * I * ↑n * cexp (2 * ↑π * I * ↑n * z + ↑π * I * ↑n ^ 2 * τ))
tactic: simp only [jacobiTheta₂'_term, jacobiTheta₂_term]
state_before: case e_f.h
z τ : ℂ
n : ℤ
⊢ 2 * ↑π * I * ↑((Equiv.neg ℤ) n) * cexp (2 * ↑π * I * ↑((Equiv.neg ℤ) n) * -z + ↑π * I * ↑((Equiv.neg ℤ) n) ^ 2 * τ) =
    -(2 * ↑π * I * ↑n * cexp (2 * ↑π * I * ↑n * z + ↑π * I * ↑n ^ 2 * τ))
state_after: case e_f.h
z τ : ℂ
n : ℤ
⊢ 2 * ↑π * I * ↑(-n) * cexp (2 * ↑π * I * ↑(-n) * -z + ↑π * I * ↑(-n) ^ 2 * τ) =
    -(2 * ↑π * I * ↑n) * cexp (2 * ↑π * I * ↑n * z + ↑π * I * ↑n ^ 2 * τ)
tactic: rw [Equiv.neg_apply, ← neg_mul]
state_before: case e_f.h
z τ : ℂ
n : ℤ
⊢ 2 * ↑π * I * ↑(-n) * cexp (2 * ↑π * I * ↑(-n) * -z + ↑π * I * ↑(-n) ^ 2 * τ) =
    -(2 * ↑π * I * ↑n) * cexp (2 * ↑π * I * ↑n * z + ↑π * I * ↑n ^ 2 * τ)
state_after: case e_f.h
z τ : ℂ
n : ℤ
⊢ 2 * ↑π * I * -↑n * cexp (2 * ↑π * I * -↑n * -z + ↑π * I * (-↑n) ^ 2 * τ) =
    -(2 * ↑π * I * ↑n) * cexp (2 * ↑π * I * ↑n * z + ↑π * I * ↑n ^ 2 * τ)
tactic: push_cast
state_before: case e_f.h
z τ : ℂ
n : ℤ
⊢ 2 * ↑π * I * -↑n * cexp (2 * ↑π * I * -↑n * -z + ↑π * I * (-↑n) ^ 2 * τ) =
    -(2 * ↑π * I * ↑n) * cexp (2 * ↑π * I * ↑n * z + ↑π * I * ↑n ^ 2 * τ)
state_after: no goals
tactic: ring_nf
Theorem: hasFDerivAt_inv'
File: Mathlib/Analysis/Calculus/FDeriv/Mul.lean

Proof steps:
state_before: 𝕜 : Type u_1
inst✝¹¹ : NontriviallyNormedField 𝕜
E : Type u_2
inst✝¹⁰ : NormedAddCommGroup E
inst✝⁹ : NormedSpace 𝕜 E
F : Type u_3
inst✝⁸ : NormedAddCommGroup F
inst✝⁷ : NormedSpace 𝕜 F
G : Type u_4
inst✝⁶ : NormedAddCommGroup G
inst✝⁵ : NormedSpace 𝕜 G
G' : Type u_5
inst✝⁴ : NormedAddCommGroup G'
inst✝³ : NormedSpace 𝕜 G'
f f₀ f₁ g : E → F
f' f₀' f₁' g' e : E →L[𝕜] F
x✝ : E
s t : Set E
L L₁ L₂ : Filter E
R : Type u_6
inst✝² : NormedDivisionRing R
inst✝¹ : NormedAlgebra 𝕜 R
inst✝ : CompleteSpace R
x : R
hx : x ≠ 0
⊢ HasFDerivAt Inv.inv (-((mulLeftRight 𝕜 R) x⁻¹) x⁻¹) x
state_after: no goals
tactic: simpa using hasFDerivAt_ring_inverse (Units.mk0 _ hx)
Theorem: Set.finite_of_encard_le_coe
File: Mathlib/Data/Set/Card.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
s t : Set α
k : ℕ
h : s.encard ≤ ↑k
⊢ s.Finite
state_after: α : Type u_1
β : Type u_2
s t : Set α
k : ℕ
h : s.encard ≤ ↑k
⊢ s.encard < ⊤
tactic: rw [← encard_lt_top_iff]
state_before: α : Type u_1
β : Type u_2
s t : Set α
k : ℕ
h : s.encard ≤ ↑k
⊢ s.encard < ⊤
state_after: no goals
tactic: exact h.trans_lt (WithTop.coe_lt_top _)
Theorem: CategoryTheory.Equalizer.Sieve.SecondObj.ext
File: Mathlib/CategoryTheory/Sites/EqualizerSheafCondition.lean

Proof steps:
state_before: C : Type u
inst✝ : Category.{v, u} C
P : Cᵒᵖ ⥤ Type (max v u)
X : C
R : Presieve X
S : Sieve X
z₁ z₂ : SecondObj P S
h :
  ∀ (Y Z : C) (g : Z ⟶ Y) (f : Y ⟶ X) (hf : S.arrows f),
    Pi.π (fun f => P.obj (op f.snd.fst)) ⟨Y, ⟨Z, ⟨g, ⟨f, hf⟩⟩⟩⟩ z₁ =
      Pi.π (fun f => P.obj (op f.snd.fst)) ⟨Y, ⟨Z, ⟨g, ⟨f, hf⟩⟩⟩⟩ z₂
⊢ z₁ = z₂
state_after: case w
C : Type u
inst✝ : Category.{v, u} C
P : Cᵒᵖ ⥤ Type (max v u)
X : C
R : Presieve X
S : Sieve X
z₁ z₂ : SecondObj P S
h :
  ∀ (Y Z : C) (g : Z ⟶ Y) (f : Y ⟶ X) (hf : S.arrows f),
    Pi.π (fun f => P.obj (op f.snd.fst)) ⟨Y, ⟨Z, ⟨g, ⟨f, hf⟩⟩⟩⟩ z₁ =
      Pi.π (fun f => P.obj (op f.snd.fst)) ⟨Y, ⟨Z, ⟨g, ⟨f, hf⟩⟩⟩⟩ z₂
⊢ ∀ (j : Discrete ((Y : C) × (Z : C) × (_ : Z ⟶ Y) × { f' // S.arrows f' })),
    limit.π (Discrete.functor fun f => P.obj (op f.snd.fst)) j z₁ =
      limit.π (Discrete.functor fun f => P.obj (op f.snd.fst)) j z₂
tactic: apply Limits.Types.limit_ext
state_before: case w
C : Type u
inst✝ : Category.{v, u} C
P : Cᵒᵖ ⥤ Type (max v u)
X : C
R : Presieve X
S : Sieve X
z₁ z₂ : SecondObj P S
h :
  ∀ (Y Z : C) (g : Z ⟶ Y) (f : Y ⟶ X) (hf : S.arrows f),
    Pi.π (fun f => P.obj (op f.snd.fst)) ⟨Y, ⟨Z, ⟨g, ⟨f, hf⟩⟩⟩⟩ z₁ =
      Pi.π (fun f => P.obj (op f.snd.fst)) ⟨Y, ⟨Z, ⟨g, ⟨f, hf⟩⟩⟩⟩ z₂
⊢ ∀ (j : Discrete ((Y : C) × (Z : C) × (_ : Z ⟶ Y) × { f' // S.arrows f' })),
    limit.π (Discrete.functor fun f => P.obj (op f.snd.fst)) j z₁ =
      limit.π (Discrete.functor fun f => P.obj (op f.snd.fst)) j z₂
state_after: case w.mk.mk.mk.mk.mk
C : Type u
inst✝ : Category.{v, u} C
P : Cᵒᵖ ⥤ Type (max v u)
X : C
R : Presieve X
S : Sieve X
z₁ z₂ : SecondObj P S
h :
  ∀ (Y Z : C) (g : Z ⟶ Y) (f : Y ⟶ X) (hf : S.arrows f),
    Pi.π (fun f => P.obj (op f.snd.fst)) ⟨Y, ⟨Z, ⟨g, ⟨f, hf⟩⟩⟩⟩ z₁ =
      Pi.π (fun f => P.obj (op f.snd.fst)) ⟨Y, ⟨Z, ⟨g, ⟨f, hf⟩⟩⟩⟩ z₂
Y Z : C
g : Z ⟶ Y
f : Y ⟶ X
hf : S.arrows f
⊢ limit.π (Discrete.functor fun f => P.obj (op f.snd.fst)) { as := ⟨Y, ⟨Z, ⟨g, ⟨f, hf⟩⟩⟩⟩ } z₁ =
    limit.π (Discrete.functor fun f => P.obj (op f.snd.fst)) { as := ⟨Y, ⟨Z, ⟨g, ⟨f, hf⟩⟩⟩⟩ } z₂
tactic: rintro ⟨⟨Y, Z, g, f, hf⟩⟩
state_before: case w.mk.mk.mk.mk.mk
C : Type u
inst✝ : Category.{v, u} C
P : Cᵒᵖ ⥤ Type (max v u)
X : C
R : Presieve X
S : Sieve X
z₁ z₂ : SecondObj P S
h :
  ∀ (Y Z : C) (g : Z ⟶ Y) (f : Y ⟶ X) (hf : S.arrows f),
    Pi.π (fun f => P.obj (op f.snd.fst)) ⟨Y, ⟨Z, ⟨g, ⟨f, hf⟩⟩⟩⟩ z₁ =
      Pi.π (fun f => P.obj (op f.snd.fst)) ⟨Y, ⟨Z, ⟨g, ⟨f, hf⟩⟩⟩⟩ z₂
Y Z : C
g : Z ⟶ Y
f : Y ⟶ X
hf : S.arrows f
⊢ limit.π (Discrete.functor fun f => P.obj (op f.snd.fst)) { as := ⟨Y, ⟨Z, ⟨g, ⟨f, hf⟩⟩⟩⟩ } z₁ =
    limit.π (Discrete.functor fun f => P.obj (op f.snd.fst)) { as := ⟨Y, ⟨Z, ⟨g, ⟨f, hf⟩⟩⟩⟩ } z₂
state_after: no goals
tactic: apply h
Theorem: CategoryTheory.Limits.coprod.map_id_comp
File: Mathlib/CategoryTheory/Limits/Shapes/BinaryProducts.lean

Proof steps:
state_before: C : Type u
inst✝³ : Category.{v, u} C
X✝ Y✝ X Y Z W : C
f : X ⟶ Y
g : Y ⟶ Z
inst✝² : HasBinaryCoproduct W X
inst✝¹ : HasBinaryCoproduct W Y
inst✝ : HasBinaryCoproduct W Z
⊢ map (𝟙 W) (f ≫ g) = map (𝟙 W) f ≫ map (𝟙 W) g
state_after: no goals
tactic: simp
Theorem: ascPochhammer_pos
File: Mathlib/RingTheory/Polynomial/Pochhammer.lean

Proof steps:
state_before: S : Type u_1
inst✝ : StrictOrderedSemiring S
n : ℕ
s : S
h : 0 < s
⊢ 0 < eval s (ascPochhammer S n)
state_after: case zero
S : Type u_1
inst✝ : StrictOrderedSemiring S
s : S
h : 0 < s
⊢ 0 < eval s (ascPochhammer S 0)

case succ
S : Type u_1
inst✝ : StrictOrderedSemiring S
s : S
h : 0 < s
n : ℕ
ih : 0 < eval s (ascPochhammer S n)
⊢ 0 < eval s (ascPochhammer S (n + 1))
tactic: induction' n with n ih
Theorem: Finset.prod_unique_nonempty
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 : α✝ → β✝
α : Type u_6
β : Type u_7
inst✝¹ : CommMonoid β
inst✝ : Unique α
s : Finset α
f : α → β
h : s.Nonempty
⊢ ∏ x ∈ s, f x = f default
state_after: no goals
tactic: rw [h.eq_singleton_default, Finset.prod_singleton]
Theorem: IsOfFinAddOrder.prod_mk
File: Mathlib/GroupTheory/OrderOfElement.lean

Proof steps:
state_before: G : Type u_1
H : Type u_2
A : Type u_3
α : Type u_4
β : Type u_5
inst✝¹ : Monoid α
inst✝ : Monoid β
x : α × β
a : α
b : β
⊢ IsOfFinOrder a → IsOfFinOrder b → IsOfFinOrder (a, b)
state_after: no goals
tactic: simpa only [← orderOf_pos_iff, Prod.orderOf] using Nat.lcm_pos
Theorem: LocalizedModule.subsingleton
File: Mathlib/Algebra/Module/LocalizedModule.lean

Proof steps:
state_before: R : Type u
inst✝⁵ : CommSemiring R
S : Submonoid R
M : Type v
inst✝⁴ : AddCommMonoid M
inst✝³ : Module R M
T : Type u_1
inst✝² : CommSemiring T
inst✝¹ : Algebra R T
inst✝ : IsLocalization S T
h : 0 ∈ S
⊢ Subsingleton (LocalizedModule S M)
state_after: R : Type u
inst✝⁵ : CommSemiring R
S : Submonoid R
M : Type v
inst✝⁴ : AddCommMonoid M
inst✝³ : Module R M
T : Type u_1
inst✝² : CommSemiring T
inst✝¹ : Algebra R T
inst✝ : IsLocalization S T
h : 0 ∈ S
a b : LocalizedModule S M
⊢ a = b
tactic: refine ⟨fun a b ↦ ?_⟩
state_before: R : Type u
inst✝⁵ : CommSemiring R
S : Submonoid R
M : Type v
inst✝⁴ : AddCommMonoid M
inst✝³ : Module R M
T : Type u_1
inst✝² : CommSemiring T
inst✝¹ : Algebra R T
inst✝ : IsLocalization S T
h : 0 ∈ S
a b : LocalizedModule S M
⊢ a = b
state_after: case h
R : Type u
inst✝⁵ : CommSemiring R
S : Submonoid R
M : Type v
inst✝⁴ : AddCommMonoid M
inst✝³ : Module R M
T : Type u_1
inst✝² : CommSemiring T
inst✝¹ : Algebra R T
inst✝ : IsLocalization S T
h : 0 ∈ S
m✝ m'✝ : M
s✝ s'✝ : ↥S
⊢ mk m✝ s✝ = mk m'✝ s'✝
tactic: induction a,b using LocalizedModule.induction_on₂
state_before: case h
R : Type u
inst✝⁵ : CommSemiring R
S : Submonoid R
M : Type v
inst✝⁴ : AddCommMonoid M
inst✝³ : Module R M
T : Type u_1
inst✝² : CommSemiring T
inst✝¹ : Algebra R T
inst✝ : IsLocalization S T
h : 0 ∈ S
m✝ m'✝ : M
s✝ s'✝ : ↥S
⊢ mk m✝ s✝ = mk m'✝ s'✝
state_after: no goals
tactic: exact mk_eq.mpr ⟨⟨0, h⟩, by simp only [Submonoid.mk_smul, zero_smul]⟩
Theorem: LSeries.term_sub_apply
File: Mathlib/NumberTheory/LSeries/Linearity.lean

Proof steps:
state_before: f g : ℕ → ℂ
s : ℂ
n : ℕ
⊢ term (f - g) s n = term f s n - term g s n
state_after: no goals
tactic: rw [term_sub, Pi.sub_apply]
Theorem: Nonneg.mk_nnqsmul
File: Mathlib/Algebra/Order/Nonneg/Field.lean

Proof steps:
state_before: α : Type u_1
inst✝ : LinearOrderedSemifield α
x y : α
q : ℚ≥0
a : α
ha : 0 ≤ a
⊢ 0 ≤ q • a
state_after: α : Type u_1
inst✝ : LinearOrderedSemifield α
x y : α
q : ℚ≥0
a : α
ha : 0 ≤ a
⊢ 0 ≤ ↑q * a
tactic: rw [NNRat.smul_def]
state_before: α : Type u_1
inst✝ : LinearOrderedSemifield α
x y : α
q : ℚ≥0
a : α
ha : 0 ≤ a
⊢ 0 ≤ ↑q * a
state_after: no goals
tactic: exact mul_nonneg q.cast_nonneg ha
Theorem: MeasureTheory.ConvolutionExistsAt.add_distrib
File: Mathlib/Analysis/Convolution.lean

Proof steps:
state_before: 𝕜 : Type u𝕜
G : Type uG
E : Type uE
E' : Type uE'
E'' : Type uE''
F : Type uF
F' : Type uF'
F'' : Type uF''
P : Type uP
inst✝¹¹ : NormedAddCommGroup E
inst✝¹⁰ : NormedAddCommGroup E'
inst✝⁹ : NormedAddCommGroup E''
inst✝⁸ : NormedAddCommGroup F
f f' : G → E
g g' : G → E'
x✝ x' : G
y y' : E
inst✝⁷ : NontriviallyNormedField 𝕜
inst✝⁶ : NormedSpace 𝕜 E
inst✝⁵ : NormedSpace 𝕜 E'
inst✝⁴ : NormedSpace 𝕜 E''
inst✝³ : NormedSpace 𝕜 F
L : E →L[𝕜] E' →L[𝕜] F
inst✝² : MeasurableSpace G
μ ν : Measure G
inst✝¹ : NormedSpace ℝ F
inst✝ : AddGroup G
x : G
hfg : ConvolutionExistsAt f g x L μ
hfg' : ConvolutionExistsAt f' g x L μ
⊢ ((f + f') ⋆[L, μ] g) x = (f ⋆[L, μ] g) x + (f' ⋆[L, μ] g) x
state_after: no goals
tactic: simp only [convolution_def, L.map_add₂, Pi.add_apply, integral_add hfg hfg']
Theorem: CategoryTheory.Meq.equiv_symm_eq_apply
File: Mathlib/CategoryTheory/Sites/ConcreteSheafification.lean

Proof steps:
state_before: C : Type u
inst✝⁴ : Category.{v, u} C
J : GrothendieckTopology C
D : Type w
inst✝³ : Category.{max v u, w} D
inst✝² : ConcreteCategory D
inst✝¹ : PreservesLimits (forget D)
X : C
P : Cᵒᵖ ⥤ D
S : J.Cover X
inst✝ : HasMultiequalizer (S.index P)
x : Meq P S
I : S.Arrow
⊢ (Multiequalizer.ι (S.index P) I) ((equiv P S).symm x) = ↑x I
state_after: C : Type u
inst✝⁴ : Category.{v, u} C
J : GrothendieckTopology C
D : Type w
inst✝³ : Category.{max v u, w} D
inst✝² : ConcreteCategory D
inst✝¹ : PreservesLimits (forget D)
X : C
P : Cᵒᵖ ⥤ D
S : J.Cover X
inst✝ : HasMultiequalizer (S.index P)
x : Meq P S
I : S.Arrow
⊢ ↑((equiv P S) ((equiv P S).symm x)) I = ↑x I
tactic: rw [← equiv_apply]
state_before: C : Type u
inst✝⁴ : Category.{v, u} C
J : GrothendieckTopology C
D : Type w
inst✝³ : Category.{max v u, w} D
inst✝² : ConcreteCategory D
inst✝¹ : PreservesLimits (forget D)
X : C
P : Cᵒᵖ ⥤ D
S : J.Cover X
inst✝ : HasMultiequalizer (S.index P)
x : Meq P S
I : S.Arrow
⊢ ↑((equiv P S) ((equiv P S).symm x)) I = ↑x I
state_after: no goals
tactic: simp
Theorem: StrictConvexOn.map_sum_lt
File: Mathlib/Analysis/Convex/Jensen.lean

Proof steps:
state_before: 𝕜 : Type u_1
E : Type u_2
F : Type u_3
β : Type u_4
ι : Type u_5
inst✝⁵ : LinearOrderedField 𝕜
inst✝⁴ : AddCommGroup E
inst✝³ : OrderedAddCommGroup β
inst✝² : Module 𝕜 E
inst✝¹ : Module 𝕜 β
inst✝ : OrderedSMul 𝕜 β
s : Set E
f : E → β
t : Finset ι
w : ι → 𝕜
p : ι → E
v : 𝕜
q : E
hf : StrictConvexOn 𝕜 s f
h₀ : ∀ i ∈ t, 0 < w i
h₁ : ∑ i ∈ t, w i = 1
hmem : ∀ i ∈ t, p i ∈ s
hp : ∃ j ∈ t, ∃ k ∈ t, p j ≠ p k
⊢ f (∑ i ∈ t, w i • p i) < ∑ i ∈ t, w i • f (p i)
state_after: no goals
tactic: classical
  obtain ⟨j, hj, k, hk, hjk⟩ := hp
  -- We replace `t` by `t \ {j, k}`
  have : k ∈ t.erase j := mem_erase.2 ⟨ne_of_apply_ne _ hjk.symm, hk⟩
  let u := (t.erase j).erase k
  have hj : j ∉ u := by simp [u]
  have hk : k ∉ u := by simp [u]
  have ht :
      t = (u.cons k hk).cons j (mem_cons.not.2 <| not_or_intro (ne_of_apply_ne _ hjk) hj) := by
    simp [insert_erase this, insert_erase ‹j ∈ t›, *]
  clear_value u
  subst ht
  simp only [sum_cons]
  have := h₀ j <| by simp
  have := h₀ k <| by simp
  let c := w j + w k
  have hc : w j / c + w k / c = 1 := by field_simp
  have hcj : c * (w j / c) = w j := by field_simp
  have hck : c * (w k / c) = w k := by field_simp
  calc f (w j • p j + (w k • p k + ∑ x ∈ u, w x • p x))
    _ = f (c • ((w j / c) • p j + (w k / c) • p k) + ∑ x ∈ u, w x • p x) := by
      rw [smul_add, ← mul_smul, ← mul_smul, hcj, hck, add_assoc]
    _ ≤ c • f ((w j / c) • p j + (w k / c) • p k) + ∑ x ∈ u, w x • f (p x) :=
      -- apply the usual Jensen's inequality wrt the weighted average of the two distinguished
      -- points and all the other points
        hf.convexOn.map_add_sum_le (fun i hi ↦ (h₀ _ <| by simp [hi]).le)
          (by simpa [-cons_eq_insert, ← add_assoc] using h₁)
          (forall_of_forall_cons <| forall_of_forall_cons hmem) (by positivity) <| by
           refine hf.1 (hmem _ <| by simp) (hmem _ <| by simp) ?_ ?_ hc <;> positivity
    _ < c • ((w j / c) • f (p j) + (w k / c) • f (p k)) + ∑ x ∈ u, w x • f (p x) := by
      -- then apply the definition of strict convexity for the two distinguished points
      gcongr; refine hf.2 (hmem _ <| by simp) (hmem _ <| by simp) hjk ?_ ?_ hc <;> positivity
    _ = (w j • f (p j) + w k • f (p k)) + ∑ x ∈ u, w x • f (p x) := by
      rw [smul_add, ← mul_smul, ← mul_smul, hcj, hck]
    _ = w j • f (p j) + (w k • f (p k) + ∑ x ∈ u, w x • f (p x)) := by abel_nf
Theorem: Encodable.decode_list_zero
File: Mathlib/Logic/Equiv/List.lean

Proof steps:
state_before: α : Type u_1
inst✝ : Encodable α
⊢ decodeList 0 = some []
state_after: no goals
tactic: rw [decodeList]
Theorem: gcd_nsmul_eq_zero
File: Mathlib/Data/Int/GCD.lean

Proof steps:
state_before: M : Type u_1
inst✝ : Monoid M
x : M
m n : ℕ
hm : x ^ m = 1
hn : x ^ n = 1
⊢ x ^ m.gcd n = 1
state_after: case zero
M : Type u_1
inst✝ : Monoid M
x : M
n : ℕ
hn : x ^ n = 1
hm : x ^ 0 = 1
⊢ x ^ Nat.gcd 0 n = 1

case succ
M : Type u_1
inst✝ : Monoid M
x : M
n : ℕ
hn : x ^ n = 1
m : ℕ
hm : x ^ (m + 1) = 1
⊢ x ^ (m + 1).gcd n = 1
tactic: rcases m with (rfl | m)
state_before: case succ
M : Type u_1
inst✝ : Monoid M
x : M
n : ℕ
hn : x ^ n = 1
m : ℕ
hm : x ^ (m + 1) = 1
⊢ x ^ (m + 1).gcd n = 1
state_after: case succ.intro
M : Type u_1
inst✝ : Monoid M
n m : ℕ
y : Mˣ
hn : ↑y ^ n = 1
hm : ↑y ^ (m + 1) = 1
⊢ ↑y ^ (m + 1).gcd n = 1
tactic: obtain ⟨y, rfl⟩ := isUnit_ofPowEqOne hm m.succ_ne_zero
state_before: case succ.intro
M : Type u_1
inst✝ : Monoid M
n m : ℕ
y : Mˣ
hn : ↑y ^ n = 1
hm : ↑y ^ (m + 1) = 1
⊢ ↑y ^ (m + 1).gcd n = 1
state_after: case succ.intro
M : Type u_1
inst✝ : Monoid M
n m : ℕ
y : Mˣ
hn : y ^ ↑n = 1
hm : y ^ ↑(m + 1) = 1
⊢ y ^ ↑((m + 1).gcd n) = 1
tactic: rw [← Units.val_pow_eq_pow_val, ← Units.val_one (α := M), ← zpow_natCast, ← Units.ext_iff] at *
state_before: case succ.intro
M : Type u_1
inst✝ : Monoid M
n m : ℕ
y : Mˣ
hn : y ^ ↑n = 1
hm : y ^ ↑(m + 1) = 1
⊢ y ^ ↑((m + 1).gcd n) = 1
state_after: no goals
tactic: rw [Nat.gcd_eq_gcd_ab, zpow_add, zpow_mul, zpow_mul, hn, hm, one_zpow, one_zpow, one_mul]
Theorem: AddHom.srange_top_iff_surjective
File: Mathlib/Algebra/Group/Subsemigroup/Operations.lean

Proof steps:
state_before: M : Type u_1
N✝ : Type u_2
P : Type u_3
σ : Type u_4
inst✝³ : Mul M
inst✝² : Mul N✝
inst✝¹ : Mul P
S : Subsemigroup M
N : Type u_5
inst✝ : Mul N
f : M →ₙ* N
⊢ ↑f.srange = ↑⊤ ↔ Set.range ⇑f = Set.univ
state_after: no goals
tactic: rw [coe_srange, coe_top]