ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
Theorem: Polynomial.sum_taylor_eq
File: Mathlib/Algebra/Polynomial/Taylor.lean

Proof steps:
state_before: R✝ : Type u_1
inst✝¹ : Semiring R✝
r✝ : R✝
f✝ : R✝[X]
R : Type u_2
inst✝ : CommRing R
f : R[X]
r : R
⊢ (((taylor r) f).sum fun i a => C a * (X - C r) ^ i) = f
state_after: no goals
tactic: rw [← comp_eq_sum_left, sub_eq_add_neg, ← C_neg, ← taylor_apply, taylor_taylor, neg_add_self,
    taylor_zero]
Theorem: Cardinal.bsup_lt_ord_of_isRegular
File: Mathlib/SetTheory/Cardinal/Cofinality.lean

Proof steps:
state_before: α : Type u_1
r : α → α → Prop
o : Ordinal.{max u_2 u_3}
f : (a : Ordinal.{max u_2 u_3}) → a < o → Ordinal.{max u_2 u_3}
c : Cardinal.{max u_2 u_3}
hc : c.IsRegular
hι : o.card < c
⊢ o.card < c.ord.cof
state_after: no goals
tactic: rwa [hc.cof_eq]
Theorem: RelSeries.last_append
File: Mathlib/Order/RelSeries.lean

Proof steps:
state_before: α : Type u_1
r : Rel α α
β : Type u_2
s : Rel β β
p q : RelSeries r
connect : r p.last q.head
⊢ (p.append q connect).last = q.last
state_after: α : Type u_1
r : Rel α α
β : Type u_2
s : Rel β β
p q : RelSeries r
connect : r p.last q.head
⊢ (p.append q connect).toFun (Fin.last (p.append q connect).length) = q.toFun (Fin.last q.length)
tactic: delta last
state_before: α : Type u_1
r : Rel α α
β : Type u_2
s : Rel β β
p q : RelSeries r
connect : r p.last q.head
⊢ (p.append q connect).toFun (Fin.last (p.append q connect).length) = q.toFun (Fin.last q.length)
state_after: case h.e'_2.h.e'_4
α : Type u_1
r : Rel α α
β : Type u_2
s : Rel β β
p q : RelSeries r
connect : r p.last q.head
⊢ Fin.last (p.append q connect).length = ↑↑(Fin.natAdd p.length (Fin.last q.length)) + 1
tactic: convert append_apply_right p q connect (Fin.last _)
state_before: case h.e'_2.h.e'_4
α : Type u_1
r : Rel α α
β : Type u_2
s : Rel β β
p q : RelSeries r
connect : r p.last q.head
⊢ Fin.last (p.append q connect).length = ↑↑(Fin.natAdd p.length (Fin.last q.length)) + 1
state_after: case h.e'_2.h.e'_4.h
α : Type u_1
r : Rel α α
β : Type u_2
s : Rel β β
p q : RelSeries r
connect : r p.last q.head
⊢ ↑(Fin.last (p.append q connect).length) = ↑(↑↑(Fin.natAdd p.length (Fin.last q.length)) + 1)
tactic: ext
state_before: case h.e'_2.h.e'_4.h
α : Type u_1
r : Rel α α
β : Type u_2
s : Rel β β
p q : RelSeries r
connect : r p.last q.head
⊢ ↑(Fin.last (p.append q connect).length) = ↑(↑↑(Fin.natAdd p.length (Fin.last q.length)) + 1)
state_after: case h.e'_2.h.e'_4.h
α : Type u_1
r : Rel α α
β : Type u_2
s : Rel β β
p q : RelSeries r
connect : r p.last q.head
⊢ ↑(Fin.last (p.append q connect).length) =
    (↑(Fin.natAdd p.length (Fin.last q.length)) % ((p.append q connect).length + 1) +
        1 % ((p.append q connect).length + 1)) %
      ((p.append q connect).length + 1)
tactic: change _ = _ % _
state_before: case h.e'_2.h.e'_4.h
α : Type u_1
r : Rel α α
β : Type u_2
s : Rel β β
p q : RelSeries r
connect : r p.last q.head
⊢ ↑(Fin.last (p.append q connect).length) =
    (↑(Fin.natAdd p.length (Fin.last q.length)) % ((p.append q connect).length + 1) +
        1 % ((p.append q connect).length + 1)) %
      ((p.append q connect).length + 1)
state_after: no goals
tactic: simp only [append_length, Fin.val_last, Fin.natAdd_last, Nat.one_mod, Nat.mod_add_mod,
    Nat.mod_succ]
Theorem: Commute.mul_zpow
File: Mathlib/Algebra/Group/Commute/Defs.lean

Proof steps:
state_before: G : Type u_1
M : Type u_2
S : Type u_3
inst✝ : DivisionMonoid G
a b c d : G
h : Commute a b
n : ℕ
⊢ (a * b) ^ ↑n = a ^ ↑n * b ^ ↑n
state_after: no goals
tactic: simp [zpow_natCast, h.mul_pow n]
state_before: G : Type u_1
M : Type u_2
S : Type u_3
inst✝ : DivisionMonoid G
a b c d : G
h : Commute a b
n : ℕ
⊢ (a * b) ^ Int.negSucc n = a ^ Int.negSucc n * b ^ Int.negSucc n
state_after: no goals
tactic: simp [h.mul_pow, (h.pow_pow _ _).eq, mul_inv_rev]
Theorem: ENNReal.ofReal_div_of_pos
File: Mathlib/Data/ENNReal/Real.lean

Proof steps:
state_before: a b c d : ℝ≥0∞
r p q : ℝ≥0
x y : ℝ
hy : 0 < y
⊢ ENNReal.ofReal (x / y) = ENNReal.ofReal x / ENNReal.ofReal y
state_after: no goals
tactic: rw [div_eq_mul_inv, div_eq_mul_inv, ofReal_mul' (inv_nonneg.2 hy.le), ofReal_inv_of_pos hy]
Theorem: OpenSubgroup.isClosed
File: Mathlib/Topology/Algebra/OpenSubgroup.lean

Proof steps:
state_before: G : Type u_1
inst✝² : Group G
inst✝¹ : TopologicalSpace G
U✝ V : OpenSubgroup G
g : G
inst✝ : ContinuousMul G
U : OpenSubgroup G
⊢ IsClosed ↑U
state_after: G : Type u_1
inst✝² : Group G
inst✝¹ : TopologicalSpace G
U✝ V : OpenSubgroup G
g : G
inst✝ : ContinuousMul G
U : OpenSubgroup G
⊢ IsOpen (↑U)ᶜ
tactic: apply isOpen_compl_iff.1
state_before: G : Type u_1
inst✝² : Group G
inst✝¹ : TopologicalSpace G
U✝ V : OpenSubgroup G
g : G
inst✝ : ContinuousMul G
U : OpenSubgroup G
⊢ IsOpen (↑U)ᶜ
state_after: case refine_1
G : Type u_1
inst✝² : Group G
inst✝¹ : TopologicalSpace G
U✝ V : OpenSubgroup G
g : G
inst✝ : ContinuousMul G
U : OpenSubgroup G
x : G
hx : x ∈ (↑U)ᶜ
⊢ (fun y => y * x⁻¹) ⁻¹' ↑U ⊆ (↑U)ᶜ

case refine_2
G : Type u_1
inst✝² : Group G
inst✝¹ : TopologicalSpace G
U✝ V : OpenSubgroup G
g : G
inst✝ : ContinuousMul G
U : OpenSubgroup G
x : G
hx : x ∈ (↑U)ᶜ
⊢ IsOpen ((fun y => y * x⁻¹) ⁻¹' ↑U)

case refine_3
G : Type u_1
inst✝² : Group G
inst✝¹ : TopologicalSpace G
U✝ V : OpenSubgroup G
g : G
inst✝ : ContinuousMul G
U : OpenSubgroup G
x : G
hx : x ∈ (↑U)ᶜ
⊢ x ∈ (fun y => y * x⁻¹) ⁻¹' ↑U
tactic: refine isOpen_iff_forall_mem_open.2 fun x hx => ⟨(fun y => y * x⁻¹) ⁻¹' U, ?_, ?_, ?_⟩
Theorem: Matrix.charpoly.univ_coeff_eval₂Hom
File: Mathlib/LinearAlgebra/Matrix/Charpoly/Univ.lean

Proof steps:
state_before: R : Type u_1
S : Type u_2
n : Type u_3
inst✝³ : CommRing R
inst✝² : CommRing S
inst✝¹ : Fintype n
inst✝ : DecidableEq n
f : R →+* S
M : n × n → S
i : ℕ
⊢ (MvPolynomial.eval₂Hom f M) ((univ R n).coeff i) = (of (Function.curry M)).charpoly.coeff i
state_after: no goals
tactic: rw [← univ_map_eval₂Hom n f M, Polynomial.coeff_map]
Theorem: iSup_symmDiff_iSup_le
File: Mathlib/Order/CompleteBooleanAlgebra.lean

Proof steps:
state_before: α : Type u
β : Type v
ι : Sort w
κ : ι → Sort w'
inst✝ : CompleteBooleanAlgebra α
a b : α
s : Set α
f g : ι → α
⊢ (⨆ i, f i) ∆ ⨆ i, g i ≤ ⨆ i, f i ∆ g i
state_after: α : Type u
β : Type v
ι : Sort w
κ : ι → Sort w'
inst✝ : CompleteBooleanAlgebra α
a b : α
s : Set α
f g : ι → α
⊢ ⨆ i, f i ≤ ⨆ x, g x ⊔ f x ∆ g x ∧ ⨆ i, g i ≤ ⨆ x, f x ⊔ f x ∆ g x
tactic: simp_rw [symmDiff_le_iff, ← iSup_sup_eq]
state_before: α : Type u
β : Type v
ι : Sort w
κ : ι → Sort w'
inst✝ : CompleteBooleanAlgebra α
a b : α
s : Set α
f g : ι → α
⊢ ⨆ i, f i ≤ ⨆ x, g x ⊔ f x ∆ g x ∧ ⨆ i, g i ≤ ⨆ x, f x ⊔ f x ∆ g x
state_after: no goals
tactic: exact ⟨iSup_mono fun i ↦ sup_comm (g i) _ ▸ le_symmDiff_sup_right ..,
    iSup_mono fun i ↦ sup_comm (f i) _ ▸ symmDiff_comm (f i) _ ▸ le_symmDiff_sup_right ..⟩
Theorem: MeasureTheory.Measure.haar.mem_prehaar_empty
File: Mathlib/MeasureTheory/Measure/Haar/Basic.lean

Proof steps:
state_before: G : Type u_1
inst✝¹ : Group G
inst✝ : TopologicalSpace G
K₀ : Set G
f : Compacts G → ℝ
⊢ f ∈ haarProduct K₀ ↔ ∀ (K : Compacts G), f K ∈ Icc 0 ↑(index (↑K) K₀)
state_after: no goals
tactic: simp only [haarProduct, Set.pi, forall_prop_of_true, mem_univ, mem_setOf_eq]
Theorem: WeierstrassCurve.Ψ_zero
File: Mathlib/AlgebraicGeometry/EllipticCurve/DivisionPolynomial/Basic.lean

Proof steps:
state_before: R : Type r
S : Type s
inst✝¹ : CommRing R
inst✝ : CommRing S
W : WeierstrassCurve R
⊢ W.Ψ 0 = 0
state_after: no goals
tactic: erw [Ψ_ofNat, preΨ'_zero, C_0, zero_mul]
Theorem: Subtype.exists_pi_extension
File: Mathlib/Tactic/Lift.lean

Proof steps:
state_before: ι : Sort u_1
α : ι → Sort u_2
ne : ∀ (i : ι), Nonempty (α i)
p : ι → Prop
f : (i : Subtype p) → α i.val
⊢ ∃ g, (fun i => g i.val) = f
state_after: ι : Sort u_1
α : ι → Sort u_2
ne : ∀ (i : ι), Nonempty (α i)
p : ι → Prop
f : (i : Subtype p) → α i.val
this : DecidablePred p
⊢ ∃ g, (fun i => g i.val) = f
tactic: haveI : DecidablePred p := fun i ↦ Classical.propDecidable (p i)
state_before: ι : Sort u_1
α : ι → Sort u_2
ne : ∀ (i : ι), Nonempty (α i)
p : ι → Prop
f : (i : Subtype p) → α i.val
this : DecidablePred p
⊢ ∃ g, (fun i => g i.val) = f
state_after: no goals
tactic: exact ⟨fun i => if hi : p i then f ⟨i, hi⟩ else Classical.choice (ne i),
    funext fun i ↦ dif_pos i.2⟩
Theorem: QuotientAddGroup.comap_comap_center
File: Mathlib/GroupTheory/QuotientGroup.lean

Proof steps:
state_before: G : Type u
inst✝⁴ : Group G
N : Subgroup G
nN : N.Normal
H : Type v
inst✝³ : Group H
M : Type x
inst✝² : Monoid M
φ : G →* H
H₁ : Subgroup G
inst✝¹ : H₁.Normal
H₂ : Subgroup (G ⧸ H₁)
inst✝ : H₂.Normal
⊢ Subgroup.comap (mk' H₁) (Subgroup.comap (mk' H₂) (Subgroup.center ((G ⧸ H₁) ⧸ H₂))) =
    Subgroup.comap (mk' (Subgroup.comap (mk' H₁) H₂)) (Subgroup.center (G ⧸ Subgroup.comap (mk' H₁) H₂))
state_after: case h
G : Type u
inst✝⁴ : Group G
N : Subgroup G
nN : N.Normal
H : Type v
inst✝³ : Group H
M : Type x
inst✝² : Monoid M
φ : G →* H
H₁ : Subgroup G
inst✝¹ : H₁.Normal
H₂ : Subgroup (G ⧸ H₁)
inst✝ : H₂.Normal
x : G
⊢ x ∈ Subgroup.comap (mk' H₁) (Subgroup.comap (mk' H₂) (Subgroup.center ((G ⧸ H₁) ⧸ H₂))) ↔
    x ∈ Subgroup.comap (mk' (Subgroup.comap (mk' H₁) H₂)) (Subgroup.center (G ⧸ Subgroup.comap (mk' H₁) H₂))
tactic: ext x
state_before: case h
G : Type u
inst✝⁴ : Group G
N : Subgroup G
nN : N.Normal
H : Type v
inst✝³ : Group H
M : Type x
inst✝² : Monoid M
φ : G →* H
H₁ : Subgroup G
inst✝¹ : H₁.Normal
H₂ : Subgroup (G ⧸ H₁)
inst✝ : H₂.Normal
x : G
⊢ x ∈ Subgroup.comap (mk' H₁) (Subgroup.comap (mk' H₂) (Subgroup.center ((G ⧸ H₁) ⧸ H₂))) ↔
    x ∈ Subgroup.comap (mk' (Subgroup.comap (mk' H₁) H₂)) (Subgroup.center (G ⧸ Subgroup.comap (mk' H₁) H₂))
state_after: no goals
tactic: simp only [mk'_apply, Subgroup.mem_comap, Subgroup.mem_center_iff, forall_mk, ← mk_mul,
    eq_iff_div_mem, mk_div]
Theorem: SimpleGraph.Subgraph.iInf_adj
File: Mathlib/Combinatorics/SimpleGraph/Subgraph.lean

Proof steps:
state_before: ι : Sort u_1
V : Type u
W : Type v
G : SimpleGraph V
G₁ G₂ : G.Subgraph
a b : V
f : ι → G.Subgraph
⊢ (⨅ i, f i).Adj a b ↔ (∀ (i : ι), (f i).Adj a b) ∧ G.Adj a b
state_after: no goals
tactic: simp [iInf]
Theorem: Nat.factors_multiset_prod_of_irreducible
File: Mathlib/RingTheory/UniqueFactorizationDomain.lean

Proof steps:
state_before: α : Type u_1
s : Multiset ℕ
h : ∀ x ∈ s, Irreducible x
⊢ normalizedFactors s.prod = s
state_after: α : Type u_1
s : Multiset ℕ
h : ∀ x ∈ s, Irreducible x
⊢ Multiset.Rel (fun x x_1 => x ~ᵤ x_1) (normalizedFactors s.prod) s
tactic: rw [← Multiset.rel_eq, ← associated_eq_eq]
state_before: α : Type u_1
s : Multiset ℕ
h : ∀ x ∈ s, Irreducible x
⊢ Multiset.Rel (fun x x_1 => x ~ᵤ x_1) (normalizedFactors s.prod) s
state_after: α : Type u_1
s : Multiset ℕ
h : ∀ x ∈ s, Irreducible x
⊢ s.prod ≠ 0
tactic: apply UniqueFactorizationMonoid.factors_unique irreducible_of_normalized_factor h
    (normalizedFactors_prod _)
state_before: α : Type u_1
s : Multiset ℕ
h : ∀ x ∈ s, Irreducible x
⊢ s.prod ≠ 0
state_after: α : Type u_1
s : Multiset ℕ
h : ∀ x ∈ s, Irreducible x
⊢ 0 ∉ s
tactic: rw [Ne, Multiset.prod_eq_zero_iff]
state_before: α : Type u_1
s : Multiset ℕ
h : ∀ x ∈ s, Irreducible x
⊢ 0 ∉ s
state_after: no goals
tactic: exact fun con ↦ not_irreducible_zero (h 0 con)
Theorem: Rat.addSubmonoid_closure_range_mul_self
File: Mathlib/Data/Rat/Star.lean

Proof steps:
state_before: ⊢ closure (range fun x => x * x) = nonneg ℚ
state_after: no goals
tactic: simpa only [sq] using addSubmonoid_closure_range_pow two_ne_zero even_two
Theorem: mem_closure_iff_frequently
File: Mathlib/Topology/Basic.lean

Proof steps:
state_before: X : Type u
Y : Type v
ι : Sort w
α : Type u_1
β : Type u_2
x : X
s s₁ s₂ t : Set X
p p₁ p₂ : X → Prop
inst✝ : TopologicalSpace X
⊢ x ∈ closure s ↔ ∃ᶠ (x : X) in 𝓝 x, x ∈ s
state_after: no goals
tactic: rw [Filter.Frequently, Filter.Eventually, ← mem_interior_iff_mem_nhds,
    closure_eq_compl_interior_compl, mem_compl_iff, compl_def]
Theorem: coborder_eq_compl_frontier_iff
File: Mathlib/Topology/LocallyClosed.lean

Proof steps:
state_before: X : Type u_1
Y : Type u_2
inst✝¹ : TopologicalSpace X
inst✝ : TopologicalSpace Y
s t : Set X
f : X → Y
⊢ coborder s = (frontier s)ᶜ ↔ IsOpen s
state_after: no goals
tactic: simp_rw [coborder_eq_union_frontier_compl, union_eq_right, subset_compl_iff_disjoint_left,
    disjoint_frontier_iff_isOpen]
Theorem: Quiver.Path.hom_heq_of_cons_eq_cons
File: Mathlib/Combinatorics/Quiver/Path.lean

Proof steps:
state_before: V : Type u
inst✝ : Quiver V
a b c d : V
p : Path a b
p' : Path a c
e : b ⟶ d
e' : c ⟶ d
h : p.cons e = p'.cons e'
⊢ HEq e e'
state_after: no goals
tactic: injection h
Theorem: CategoryTheory.ShortComplex.HomologyData.map_left
File: Mathlib/Algebra/Homology/ShortComplex/PreservesHomology.lean

Proof steps:
state_before: C : Type u_1
D : Type u_2
inst✝⁶ : Category.{?u.45702, u_1} C
inst✝⁵ : Category.{?u.45706, u_2} D
inst✝⁴ : HasZeroMorphisms C
inst✝³ : HasZeroMorphisms D
S S₁ S₂ : ShortComplex C
h : S.HomologyData
F : C ⥤ D
inst✝² : F.PreservesZeroMorphisms
inst✝¹ : h.left.IsPreservedBy F
inst✝ : h.right.IsPreservedBy F
⊢ (h.left.map F).π ≫ (F.mapIso h.iso).hom ≫ (h.right.map F).ι = (h.left.map F).i ≫ (h.right.map F).p
state_after: no goals
tactic: simpa only [F.map_comp] using F.congr_map h.comm
Theorem: List.forall₂_take_append
File: Mathlib/Data/List/Forall2.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
R S : α → β → Prop
P : γ → δ → Prop
Rₐ : α → α → Prop
l : List α
l₁ l₂ : List β
h : Forall₂ R l (l₁ ++ l₂)
⊢ Forall₂ R (take l₁.length l) l₁
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
R S : α → β → Prop
P : γ → δ → Prop
Rₐ : α → α → Prop
l : List α
l₁ l₂ : List β
h : Forall₂ R l (l₁ ++ l₂)
h' : Forall₂ R (take l₁.length l) (take l₁.length (l₁ ++ l₂))
⊢ Forall₂ R (take l₁.length l) l₁
tactic: have h' : Forall₂ R (take (length l₁) l) (take (length l₁) (l₁ ++ l₂)) :=
    forall₂_take (length l₁) h
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
R S : α → β → Prop
P : γ → δ → Prop
Rₐ : α → α → Prop
l : List α
l₁ l₂ : List β
h : Forall₂ R l (l₁ ++ l₂)
h' : Forall₂ R (take l₁.length l) (take l₁.length (l₁ ++ l₂))
⊢ Forall₂ R (take l₁.length l) l₁
state_after: no goals
tactic: rwa [take_left] at h'
Theorem: List.toFinsupp_concat_eq_toFinsupp_add_single
File: Mathlib/Data/List/ToFinsupp.lean

Proof steps:
state_before: M : Type u_1
inst✝⁴ : Zero M
l : List M
inst✝³ : DecidablePred fun x => l.getD x 0 ≠ 0
n : ℕ
R : Type u_2
inst✝² : AddZeroClass R
x : R
xs : List R
inst✝¹ : DecidablePred fun i => (xs ++ [x]).getD i 0 ≠ 0
inst✝ : DecidablePred fun i => xs.getD i 0 ≠ 0
⊢ (xs ++ [x]).toFinsupp = xs.toFinsupp + Finsupp.single xs.length x
state_after: no goals
tactic: classical rw [toFinsupp_append, toFinsupp_singleton, Finsupp.embDomain_single,
    addLeftEmbedding_apply, add_zero]
Theorem: IsFractional.mul
File: Mathlib/RingTheory/FractionalIdeal/Basic.lean

Proof steps:
state_before: R : Type u_1
inst✝² : CommRing R
S : Submonoid R
P : Type u_2
inst✝¹ : CommRing P
inst✝ : Algebra R P
loc : IsLocalization S P
I J : Submodule R P
aI : R
haI : aI ∈ S
hI : ∀ b ∈ I, IsInteger R (aI • b)
aJ : R
haJ : aJ ∈ S
hJ : ∀ b ∈ J, IsInteger R (aJ • b)
b : P
hb : b ∈ I * J
⊢ IsInteger R ((aI * aJ) • b)
state_after: case refine_1
R : Type u_1
inst✝² : CommRing R
S : Submonoid R
P : Type u_2
inst✝¹ : CommRing P
inst✝ : Algebra R P
loc : IsLocalization S P
I J : Submodule R P
aI : R
haI : aI ∈ S
hI : ∀ b ∈ I, IsInteger R (aI • b)
aJ : R
haJ : aJ ∈ S
hJ : ∀ b ∈ J, IsInteger R (aJ • b)
b : P
hb : b ∈ I * J
⊢ ∀ m ∈ I, ∀ n ∈ J, IsInteger R ((aI * aJ) • (m * n))

case refine_2
R : Type u_1
inst✝² : CommRing R
S : Submonoid R
P : Type u_2
inst✝¹ : CommRing P
inst✝ : Algebra R P
loc : IsLocalization S P
I J : Submodule R P
aI : R
haI : aI ∈ S
hI : ∀ b ∈ I, IsInteger R (aI • b)
aJ : R
haJ : aJ ∈ S
hJ : ∀ b ∈ J, IsInteger R (aJ • b)
b : P
hb : b ∈ I * J
⊢ ∀ (x y : P), IsInteger R ((aI * aJ) • x) → IsInteger R ((aI * aJ) • y) → IsInteger R ((aI * aJ) • (x + y))
tactic: refine Submodule.mul_induction_on hb ?_ ?_
Theorem: integral_mul_cexp_neg_mul_sq
File: Mathlib/Analysis/SpecialFunctions/Gaussian/GaussianIntegral.lean

Proof steps:
state_before: b : ℂ
hb : 0 < b.re
⊢ ∫ (r : ℝ) in Ioi 0, ↑r * cexp (-b * ↑r ^ 2) = (2 * b)⁻¹
state_after: b : ℂ
hb : 0 < b.re
hb' : b ≠ 0
⊢ ∫ (r : ℝ) in Ioi 0, ↑r * cexp (-b * ↑r ^ 2) = (2 * b)⁻¹
tactic: have hb' : b ≠ 0 := by contrapose! hb; rw [hb, zero_re]
state_before: b : ℂ
hb : 0 < b.re
hb' : b ≠ 0
⊢ ∫ (r : ℝ) in Ioi 0, ↑r * cexp (-b * ↑r ^ 2) = (2 * b)⁻¹
state_after: b : ℂ
hb : 0 < b.re
hb' : b ≠ 0
A : ∀ (x : ℂ), HasDerivAt (fun x => -(2 * b)⁻¹ * cexp (-b * x ^ 2)) (x * cexp (-b * x ^ 2)) x
⊢ ∫ (r : ℝ) in Ioi 0, ↑r * cexp (-b * ↑r ^ 2) = (2 * b)⁻¹
tactic: have A : ∀ x : ℂ, HasDerivAt (fun x => -(2 * b)⁻¹ * cexp (-b * x ^ 2))
    (x * cexp (-b * x ^ 2)) x := by
    intro x
    convert ((hasDerivAt_pow 2 x).const_mul (-b)).cexp.const_mul (-(2 * b)⁻¹) using 1
    field_simp [hb']
    ring
state_before: b : ℂ
hb : 0 < b.re
hb' : b ≠ 0
A : ∀ (x : ℂ), HasDerivAt (fun x => -(2 * b)⁻¹ * cexp (-b * x ^ 2)) (x * cexp (-b * x ^ 2)) x
⊢ ∫ (r : ℝ) in Ioi 0, ↑r * cexp (-b * ↑r ^ 2) = (2 * b)⁻¹
state_after: b : ℂ
hb : 0 < b.re
hb' : b ≠ 0
A : ∀ (x : ℂ), HasDerivAt (fun x => -(2 * b)⁻¹ * cexp (-b * x ^ 2)) (x * cexp (-b * x ^ 2)) x
B : Tendsto (fun y => -(2 * b)⁻¹ * cexp (-b * ↑y ^ 2)) atTop (𝓝 (-(2 * b)⁻¹ * 0))
⊢ ∫ (r : ℝ) in Ioi 0, ↑r * cexp (-b * ↑r ^ 2) = (2 * b)⁻¹
tactic: have B : Tendsto (fun y : ℝ ↦ -(2 * b)⁻¹ * cexp (-b * (y : ℂ) ^ 2))
    atTop (𝓝 (-(2 * b)⁻¹ * 0)) := by
    refine Tendsto.const_mul _ (tendsto_zero_iff_norm_tendsto_zero.mpr ?_)
    simp_rw [norm_cexp_neg_mul_sq b]
    exact tendsto_exp_atBot.comp
      ((tendsto_pow_atTop two_ne_zero).const_mul_atTop_of_neg (neg_lt_zero.2 hb))
state_before: b : ℂ
hb : 0 < b.re
hb' : b ≠ 0
A : ∀ (x : ℂ), HasDerivAt (fun x => -(2 * b)⁻¹ * cexp (-b * x ^ 2)) (x * cexp (-b * x ^ 2)) x
B : Tendsto (fun y => -(2 * b)⁻¹ * cexp (-b * ↑y ^ 2)) atTop (𝓝 (-(2 * b)⁻¹ * 0))
⊢ ∫ (r : ℝ) in Ioi 0, ↑r * cexp (-b * ↑r ^ 2) = (2 * b)⁻¹
state_after: case h.e'_3
b : ℂ
hb : 0 < b.re
hb' : b ≠ 0
A : ∀ (x : ℂ), HasDerivAt (fun x => -(2 * b)⁻¹ * cexp (-b * x ^ 2)) (x * cexp (-b * x ^ 2)) x
B : Tendsto (fun y => -(2 * b)⁻¹ * cexp (-b * ↑y ^ 2)) atTop (𝓝 (-(2 * b)⁻¹ * 0))
⊢ (2 * b)⁻¹ = -(2 * b)⁻¹ * 0 - -(2 * b)⁻¹ * cexp (-b * ↑0 ^ 2)
tactic: convert integral_Ioi_of_hasDerivAt_of_tendsto' (fun x _ => (A ↑x).comp_ofReal)
    (integrable_mul_cexp_neg_mul_sq hb).integrableOn B using 1
state_before: case h.e'_3
b : ℂ
hb : 0 < b.re
hb' : b ≠ 0
A : ∀ (x : ℂ), HasDerivAt (fun x => -(2 * b)⁻¹ * cexp (-b * x ^ 2)) (x * cexp (-b * x ^ 2)) x
B : Tendsto (fun y => -(2 * b)⁻¹ * cexp (-b * ↑y ^ 2)) atTop (𝓝 (-(2 * b)⁻¹ * 0))
⊢ (2 * b)⁻¹ = -(2 * b)⁻¹ * 0 - -(2 * b)⁻¹ * cexp (-b * ↑0 ^ 2)
state_after: no goals
tactic: simp only [mul_zero, ofReal_zero, zero_pow, Ne, Nat.one_ne_zero,
    not_false_iff, Complex.exp_zero, mul_one, sub_neg_eq_add, zero_add]
Theorem: Polynomial.Monic.irreducible_iff_natDegree
File: Mathlib/Algebra/Polynomial/RingDivision.lean

Proof steps:
state_before: R : Type u
S : Type v
T : Type w
a b : R
n : ℕ
inst✝¹ : CommSemiring R
inst✝ : NoZeroDivisors R
p q : R[X]
hp : p.Monic
⊢ Irreducible p ↔ p ≠ 1 ∧ ∀ (f g : R[X]), f.Monic → g.Monic → f * g = p → f.natDegree = 0 ∨ g.natDegree = 0
state_after: case pos
R : Type u
S : Type v
T : Type w
a b : R
n : ℕ
inst✝¹ : CommSemiring R
inst✝ : NoZeroDivisors R
p q : R[X]
hp : p.Monic
hp1 : p = 1
⊢ Irreducible p ↔ p ≠ 1 ∧ ∀ (f g : R[X]), f.Monic → g.Monic → f * g = p → f.natDegree = 0 ∨ g.natDegree = 0

case neg
R : Type u
S : Type v
T : Type w
a b : R
n : ℕ
inst✝¹ : CommSemiring R
inst✝ : NoZeroDivisors R
p q : R[X]
hp : p.Monic
hp1 : ¬p = 1
⊢ Irreducible p ↔ p ≠ 1 ∧ ∀ (f g : R[X]), f.Monic → g.Monic → f * g = p → f.natDegree = 0 ∨ g.natDegree = 0
tactic: by_cases hp1 : p = 1
state_before: case neg
R : Type u
S : Type v
T : Type w
a b : R
n : ℕ
inst✝¹ : CommSemiring R
inst✝ : NoZeroDivisors R
p q : R[X]
hp : p.Monic
hp1 : ¬p = 1
⊢ Irreducible p ↔ p ≠ 1 ∧ ∀ (f g : R[X]), f.Monic → g.Monic → f * g = p → f.natDegree = 0 ∨ g.natDegree = 0
state_after: case neg
R : Type u
S : Type v
T : Type w
a b : R
n : ℕ
inst✝¹ : CommSemiring R
inst✝ : NoZeroDivisors R
p q : R[X]
hp : p.Monic
hp1 : ¬p = 1
⊢ (∀ (f g : R[X]), f.Monic → g.Monic → f * g = p → f = 1 ∨ g = 1) ↔
    ∀ (f g : R[X]), f.Monic → g.Monic → f * g = p → f.natDegree = 0 ∨ g.natDegree = 0
tactic: rw [irreducible_of_monic hp hp1, and_iff_right hp1]
state_before: case neg
R : Type u
S : Type v
T : Type w
a b : R
n : ℕ
inst✝¹ : CommSemiring R
inst✝ : NoZeroDivisors R
p q : R[X]
hp : p.Monic
hp1 : ¬p = 1
⊢ (∀ (f g : R[X]), f.Monic → g.Monic → f * g = p → f = 1 ∨ g = 1) ↔
    ∀ (f g : R[X]), f.Monic → g.Monic → f * g = p → f.natDegree = 0 ∨ g.natDegree = 0
state_after: case neg
R : Type u
S : Type v
T : Type w
a✝ b✝ : R
n : ℕ
inst✝¹ : CommSemiring R
inst✝ : NoZeroDivisors R
p q : R[X]
hp : p.Monic
hp1 : ¬p = 1
a b : R[X]
ha : a.Monic
hb : b.Monic
⊢ a * b = p → a = 1 ∨ b = 1 ↔ a * b = p → a.natDegree = 0 ∨ b.natDegree = 0
tactic: refine forall₄_congr fun a b ha hb => ?_
state_before: case neg
R : Type u
S : Type v
T : Type w
a✝ b✝ : R
n : ℕ
inst✝¹ : CommSemiring R
inst✝ : NoZeroDivisors R
p q : R[X]
hp : p.Monic
hp1 : ¬p = 1
a b : R[X]
ha : a.Monic
hb : b.Monic
⊢ a * b = p → a = 1 ∨ b = 1 ↔ a * b = p → a.natDegree = 0 ∨ b.natDegree = 0
state_after: no goals
tactic: rw [ha.natDegree_eq_zero_iff_eq_one, hb.natDegree_eq_zero_iff_eq_one]
Theorem: derivationToSquareZeroEquivLift_symm_apply_apply_coe
File: Mathlib/RingTheory/Derivation/ToSquareZero.lean

Proof steps:
state_before: R : Type u
A : Type v
B : Type w
inst✝⁶ : CommSemiring R
inst✝⁵ : CommSemiring A
inst✝⁴ : CommRing B
inst✝³ : Algebra R A
inst✝² : Algebra R B
I : Ideal B
hI : I ^ 2 = ⊥
inst✝¹ : Algebra A B
inst✝ : IsScalarTower R A B
⊢ Derivation R A ↥I ≃ { f // (Ideal.Quotient.mkₐ R I).comp f = IsScalarTower.toAlgHom R A (B ⧸ I) }
state_after: case refine_1
R : Type u
A : Type v
B : Type w
inst✝⁶ : CommSemiring R
inst✝⁵ : CommSemiring A
inst✝⁴ : CommRing B
inst✝³ : Algebra R A
inst✝² : Algebra R B
I : Ideal B
hI : I ^ 2 = ⊥
inst✝¹ : Algebra A B
inst✝ : IsScalarTower R A B
d : Derivation R A ↥I
⊢ (Ideal.Quotient.mkₐ R I).comp (liftOfDerivationToSquareZero I hI d) = IsScalarTower.toAlgHom R A (B ⧸ I)

case refine_2
R : Type u
A : Type v
B : Type w
inst✝⁶ : CommSemiring R
inst✝⁵ : CommSemiring A
inst✝⁴ : CommRing B
inst✝³ : Algebra R A
inst✝² : Algebra R B
I : Ideal B
hI : I ^ 2 = ⊥
inst✝¹ : Algebra A B
inst✝ : IsScalarTower R A B
⊢ Function.LeftInverse (fun f => derivationToSquareZeroOfLift I hI ↑f ⋯) fun d =>
    ⟨liftOfDerivationToSquareZero I hI d, ⋯⟩

case refine_3
R : Type u
A : Type v
B : Type w
inst✝⁶ : CommSemiring R
inst✝⁵ : CommSemiring A
inst✝⁴ : CommRing B
inst✝³ : Algebra R A
inst✝² : Algebra R B
I : Ideal B
hI : I ^ 2 = ⊥
inst✝¹ : Algebra A B
inst✝ : IsScalarTower R A B
⊢ Function.RightInverse (fun f => derivationToSquareZeroOfLift I hI ↑f ⋯) fun d =>
    ⟨liftOfDerivationToSquareZero I hI d, ⋯⟩
tactic: refine ⟨fun d => ⟨liftOfDerivationToSquareZero I hI d, ?_⟩, fun f =>
    (derivationToSquareZeroOfLift I hI f.1 f.2 : _), ?_, ?_⟩
Theorem: Pi.lt_def
File: Mathlib/Order/Basic.lean

Proof steps:
state_before: ι : Type u_1
α : Type u_2
β : Type u_3
π : ι → Type u_4
inst✝ : (i : ι) → Preorder (π i)
x y : (i : ι) → π i
⊢ x < y ↔ x ≤ y ∧ ∃ i, x i < y i
state_after: no goals
tactic: simp (config := { contextual := true }) [lt_iff_le_not_le, Pi.le_def]