ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
Theorem: WeierstrassCurve.Jacobian.add_smul_of_equiv
File: Mathlib/AlgebraicGeometry/EllipticCurve/Jacobian.lean

Proof steps:
state_before: R : Type u
inst✝¹ : CommRing R
W' : Jacobian R
F : Type v
inst✝ : Field F
W : Jacobian F
P Q : Fin 3 → R
h : P ≈ Q
u v : R
hu : IsUnit u
hv : IsUnit v
⊢ W'.add (u • P) (v • Q) = u ^ 4 • W'.add P Q
state_after: R : Type u
inst✝¹ : CommRing R
W' : Jacobian R
F : Type v
inst✝ : Field F
W : Jacobian F
P Q : Fin 3 → R
h : P ≈ Q
u v : R
hu : IsUnit u
hv : IsUnit v
smul : P ≈ Q ↔ u • P ≈ v • Q
⊢ W'.add (u • P) (v • Q) = u ^ 4 • W'.add P Q
tactic: have smul : P ≈ Q ↔ u • P ≈ v • Q := by
    erw [← Quotient.eq, ← Quotient.eq, smul_eq P hu, smul_eq Q hv]
    rfl
state_before: R : Type u
inst✝¹ : CommRing R
W' : Jacobian R
F : Type v
inst✝ : Field F
W : Jacobian F
P Q : Fin 3 → R
h : P ≈ Q
u v : R
hu : IsUnit u
hv : IsUnit v
smul : P ≈ Q ↔ u • P ≈ v • Q
⊢ W'.add (u • P) (v • Q) = u ^ 4 • W'.add P Q
state_after: no goals
tactic: rw [add_of_equiv <| smul.mp h, dblXYZ_smul, add_of_equiv h]
Theorem: variationOnFromTo.eq_left_iff
File: Mathlib/Analysis/BoundedVariation.lean

Proof steps:
state_before: α : Type u_1
inst✝¹ : LinearOrder α
E : Type u_2
inst✝ : PseudoEMetricSpace E
f✝ : α → E
s✝ : Set α
f : α → E
s : Set α
hf : LocallyBoundedVariationOn f s
a b c : α
ha : a ∈ s
hb : b ∈ s
hc : c ∈ s
⊢ variationOnFromTo f s a b = variationOnFromTo f s a c ↔ variationOnFromTo f s b c = 0
state_after: no goals
tactic: simp only [← variationOnFromTo.add hf ha hb hc, self_eq_add_right]
Theorem: Monotone.le_iterate_comp_of_le
File: Mathlib/Order/Iterate.lean

Proof steps:
state_before: α : Type u_1
inst✝ : Preorder α
f : α → α
x✝ y : ℕ → α
β : Type u_2
g : β → β
h : β → α
hf : Monotone f
H : h ∘ g ≤ f ∘ h
n : ℕ
x : β
⊢ (h ∘ g^[n]) x ≤ (f^[n] ∘ h) x
state_after: case hx
α : Type u_1
inst✝ : Preorder α
f : α → α
x✝ y : ℕ → α
β : Type u_2
g : β → β
h : β → α
hf : Monotone f
H : h ∘ g ≤ f ∘ h
n : ℕ
x : β
k✝ : ℕ
a✝ : k✝ < n
⊢ h (g (g^[k✝] x)) ≤ f (h (g^[k✝] x))
tactic: apply hf.seq_le_seq n <;> intros <;>
    simp [iterate_succ', -iterate_succ, comp_apply, id_eq, le_refl]
state_before: case hx
α : Type u_1
inst✝ : Preorder α
f : α → α
x✝ y : ℕ → α
β : Type u_2
g : β → β
h : β → α
hf : Monotone f
H : h ∘ g ≤ f ∘ h
n : ℕ
x : β
k✝ : ℕ
a✝ : k✝ < n
⊢ h (g (g^[k✝] x)) ≤ f (h (g^[k✝] x))
state_after: no goals
tactic: case hx => exact H _
Theorem: Matroid.ExchangeProperty.encard_base_eq
File: Mathlib/Data/Matroid/Basic.lean

Proof steps:
state_before: α : Type u_1
M : Matroid α
Base : Set α → Prop
exch : ExchangeProperty Base
B B' B₁ B₂ : Set α
hB₁ : Base B₁
hB₂ : Base B₂
⊢ B₁.encard = B₂.encard
state_after: no goals
tactic: rw [← encard_diff_add_encard_inter B₁ B₂, exch.encard_diff_eq hB₁ hB₂, inter_comm,
     encard_diff_add_encard_inter]
Theorem: Ideal.map_eq_top_iff
File: Mathlib/RingTheory/Ideal/Over.lean

Proof steps:
state_before: R : Type u_1
inst✝² : CommRing R
S : Type u_2
inst✝¹ : CommRing S
f✝ : R →+* S
I✝ J : Ideal S
inst✝ : Algebra R S
f : R →+* S
I : Ideal R
hf₁ : Function.Injective ⇑f
hf₂ : f.IsIntegral
⊢ RingHom.ker f ≤ I
state_after: no goals
tactic: simp [f.injective_iff_ker_eq_bot.mp hf₁]
Theorem: egauge_ball_one_le_of_one_lt_norm
File: Mathlib/Analysis/Convex/EGauge.lean

Proof steps:
state_before: 𝕜 : Type u_1
inst✝² : NormedField 𝕜
α : Type u_2
E : Type u_3
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
c : 𝕜
s t : Set E
x✝ y : E
r : ℝ≥0
hc : 1 < ‖c‖
x : E
⊢ egauge 𝕜 (ball 0 1) x ≤ ↑‖c‖₊ * ↑‖x‖₊
state_after: no goals
tactic: simpa using egauge_ball_le_of_one_lt_norm hc (.inl one_ne_zero)
Theorem: Metric.infDist_image
File: Mathlib/Topology/MetricSpace/HausdorffDistance.lean

Proof steps:
state_before: ι : Sort u_1
α : Type u
β : Type v
inst✝¹ : PseudoMetricSpace α
inst✝ : PseudoMetricSpace β
s t u : Set α
x y : α
Φ : α → β
hΦ : Isometry Φ
⊢ infDist (Φ x) (Φ '' t) = infDist x t
state_after: no goals
tactic: simp [infDist, infEdist_image hΦ]
Theorem: Bimod.RightUnitorBimod.inv_hom_id
File: Mathlib/CategoryTheory/Monoidal/Bimod.lean

Proof steps:
state_before: C : Type u₁
inst✝² : Category.{v₁, u₁} C
inst✝¹ : MonoidalCategory C
A B : Mon_ C
M : Bimod A B
inst✝ : HasCoequalizers C
R S : Mon_ C
P : Bimod R S
⊢ inv P ≫ hom P = 𝟙 P.X
state_after: C : Type u₁
inst✝² : Category.{v₁, u₁} C
inst✝¹ : MonoidalCategory C
A B : Mon_ C
M : Bimod A B
inst✝ : HasCoequalizers C
R S : Mon_ C
P : Bimod R S
⊢ ((ρ_ P.X).inv ≫ P.X ◁ S.one ≫ coequalizer.π (P.actRight ▷ S.X) ((α_ P.X S.X S.X).hom ≫ P.X ◁ S.mul)) ≫
      coequalizer.desc P.actRight ⋯ =
    𝟙 P.X
tactic: dsimp [hom, inv]
state_before: C : Type u₁
inst✝² : Category.{v₁, u₁} C
inst✝¹ : MonoidalCategory C
A B : Mon_ C
M : Bimod A B
inst✝ : HasCoequalizers C
R S : Mon_ C
P : Bimod R S
⊢ ((ρ_ P.X).inv ≫ P.X ◁ S.one ≫ coequalizer.π (P.actRight ▷ S.X) ((α_ P.X S.X S.X).hom ≫ P.X ◁ S.mul)) ≫
      coequalizer.desc P.actRight ⋯ =
    𝟙 P.X
state_after: C : Type u₁
inst✝² : Category.{v₁, u₁} C
inst✝¹ : MonoidalCategory C
A B : Mon_ C
M : Bimod A B
inst✝ : HasCoequalizers C
R S : Mon_ C
P : Bimod R S
⊢ (ρ_ P.X).inv ≫ P.X ◁ S.one ≫ P.actRight = 𝟙 P.X
tactic: slice_lhs 3 4 => rw [coequalizer.π_desc]
state_before: C : Type u₁
inst✝² : Category.{v₁, u₁} C
inst✝¹ : MonoidalCategory C
A B : Mon_ C
M : Bimod A B
inst✝ : HasCoequalizers C
R S : Mon_ C
P : Bimod R S
⊢ (ρ_ P.X).inv ≫ P.X ◁ S.one ≫ P.actRight = 𝟙 P.X
state_after: no goals
tactic: rw [actRight_one, Iso.inv_hom_id]
Theorem: MeasureTheory.SimpleFunc.iSup_approx_apply
File: Mathlib/MeasureTheory/Function/SimpleFunc.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
inst✝⁶ : MeasurableSpace α
K : Type u_5
inst✝⁵ : TopologicalSpace β
inst✝⁴ : CompleteLattice β
inst✝³ : OrderClosedTopology β
inst✝² : Zero β
inst✝¹ : MeasurableSpace β
inst✝ : OpensMeasurableSpace β
i : ℕ → β
f : α → β
a : α
hf : Measurable f
h_zero : 0 = ⊥
⊢ ⨆ n, ↑(approx i f n) a = ⨆ k, ⨆ (_ : i k ≤ f a), i k
state_after: case refine_1
α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
inst✝⁶ : MeasurableSpace α
K : Type u_5
inst✝⁵ : TopologicalSpace β
inst✝⁴ : CompleteLattice β
inst✝³ : OrderClosedTopology β
inst✝² : Zero β
inst✝¹ : MeasurableSpace β
inst✝ : OpensMeasurableSpace β
i : ℕ → β
f : α → β
a : α
hf : Measurable f
h_zero : 0 = ⊥
n : ℕ
⊢ ↑(approx i f n) a ≤ ⨆ k, ⨆ (_ : i k ≤ f a), i k

case refine_2
α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
inst✝⁶ : MeasurableSpace α
K : Type u_5
inst✝⁵ : TopologicalSpace β
inst✝⁴ : CompleteLattice β
inst✝³ : OrderClosedTopology β
inst✝² : Zero β
inst✝¹ : MeasurableSpace β
inst✝ : OpensMeasurableSpace β
i : ℕ → β
f : α → β
a : α
hf : Measurable f
h_zero : 0 = ⊥
k : ℕ
hk : i k ≤ f a
⊢ i k ≤ ⨆ n, ↑(approx i f n) a
tactic: refine le_antisymm (iSup_le fun n => ?_) (iSup_le fun k => iSup_le fun hk => ?_)
Theorem: CategoryTheory.Limits.imageSubobject_arrow
File: Mathlib/CategoryTheory/Subobject/Limits.lean

Proof steps:
state_before: C : Type u
inst✝¹ : Category.{v, u} C
X Y Z : C
f : X ⟶ Y
inst✝ : HasImage f
⊢ (imageSubobjectIso f).hom ≫ image.ι f = (imageSubobject f).arrow
state_after: no goals
tactic: simp [imageSubobjectIso]
Theorem: Associated.isUnit
File: Mathlib/Algebra/Associated/Basic.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
inst✝ : Monoid α
a b : α
h : a ~ᵤ b
u : αˣ
hu : a * ↑u = b
x✝ : IsUnit a
v : αˣ
hv : ↑v = a
⊢ ↑(v * u) = b
state_after: no goals
tactic: simp [hv, hu.symm]
Theorem: Polynomial.coeff_map
File: Mathlib/Algebra/Polynomial/Eval.lean

Proof steps:
state_before: R : Type u
S : Type v
T : Type w
ι : Type y
a b : R
m n✝ : ℕ
inst✝¹ : Semiring R
p q r : R[X]
inst✝ : Semiring S
f : R →+* S
n : ℕ
⊢ (map f p).coeff n = f (p.coeff n)
state_after: R : Type u
S : Type v
T : Type w
ι : Type y
a b : R
m n✝ : ℕ
inst✝¹ : Semiring R
p q r : R[X]
inst✝ : Semiring S
f : R →+* S
n : ℕ
⊢ ∑ n_1 ∈ p.support, ((C.comp f) (p.coeff n_1) * X ^ n_1).coeff n = f (p.coeff n)
tactic: rw [map, eval₂_def, coeff_sum, sum]
state_before: R : Type u
S : Type v
T : Type w
ι : Type y
a b : R
m n✝ : ℕ
inst✝¹ : Semiring R
p q r : R[X]
inst✝ : Semiring S
f : R →+* S
n : ℕ
⊢ ∑ n_1 ∈ p.support, ((C.comp f) (p.coeff n_1) * X ^ n_1).coeff n = f (p.coeff n)
state_after: R : Type u
S : Type v
T : Type w
ι : Type y
a b : R
m n✝ : ℕ
inst✝¹ : Semiring R
p q r : R[X]
inst✝ : Semiring S
f : R →+* S
n : ℕ
⊢ ∑ n_1 ∈ p.support, ((C.comp f) (p.coeff n_1) * X ^ n_1).coeff n = ∑ x ∈ p.support, f ((C (p.coeff x) * X ^ x).coeff n)
tactic: conv_rhs => rw [← sum_C_mul_X_pow_eq p, coeff_sum, sum, map_sum]
state_before: R : Type u
S : Type v
T : Type w
ι : Type y
a b : R
m n✝ : ℕ
inst✝¹ : Semiring R
p q r : R[X]
inst✝ : Semiring S
f : R →+* S
n : ℕ
⊢ ∑ n_1 ∈ p.support, ((C.comp f) (p.coeff n_1) * X ^ n_1).coeff n = ∑ x ∈ p.support, f ((C (p.coeff x) * X ^ x).coeff n)
state_after: R : Type u
S : Type v
T : Type w
ι : Type y
a b : R
m n✝ : ℕ
inst✝¹ : Semiring R
p q r : R[X]
inst✝ : Semiring S
f : R →+* S
n x : ℕ
_hx : x ∈ p.support
⊢ ((C.comp f) (p.coeff x) * X ^ x).coeff n = f ((C (p.coeff x) * X ^ x).coeff n)
tactic: refine Finset.sum_congr rfl fun x _hx => ?_
state_before: R : Type u
S : Type v
T : Type w
ι : Type y
a b : R
m n✝ : ℕ
inst✝¹ : Semiring R
p q r : R[X]
inst✝ : Semiring S
f : R →+* S
n x : ℕ
_hx : x ∈ p.support
⊢ ((C.comp f) (p.coeff x) * X ^ x).coeff n = f ((C (p.coeff x) * X ^ x).coeff n)
state_after: R : Type u
S : Type v
T : Type w
ι : Type y
a b : R
m n✝ : ℕ
inst✝¹ : Semiring R
p q r : R[X]
inst✝ : Semiring S
f : R →+* S
n x : ℕ
_hx : x ∈ p.support
⊢ (if n = x then f (p.coeff x) else 0) = f (if n = x then p.coeff x else 0)
tactic: simp only [RingHom.coe_comp, Function.comp, coeff_C_mul_X_pow]
state_before: R : Type u
S : Type v
T : Type w
ι : Type y
a b : R
m n✝ : ℕ
inst✝¹ : Semiring R
p q r : R[X]
inst✝ : Semiring S
f : R →+* S
n x : ℕ
_hx : x ∈ p.support
⊢ (if n = x then f (p.coeff x) else 0) = f (if n = x then p.coeff x else 0)
state_after: no goals
tactic: split_ifs <;> simp [f.map_zero]
Theorem: Nat.dvd_ofDigits_sub_ofDigits
File: Mathlib/Data/Nat/Digits.lean

Proof steps:
state_before: n : ℕ
α : Type u_1
inst✝ : CommRing α
a b k : α
h : k ∣ a - b
L : List ℕ
⊢ k ∣ ofDigits a L - ofDigits b L
state_after: case nil
n : ℕ
α : Type u_1
inst✝ : CommRing α
a b k : α
h : k ∣ a - b
⊢ k ∣ ofDigits a [] - ofDigits b []

case cons
n : ℕ
α : Type u_1
inst✝ : CommRing α
a b k : α
h : k ∣ a - b
d : ℕ
L : List ℕ
ih : k ∣ ofDigits a L - ofDigits b L
⊢ k ∣ ofDigits a (d :: L) - ofDigits b (d :: L)
tactic: induction' L with d L ih
Theorem: CategoryTheory.Limits.diagramIsoCospan_inv_app
File: Mathlib/CategoryTheory/Limits/Shapes/Pullback/Cospan.lean

Proof steps:
state_before: C : Type u
inst✝ : Category.{v, u} C
F : WalkingCospan ⥤ C
j : WalkingCospan
⊢ F.obj j = (cospan (F.map inl) (F.map inr)).obj j
state_after: no goals
tactic: rcases j with (⟨⟩ | ⟨⟨⟩⟩) <;> rfl
state_before: C : Type u
inst✝ : Category.{v, u} C
F : WalkingCospan ⥤ C
⊢ ∀ {X Y : WalkingCospan} (f : X ⟶ Y),
    F.map f ≫ ((fun j => eqToIso ⋯) Y).hom = ((fun j => eqToIso ⋯) X).hom ≫ (cospan (F.map inl) (F.map inr)).map f
state_after: no goals
tactic: rintro (⟨⟩ | ⟨⟨⟩⟩) (⟨⟩ | ⟨⟨⟩⟩) f <;> cases f <;> dsimp <;> simp
Theorem: add_neg_eq_of_eq_add
File: Mathlib/Algebra/Group/Basic.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
G : Type u_3
M : Type u_4
inst✝ : Group G
a b c d : G
n : ℤ
h : a = c * b
⊢ a * b⁻¹ = c
state_after: no goals
tactic: simp [h]
Theorem: Padic.AddValuation.map_zero
File: Mathlib/NumberTheory/Padics/PadicNumbers.lean

Proof steps:
state_before: p : ℕ
hp : Fact (Nat.Prime p)
⊢ addValuationDef 0 = ⊤
state_after: no goals
tactic: rw [addValuationDef, if_pos (Eq.refl _)]
Theorem: Function.support_pow
File: Mathlib/Algebra/GroupWithZero/Indicator.lean

Proof steps:
state_before: ι : Type u_1
κ : Type u_2
G₀ : Type u_3
M₀ : Type u_4
R : Type u_5
inst✝¹ : MonoidWithZero M₀
inst✝ : NoZeroDivisors M₀
n : ℕ
f : ι → M₀
hn : n ≠ 0
⊢ (support fun a => f a ^ n) = support f
state_after: case h
ι : Type u_1
κ : Type u_2
G₀ : Type u_3
M₀ : Type u_4
R : Type u_5
inst✝¹ : MonoidWithZero M₀
inst✝ : NoZeroDivisors M₀
n : ℕ
f : ι → M₀
hn : n ≠ 0
x✝ : ι
⊢ (x✝ ∈ support fun a => f a ^ n) ↔ x✝ ∈ support f
tactic: ext
state_before: case h
ι : Type u_1
κ : Type u_2
G₀ : Type u_3
M₀ : Type u_4
R : Type u_5
inst✝¹ : MonoidWithZero M₀
inst✝ : NoZeroDivisors M₀
n : ℕ
f : ι → M₀
hn : n ≠ 0
x✝ : ι
⊢ (x✝ ∈ support fun a => f a ^ n) ↔ x✝ ∈ support f
state_after: no goals
tactic: exact (pow_eq_zero_iff hn).not
Theorem: Nat.pow_right_injective
File: Mathlib/Data/Nat/Defs.lean

Proof steps:
state_before: a b c d m n k : ℕ
p q : ℕ → Prop
ha : 2 ≤ a
⊢ Injective fun x => a ^ x
state_after: no goals
tactic: simp [Injective, le_antisymm_iff, Nat.pow_le_pow_iff_right ha]
Theorem: Rat.mk_num_ne_zero_of_ne_zero
File: Mathlib/Data/Rat/Defs.lean

Proof steps:
state_before: q✝ a b c q : ℚ
n d : ℤ
hq : q ≠ 0
hqnd : q = n /. d
this : n = 0
⊢ q = 0
state_after: no goals
tactic: simpa [this] using hqnd
Theorem: Order.IsPredLimit.isMin
File: Mathlib/Order/SuccPred/Limit.lean

Proof steps:
state_before: α : Type u_1
inst✝¹ : Preorder α
a : α
inst✝ : PredOrder α
h : IsPredLimit (pred a)
⊢ IsMin a
state_after: α : Type u_1
inst✝¹ : Preorder α
a : α
inst✝ : PredOrder α
h : IsPredLimit (pred a)
H : ¬IsMin a
⊢ False
tactic: by_contra H
state_before: α : Type u_1
inst✝¹ : Preorder α
a : α
inst✝ : PredOrder α
h : IsPredLimit (pred a)
H : ¬IsMin a
⊢ False
state_after: no goals
tactic: exact h a (pred_covBy_of_not_isMin H)
Theorem: eigenvalue_mem_ball
File: Mathlib/LinearAlgebra/Matrix/Gershgorin.lean

Proof steps:
state_before: K : Type u_1
n : Type u_2
inst✝² : NormedField K
inst✝¹ : Fintype n
inst✝ : DecidableEq n
A : Matrix n n K
μ : K
hμ : Module.End.HasEigenvalue (Matrix.toLin' A) μ
⊢ ∃ k, μ ∈ Metric.closedBall (A k k) (∑ j ∈ Finset.univ.erase k, ‖A k j‖)
state_after: case inl
K : Type u_1
n : Type u_2
inst✝² : NormedField K
inst✝¹ : Fintype n
inst✝ : DecidableEq n
A : Matrix n n K
μ : K
hμ : Module.End.HasEigenvalue (Matrix.toLin' A) μ
h✝ : IsEmpty n
⊢ ∃ k, μ ∈ Metric.closedBall (A k k) (∑ j ∈ Finset.univ.erase k, ‖A k j‖)

case inr
K : Type u_1
n : Type u_2
inst✝² : NormedField K
inst✝¹ : Fintype n
inst✝ : DecidableEq n
A : Matrix n n K
μ : K
hμ : Module.End.HasEigenvalue (Matrix.toLin' A) μ
h✝ : Nonempty n
⊢ ∃ k, μ ∈ Metric.closedBall (A k k) (∑ j ∈ Finset.univ.erase k, ‖A k j‖)
tactic: cases isEmpty_or_nonempty n
Theorem: locallyConvexSpace_iInf
File: Mathlib/Topology/Algebra/Module/LocallyConvex.lean

Proof steps:
state_before: ι : Sort u_1
𝕜 : Type u_2
E : Type u_3
F : Type u_4
inst✝⁴ : OrderedSemiring 𝕜
inst✝³ : AddCommMonoid E
inst✝² : Module 𝕜 E
inst✝¹ : AddCommMonoid F
inst✝ : Module 𝕜 F
ts' : ι → TopologicalSpace E
h' : ∀ (i : ι), LocallyConvexSpace 𝕜 E
⊢ LocallyConvexSpace 𝕜 E
state_after: ι : Sort u_1
𝕜 : Type u_2
E : Type u_3
F : Type u_4
inst✝⁴ : OrderedSemiring 𝕜
inst✝³ : AddCommMonoid E
inst✝² : Module 𝕜 E
inst✝¹ : AddCommMonoid F
inst✝ : Module 𝕜 F
ts' : ι → TopologicalSpace E
h' : ∀ (i : ι), LocallyConvexSpace 𝕜 E
⊢ ∀ t ∈ range fun i => ts' i, LocallyConvexSpace 𝕜 E
tactic: refine locallyConvexSpace_sInf ?_
state_before: ι : Sort u_1
𝕜 : Type u_2
E : Type u_3
F : Type u_4
inst✝⁴ : OrderedSemiring 𝕜
inst✝³ : AddCommMonoid E
inst✝² : Module 𝕜 E
inst✝¹ : AddCommMonoid F
inst✝ : Module 𝕜 F
ts' : ι → TopologicalSpace E
h' : ∀ (i : ι), LocallyConvexSpace 𝕜 E
⊢ ∀ t ∈ range fun i => ts' i, LocallyConvexSpace 𝕜 E
state_after: no goals
tactic: rwa [forall_mem_range]
Theorem: Prime.pow_dvd_of_dvd_mul_left
File: Mathlib/Algebra/Associated/Basic.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
inst✝ : CancelCommMonoidWithZero α
p a b : α
hp : Prime p
n : ℕ
h : ¬p ∣ a
h' : p ^ n ∣ a * b
⊢ p ^ n ∣ b
state_after: case zero
α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
inst✝ : CancelCommMonoidWithZero α
p a b : α
hp : Prime p
h : ¬p ∣ a
h' : p ^ 0 ∣ a * b
⊢ p ^ 0 ∣ b

case succ
α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
inst✝ : CancelCommMonoidWithZero α
p a b : α
hp : Prime p
h : ¬p ∣ a
n : ℕ
ih : p ^ n ∣ a * b → p ^ n ∣ b
h' : p ^ (n + 1) ∣ a * b
⊢ p ^ (n + 1) ∣ b
tactic: induction' n with n ih
Theorem: HasFDerivWithinAt.comp_hasDerivWithinAt_of_eq
File: Mathlib/Analysis/Calculus/Deriv/Comp.lean

Proof steps:
state_before: 𝕜 : Type u
inst✝⁴ : NontriviallyNormedField 𝕜
F : Type v
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
E : Type w
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
f f₀ f₁ g : 𝕜 → F
f' f₀' f₁' g' : F
x : 𝕜
s t✝ : Set 𝕜
L L₁ L₂ : Filter 𝕜
l : F → E
l' : F →L[𝕜] E
y : F
t : Set F
hl : HasFDerivWithinAt l l' t y
hf : HasDerivWithinAt f f' s x
hst : MapsTo f s t
hy : y = f x
⊢ HasDerivWithinAt (l ∘ f) (l' f') s x
state_after: 𝕜 : Type u
inst✝⁴ : NontriviallyNormedField 𝕜
F : Type v
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
E : Type w
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
f f₀ f₁ g : 𝕜 → F
f' f₀' f₁' g' : F
x : 𝕜
s t✝ : Set 𝕜
L L₁ L₂ : Filter 𝕜
l : F → E
l' : F →L[𝕜] E
y : F
t : Set F
hl : HasFDerivWithinAt l l' t (f x)
hf : HasDerivWithinAt f f' s x
hst : MapsTo f s t
hy : y = f x
⊢ HasDerivWithinAt (l ∘ f) (l' f') s x
tactic: rw [hy] at hl
state_before: 𝕜 : Type u
inst✝⁴ : NontriviallyNormedField 𝕜
F : Type v
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
E : Type w
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
f f₀ f₁ g : 𝕜 → F
f' f₀' f₁' g' : F
x : 𝕜
s t✝ : Set 𝕜
L L₁ L₂ : Filter 𝕜
l : F → E
l' : F →L[𝕜] E
y : F
t : Set F
hl : HasFDerivWithinAt l l' t (f x)
hf : HasDerivWithinAt f f' s x
hst : MapsTo f s t
hy : y = f x
⊢ HasDerivWithinAt (l ∘ f) (l' f') s x
state_after: no goals
tactic: exact hl.comp_hasDerivWithinAt x hf hst
Theorem: Subalgebra.range_isScalarTower_toAlgHom
File: Mathlib/Algebra/Algebra/Subalgebra/Tower.lean

Proof steps:
state_before: R : Type u
S✝ : Type v
A : Type w
B : Type u₁
M : Type v₁
inst✝² : CommSemiring R
inst✝¹ : CommSemiring A
inst✝ : Algebra R A
S : Subalgebra R A
⊢ LinearMap.range (toAlgHom R (↥S) A) = toSubmodule S
state_after: case h
R : Type u
S✝ : Type v
A : Type w
B : Type u₁
M : Type v₁
inst✝² : CommSemiring R
inst✝¹ : CommSemiring A
inst✝ : Algebra R A
S : Subalgebra R A
x✝ : A
⊢ x✝ ∈ LinearMap.range (toAlgHom R (↥S) A) ↔ x✝ ∈ toSubmodule S
tactic: ext
state_before: case h
R : Type u
S✝ : Type v
A : Type w
B : Type u₁
M : Type v₁
inst✝² : CommSemiring R
inst✝¹ : CommSemiring A
inst✝ : Algebra R A
S : Subalgebra R A
x✝ : A
⊢ x✝ ∈ LinearMap.range (toAlgHom R (↥S) A) ↔ x✝ ∈ toSubmodule S
state_after: case h
R : Type u
S✝ : Type v
A : Type w
B : Type u₁
M : Type v₁
inst✝² : CommSemiring R
inst✝¹ : CommSemiring A
inst✝ : Algebra R A
S : Subalgebra R A
x✝ : A
⊢ (∃ y, (algebraMap (↥S) A) y = x✝) ↔ ∃ y, (toSubmodule S).subtype y = x✝
tactic: simp only [← Submodule.range_subtype (Subalgebra.toSubmodule S), LinearMap.mem_range,
    IsScalarTower.coe_toAlgHom', Subalgebra.mem_toSubmodule]
state_before: case h
R : Type u
S✝ : Type v
A : Type w
B : Type u₁
M : Type v₁
inst✝² : CommSemiring R
inst✝¹ : CommSemiring A
inst✝ : Algebra R A
S : Subalgebra R A
x✝ : A
⊢ (∃ y, (algebraMap (↥S) A) y = x✝) ↔ ∃ y, (toSubmodule S).subtype y = x✝
state_after: no goals
tactic: rfl
Theorem: isClosed_setOf_inseparable
File: Mathlib/Topology/Separation.lean

Proof steps:
state_before: X : Type u_1
Y : Type u_2
inst✝² : TopologicalSpace X
inst✝¹ : FirstCountableTopology X
inst✝ : R1Space X
x y : X
⊢ IsClosed {p | Inseparable p.1 p.2}
state_after: no goals
tactic: simp only [← specializes_iff_inseparable, isClosed_setOf_specializes]
Theorem: tsub_left_inj
File: Mathlib/Algebra/Order/Sub/Canonical.lean

Proof steps:
state_before: α : Type u_1
inst✝⁵ : AddCommSemigroup α
inst✝⁴ : PartialOrder α
inst✝³ : ExistsAddOfLE α
inst✝² : CovariantClass α α (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
inst✝¹ : Sub α
inst✝ : OrderedSub α
a b c d : α
h1 : c ≤ a
h2 : c ≤ b
⊢ a - c = b - c ↔ a = b
state_after: no goals
tactic: simp_rw [le_antisymm_iff, tsub_le_tsub_iff_right h1, tsub_le_tsub_iff_right h2]
Theorem: isPurelyInseparable_iff_perfectClosure_eq_top
File: Mathlib/FieldTheory/PurelyInseparable.lean

Proof steps:
state_before: F : Type u
E : Type v
inst✝⁴ : Field F
inst✝³ : Field E
inst✝² : Algebra F E
K : Type w
inst✝¹ : Field K
inst✝ : Algebra F K
⊢ IsPurelyInseparable F E ↔ perfectClosure F E = ⊤
state_after: F : Type u
E : Type v
inst✝⁴ : Field F
inst✝³ : Field E
inst✝² : Algebra F E
K : Type w
inst✝¹ : Field K
inst✝ : Algebra F K
⊢ (∀ (x : E), ∃ n, x ^ ringExpChar F ^ n ∈ (algebraMap F E).range) ↔ perfectClosure F E = ⊤
tactic: rw [isPurelyInseparable_iff_pow_mem F (ringExpChar F)]
state_before: F : Type u
E : Type v
inst✝⁴ : Field F
inst✝³ : Field E
inst✝² : Algebra F E
K : Type w
inst✝¹ : Field K
inst✝ : Algebra F K
⊢ (∀ (x : E), ∃ n, x ^ ringExpChar F ^ n ∈ (algebraMap F E).range) ↔ perfectClosure F E = ⊤
state_after: no goals
tactic: exact ⟨fun H ↦ top_unique fun x _ ↦ H x, fun H _ ↦ H.ge trivial⟩
Theorem: List.getElem?_enum
File: Mathlib/Data/List/Enum.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
l : List α
n : ℕ
⊢ l.enum[n]? = Option.map (fun a => (n, a)) l[n]?
state_after: no goals
tactic: rw [enum, getElem?_enumFrom, Nat.zero_add]
Theorem: Ordnode.Valid'.dual
File: Mathlib/Data/Ordmap/Ordset.lean

Proof steps:
state_before: α : Type u_1
inst✝ : Preorder α
l : Ordnode α
x : α
r : Ordnode α
o₁ : WithBot α
o₂ : WithTop α
ol : l.Bounded o₁ ↑x
Or : r.Bounded (↑x) o₂
sl : l.Sized
sr : r.Sized
b : BalancedSz l.size r.size
bl : l.Balanced
br : r.Balanced
ol' : l.dual.Bounded (↑x) o₁
sl' : l.dual.Sized
bl' : l.dual.Balanced
or' : r.dual.Bounded o₂ ↑x
sr' : r.dual.Sized
br' : r.dual.Balanced
⊢ l.size + r.size + 1 = r.dual.size + l.dual.size + 1
state_after: no goals
tactic: simp [size_dual, add_comm]
state_before: α : Type u_1
inst✝ : Preorder α
l : Ordnode α
x : α
r : Ordnode α
o₁ : WithBot α
o₂ : WithTop α
ol : l.Bounded o₁ ↑x
Or : r.Bounded (↑x) o₂
sl : l.Sized
sr : r.Sized
b : BalancedSz l.size r.size
bl : l.Balanced
br : r.Balanced
ol' : l.dual.Bounded (↑x) o₁
sl' : l.dual.Sized
bl' : l.dual.Balanced
or' : r.dual.Bounded o₂ ↑x
sr' : r.dual.Sized
br' : r.dual.Balanced
⊢ BalancedSz r.dual.size l.dual.size
state_after: α : Type u_1
inst✝ : Preorder α
l : Ordnode α
x : α
r : Ordnode α
o₁ : WithBot α
o₂ : WithTop α
ol : l.Bounded o₁ ↑x
Or : r.Bounded (↑x) o₂
sl : l.Sized
sr : r.Sized
b : BalancedSz l.size r.size
bl : l.Balanced
br : r.Balanced
ol' : l.dual.Bounded (↑x) o₁
sl' : l.dual.Sized
bl' : l.dual.Balanced
or' : r.dual.Bounded o₂ ↑x
sr' : r.dual.Sized
br' : r.dual.Balanced
⊢ BalancedSz r.size l.size
tactic: rw [size_dual, size_dual]
state_before: α : Type u_1
inst✝ : Preorder α
l : Ordnode α
x : α
r : Ordnode α
o₁ : WithBot α
o₂ : WithTop α
ol : l.Bounded o₁ ↑x
Or : r.Bounded (↑x) o₂
sl : l.Sized
sr : r.Sized
b : BalancedSz l.size r.size
bl : l.Balanced
br : r.Balanced
ol' : l.dual.Bounded (↑x) o₁
sl' : l.dual.Sized
bl' : l.dual.Balanced
or' : r.dual.Bounded o₂ ↑x
sr' : r.dual.Sized
br' : r.dual.Balanced
⊢ BalancedSz r.size l.size
state_after: no goals
tactic: exact b.symm
Theorem: Traversable.toList_eq_self
File: Mathlib/Control/Fold.lean

Proof steps:
state_before: α β γ : Type u
t : Type u → Type u
inst✝¹ : Traversable t
inst✝ : LawfulTraversable t
xs : List α
⊢ toList xs = xs
state_after: α β γ : Type u
t : Type u → Type u
inst✝¹ : Traversable t
inst✝ : LawfulTraversable t
xs : List α
⊢ FreeMonoid.toList (List.traverse (Const.mk' ∘ FreeMonoid.of) xs) = xs
tactic: simp only [toList_spec, foldMap, traverse]
state_before: α β γ : Type u
t : Type u → Type u
inst✝¹ : Traversable t
inst✝ : LawfulTraversable t
xs : List α
⊢ FreeMonoid.toList (List.traverse (Const.mk' ∘ FreeMonoid.of) xs) = xs
state_after: no goals
tactic: induction xs with
  | nil => rfl
  | cons _ _ ih => (conv_rhs => rw [← ih]); rfl