ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
Theorem: GenContFract.exists_gcf_pair_rat_eq_of_nth_contsAux
File: Mathlib/Algebra/ContinuedFractions/Computation/TerminatesIffRat.lean

Proof steps:
state_before: K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
n : ℕ
⊢ ∀ (n : ℕ),
    (∀ m < n, ∃ conts, (of v).contsAux m = Pair.map Rat.cast conts) →
      ∃ conts, (of v).contsAux n = Pair.map Rat.cast conts
state_after: K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
⊢ ∀ (n : ℕ),
    (∀ m < n, ∃ conts, (of v).contsAux m = Pair.map Rat.cast conts) →
      ∃ conts, (of v).contsAux n = Pair.map Rat.cast conts
tactic: clear n
state_before: K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
⊢ ∀ (n : ℕ),
    (∀ m < n, ∃ conts, (of v).contsAux m = Pair.map Rat.cast conts) →
      ∃ conts, (of v).contsAux n = Pair.map Rat.cast conts
state_after: K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
g : GenContFract K := of v
⊢ ∀ (n : ℕ),
    (∀ m < n, ∃ conts, (of v).contsAux m = Pair.map Rat.cast conts) →
      ∃ conts, (of v).contsAux n = Pair.map Rat.cast conts
tactic: let g := of v
state_before: K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
g : GenContFract K := of v
⊢ ∀ (n : ℕ),
    (∀ m < n, ∃ conts, (of v).contsAux m = Pair.map Rat.cast conts) →
      ∃ conts, (of v).contsAux n = Pair.map Rat.cast conts
state_after: K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
g : GenContFract K := of v
n : ℕ
IH : ∀ m < n, ∃ conts, (of v).contsAux m = Pair.map Rat.cast conts
⊢ ∃ conts, (of v).contsAux n = Pair.map Rat.cast conts
tactic: intro n IH
state_before: K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
g : GenContFract K := of v
n : ℕ
IH : ∀ m < n, ∃ conts, (of v).contsAux m = Pair.map Rat.cast conts
⊢ ∃ conts, (of v).contsAux n = Pair.map Rat.cast conts
state_after: case zero
K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
g : GenContFract K := of v
IH : ∀ m < 0, ∃ conts, (of v).contsAux m = Pair.map Rat.cast conts
⊢ ∃ conts, (of v).contsAux 0 = Pair.map Rat.cast conts

case succ.zero
K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
g : GenContFract K := of v
IH : ∀ m < 0 + 1, ∃ conts, (of v).contsAux m = Pair.map Rat.cast conts
⊢ ∃ conts, (of v).contsAux (0 + 1) = Pair.map Rat.cast conts

case succ.succ
K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
g : GenContFract K := of v
n : ℕ
IH : ∀ m < n + 1 + 1, ∃ conts, (of v).contsAux m = Pair.map Rat.cast conts
⊢ ∃ conts, (of v).contsAux (n + 1 + 1) = Pair.map Rat.cast conts
tactic: rcases n with (_ | _ | n)
Theorem: MeasureTheory.Integrable.simpleFunc_mul
File: Mathlib/MeasureTheory/Integral/SetIntegral.lean

Proof steps:
state_before: X : Type u_1
Y : Type u_2
E : Type u_3
F : Type u_4
inst✝ : MeasurableSpace X
f : X → ℝ
m m0 : MeasurableSpace X
μ : Measure X
g : SimpleFunc X ℝ
hf : Integrable f μ
⊢ Integrable (↑g * f) μ
state_after: X : Type u_1
Y : Type u_2
E : Type u_3
F : Type u_4
inst✝ : MeasurableSpace X
f : X → ℝ
m m0 : MeasurableSpace X
μ : Measure X
g : SimpleFunc X ℝ
hf : Integrable f μ
c : ℝ
s : Set X
hs : MeasurableSet s
⊢ Integrable (↑(SimpleFunc.piecewise s hs (SimpleFunc.const X c) (SimpleFunc.const X 0)) * f) μ
tactic: refine
    SimpleFunc.induction (fun c s hs => ?_)
      (fun g₁ g₂ _ h_int₁ h_int₂ =>
        (h_int₁.add h_int₂).congr (by rw [SimpleFunc.coe_add, add_mul]))
      g
state_before: X : Type u_1
Y : Type u_2
E : Type u_3
F : Type u_4
inst✝ : MeasurableSpace X
f : X → ℝ
m m0 : MeasurableSpace X
μ : Measure X
g : SimpleFunc X ℝ
hf : Integrable f μ
c : ℝ
s : Set X
hs : MeasurableSet s
⊢ Integrable (↑(SimpleFunc.piecewise s hs (SimpleFunc.const X c) (SimpleFunc.const X 0)) * f) μ
state_after: X : Type u_1
Y : Type u_2
E : Type u_3
F : Type u_4
inst✝ : MeasurableSpace X
f : X → ℝ
m m0 : MeasurableSpace X
μ : Measure X
g : SimpleFunc X ℝ
hf : Integrable f μ
c : ℝ
s : Set X
hs : MeasurableSet s
⊢ Integrable (s.indicator (const X c) * f) μ
tactic: simp only [SimpleFunc.const_zero, SimpleFunc.coe_piecewise, SimpleFunc.coe_const,
    SimpleFunc.coe_zero, Set.piecewise_eq_indicator]
state_before: X : Type u_1
Y : Type u_2
E : Type u_3
F : Type u_4
inst✝ : MeasurableSpace X
f : X → ℝ
m m0 : MeasurableSpace X
μ : Measure X
g : SimpleFunc X ℝ
hf : Integrable f μ
c : ℝ
s : Set X
hs : MeasurableSet s
this : s.indicator (const X c) * f = s.indicator (c • f)
⊢ Integrable (s.indicator (const X c) * f) μ
state_after: X : Type u_1
Y : Type u_2
E : Type u_3
F : Type u_4
inst✝ : MeasurableSpace X
f : X → ℝ
m m0 : MeasurableSpace X
μ : Measure X
g : SimpleFunc X ℝ
hf : Integrable f μ
c : ℝ
s : Set X
hs : MeasurableSet s
this : s.indicator (const X c) * f = s.indicator (c • f)
⊢ IntegrableOn (c • f) s μ
tactic: rw [this, integrable_indicator_iff hs]
state_before: X : Type u_1
Y : Type u_2
E : Type u_3
F : Type u_4
inst✝ : MeasurableSpace X
f : X → ℝ
m m0 : MeasurableSpace X
μ : Measure X
g : SimpleFunc X ℝ
hf : Integrable f μ
c : ℝ
s : Set X
hs : MeasurableSet s
this : s.indicator (const X c) * f = s.indicator (c • f)
⊢ IntegrableOn (c • f) s μ
state_after: no goals
tactic: exact (hf.smul c).integrableOn
Theorem: AlgebraicGeometry.HasRingHomProperty.Spec_iff
File: Mathlib/AlgebraicGeometry/Morphisms/RingHomProperties.lean

Proof steps:
state_before: P : MorphismProperty Scheme
Q : {R S : Type u} → [inst : CommRing R] → [inst_1 : CommRing S] → (R →+* S) → Prop
inst✝ : HasRingHomProperty P Q
X Y Z : Scheme
f : X ⟶ Y
g : Y ⟶ Z
R S : CommRingCat
φ : R ⟶ S
⊢ P (Spec.map φ) ↔ Q φ
state_after: P : MorphismProperty Scheme
Q : {R S : Type u} → [inst : CommRing R] → [inst_1 : CommRing S] → (R →+* S) → Prop
inst✝ : HasRingHomProperty P Q
X Y Z : Scheme
f : X ⟶ Y
g : Y ⟶ Z
R S : CommRingCat
φ : R ⟶ S
H : RingHom.RespectsIso fun {R S} [CommRing R] [CommRing S] => Q
⊢ P (Spec.map φ) ↔ Q φ
tactic: have H := (isLocal_ringHomProperty P).respectsIso
state_before: P : MorphismProperty Scheme
Q : {R S : Type u} → [inst : CommRing R] → [inst_1 : CommRing S] → (R →+* S) → Prop
inst✝ : HasRingHomProperty P Q
X Y Z : Scheme
f : X ⟶ Y
g : Y ⟶ Z
R S : CommRingCat
φ : R ⟶ S
H : RingHom.RespectsIso fun {R S} [CommRing R] [CommRing S] => Q
⊢ P (Spec.map φ) ↔ Q φ
state_after: no goals
tactic: rw [iff_of_isAffine (P := P), ← H.cancel_right_isIso _ (Scheme.ΓSpecIso _).hom,
    Scheme.ΓSpecIso_naturality, H.cancel_left_isIso]
Theorem: Ordinal.Principal.iterate_lt
File: Mathlib/SetTheory/Ordinal/Principal.lean

Proof steps:
state_before: op : Ordinal.{u_1} → Ordinal.{u_1} → Ordinal.{u_1}
a o : Ordinal.{u_1}
hao : a < o
ho : Principal op o
n : ℕ
⊢ (op a)^[n] a < o
state_after: case zero
op : Ordinal.{u_1} → Ordinal.{u_1} → Ordinal.{u_1}
a o : Ordinal.{u_1}
hao : a < o
ho : Principal op o
⊢ (op a)^[0] a < o

case succ
op : Ordinal.{u_1} → Ordinal.{u_1} → Ordinal.{u_1}
a o : Ordinal.{u_1}
hao : a < o
ho : Principal op o
n : ℕ
hn : (op a)^[n] a < o
⊢ (op a)^[n + 1] a < o
tactic: induction' n with n hn
Theorem: isOfFinAddOrder_iff_zsmul_eq_zero
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 G✝
a b x✝ y : G✝
n m : ℕ
G : Type u_6
inst✝ : Group G
x : G
⊢ IsOfFinOrder x ↔ ∃ n, n ≠ 0 ∧ x ^ n = 1
state_after: G✝ : Type u_1
H : Type u_2
A : Type u_3
α : Type u_4
β : Type u_5
inst✝¹ : Monoid G✝
a b x✝ y : G✝
n m : ℕ
G : Type u_6
inst✝ : Group G
x : G
⊢ (∃ n, 0 < n ∧ x ^ n = 1) ↔ ∃ n, n ≠ 0 ∧ x ^ n = 1
tactic: rw [isOfFinOrder_iff_pow_eq_one]
state_before: G✝ : Type u_1
H : Type u_2
A : Type u_3
α : Type u_4
β : Type u_5
inst✝¹ : Monoid G✝
a b x✝ y : G✝
n m : ℕ
G : Type u_6
inst✝ : Group G
x : G
⊢ (∃ n, 0 < n ∧ x ^ n = 1) ↔ ∃ n, n ≠ 0 ∧ x ^ n = 1
state_after: G✝ : Type u_1
H : Type u_2
A : Type u_3
α : Type u_4
β : Type u_5
inst✝¹ : Monoid G✝
a b x✝¹ y : G✝
n✝ m : ℕ
G : Type u_6
inst✝ : Group G
x : G
x✝ : ∃ n, n ≠ 0 ∧ x ^ n = 1
n : ℤ
hn : n ≠ 0
hn' : x ^ n = 1
⊢ x ^ n.natAbs = 1
tactic: refine ⟨fun ⟨n, hn, hn'⟩ ↦ ⟨n, Int.natCast_ne_zero_iff_pos.mpr hn, zpow_natCast x n ▸ hn'⟩,
    fun ⟨n, hn, hn'⟩ ↦ ⟨n.natAbs, Int.natAbs_pos.mpr hn, ?_⟩⟩
state_before: G✝ : Type u_1
H : Type u_2
A : Type u_3
α : Type u_4
β : Type u_5
inst✝¹ : Monoid G✝
a b x✝¹ y : G✝
n✝ m : ℕ
G : Type u_6
inst✝ : Group G
x : G
x✝ : ∃ n, n ≠ 0 ∧ x ^ n = 1
n : ℤ
hn : n ≠ 0
hn' : x ^ n = 1
⊢ x ^ n.natAbs = 1
state_after: case inl
G✝ : Type u_1
H : Type u_2
A : Type u_3
α : Type u_4
β : Type u_5
inst✝¹ : Monoid G✝
a b x✝¹ y : G✝
n✝ m : ℕ
G : Type u_6
inst✝ : Group G
x : G
x✝ : ∃ n, n ≠ 0 ∧ x ^ n = 1
n : ℤ
hn : n ≠ 0
hn' : x ^ n = 1
h : n = ↑n.natAbs
⊢ x ^ n.natAbs = 1

case inr
G✝ : Type u_1
H : Type u_2
A : Type u_3
α : Type u_4
β : Type u_5
inst✝¹ : Monoid G✝
a b x✝¹ y : G✝
n✝ m : ℕ
G : Type u_6
inst✝ : Group G
x : G
x✝ : ∃ n, n ≠ 0 ∧ x ^ n = 1
n : ℤ
hn : n ≠ 0
hn' : x ^ n = 1
h : n = -↑n.natAbs
⊢ x ^ n.natAbs = 1
tactic: cases' (Int.natAbs_eq_iff (a := n)).mp rfl with h h
Theorem: CategoryTheory.Idempotents.FunctorExtension₁.obj_map_f
File: Mathlib/CategoryTheory/Idempotents/FunctorExtension.lean

Proof steps:
state_before: C : Type u_1
D : Type u_2
E : Type u_3
inst✝² : Category.{?u.1617, u_1} C
inst✝¹ : Category.{?u.1621, u_2} D
inst✝ : Category.{?u.1625, u_3} E
F : C ⥤ Karoubi D
P : Karoubi C
⊢ (F.map P.p).f ≫ (F.map P.p).f = (F.map P.p).f
state_after: no goals
tactic: simpa only [F.map_comp, hom_ext_iff] using F.congr_map P.idem
state_before: C : Type u_1
D : Type u_2
E : Type u_3
inst✝² : Category.{?u.1617, u_1} C
inst✝¹ : Category.{?u.1621, u_2} D
inst✝ : Category.{?u.1625, u_3} E
F : C ⥤ Karoubi D
X✝ Y✝ : Karoubi C
f : X✝ ⟶ Y✝
⊢ (F.map f.f).f =
    ((fun P => { X := (F.obj P.X).X, p := (F.map P.p).f, idem := ⋯ }) X✝).p ≫
      (F.map f.f).f ≫ ((fun P => { X := (F.obj P.X).X, p := (F.map P.p).f, idem := ⋯ }) Y✝).p
state_after: no goals
tactic: simpa only [F.map_comp, hom_ext_iff] using F.congr_map f.comm
Theorem: NumberField.mixedEmbedding.mem_span_fractionalIdealLatticeBasis
File: Mathlib/NumberTheory/NumberField/CanonicalEmbedding/Basic.lean

Proof steps:
state_before: K : Type u_1
inst✝¹ : Field K
inst✝ : NumberField K
I : (FractionalIdeal (𝓞 K)⁰ K)ˣ
x : ({ w // w.IsReal } → ℝ) × ({ w // w.IsComplex } → ℂ)
⊢ x ∈ Submodule.span ℤ (Set.range ⇑(fractionalIdealLatticeBasis K I)) ↔ x ∈ ⇑(mixedEmbedding K) '' ↑↑I
state_after: K : Type u_1
inst✝¹ : Field K
inst✝ : NumberField K
I : (FractionalIdeal (𝓞 K)⁰ K)ˣ
x : ({ w // w.IsReal } → ℝ) × ({ w // w.IsComplex } → ℂ)
⊢ x ∈ Submodule.span ℤ (⇑(mixedEmbedding K).toIntAlgHom.toLinearMap '' Set.range ⇑(basisOfFractionalIdeal K I)) ↔
    x ∈ ⇑(mixedEmbedding K) '' ↑↑I
tactic: rw [show Set.range (fractionalIdealLatticeBasis K I) =
        (mixedEmbedding K).toIntAlgHom.toLinearMap '' (Set.range (basisOfFractionalIdeal K I)) by
      rw [← Set.range_comp]
      exact congr_arg Set.range (funext (fun i ↦ fractionalIdealLatticeBasis_apply K I i))]
state_before: K : Type u_1
inst✝¹ : Field K
inst✝ : NumberField K
I : (FractionalIdeal (𝓞 K)⁰ K)ˣ
x : ({ w // w.IsReal } → ℝ) × ({ w // w.IsComplex } → ℂ)
⊢ x ∈ Submodule.span ℤ (⇑(mixedEmbedding K).toIntAlgHom.toLinearMap '' Set.range ⇑(basisOfFractionalIdeal K I)) ↔
    x ∈ ⇑(mixedEmbedding K) '' ↑↑I
state_after: K : Type u_1
inst✝¹ : Field K
inst✝ : NumberField K
I : (FractionalIdeal (𝓞 K)⁰ K)ˣ
x : ({ w // w.IsReal } → ℝ) × ({ w // w.IsComplex } → ℂ)
⊢ x ∈ ⇑(mixedEmbedding K).toIntAlgHom.toLinearMap '' ↑(Submodule.span ℤ (Set.range ⇑(basisOfFractionalIdeal K I))) ↔
    x ∈ ⇑(mixedEmbedding K) '' ↑↑I
tactic: rw [← Submodule.map_span, ← SetLike.mem_coe, Submodule.map_coe]
state_before: K : Type u_1
inst✝¹ : Field K
inst✝ : NumberField K
I : (FractionalIdeal (𝓞 K)⁰ K)ˣ
x : ({ w // w.IsReal } → ℝ) × ({ w // w.IsComplex } → ℂ)
⊢ x ∈ ⇑(mixedEmbedding K).toIntAlgHom.toLinearMap '' ↑(Submodule.span ℤ (Set.range ⇑(basisOfFractionalIdeal K I))) ↔
    x ∈ ⇑(mixedEmbedding K) '' ↑↑I
state_after: K : Type u_1
inst✝¹ : Field K
inst✝ : NumberField K
I : (FractionalIdeal (𝓞 K)⁰ K)ˣ
x : ({ w // w.IsReal } → ℝ) × ({ w // w.IsComplex } → ℂ)
⊢ x ∈ ⇑(mixedEmbedding K).toIntAlgHom.toLinearMap '' ↑↑I ↔ x ∈ ⇑(mixedEmbedding K) '' ↑↑I
tactic: rw [show Submodule.span ℤ (Set.range (basisOfFractionalIdeal K I)) = (I : Set K) by
        ext; erw [mem_span_basisOfFractionalIdeal]]
state_before: K : Type u_1
inst✝¹ : Field K
inst✝ : NumberField K
I : (FractionalIdeal (𝓞 K)⁰ K)ˣ
x : ({ w // w.IsReal } → ℝ) × ({ w // w.IsComplex } → ℂ)
⊢ x ∈ ⇑(mixedEmbedding K).toIntAlgHom.toLinearMap '' ↑↑I ↔ x ∈ ⇑(mixedEmbedding K) '' ↑↑I
state_after: no goals
tactic: rfl
Theorem: CategoryTheory.Functor.ranCounit_app_whiskerLeft_ranAdjunction_unit_app
File: Mathlib/CategoryTheory/Functor/KanExtension/Adjunction.lean

Proof steps:
state_before: C : Type u_1
D : Type u_2
inst✝³ : Category.{u_6, u_1} C
inst✝² : Category.{u_4, u_2} D
L : C ⥤ D
H : Type u_3
inst✝¹ : Category.{u_5, u_3} H
inst✝ : ∀ (F : C ⥤ H), L.HasRightKanExtension F
G : D ⥤ H
⊢ whiskerLeft L ((L.ranAdjunction H).unit.app G) ≫ L.ranCounit.app (L ⋙ G) = 𝟙 (L ⋙ G)
state_after: no goals
tactic: simp [ranAdjunction_unit_app]
Theorem: CategoryTheory.Limits.PreservesPushout.inr_iso_inv
File: Mathlib/CategoryTheory/Limits/Preserves/Shapes/Pullbacks.lean

Proof steps:
state_before: C : Type u₁
inst✝⁴ : Category.{v₁, u₁} C
D : Type u₂
inst✝³ : Category.{v₂, u₂} D
G : C ⥤ D
W X Y Z : C
h : X ⟶ Z
k : Y ⟶ Z
f : W ⟶ X
g : W ⟶ Y
comm : f ≫ h = g ≫ k
inst✝² : PreservesColimit (span f g) G
inst✝¹ : HasPushout f g
inst✝ : HasPushout (G.map f) (G.map g)
⊢ G.map (pushout.inr f g) ≫ (iso G f g).inv = pushout.inr (G.map f) (G.map g)
state_after: no goals
tactic: simp [PreservesPushout.iso, Iso.comp_inv_eq]
Theorem: ArithmeticFunction.coe_coe
File: Mathlib/NumberTheory/ArithmeticFunction.lean

Proof steps:
state_before: R : Type u_1
inst✝ : AddGroupWithOne R
f : ArithmeticFunction ℕ
⊢ ↑↑f = ↑f
state_after: case h
R : Type u_1
inst✝ : AddGroupWithOne R
f : ArithmeticFunction ℕ
x✝ : ℕ
⊢ ↑↑f x✝ = ↑f x✝
tactic: ext
state_before: case h
R : Type u_1
inst✝ : AddGroupWithOne R
f : ArithmeticFunction ℕ
x✝ : ℕ
⊢ ↑↑f x✝ = ↑f x✝
state_after: no goals
tactic: simp
Theorem: Cardinal.mk_diff_add_mk
File: Mathlib/SetTheory/Cardinal/Basic.lean

Proof steps:
state_before: α β : Type u
c : Cardinal.{?u.225151}
S T : Set α
h : T ⊆ S
⊢ #↑(S \ T) + #↑T = #↑S
state_after: α β : Type u
c : Cardinal.{?u.225151}
S T : Set α
h : T ⊆ S
⊢ Disjoint (S \ T) T
tactic: refine (mk_union_of_disjoint <| ?_).symm.trans <| by rw [diff_union_of_subset h]
state_before: α β : Type u
c : Cardinal.{?u.225151}
S T : Set α
h : T ⊆ S
⊢ Disjoint (S \ T) T
state_after: no goals
tactic: exact disjoint_sdiff_self_left
Theorem: Function.star_sum_elim
File: Mathlib/Algebra/Star/Pi.lean

Proof steps:
state_before: I✝ : Type u
f : I✝ → Type v
I : Type u_1
J : Type u_2
α : Type u_3
x : I → α
y : J → α
inst✝ : Star α
⊢ star (Sum.elim x y) = Sum.elim (star x) (star y)
state_after: case h
I✝ : Type u
f : I✝ → Type v
I : Type u_1
J : Type u_2
α : Type u_3
x✝ : I → α
y : J → α
inst✝ : Star α
x : I ⊕ J
⊢ star (Sum.elim x✝ y) x = Sum.elim (star x✝) (star y) x
tactic: ext x
state_before: case h
I✝ : Type u
f : I✝ → Type v
I : Type u_1
J : Type u_2
α : Type u_3
x✝ : I → α
y : J → α
inst✝ : Star α
x : I ⊕ J
⊢ star (Sum.elim x✝ y) x = Sum.elim (star x✝) (star y) x
state_after: no goals
tactic: cases x <;> simp only [Pi.star_apply, Sum.elim_inl, Sum.elim_inr]
Theorem: circleMap_sub_center
File: Mathlib/MeasureTheory/Integral/CircleIntegral.lean

Proof steps:
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
c : ℂ
R θ : ℝ
⊢ circleMap c R θ - c = circleMap 0 R θ
state_after: no goals
tactic: simp [circleMap]
Theorem: quadraticChar_apply
File: Mathlib/NumberTheory/LegendreSymbol/QuadraticChar/Basic.lean

Proof steps:
state_before: F : Type u_1
inst✝² : Field F
inst✝¹ : Fintype F
inst✝ : DecidableEq F
a : F
ha : ¬IsUnit a
⊢ (↑{ toFun := quadraticCharFun F, map_one' := ⋯, map_mul' := ⋯ }).toFun a = 0
state_after: F : Type u_1
inst✝² : Field F
inst✝¹ : Fintype F
inst✝ : DecidableEq F
a : F
ha : ¬IsUnit a
⊢ (↑{ toFun := quadraticCharFun F, map_one' := ⋯, map_mul' := ⋯ }).toFun 0 = 0
tactic: rw [of_not_not (mt Ne.isUnit ha)]
state_before: F : Type u_1
inst✝² : Field F
inst✝¹ : Fintype F
inst✝ : DecidableEq F
a : F
ha : ¬IsUnit a
⊢ (↑{ toFun := quadraticCharFun F, map_one' := ⋯, map_mul' := ⋯ }).toFun 0 = 0
state_after: no goals
tactic: exact quadraticCharFun_zero
Theorem: IntermediateField.minpoly_gen
File: Mathlib/FieldTheory/Adjoin.lean

Proof steps:
state_before: F : Type u_1
inst✝⁴ : Field F
E : Type u_2
inst✝³ : Field E
inst✝² : Algebra F E
α✝ : E
K : Type u
inst✝¹ : Field K
inst✝ : Algebra F K
α : E
⊢ minpoly F (AdjoinSimple.gen F α) = minpoly F α
state_after: no goals
tactic: rw [← minpoly.algebraMap_eq (algebraMap F⟮α⟯ E).injective, AdjoinSimple.algebraMap_gen]
Theorem: List.count_cons_self
File: .lake/packages/batteries/Batteries/Data/List/Count.lean

Proof steps:
state_before: α : Type u_1
inst✝ : DecidableEq α
a : α
l : List α
⊢ count a (a :: l) = count a l + 1
state_after: no goals
tactic: simp [count_cons]
Theorem: List.length_scanl
File: Mathlib/Data/List/Basic.lean

Proof steps:
state_before: ι : Type u_1
α : Type u
β : Type v
γ : Type w
l₁ l₂ : List α
f : β → α → β
b : β
a✝ : α
l✝ : List α
a : β
x : α
l : List α
⊢ (scanl f a (x :: l)).length = (x :: l).length + 1
state_after: ι : Type u_1
α : Type u
β : Type v
γ : Type w
l₁ l₂ : List α
f : β → α → β
b : β
a✝ : α
l✝ : List α
a : β
x : α
l : List α
⊢ (scanl f (f a x) l).length = l.length + 1
tactic: rw [scanl, length_cons, length_cons, ← succ_eq_add_one, congr_arg succ]
state_before: ι : Type u_1
α : Type u
β : Type v
γ : Type w
l₁ l₂ : List α
f : β → α → β
b : β
a✝ : α
l✝ : List α
a : β
x : α
l : List α
⊢ (scanl f (f a x) l).length = l.length + 1
state_after: no goals
tactic: exact length_scanl _ _
Theorem: Ring.image_closure
File: Mathlib/Deprecated/Subring.lean

Proof steps:
state_before: R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
⊢ ⇑f '' closure s = closure (⇑f '' s)
state_after: R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
⊢ ⇑f '' closure s ≤ closure (⇑f '' s)
tactic: refine le_antisymm ?_ (closure_subset (RingHom.isSubring_image _ closure.isSubring) <|
    Set.image_subset _ subset_closure)
state_before: R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
⊢ ⇑f '' closure s ≤ closure (⇑f '' s)
state_after: case intro.intro
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
⊢ f x ∈ closure (⇑f '' s)
tactic: rintro _ ⟨x, hx, rfl⟩
state_before: case intro.intro
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
⊢ f x ∈ closure (⇑f '' s)
state_after: case intro.intro.zero
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
⊢ f 0 ∈ closure (⇑f '' s)

case intro.intro.neg
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
a✝¹ : R
a✝ : AddGroup.InClosure (Monoid.Closure s) a✝¹
a_ih✝ : f a✝¹ ∈ closure (⇑f '' s)
⊢ f (-a✝¹) ∈ closure (⇑f '' s)

case intro.intro.add
R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
a✝² b✝ : R
a✝¹ : AddGroup.InClosure (Monoid.Closure s) a✝²
a✝ : AddGroup.InClosure (Monoid.Closure s) b✝
a_ih✝¹ : f a✝² ∈ closure (⇑f '' s)
a_ih✝ : f b✝ ∈ closure (⇑f '' s)
⊢ f (a✝² + b✝) ∈ closure (⇑f '' s)

R : Type u
inst✝² : Ring R
cR : Type u
inst✝¹ : CommRing cR
s✝ : Set R
S : Type u_1
inst✝ : Ring S
f : R →+* S
s : Set R
x : R
hx : x ∈ closure s
a✝¹ : R
a✝ : a✝¹ ∈ Monoid.Closure s
⊢ f a✝¹ ∈ closure (⇑f '' s)
tactic: apply AddGroup.InClosure.recOn (motive := fun {x} _ ↦ f x ∈ closure (f '' s)) hx _ <;> intros
Theorem: Mathlib.Vector.map₂_eq_mapAccumr₂
File: Mathlib/Data/Vector/MapLemmas.lean

Proof steps:
state_before: α : Type
n : ℕ
β : Type
xs : Vector α n
ys : Vector β n
α✝ : Type
f : α → β → α✝
⊢ map₂ f xs ys = (mapAccumr₂ (fun x y x_1 => ((), f x y)) xs ys ()).2
state_after: no goals
tactic: induction xs, ys using Vector.revInductionOn₂ <;> simp_all
Theorem: MulAction.stabilizer_image_coe_quotient
File: Mathlib/Algebra/Pointwise/Stabilizer.lean

Proof steps:
state_before: G : Type u_1
inst✝ : CommGroup G
s : Set G
⊢ stabilizer (G ⧸ stabilizer G s) (QuotientGroup.mk '' s) = ⊥
state_after: case h
G : Type u_1
inst✝ : CommGroup G
s : Set G
a : G ⧸ stabilizer G s
⊢ a ∈ stabilizer (G ⧸ stabilizer G s) (QuotientGroup.mk '' s) ↔ a ∈ ⊥
tactic: ext a
state_before: case h
G : Type u_1
inst✝ : CommGroup G
s : Set G
a : G ⧸ stabilizer G s
⊢ a ∈ stabilizer (G ⧸ stabilizer G s) (QuotientGroup.mk '' s) ↔ a ∈ ⊥
state_after: case h.H
G : Type u_1
inst✝ : CommGroup G
s : Set G
a : G
⊢ ↑a ∈ stabilizer (G ⧸ stabilizer G s) (QuotientGroup.mk '' s) ↔ ↑a ∈ ⊥
tactic: induction' a using QuotientGroup.induction_on' with a
state_before: case h.H
G : Type u_1
inst✝ : CommGroup G
s : Set G
a : G
⊢ ↑a ∈ stabilizer (G ⧸ stabilizer G s) (QuotientGroup.mk '' s) ↔ ↑a ∈ ⊥
state_after: case h.H
G : Type u_1
inst✝ : CommGroup G
s : Set G
a : G
⊢ ↑a • QuotientGroup.mk '' s = QuotientGroup.mk '' s ↔ a • s = s
tactic: simp only [mem_stabilizer_iff, Subgroup.mem_bot, QuotientGroup.eq_one_iff]
state_before: case h.H
G : Type u_1
inst✝ : CommGroup G
s : Set G
a : G
⊢ ↑a • QuotientGroup.mk '' s = QuotientGroup.mk '' s ↔ a • s = s
state_after: case h.H
G : Type u_1
inst✝ : CommGroup G
s : Set G
a : G
this : ↑a • QuotientGroup.mk '' s = QuotientGroup.mk '' (a • s)
⊢ ↑a • QuotientGroup.mk '' s = QuotientGroup.mk '' s ↔ a • s = s
tactic: have : q a • q '' s = q '' (a • s) :=
    (image_smul_distrib (QuotientGroup.mk' <| stabilizer G s) _ _).symm
state_before: case h.H
G : Type u_1
inst✝ : CommGroup G
s : Set G
a : G
this : ↑a • QuotientGroup.mk '' s = QuotientGroup.mk '' (a • s)
⊢ ↑a • QuotientGroup.mk '' s = QuotientGroup.mk '' s ↔ a • s = s
state_after: case h.H
G : Type u_1
inst✝ : CommGroup G
s : Set G
a : G
this : ↑a • QuotientGroup.mk '' s = QuotientGroup.mk '' (a • s)
⊢ QuotientGroup.mk '' (a • s) = QuotientGroup.mk '' s ↔ a • s = s
tactic: rw [this]
state_before: case h.H
G : Type u_1
inst✝ : CommGroup G
s : Set G
a : G
this : ↑a • QuotientGroup.mk '' s = QuotientGroup.mk '' (a • s)
⊢ QuotientGroup.mk '' (a • s) = QuotientGroup.mk '' s ↔ a • s = s
state_after: case h.H
G : Type u_1
inst✝ : CommGroup G
s : Set G
a : G
this : ↑a • QuotientGroup.mk '' s = QuotientGroup.mk '' (a • s)
h : QuotientGroup.mk '' (a • s) = QuotientGroup.mk '' s
⊢ a • s = s
tactic: refine ⟨fun h ↦ ?_, fun h ↦ by rw [h]⟩
state_before: case h.H
G : Type u_1
inst✝ : CommGroup G
s : Set G
a : G
this : ↑a • QuotientGroup.mk '' s = QuotientGroup.mk '' (a • s)
h : QuotientGroup.mk '' (a • s) = QuotientGroup.mk '' s
⊢ a • s = s
state_after: no goals
tactic: rwa [QuotientGroup.image_coe_inj, mul_smul_comm, stabilizer_mul_self] at h