ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
Theorem: AddCircle.exists_norm_eq_of_isOfFinAddOrder
File: Mathlib/Analysis/Normed/Group/AddCircle.lean

Proof steps:
state_before: p : ℝ
hp : Fact (0 < p)
u : AddCircle p
hu : IsOfFinAddOrder u
⊢ ∃ k, ‖u‖ = p * (↑k / ↑(addOrderOf u))
state_after: p : ℝ
hp : Fact (0 < p)
u : AddCircle p
hu : IsOfFinAddOrder u
n : ℕ := addOrderOf u
⊢ ∃ k, ‖u‖ = p * (↑k / ↑(addOrderOf u))
tactic: let n := addOrderOf u
state_before: p : ℝ
hp : Fact (0 < p)
u : AddCircle p
hu : IsOfFinAddOrder u
n : ℕ := addOrderOf u
⊢ ∃ k, ‖u‖ = p * (↑k / ↑(addOrderOf u))
state_after: p : ℝ
hp : Fact (0 < p)
u : AddCircle p
hu : IsOfFinAddOrder u
n : ℕ := addOrderOf u
⊢ ∃ k, ‖u‖ = p * (↑k / ↑n)
tactic: change ∃ k : ℕ, ‖u‖ = p * (k / n)
state_before: p : ℝ
hp : Fact (0 < p)
u : AddCircle p
hu : IsOfFinAddOrder u
n : ℕ := addOrderOf u
⊢ ∃ k, ‖u‖ = p * (↑k / ↑n)
state_after: case intro.intro.intro
p : ℝ
hp : Fact (0 < p)
u : AddCircle p
hu : IsOfFinAddOrder u
n : ℕ := addOrderOf u
m : ℕ
hm : ↑(↑m / ↑(addOrderOf u) * p) = u
⊢ ∃ k, ‖u‖ = p * (↑k / ↑n)
tactic: obtain ⟨m, -, -, hm⟩ := exists_gcd_eq_one_of_isOfFinAddOrder hu
state_before: case intro.intro.intro
p : ℝ
hp : Fact (0 < p)
u : AddCircle p
hu : IsOfFinAddOrder u
n : ℕ := addOrderOf u
m : ℕ
hm : ↑(↑m / ↑(addOrderOf u) * p) = u
⊢ ∃ k, ‖u‖ = p * (↑k / ↑n)
state_after: case intro.intro.intro
p : ℝ
hp : Fact (0 < p)
u : AddCircle p
hu : IsOfFinAddOrder u
n : ℕ := addOrderOf u
m : ℕ
hm : ↑(↑m / ↑(addOrderOf u) * p) = u
⊢ ‖u‖ = p * (↑(min (m % n) (n - m % n)) / ↑n)
tactic: refine ⟨min (m % n) (n - m % n), ?_⟩
state_before: case intro.intro.intro
p : ℝ
hp : Fact (0 < p)
u : AddCircle p
hu : IsOfFinAddOrder u
n : ℕ := addOrderOf u
m : ℕ
hm : ↑(↑m / ↑(addOrderOf u) * p) = u
⊢ ‖u‖ = p * (↑(min (m % n) (n - m % n)) / ↑n)
state_after: no goals
tactic: rw [← hm, norm_div_natCast]
Theorem: MeasureTheory.IsStoppingTime.measurableSet_lt_of_countable_range'
File: Mathlib/Probability/Process/Stopping.lean

Proof steps:
state_before: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝ : LinearOrder ι
f : Filtration ι m
τ π : Ω → ι
hτ : IsStoppingTime f τ
h_countable : (Set.range τ).Countable
i : ι
⊢ MeasurableSet {ω | τ ω < i}
state_after: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝ : LinearOrder ι
f : Filtration ι m
τ π : Ω → ι
hτ : IsStoppingTime f τ
h_countable : (Set.range τ).Countable
i : ι
this : {ω | τ ω < i} = {ω | τ ω ≤ i} \ {ω | τ ω = i}
⊢ MeasurableSet {ω | τ ω < i}
tactic: have : {ω | τ ω < i} = {ω | τ ω ≤ i} \ {ω | τ ω = i} := by
    ext1 ω
    simp only [lt_iff_le_and_ne, Set.mem_setOf_eq, Set.mem_diff]
state_before: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝ : LinearOrder ι
f : Filtration ι m
τ π : Ω → ι
hτ : IsStoppingTime f τ
h_countable : (Set.range τ).Countable
i : ι
this : {ω | τ ω < i} = {ω | τ ω ≤ i} \ {ω | τ ω = i}
⊢ MeasurableSet {ω | τ ω < i}
state_after: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝ : LinearOrder ι
f : Filtration ι m
τ π : Ω → ι
hτ : IsStoppingTime f τ
h_countable : (Set.range τ).Countable
i : ι
this : {ω | τ ω < i} = {ω | τ ω ≤ i} \ {ω | τ ω = i}
⊢ MeasurableSet ({ω | τ ω ≤ i} \ {ω | τ ω = i})
tactic: rw [this]
state_before: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝ : LinearOrder ι
f : Filtration ι m
τ π : Ω → ι
hτ : IsStoppingTime f τ
h_countable : (Set.range τ).Countable
i : ι
this : {ω | τ ω < i} = {ω | τ ω ≤ i} \ {ω | τ ω = i}
⊢ MeasurableSet ({ω | τ ω ≤ i} \ {ω | τ ω = i})
state_after: no goals
tactic: exact (hτ.measurableSet_le' i).diff (hτ.measurableSet_eq_of_countable_range' h_countable i)
Theorem: ContinuousMap.dist_le
File: Mathlib/Topology/ContinuousFunction/Compact.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
E : Type u_3
inst✝³ : TopologicalSpace α
inst✝² : CompactSpace α
inst✝¹ : MetricSpace β
inst✝ : NormedAddCommGroup E
f g : C(α, β)
C : ℝ
C0 : 0 ≤ C
⊢ dist f g ≤ C ↔ ∀ (x : α), dist (f x) (g x) ≤ C
state_after: no goals
tactic: simp only [← dist_mkOfCompact, BoundedContinuousFunction.dist_le C0, mkOfCompact_apply]
Theorem: integral_sin
File: Mathlib/Analysis/SpecialFunctions/Integrals.lean

Proof steps:
state_before: a b : ℝ
n : ℕ
⊢ ∫ (x : ℝ) in a..b, sin x = cos a - cos b
state_after: a b : ℝ
n : ℕ
⊢ -cos b - -cos a = cos a - cos b

case hderiv
a b : ℝ
n : ℕ
⊢ (deriv fun x => -cos x) = sin

case hdiff
a b : ℝ
n : ℕ
⊢ ∀ x ∈ [[a, b]], DifferentiableAt ℝ (fun x => -cos x) x

case hcont
a b : ℝ
n : ℕ
⊢ ContinuousOn sin [[a, b]]
tactic: rw [integral_deriv_eq_sub' fun x => -cos x]
Theorem: isRegular_mul_and_mul_iff
File: Mathlib/Algebra/Regular/Basic.lean

Proof steps:
state_before: R : Type u_1
inst✝ : Semigroup R
a b : R
⊢ IsRegular (a * b) ∧ IsRegular (b * a) ↔ IsRegular a ∧ IsRegular b
state_after: case refine_1
R : Type u_1
inst✝ : Semigroup R
a b : R
⊢ IsRegular (a * b) ∧ IsRegular (b * a) → IsRegular a ∧ IsRegular b

case refine_2
R : Type u_1
inst✝ : Semigroup R
a b : R
⊢ IsRegular a ∧ IsRegular b → IsRegular (a * b) ∧ IsRegular (b * a)
tactic: refine ⟨?_, ?_⟩
Theorem: Multiset.filter_eq_self
File: Mathlib/Data/Multiset/Basic.lean

Proof steps:
state_before: α : Type u_1
β : Type v
γ : Type u_2
p : α → Prop
inst✝ : DecidablePred p
s : Multiset α
_l : List α
⊢ List.filter (fun b => decide (p b)) _l = _l ↔ ∀ a ∈ Quot.mk Setoid.r _l, p a
state_after: no goals
tactic: simp
Theorem: CategoryTheory.Limits.colimit.pre_desc
File: Mathlib/CategoryTheory/Limits/HasLimits.lean

Proof steps:
state_before: J : Type u₁
inst✝⁴ : Category.{v₁, u₁} J
K : Type u₂
inst✝³ : Category.{v₂, u₂} K
C : Type u
inst✝² : Category.{v, u} C
F : J ⥤ C
inst✝¹ : HasColimit F
E : K ⥤ J
inst✝ : HasColimit (E ⋙ F)
c : Cocone F
⊢ pre F E ≫ desc F c = desc (E ⋙ F) (Cocone.whisker E c)
state_after: case w
J : Type u₁
inst✝⁴ : Category.{v₁, u₁} J
K : Type u₂
inst✝³ : Category.{v₂, u₂} K
C : Type u
inst✝² : Category.{v, u} C
F : J ⥤ C
inst✝¹ : HasColimit F
E : K ⥤ J
inst✝ : HasColimit (E ⋙ F)
c : Cocone F
j✝ : K
⊢ ι (E ⋙ F) j✝ ≫ pre F E ≫ desc F c = ι (E ⋙ F) j✝ ≫ desc (E ⋙ F) (Cocone.whisker E c)
tactic: ext
state_before: case w
J : Type u₁
inst✝⁴ : Category.{v₁, u₁} J
K : Type u₂
inst✝³ : Category.{v₂, u₂} K
C : Type u
inst✝² : Category.{v, u} C
F : J ⥤ C
inst✝¹ : HasColimit F
E : K ⥤ J
inst✝ : HasColimit (E ⋙ F)
c : Cocone F
j✝ : K
⊢ ι (E ⋙ F) j✝ ≫ pre F E ≫ desc F c = ι (E ⋙ F) j✝ ≫ desc (E ⋙ F) (Cocone.whisker E c)
state_after: case w
J : Type u₁
inst✝⁴ : Category.{v₁, u₁} J
K : Type u₂
inst✝³ : Category.{v₂, u₂} K
C : Type u
inst✝² : Category.{v, u} C
F : J ⥤ C
inst✝¹ : HasColimit F
E : K ⥤ J
inst✝ : HasColimit (E ⋙ F)
c : Cocone F
j✝ : K
⊢ ι F (E.obj j✝) ≫ desc F c = ι (E ⋙ F) j✝ ≫ desc (E ⋙ F) (Cocone.whisker E c)
tactic: rw [← assoc, colimit.ι_pre]
state_before: case w
J : Type u₁
inst✝⁴ : Category.{v₁, u₁} J
K : Type u₂
inst✝³ : Category.{v₂, u₂} K
C : Type u
inst✝² : Category.{v, u} C
F : J ⥤ C
inst✝¹ : HasColimit F
E : K ⥤ J
inst✝ : HasColimit (E ⋙ F)
c : Cocone F
j✝ : K
⊢ ι F (E.obj j✝) ≫ desc F c = ι (E ⋙ F) j✝ ≫ desc (E ⋙ F) (Cocone.whisker E c)
state_after: no goals
tactic: simp
Theorem: Metric.uniformEmbedding_iff'
File: Mathlib/Topology/MetricSpace/Basic.lean

Proof steps:
state_before: α : Type u
β : Type v
X : Type u_1
ι : Type u_2
inst✝² : PseudoMetricSpace α
γ : Type w
inst✝¹ : MetricSpace γ
x : γ
s : Set γ
inst✝ : MetricSpace β
f : γ → β
⊢ UniformEmbedding f ↔
    (∀ ε > 0, ∃ δ > 0, ∀ {a b : γ}, dist a b < δ → dist (f a) (f b) < ε) ∧
      ∀ δ > 0, ∃ ε > 0, ∀ {a b : γ}, dist (f a) (f b) < ε → dist a b < δ
state_after: no goals
tactic: rw [uniformEmbedding_iff_uniformInducing, uniformInducing_iff, uniformContinuous_iff]
Theorem: LinearMap.BilinForm.IsAdjointPair.add
File: Mathlib/LinearAlgebra/BilinearForm/Properties.lean

Proof steps:
state_before: R : Type u_1
M : Type u_2
inst✝¹⁴ : CommSemiring R
inst✝¹³ : AddCommMonoid M
inst✝¹² : Module R M
R₁ : Type u_3
M₁ : Type u_4
inst✝¹¹ : CommRing R₁
inst✝¹⁰ : AddCommGroup M₁
inst✝⁹ : Module R₁ M₁
V : Type u_5
K : Type u_6
inst✝⁸ : Field K
inst✝⁷ : AddCommGroup V
inst✝⁶ : Module K V
M'✝ : Type u_7
M'' : Type u_8
inst✝⁵ : AddCommMonoid M'✝
inst✝⁴ : AddCommMonoid M''
inst✝³ : Module R M'✝
inst✝² : Module R M''
B : BilinForm R M
B₁ : BilinForm R₁ M₁
F : BilinForm R M
M' : Type u_9
inst✝¹ : AddCommMonoid M'
inst✝ : Module R M'
B' : BilinForm R M'
f f' : M →ₗ[R] M'
g g' : M' →ₗ[R] M
h : B.IsAdjointPair B' f g
h' : B.IsAdjointPair B' f' g'
x : M
y : M'
⊢ (B' ((f + f') x)) y = (B x) ((g + g') y)
state_after: no goals
tactic: rw [LinearMap.add_apply, LinearMap.add_apply, add_left, add_right, h, h']
Theorem: ENNReal.zero_rpow_mul_self
File: Mathlib/Analysis/SpecialFunctions/Pow/NNReal.lean

Proof steps:
state_before: y : ℝ
⊢ 0 ^ y * 0 ^ y = 0 ^ y
state_after: y : ℝ
⊢ ((if 0 < y then 0 else if y = 0 then 1 else ⊤) * if 0 < y then 0 else if y = 0 then 1 else ⊤) =
    if 0 < y then 0 else if y = 0 then 1 else ⊤
tactic: rw [zero_rpow_def]
state_before: y : ℝ
⊢ ((if 0 < y then 0 else if y = 0 then 1 else ⊤) * if 0 < y then 0 else if y = 0 then 1 else ⊤) =
    if 0 < y then 0 else if y = 0 then 1 else ⊤
state_after: case pos
y : ℝ
h✝ : 0 < y
⊢ 0 * 0 = 0

case pos
y : ℝ
h✝¹ : ¬0 < y
h✝ : y = 0
⊢ 1 * 1 = 1

case neg
y : ℝ
h✝¹ : ¬0 < y
h✝ : ¬y = 0
⊢ ⊤ * ⊤ = ⊤
tactic: split_ifs
state_before: case pos
y : ℝ
h✝ : 0 < y
⊢ 0 * 0 = 0

case pos
y : ℝ
h✝¹ : ¬0 < y
h✝ : y = 0
⊢ 1 * 1 = 1

case neg
y : ℝ
h✝¹ : ¬0 < y
h✝ : ¬y = 0
⊢ ⊤ * ⊤ = ⊤
state_after: no goals
tactic: exacts [zero_mul _, one_mul _, top_mul_top]
Theorem: Ideal.finprod_heightOneSpectrum_factorization_coe
File: Mathlib/RingTheory/DedekindDomain/Factorization.lean

Proof steps:
state_before: R : Type u_1
inst✝⁴ : CommRing R
K : Type u_2
inst✝³ : Field K
inst✝² : Algebra R K
inst✝¹ : IsFractionRing R K
inst✝ : IsDedekindDomain R
v : HeightOneSpectrum R
I : Ideal R
hI : I ≠ 0
⊢ ∏ᶠ (v : HeightOneSpectrum R), ↑v.asIdeal ^ ↑((Associates.mk v.asIdeal).count (Associates.mk I).factors) = ↑I
state_after: R : Type u_1
inst✝⁴ : CommRing R
K : Type u_2
inst✝³ : Field K
inst✝² : Algebra R K
inst✝¹ : IsFractionRing R K
inst✝ : IsDedekindDomain R
v : HeightOneSpectrum R
I : Ideal R
hI : I ≠ 0
⊢ ∏ᶠ (v : HeightOneSpectrum R), ↑v.asIdeal ^ ↑((Associates.mk v.asIdeal).count (Associates.mk I).factors) =
    ↑(∏ᶠ (v : HeightOneSpectrum R), v.maxPowDividing I)
tactic: conv_rhs => rw [← Ideal.finprod_heightOneSpectrum_factorization hI]
state_before: R : Type u_1
inst✝⁴ : CommRing R
K : Type u_2
inst✝³ : Field K
inst✝² : Algebra R K
inst✝¹ : IsFractionRing R K
inst✝ : IsDedekindDomain R
v : HeightOneSpectrum R
I : Ideal R
hI : I ≠ 0
⊢ ∏ᶠ (v : HeightOneSpectrum R), ↑v.asIdeal ^ ↑((Associates.mk v.asIdeal).count (Associates.mk I).factors) =
    ↑(∏ᶠ (v : HeightOneSpectrum R), v.maxPowDividing I)
state_after: R : Type u_1
inst✝⁴ : CommRing R
K : Type u_2
inst✝³ : Field K
inst✝² : Algebra R K
inst✝¹ : IsFractionRing R K
inst✝ : IsDedekindDomain R
v : HeightOneSpectrum R
I : Ideal R
hI : I ≠ 0
⊢ ∏ᶠ (v : HeightOneSpectrum R), ↑v.asIdeal ^ ↑((Associates.mk v.asIdeal).count (Associates.mk I).factors) =
    ∏ᶠ (a : HeightOneSpectrum R), ↑(a.maxPowDividing I)
tactic: rw [FractionalIdeal.coeIdeal_finprod R⁰ K (le_refl _)]
state_before: R : Type u_1
inst✝⁴ : CommRing R
K : Type u_2
inst✝³ : Field K
inst✝² : Algebra R K
inst✝¹ : IsFractionRing R K
inst✝ : IsDedekindDomain R
v : HeightOneSpectrum R
I : Ideal R
hI : I ≠ 0
⊢ ∏ᶠ (v : HeightOneSpectrum R), ↑v.asIdeal ^ ↑((Associates.mk v.asIdeal).count (Associates.mk I).factors) =
    ∏ᶠ (a : HeightOneSpectrum R), ↑(a.maxPowDividing I)
state_after: no goals
tactic: simp_rw [IsDedekindDomain.HeightOneSpectrum.maxPowDividing, FractionalIdeal.coeIdeal_pow,
    zpow_natCast]
Theorem: Finset.weightedVSubOfPoint_erase
File: Mathlib/LinearAlgebra/AffineSpace/Combination.lean

Proof steps:
state_before: k : Type u_1
V : Type u_2
P : Type u_3
inst✝³ : Ring k
inst✝² : AddCommGroup V
inst✝¹ : Module k V
S : AffineSpace V P
ι : Type u_4
s : Finset ι
ι₂ : Type u_5
s₂ : Finset ι₂
inst✝ : DecidableEq ι
w : ι → k
p : ι → P
i : ι
⊢ ((s.erase i).weightedVSubOfPoint p (p i)) w = (s.weightedVSubOfPoint p (p i)) w
state_after: k : Type u_1
V : Type u_2
P : Type u_3
inst✝³ : Ring k
inst✝² : AddCommGroup V
inst✝¹ : Module k V
S : AffineSpace V P
ι : Type u_4
s : Finset ι
ι₂ : Type u_5
s₂ : Finset ι₂
inst✝ : DecidableEq ι
w : ι → k
p : ι → P
i : ι
⊢ ∑ i_1 ∈ s.erase i, w i_1 • (p i_1 -ᵥ p i) = ∑ i_1 ∈ s, w i_1 • (p i_1 -ᵥ p i)
tactic: rw [weightedVSubOfPoint_apply, weightedVSubOfPoint_apply]
state_before: k : Type u_1
V : Type u_2
P : Type u_3
inst✝³ : Ring k
inst✝² : AddCommGroup V
inst✝¹ : Module k V
S : AffineSpace V P
ι : Type u_4
s : Finset ι
ι₂ : Type u_5
s₂ : Finset ι₂
inst✝ : DecidableEq ι
w : ι → k
p : ι → P
i : ι
⊢ ∑ i_1 ∈ s.erase i, w i_1 • (p i_1 -ᵥ p i) = ∑ i_1 ∈ s, w i_1 • (p i_1 -ᵥ p i)
state_after: case h
k : Type u_1
V : Type u_2
P : Type u_3
inst✝³ : Ring k
inst✝² : AddCommGroup V
inst✝¹ : Module k V
S : AffineSpace V P
ι : Type u_4
s : Finset ι
ι₂ : Type u_5
s₂ : Finset ι₂
inst✝ : DecidableEq ι
w : ι → k
p : ι → P
i : ι
⊢ w i • (p i -ᵥ p i) = 0
tactic: apply sum_erase
state_before: case h
k : Type u_1
V : Type u_2
P : Type u_3
inst✝³ : Ring k
inst✝² : AddCommGroup V
inst✝¹ : Module k V
S : AffineSpace V P
ι : Type u_4
s : Finset ι
ι₂ : Type u_5
s₂ : Finset ι₂
inst✝ : DecidableEq ι
w : ι → k
p : ι → P
i : ι
⊢ w i • (p i -ᵥ p i) = 0
state_after: no goals
tactic: rw [vsub_self, smul_zero]
Theorem: IsPrimitiveRoot.nthRoots_nodup
File: Mathlib/RingTheory/RootsOfUnity/Basic.lean

Proof steps:
state_before: M : Type u_1
N : Type u_2
G : Type u_3
R : Type u_4
S : Type u_5
F : Type u_6
inst✝⁴ : CommMonoid M
inst✝³ : CommMonoid N
inst✝² : DivisionCommMonoid G
k l : ℕ
inst✝¹ : CommRing R
ζ✝ : Rˣ
h✝ : IsPrimitiveRoot ζ✝ k
inst✝ : IsDomain R
ζ : R
n : ℕ
h : IsPrimitiveRoot ζ n
a : R
ha : a ≠ 0
⊢ (nthRoots n a).Nodup
state_after: case inl
M : Type u_1
N : Type u_2
G : Type u_3
R : Type u_4
S : Type u_5
F : Type u_6
inst✝⁴ : CommMonoid M
inst✝³ : CommMonoid N
inst✝² : DivisionCommMonoid G
k l : ℕ
inst✝¹ : CommRing R
ζ✝ : Rˣ
h✝ : IsPrimitiveRoot ζ✝ k
inst✝ : IsDomain R
ζ a : R
ha : a ≠ 0
h : IsPrimitiveRoot ζ 0
⊢ (nthRoots 0 a).Nodup

case inr
M : Type u_1
N : Type u_2
G : Type u_3
R : Type u_4
S : Type u_5
F : Type u_6
inst✝⁴ : CommMonoid M
inst✝³ : CommMonoid N
inst✝² : DivisionCommMonoid G
k l : ℕ
inst✝¹ : CommRing R
ζ✝ : Rˣ
h✝ : IsPrimitiveRoot ζ✝ k
inst✝ : IsDomain R
ζ : R
n : ℕ
h : IsPrimitiveRoot ζ n
a : R
ha : a ≠ 0
hn : n > 0
⊢ (nthRoots n a).Nodup
tactic: obtain (rfl|hn) := n.eq_zero_or_pos
state_before: case inr
M : Type u_1
N : Type u_2
G : Type u_3
R : Type u_4
S : Type u_5
F : Type u_6
inst✝⁴ : CommMonoid M
inst✝³ : CommMonoid N
inst✝² : DivisionCommMonoid G
k l : ℕ
inst✝¹ : CommRing R
ζ✝ : Rˣ
h✝ : IsPrimitiveRoot ζ✝ k
inst✝ : IsDomain R
ζ : R
n : ℕ
h : IsPrimitiveRoot ζ n
a : R
ha : a ≠ 0
hn : n > 0
⊢ (nthRoots n a).Nodup
state_after: case pos
M : Type u_1
N : Type u_2
G : Type u_3
R : Type u_4
S : Type u_5
F : Type u_6
inst✝⁴ : CommMonoid M
inst✝³ : CommMonoid N
inst✝² : DivisionCommMonoid G
k l : ℕ
inst✝¹ : CommRing R
ζ✝ : Rˣ
h✝¹ : IsPrimitiveRoot ζ✝ k
inst✝ : IsDomain R
ζ : R
n : ℕ
h✝ : IsPrimitiveRoot ζ n
a : R
ha : a ≠ 0
hn : n > 0
h : ∃ α, α ^ n = a
⊢ (nthRoots n a).Nodup

case neg
M : Type u_1
N : Type u_2
G : Type u_3
R : Type u_4
S : Type u_5
F : Type u_6
inst✝⁴ : CommMonoid M
inst✝³ : CommMonoid N
inst✝² : DivisionCommMonoid G
k l : ℕ
inst✝¹ : CommRing R
ζ✝ : Rˣ
h✝¹ : IsPrimitiveRoot ζ✝ k
inst✝ : IsDomain R
ζ : R
n : ℕ
h✝ : IsPrimitiveRoot ζ n
a : R
ha : a ≠ 0
hn : n > 0
h : ¬∃ α, α ^ n = a
⊢ (nthRoots n a).Nodup
tactic: by_cases h : ∃ α, α ^ n = a
Theorem: Matrix.det_conj
File: Mathlib/LinearAlgebra/Matrix/NonsingularInverse.lean

Proof steps:
state_before: l : Type u_1
m : Type u
n : Type u'
α : Type v
inst✝⁵ : Fintype n
inst✝⁴ : DecidableEq n
inst✝³ : CommRing α
A B : Matrix n n α
inst✝² : Fintype m
inst✝¹ : DecidableEq m
inst✝ : CommRing α
M : Matrix m m α
h : IsUnit M
N : Matrix m m α
⊢ (M * N * M⁻¹).det = N.det
state_after: no goals
tactic: rw [← h.unit_spec, ← coe_units_inv, det_units_conj]
Theorem: Filter.frequently_imp_distrib_left
File: Mathlib/Order/Filter/Basic.lean

Proof steps:
state_before: α : Type u
β : Type v
γ : Type w
δ : Type u_1
ι : Sort x
f : Filter α
inst✝ : f.NeBot
p : Prop
q : α → Prop
⊢ (∃ᶠ (x : α) in f, p → q x) ↔ p → ∃ᶠ (x : α) in f, q x
state_after: no goals
tactic: simp [frequently_imp_distrib]
Theorem: Commute.geom_sum₂_mul_add
File: Mathlib/Algebra/GeomSum.lean

Proof steps:
state_before: α : Type u
inst✝ : Semiring α
x y : α
h : Commute x y
n : ℕ
⊢ (∑ i ∈ range n, (x + y) ^ i * y ^ (n - 1 - i)) * x + y ^ n = (x + y) ^ n
state_after: α : Type u
inst✝ : Semiring α
x y : α
h : Commute x y
n : ℕ
f : ℕ → ℕ → α := fun m i => (x + y) ^ i * y ^ (m - 1 - i)
⊢ (∑ i ∈ range n, (x + y) ^ i * y ^ (n - 1 - i)) * x + y ^ n = (x + y) ^ n
tactic: let f :  ℕ → ℕ → α := fun m i : ℕ => (x + y) ^ i * y ^ (m - 1 - i)
state_before: α : Type u
inst✝ : Semiring α
x y : α
h : Commute x y
n : ℕ
f : ℕ → ℕ → α := fun m i => (x + y) ^ i * y ^ (m - 1 - i)
⊢ (∑ i ∈ range n, (x + y) ^ i * y ^ (n - 1 - i)) * x + y ^ n = (x + y) ^ n
state_after: α : Type u
inst✝ : Semiring α
x y : α
h : Commute x y
n : ℕ
f : ℕ → ℕ → α := fun m i => (x + y) ^ i * y ^ (m - 1 - i)
⊢ (∑ i ∈ range n, f n i) * x + y ^ n = (x + y) ^ n
tactic: change (∑ i ∈ range n, (f n) i) * x + y ^ n = (x + y) ^ n
state_before: α : Type u
inst✝ : Semiring α
x y : α
h : Commute x y
n : ℕ
f : ℕ → ℕ → α := fun m i => (x + y) ^ i * y ^ (m - 1 - i)
⊢ (∑ i ∈ range n, f n i) * x + y ^ n = (x + y) ^ n
state_after: case zero
α : Type u
inst✝ : Semiring α
x y : α
h : Commute x y
f : ℕ → ℕ → α := fun m i => (x + y) ^ i * y ^ (m - 1 - i)
⊢ (∑ i ∈ range 0, f 0 i) * x + y ^ 0 = (x + y) ^ 0

case succ
α : Type u
inst✝ : Semiring α
x y : α
h : Commute x y
f : ℕ → ℕ → α := fun m i => (x + y) ^ i * y ^ (m - 1 - i)
n : ℕ
ih : (∑ i ∈ range n, f n i) * x + y ^ n = (x + y) ^ n
⊢ (∑ i ∈ range (n + 1), f (n + 1) i) * x + y ^ (n + 1) = (x + y) ^ (n + 1)
tactic: induction' n with n ih
Theorem: Polynomial.rootSet_prod
File: Mathlib/Algebra/Polynomial/FieldDivision.lean

Proof steps:
state_before: R : Type u
S : Type v
k : Type y
A : Type z
a b : R
n : ℕ
inst✝³ : Field R
p q : R[X]
inst✝² : CommRing S
inst✝¹ : IsDomain S
inst✝ : Algebra R S
ι : Type u_1
f : ι → R[X]
s : Finset ι
h : s.prod f ≠ 0
⊢ (s.prod f).rootSet S = ⋃ i ∈ s, (f i).rootSet S
state_after: no goals
tactic: classical
  simp only [rootSet, aroots, ← Finset.mem_coe]
  rw [Polynomial.map_prod, roots_prod, Finset.bind_toFinset, s.val_toFinset, Finset.coe_biUnion]
  rwa [← Polynomial.map_prod, Ne, map_eq_zero]
Theorem: ProbabilityTheory.Kernel.iIndepSet.indep_generateFrom_lt
File: Mathlib/Probability/Independence/Kernel.lean

Proof steps:
state_before: α : Type u_1
Ω : Type u_2
ι : Type u_3
_mα : MeasurableSpace α
_mΩ : MeasurableSpace Ω
κ : Kernel α Ω
μ : Measure α
inst✝¹ : Preorder ι
inst✝ : IsMarkovKernel κ
s : ι → Set Ω
hsm : ∀ (n : ι), MeasurableSet (s n)
hs : iIndepSet s κ μ
i : ι
⊢ Indep (generateFrom {s i}) (generateFrom {t | ∃ j < i, s j = t}) κ μ
state_after: case h.e'_4.h.e'_2
α : Type u_1
Ω : Type u_2
ι : Type u_3
_mα : MeasurableSpace α
_mΩ : MeasurableSpace Ω
κ : Kernel α Ω
μ : Measure α
inst✝¹ : Preorder ι
inst✝ : IsMarkovKernel κ
s : ι → Set Ω
hsm : ∀ (n : ι), MeasurableSet (s n)
hs : iIndepSet s κ μ
i : ι
⊢ {s i} = {t | ∃ n ∈ {i}, s n = t}
tactic: convert iIndepSet.indep_generateFrom_of_disjoint hsm hs {i} { j | j < i }
    (Set.disjoint_singleton_left.mpr (lt_irrefl _))
state_before: case h.e'_4.h.e'_2
α : Type u_1
Ω : Type u_2
ι : Type u_3
_mα : MeasurableSpace α
_mΩ : MeasurableSpace Ω
κ : Kernel α Ω
μ : Measure α
inst✝¹ : Preorder ι
inst✝ : IsMarkovKernel κ
s : ι → Set Ω
hsm : ∀ (n : ι), MeasurableSet (s n)
hs : iIndepSet s κ μ
i : ι
⊢ {s i} = {t | ∃ n ∈ {i}, s n = t}
state_after: no goals
tactic: simp only [Set.mem_singleton_iff, exists_prop, exists_eq_left, Set.setOf_eq_eq_singleton']
Theorem: MeasureTheory.condexp_of_aestronglyMeasurable'
File: Mathlib/MeasureTheory/Function/ConditionalExpectation/Basic.lean

Proof steps:
state_before: α : Type u_1
F : Type u_2
F' : Type u_3
𝕜 : Type u_4
p : ℝ≥0∞
inst✝⁶ : RCLike 𝕜
inst✝⁵ : NormedAddCommGroup F
inst✝⁴ : NormedSpace 𝕜 F
inst✝³ : NormedAddCommGroup F'
inst✝² : NormedSpace 𝕜 F'
inst✝¹ : NormedSpace ℝ F'
inst✝ : CompleteSpace F'
m m0 : MeasurableSpace α
μ : Measure α
f✝ g : α → F'
s : Set α
hm : m ≤ m0
hμm : SigmaFinite (μ.trim hm)
f : α → F'
hf : AEStronglyMeasurable' m f μ
hfi : Integrable f μ
⊢ μ[f|m] =ᶠ[ae μ] f
state_after: α : Type u_1
F : Type u_2
F' : Type u_3
𝕜 : Type u_4
p : ℝ≥0∞
inst✝⁶ : RCLike 𝕜
inst✝⁵ : NormedAddCommGroup F
inst✝⁴ : NormedSpace 𝕜 F
inst✝³ : NormedAddCommGroup F'
inst✝² : NormedSpace 𝕜 F'
inst✝¹ : NormedSpace ℝ F'
inst✝ : CompleteSpace F'
m m0 : MeasurableSpace α
μ : Measure α
f✝ g : α → F'
s : Set α
hm : m ≤ m0
hμm : SigmaFinite (μ.trim hm)
f : α → F'
hf : AEStronglyMeasurable' m f μ
hfi : Integrable f μ
⊢ μ[AEStronglyMeasurable'.mk f hf|m] =ᶠ[ae μ] AEStronglyMeasurable'.mk f hf
tactic: refine ((condexp_congr_ae hf.ae_eq_mk).trans ?_).trans hf.ae_eq_mk.symm
state_before: α : Type u_1
F : Type u_2
F' : Type u_3
𝕜 : Type u_4
p : ℝ≥0∞
inst✝⁶ : RCLike 𝕜
inst✝⁵ : NormedAddCommGroup F
inst✝⁴ : NormedSpace 𝕜 F
inst✝³ : NormedAddCommGroup F'
inst✝² : NormedSpace 𝕜 F'
inst✝¹ : NormedSpace ℝ F'
inst✝ : CompleteSpace F'
m m0 : MeasurableSpace α
μ : Measure α
f✝ g : α → F'
s : Set α
hm : m ≤ m0
hμm : SigmaFinite (μ.trim hm)
f : α → F'
hf : AEStronglyMeasurable' m f μ
hfi : Integrable f μ
⊢ μ[AEStronglyMeasurable'.mk f hf|m] =ᶠ[ae μ] AEStronglyMeasurable'.mk f hf
state_after: no goals
tactic: rw [condexp_of_stronglyMeasurable hm hf.stronglyMeasurable_mk
    ((integrable_congr hf.ae_eq_mk).mp hfi)]
Theorem: Set.preimage_add_const_Icc
File: Mathlib/Data/Set/Pointwise/Interval.lean

Proof steps:
state_before: α : Type u_1
inst✝ : OrderedAddCommGroup α
a b c : α
⊢ (fun x => x + a) ⁻¹' Icc b c = Icc (b - a) (c - a)
state_after: no goals
tactic: simp [← Ici_inter_Iic]
Theorem: Matroid.Indep.rkPos_of_nonempty
File: Mathlib/Data/Matroid/Basic.lean

Proof steps:
state_before: α : Type u_1
M : Matroid α
B B' I J D X : Set α
e f : α
hI : M.Indep I
hne : I.Nonempty
⊢ M.RkPos
state_after: case intro.intro
α : Type u_1
M : Matroid α
B✝ B' I J D X : Set α
e f : α
hI : M.Indep I
hne : I.Nonempty
B : Set α
hB : M.Base B
hIB : I ⊆ B
⊢ M.RkPos
tactic: obtain ⟨B, hB, hIB⟩ := hI.exists_base_superset
state_before: case intro.intro
α : Type u_1
M : Matroid α
B✝ B' I J D X : Set α
e f : α
hI : M.Indep I
hne : I.Nonempty
B : Set α
hB : M.Base B
hIB : I ⊆ B
⊢ M.RkPos
state_after: no goals
tactic: exact hB.rkPos_of_nonempty (hne.mono hIB)
Theorem: map_comp_zsmul'
File: Mathlib/Algebra/Group/Hom/Defs.lean

Proof steps:
state_before: ι : Type u_1
α : Type u_2
β : Type u_3
M : Type u_4
N : Type u_5
P : Type u_6
G : Type u_7
H : Type u_8
F : Type u_9
inst✝⁶ : MulOneClass M
inst✝⁵ : MulOneClass N
inst✝⁴ : FunLike F M N
inst✝³ : FunLike F G H
inst✝² : DivInvMonoid G
inst✝¹ : DivInvMonoid H
inst✝ : MonoidHomClass F G H
f : F
hf : ∀ (x : G), f x⁻¹ = (f x)⁻¹
g : ι → G
n : ℤ
⊢ ⇑f ∘ (g ^ n) = ⇑f ∘ g ^ n
state_after: case h
ι : Type u_1
α : Type u_2
β : Type u_3
M : Type u_4
N : Type u_5
P : Type u_6
G : Type u_7
H : Type u_8
F : Type u_9
inst✝⁶ : MulOneClass M
inst✝⁵ : MulOneClass N
inst✝⁴ : FunLike F M N
inst✝³ : FunLike F G H
inst✝² : DivInvMonoid G
inst✝¹ : DivInvMonoid H
inst✝ : MonoidHomClass F G H
f : F
hf : ∀ (x : G), f x⁻¹ = (f x)⁻¹
g : ι → G
n : ℤ
x✝ : ι
⊢ (⇑f ∘ (g ^ n)) x✝ = (⇑f ∘ g ^ n) x✝
tactic: ext
state_before: case h
ι : Type u_1
α : Type u_2
β : Type u_3
M : Type u_4
N : Type u_5
P : Type u_6
G : Type u_7
H : Type u_8
F : Type u_9
inst✝⁶ : MulOneClass M
inst✝⁵ : MulOneClass N
inst✝⁴ : FunLike F M N
inst✝³ : FunLike F G H
inst✝² : DivInvMonoid G
inst✝¹ : DivInvMonoid H
inst✝ : MonoidHomClass F G H
f : F
hf : ∀ (x : G), f x⁻¹ = (f x)⁻¹
g : ι → G
n : ℤ
x✝ : ι
⊢ (⇑f ∘ (g ^ n)) x✝ = (⇑f ∘ g ^ n) x✝
state_after: no goals
tactic: simp [map_zpow' f hf]
Theorem: Nat.ceil_natCast
File: Mathlib/Algebra/Order/Floor.lean

Proof steps:
state_before: F : Type u_1
α : Type u_2
β : Type u_3
inst✝¹ : LinearOrderedSemiring α
inst✝ : FloorSemiring α
a✝ : α
n✝ n a : ℕ
⊢ ⌈↑n⌉₊ ≤ a ↔ n ≤ a
state_after: no goals
tactic: rw [ceil_le, cast_le]