ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
Theorem: MeasureTheory.SignedMeasure.toMeasureOfZeroLE_toSignedMeasure
File: Mathlib/MeasureTheory/Measure/VectorMeasure.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
m : MeasurableSpace α
s : SignedMeasure α
i j : Set α
hs : VectorMeasure.restrict 0 univ ≤ VectorMeasure.restrict s univ
⊢ (s.toMeasureOfZeroLE univ ⋯ hs).toSignedMeasure = s
state_after: case h
α : Type u_1
β : Type u_2
m : MeasurableSpace α
s : SignedMeasure α
i✝ j : Set α
hs : VectorMeasure.restrict 0 univ ≤ VectorMeasure.restrict s univ
i : Set α
hi : MeasurableSet i
⊢ ↑(s.toMeasureOfZeroLE univ ⋯ hs).toSignedMeasure i = ↑s i
tactic: ext i hi
state_before: case h
α : Type u_1
β : Type u_2
m : MeasurableSpace α
s : SignedMeasure α
i✝ j : Set α
hs : VectorMeasure.restrict 0 univ ≤ VectorMeasure.restrict s univ
i : Set α
hi : MeasurableSet i
⊢ ↑(s.toMeasureOfZeroLE univ ⋯ hs).toSignedMeasure i = ↑s i
state_after: no goals
tactic: simp [hi, toMeasureOfZeroLE_apply _ _ _ hi]
Theorem: CategoryTheory.ShortComplex.ShortExact.moduleCat_exact_iff_function_exact
File: Mathlib/Algebra/Homology/ShortComplex/ModuleCat.lean

Proof steps:
state_before: R : Type u
inst✝ : Ring R
S : ShortComplex (ModuleCat R)
⊢ S.Exact ↔ Function.Exact ⇑S.f ⇑S.g
state_after: R : Type u
inst✝ : Ring R
S : ShortComplex (ModuleCat R)
⊢ LinearMap.range S.f = LinearMap.ker S.g ↔ LinearMap.ker S.g = LinearMap.range S.f
tactic: rw [moduleCat_exact_iff_range_eq_ker, LinearMap.exact_iff]
state_before: R : Type u
inst✝ : Ring R
S : ShortComplex (ModuleCat R)
⊢ LinearMap.range S.f = LinearMap.ker S.g ↔ LinearMap.ker S.g = LinearMap.range S.f
state_after: no goals
tactic: tauto
Theorem: AlgebraicTopology.DoldKan.Q_succ
File: Mathlib/AlgebraicTopology/DoldKan/Projections.lean

Proof steps:
state_before: C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : Preadditive C
X : SimplicialObject C
q : ℕ
⊢ Q (q + 1) = Q q - P q ≫ Hσ q
state_after: C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : Preadditive C
X : SimplicialObject C
q : ℕ
⊢ 𝟙 K[X] - (P q + P q ≫ Hσ q) = 𝟙 K[X] - P q - P q ≫ Hσ q
tactic: simp only [Q, P_succ, comp_add, comp_id]
state_before: C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : Preadditive C
X : SimplicialObject C
q : ℕ
⊢ 𝟙 K[X] - (P q + P q ≫ Hσ q) = 𝟙 K[X] - P q - P q ≫ Hσ q
state_after: no goals
tactic: abel
Theorem: mellin_div_const
File: Mathlib/Analysis/MellinTransform.lean

Proof steps:
state_before: E : Type u_1
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace ℂ E
f : ℝ → ℂ
s a : ℂ
⊢ mellin (fun t => f t / a) s = mellin f s / a
state_after: no goals
tactic: simp_rw [mellin, smul_eq_mul, ← mul_div_assoc, integral_div]
Theorem: Ordnode.dual_balanceR
File: Mathlib/Data/Ordmap/Ordset.lean

Proof steps:
state_before: α : Type u_1
l : Ordnode α
x : α
r : Ordnode α
⊢ (l.balanceR x r).dual = r.dual.balanceL x l.dual
state_after: no goals
tactic: rw [← dual_dual (balanceL _ _ _), dual_balanceL, dual_dual, dual_dual]
Theorem: Stream'.WSeq.bind_ret
File: Mathlib/Data/Seq/WSeq.lean

Proof steps:
state_before: α : Type u
β : Type v
γ : Type w
f : α → β
s : WSeq α
⊢ s.bind (ret ∘ f) ~ʷ map f s
state_after: α : Type u
β : Type v
γ : Type w
f : α → β
s : WSeq α
⊢ (map (ret ∘ f) s).join ~ʷ map f s
tactic: dsimp [bind]
state_before: α : Type u
β : Type v
γ : Type w
f : α → β
s : WSeq α
⊢ (map (ret ∘ f) s).join ~ʷ map f s
state_after: α : Type u
β : Type v
γ : Type w
f : α → β
s : WSeq α
⊢ (map ret (map f s)).join ~ʷ map f s
tactic: rw [map_comp]
state_before: α : Type u
β : Type v
γ : Type w
f : α → β
s : WSeq α
⊢ (map ret (map f s)).join ~ʷ map f s
state_after: no goals
tactic: apply join_map_ret
Theorem: IsClosedMap.restrictPreimage
File: Mathlib/Topology/LocalAtTarget.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace β
f : α → β
s✝ : Set β
ι : Type u_3
U : ι → Opens β
hU : iSup U = ⊤
H : IsClosedMap f
s : Set β
⊢ IsClosedMap (s.restrictPreimage f)
state_after: α : Type u_1
β : Type u_2
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace β
f : α → β
s✝ : Set β
ι : Type u_3
U : ι → Opens β
hU : iSup U = ⊤
H : IsClosedMap f
s : Set β
t : Set ↑(f ⁻¹' s)
⊢ IsClosed t → IsClosed (s.restrictPreimage f '' t)
tactic: intro t
state_before: α : Type u_1
β : Type u_2
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace β
f : α → β
s✝ : Set β
ι : Type u_3
U : ι → Opens β
hU : iSup U = ⊤
H : IsClosedMap f
s : Set β
t : Set ↑(f ⁻¹' s)
⊢ IsClosed t → IsClosed (s.restrictPreimage f '' t)
state_after: α : Type u_1
β : Type u_2
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace β
f : α → β
s✝ : Set β
ι : Type u_3
U : ι → Opens β
hU : iSup U = ⊤
H : IsClosedMap f
s : Set β
t : Set ↑(f ⁻¹' s)
⊢ ∀ (u : Set α), IsClosed u → Subtype.val ⁻¹' u = t → ∃ v, IsClosed v ∧ Subtype.val ⁻¹' v = s.restrictPreimage f '' t
tactic: suffices ∀ u, IsClosed u → Subtype.val ⁻¹' u = t →
    ∃ v, IsClosed v ∧ Subtype.val ⁻¹' v = s.restrictPreimage f '' t by
      simpa [isClosed_induced_iff]
state_before: α : Type u_1
β : Type u_2
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace β
f : α → β
s✝ : Set β
ι : Type u_3
U : ι → Opens β
hU : iSup U = ⊤
H : IsClosedMap f
s : Set β
t : Set ↑(f ⁻¹' s)
⊢ ∀ (u : Set α), IsClosed u → Subtype.val ⁻¹' u = t → ∃ v, IsClosed v ∧ Subtype.val ⁻¹' v = s.restrictPreimage f '' t
state_after: no goals
tactic: exact fun u hu e => ⟨f '' u, H u hu, by simp [← e, image_restrictPreimage]⟩
Theorem: SchwartzMap.decay
File: Mathlib/Analysis/Distribution/SchwartzSpace.lean

Proof steps:
state_before: 𝕜 : Type u_1
𝕜' : Type u_2
D : Type u_3
E : Type u_4
F : Type u_5
G : Type u_6
V : Type u_7
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace ℝ E
inst✝¹ : NormedAddCommGroup F
inst✝ : NormedSpace ℝ F
f : 𝓢(E, F)
k n : ℕ
⊢ ∃ C, 0 < C ∧ ∀ (x : E), ‖x‖ ^ k * ‖iteratedFDeriv ℝ n (⇑f) x‖ ≤ C
state_after: case intro
𝕜 : Type u_1
𝕜' : Type u_2
D : Type u_3
E : Type u_4
F : Type u_5
G : Type u_6
V : Type u_7
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace ℝ E
inst✝¹ : NormedAddCommGroup F
inst✝ : NormedSpace ℝ F
f : 𝓢(E, F)
k n : ℕ
C : ℝ
hC : ∀ (x : E), ‖x‖ ^ k * ‖iteratedFDeriv ℝ n f.toFun x‖ ≤ C
⊢ ∃ C, 0 < C ∧ ∀ (x : E), ‖x‖ ^ k * ‖iteratedFDeriv ℝ n (⇑f) x‖ ≤ C
tactic: rcases f.decay' k n with ⟨C, hC⟩
state_before: case intro
𝕜 : Type u_1
𝕜' : Type u_2
D : Type u_3
E : Type u_4
F : Type u_5
G : Type u_6
V : Type u_7
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace ℝ E
inst✝¹ : NormedAddCommGroup F
inst✝ : NormedSpace ℝ F
f : 𝓢(E, F)
k n : ℕ
C : ℝ
hC : ∀ (x : E), ‖x‖ ^ k * ‖iteratedFDeriv ℝ n f.toFun x‖ ≤ C
⊢ ∃ C, 0 < C ∧ ∀ (x : E), ‖x‖ ^ k * ‖iteratedFDeriv ℝ n (⇑f) x‖ ≤ C
state_after: no goals
tactic: exact ⟨max C 1, by positivity, fun x => (hC x).trans (le_max_left _ _)⟩
Theorem: closedBall_sub_ball
File: Mathlib/Analysis/NormedSpace/Pointwise.lean

Proof steps:
state_before: 𝕜 : Type u_1
E : Type u_2
inst✝³ : NormedField 𝕜
inst✝² : SeminormedAddCommGroup E
inst✝¹ : NormedSpace 𝕜 E
inst✝ : NormedSpace ℝ E
x y z : E
δ ε : ℝ
hε : 0 ≤ ε
hδ : 0 < δ
a b : E
⊢ Metric.closedBall a ε - Metric.ball b δ = Metric.ball (a - b) (ε + δ)
state_after: no goals
tactic: simp_rw [sub_eq_add_neg, neg_ball, closedBall_add_ball hε hδ]
Theorem: dist_zero_left
File: Mathlib/Analysis/Normed/Group/Basic.lean

Proof steps:
state_before: 𝓕 : Type u_1
𝕜 : Type u_2
α : Type u_3
ι : Type u_4
κ : Type u_5
E : Type u_6
F : Type u_7
G : Type u_8
inst✝² : SeminormedGroup E
inst✝¹ : SeminormedGroup F
inst✝ : SeminormedGroup G
s : Set E
a✝ a₁ a₂ b b₁ b₂ : E
r r₁ r₂ : ℝ
a : E
⊢ dist 1 a = ‖a‖
state_after: no goals
tactic: rw [dist_comm, dist_one_right]
Theorem: Polynomial.mirror_natDegree
File: Mathlib/Algebra/Polynomial/Mirror.lean

Proof steps:
state_before: R : Type u_1
inst✝ : Semiring R
p q : R[X]
⊢ p.mirror.natDegree = p.natDegree
state_after: case pos
R : Type u_1
inst✝ : Semiring R
p q : R[X]
hp : p = 0
⊢ p.mirror.natDegree = p.natDegree

case neg
R : Type u_1
inst✝ : Semiring R
p q : R[X]
hp : ¬p = 0
⊢ p.mirror.natDegree = p.natDegree
tactic: by_cases hp : p = 0
state_before: case neg
R : Type u_1
inst✝ : Semiring R
p q : R[X]
hp : ¬p = 0
⊢ p.mirror.natDegree = p.natDegree
state_after: R : Type u_1
inst✝ : Semiring R
p q : R[X]
hp : ¬p = 0
a✝ : Nontrivial R
⊢ p.mirror.natDegree = p.natDegree
tactic: nontriviality R
state_before: R : Type u_1
inst✝ : Semiring R
p q : R[X]
hp : ¬p = 0
a✝ : Nontrivial R
⊢ p.mirror.natDegree = p.natDegree
state_after: R : Type u_1
inst✝ : Semiring R
p q : R[X]
hp : ¬p = 0
a✝ : Nontrivial R
⊢ p.reverse.leadingCoeff * (X ^ p.natTrailingDegree).leadingCoeff ≠ 0
tactic: rw [mirror, natDegree_mul', reverse_natDegree, natDegree_X_pow,
    tsub_add_cancel_of_le p.natTrailingDegree_le_natDegree]
state_before: R : Type u_1
inst✝ : Semiring R
p q : R[X]
hp : ¬p = 0
a✝ : Nontrivial R
⊢ p.reverse.leadingCoeff * (X ^ p.natTrailingDegree).leadingCoeff ≠ 0
state_after: no goals
tactic: rwa [leadingCoeff_X_pow, mul_one, reverse_leadingCoeff, Ne, trailingCoeff_eq_zero]
Theorem: QPF.liftp_iff
File: Mathlib/Data/QPF/Univariate/Basic.lean

Proof steps:
state_before: F : Type u → Type u
q : QPF F
α : Type u
p : α → Prop
x : F α
⊢ Liftp p x ↔ ∃ a f, x = abs ⟨a, f⟩ ∧ ∀ (i : (P F).B a), p (f i)
state_after: case mp
F : Type u → Type u
q : QPF F
α : Type u
p : α → Prop
x : F α
⊢ Liftp p x → ∃ a f, x = abs ⟨a, f⟩ ∧ ∀ (i : (P F).B a), p (f i)

case mpr
F : Type u → Type u
q : QPF F
α : Type u
p : α → Prop
x : F α
⊢ (∃ a f, x = abs ⟨a, f⟩ ∧ ∀ (i : (P F).B a), p (f i)) → Liftp p x
tactic: constructor
state_before: case mpr
F : Type u → Type u
q : QPF F
α : Type u
p : α → Prop
x : F α
⊢ (∃ a f, x = abs ⟨a, f⟩ ∧ ∀ (i : (P F).B a), p (f i)) → Liftp p x
state_after: case mpr.intro.intro.intro
F : Type u → Type u
q : QPF F
α : Type u
p : α → Prop
x : F α
a : (P F).A
f : (P F).B a → α
h₀ : x = abs ⟨a, f⟩
h₁ : ∀ (i : (P F).B a), p (f i)
⊢ Liftp p x
tactic: rintro ⟨a, f, h₀, h₁⟩
state_before: case mpr.intro.intro.intro
F : Type u → Type u
q : QPF F
α : Type u
p : α → Prop
x : F α
a : (P F).A
f : (P F).B a → α
h₀ : x = abs ⟨a, f⟩
h₁ : ∀ (i : (P F).B a), p (f i)
⊢ Liftp p x
state_after: case h
F : Type u → Type u
q : QPF F
α : Type u
p : α → Prop
x : F α
a : (P F).A
f : (P F).B a → α
h₀ : x = abs ⟨a, f⟩
h₁ : ∀ (i : (P F).B a), p (f i)
⊢ Subtype.val <$> abs ⟨a, fun i => ⟨f i, ⋯⟩⟩ = x
tactic: use abs ⟨a, fun i => ⟨f i, h₁ i⟩⟩
state_before: case h
F : Type u → Type u
q : QPF F
α : Type u
p : α → Prop
x : F α
a : (P F).A
f : (P F).B a → α
h₀ : x = abs ⟨a, f⟩
h₁ : ∀ (i : (P F).B a), p (f i)
⊢ Subtype.val <$> abs ⟨a, fun i => ⟨f i, ⋯⟩⟩ = x
state_after: case h
F : Type u → Type u
q : QPF F
α : Type u
p : α → Prop
x : F α
a : (P F).A
f : (P F).B a → α
h₀ : x = abs ⟨a, f⟩
h₁ : ∀ (i : (P F).B a), p (f i)
⊢ abs ((P F).map Subtype.val ⟨a, fun i => ⟨f i, ⋯⟩⟩) = abs ⟨a, f⟩
tactic: rw [← abs_map, h₀]
state_before: case h
F : Type u → Type u
q : QPF F
α : Type u
p : α → Prop
x : F α
a : (P F).A
f : (P F).B a → α
h₀ : x = abs ⟨a, f⟩
h₁ : ∀ (i : (P F).B a), p (f i)
⊢ abs ((P F).map Subtype.val ⟨a, fun i => ⟨f i, ⋯⟩⟩) = abs ⟨a, f⟩
state_after: no goals
tactic: rfl
Theorem: finprod_mem_mul_diff'
File: Mathlib/Algebra/BigOperators/Finprod.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
ι : Type u_3
G : Type u_4
M : Type u_5
N : Type u_6
inst✝¹ : CommMonoid M
inst✝ : CommMonoid N
f g : α → M
a b : α
s t : Set α
hst : s ⊆ t
ht : (t ∩ mulSupport f).Finite
⊢ (∏ᶠ (i : α) (_ : i ∈ s), f i) * ∏ᶠ (i : α) (_ : i ∈ t \ s), f i = ∏ᶠ (i : α) (_ : i ∈ t), f i
state_after: no goals
tactic: rw [← finprod_mem_inter_mul_diff' _ ht, inter_eq_self_of_subset_right hst]
Theorem: List.revzip_sublists'
File: Mathlib/Data/List/Sublists.lean

Proof steps:
state_before: α : Type u
β : Type v
γ : Type w
l : List α
⊢ ∀ (l₁ l₂ : List α), (l₁, l₂) ∈ l.sublists'.revzip → l₁ ++ l₂ ~ l
state_after: α : Type u
β : Type v
γ : Type w
l : List α
⊢ ∀ (l₁ l₂ : List α), (l₁, l₂) ∈ l.sublists'.zip l.sublists'.reverse → l₁ ++ l₂ ~ l
tactic: rw [revzip]
state_before: α : Type u
β : Type v
γ : Type w
l : List α
⊢ ∀ (l₁ l₂ : List α), (l₁, l₂) ∈ l.sublists'.zip l.sublists'.reverse → l₁ ++ l₂ ~ l
state_after: case nil
α : Type u
β : Type v
γ : Type w
l₁ l₂ : List α
h : (l₁, l₂) ∈ [].sublists'.zip [].sublists'.reverse
⊢ l₁ ++ l₂ ~ []

case cons
α : Type u
β : Type v
γ : Type w
a : α
l : List α
IH : ∀ (l₁ l₂ : List α), (l₁, l₂) ∈ l.sublists'.zip l.sublists'.reverse → l₁ ++ l₂ ~ l
l₁ l₂ : List α
h : (l₁, l₂) ∈ (a :: l).sublists'.zip (a :: l).sublists'.reverse
⊢ l₁ ++ l₂ ~ a :: l
tactic: induction' l with a l IH <;> intro l₁ l₂ h
Theorem: summable_pow_mul_jacobiTheta₂_term_bound
File: Mathlib/NumberTheory/ModularForms/JacobiTheta/TwoVariable.lean

Proof steps:
state_before: S T : ℝ
hT : 0 < T
k : ℕ
⊢ Summable fun n => ↑|n| ^ k * rexp (-π * (T * ↑n ^ 2 - 2 * S * ↑|n|))
state_after: S T : ℝ
hT : 0 < T
k : ℕ
⊢ Summable fun n => ↑n ^ k * rexp (-π * (T * ↑n ^ 2 - 2 * S * ↑n))
tactic: suffices Summable (fun n : ℕ ↦ (n ^ k : ℝ) * Real.exp (-π * (T * n ^ 2 - 2 * S * n))) by
    apply Summable.of_nat_of_neg <;>
    simpa only [Int.cast_neg, neg_sq, abs_neg, Int.cast_natCast, Nat.abs_cast]
state_before: S T : ℝ
hT : 0 < T
k : ℕ
⊢ Summable fun n => ↑n ^ k * rexp (-π * (T * ↑n ^ 2 - 2 * S * ↑n))
state_after: S T : ℝ
hT : 0 < T
k : ℕ
⊢ (fun n => ↑n ^ k * rexp (-π * (T * ↑n ^ 2 - 2 * S * ↑n))) =O[atTop] fun n => ↑n ^ k * rexp (-1 * ↑n)
tactic: apply summable_of_isBigO_nat (summable_pow_mul_exp_neg_nat_mul k zero_lt_one)
state_before: S T : ℝ
hT : 0 < T
k : ℕ
⊢ (fun n => ↑n ^ k * rexp (-π * (T * ↑n ^ 2 - 2 * S * ↑n))) =O[atTop] fun n => ↑n ^ k * rexp (-1 * ↑n)
state_after: S T : ℝ
hT : 0 < T
k : ℕ
⊢ (fun x => rexp (-π * (T * ↑x ^ 2 - 2 * S * ↑x))) =O[atTop] fun x => rexp (-1 * ↑x)
tactic: apply IsBigO.mul (isBigO_refl _ _)
state_before: S T : ℝ
hT : 0 < T
k : ℕ
⊢ (fun x => rexp (-π * (T * ↑x ^ 2 - 2 * S * ↑x))) =O[atTop] fun x => rexp (-1 * ↑x)
state_after: S T : ℝ
hT : 0 < T
k : ℕ
⊢ Tendsto ((fun x => -π * (T * ↑x ^ 2 - 2 * S * ↑x)) - fun x => -1 * ↑x) atTop atBot
tactic: refine Real.isBigO_exp_comp_exp_comp.mpr (Tendsto.isBoundedUnder_le_atBot ?_)
state_before: S T : ℝ
hT : 0 < T
k : ℕ
⊢ Tendsto ((fun x => -π * (T * ↑x ^ 2 - 2 * S * ↑x)) - fun x => -1 * ↑x) atTop atBot
state_after: S T : ℝ
hT : 0 < T
k : ℕ
⊢ Tendsto (fun x => -(-π * (T * ↑x ^ 2 - 2 * S * ↑x) - -1 * ↑x)) atTop atTop
tactic: simp_rw [← tendsto_neg_atTop_iff, Pi.sub_apply]
state_before: S T : ℝ
hT : 0 < T
k : ℕ
⊢ Tendsto (fun x => -(-π * (T * ↑x ^ 2 - 2 * S * ↑x) - -1 * ↑x)) atTop atTop
state_after: S T : ℝ
hT : 0 < T
k : ℕ
⊢ Tendsto (fun n => ↑n * (π * T * ↑n - (2 * π * S + 1))) atTop atTop
tactic: conv =>
    enter [1, n]
    rw [show -(-π * (T * n ^ 2 - 2 * S * n) - -1 * n) = n * (π * T * n - (2 * π * S + 1)) by ring]
state_before: S T : ℝ
hT : 0 < T
k : ℕ
⊢ Tendsto (fun n => ↑n * (π * T * ↑n - (2 * π * S + 1))) atTop atTop
state_after: S T : ℝ
hT : 0 < T
k : ℕ
⊢ Tendsto (fun n => π * T * ↑n) atTop atTop
tactic: refine tendsto_natCast_atTop_atTop.atTop_mul_atTop (tendsto_atTop_add_const_right _ _ ?_)
state_before: S T : ℝ
hT : 0 < T
k : ℕ
⊢ Tendsto (fun n => π * T * ↑n) atTop atTop
state_after: no goals
tactic: exact tendsto_natCast_atTop_atTop.const_mul_atTop (mul_pos pi_pos hT)
Theorem: Nat.maxPowDiv.le_of_dvd
File: Mathlib/Data/Nat/MaxPowDiv.lean

Proof steps:
state_before: p n pow : ℕ
hp : 1 < p
hn : 0 < n
h : p ^ pow ∣ n
⊢ pow ≤ p.maxPowDiv n
state_after: p n pow : ℕ
hp : 1 < p
hn : 0 < n
h : p ^ pow ∣ n
c : ℕ
hc : n = p ^ pow * c
⊢ pow ≤ p.maxPowDiv n
tactic: have ⟨c, hc⟩ := h
state_before: p n pow : ℕ
hp : 1 < p
hn : 0 < n
h : p ^ pow ∣ n
c : ℕ
hc : n = p ^ pow * c
⊢ pow ≤ p.maxPowDiv n
state_after: p n pow : ℕ
hp : 1 < p
hn : 0 < n
h : p ^ pow ∣ n
c : ℕ
hc : n = p ^ pow * c
this : 0 < c
⊢ pow ≤ p.maxPowDiv n
tactic: have : 0 < c := by
    apply Nat.pos_of_ne_zero
    intro h'
    rw [h',mul_zero] at hc
    exact not_eq_zero_of_lt hn hc
state_before: p n pow : ℕ
hp : 1 < p
hn : 0 < n
h : p ^ pow ∣ n
c : ℕ
hc : n = p ^ pow * c
this : 0 < c
⊢ pow ≤ p.maxPowDiv n
state_after: no goals
tactic: simp [hc, base_pow_mul hp this]
Theorem: CategoryTheory.ShortComplex.RightHomologyMapData.rightHomologyMap_comm
File: Mathlib/Algebra/Homology/ShortComplex/RightHomology.lean

Proof steps:
state_before: C : Type u_1
inst✝³ : Category.{u_2, u_1} C
inst✝² : HasZeroMorphisms C
S S₁ S₂ S₃ : ShortComplex C
φ : S₁ ⟶ S₂
h₁ : S₁.RightHomologyData
h₂ : S₂.RightHomologyData
γ : RightHomologyMapData φ h₁ h₂
inst✝¹ : S₁.HasRightHomology
inst✝ : S₂.HasRightHomology
⊢ rightHomologyMap φ ≫ h₂.rightHomologyIso.hom = h₁.rightHomologyIso.hom ≫ γ.φH
state_after: no goals
tactic: simp only [γ.rightHomologyMap_eq, assoc, Iso.inv_hom_id, comp_id]
Theorem: Real.range_cos_infinite
File: Mathlib/Analysis/SpecialFunctions/Trigonometric/Basic.lean

Proof steps:
state_before: ⊢ (range cos).Infinite
state_after: ⊢ (Icc (-1) 1).Infinite
tactic: rw [Real.range_cos]
state_before: ⊢ (Icc (-1) 1).Infinite
state_after: no goals
tactic: exact Icc_infinite (by norm_num)
Theorem: Nat.count_monotone
File: Mathlib/Data/Nat/Count.lean

Proof steps:
state_before: p : ℕ → Prop
inst✝ : DecidablePred p
n : ℕ
⊢ count p n ≤ count p (n + 1)
state_after: no goals
tactic: by_cases h : p n <;> simp [count_succ, h]
Theorem: ZMod.valMinAbs_eq_zero
File: Mathlib/Data/ZMod/Basic.lean

Proof steps:
state_before: m n✝ n : ℕ
x : ZMod n
⊢ x.valMinAbs = 0 ↔ x = 0
state_after: case zero
m n : ℕ
x : ZMod 0
⊢ x.valMinAbs = 0 ↔ x = 0

case succ
m n✝ n : ℕ
x : ZMod (n + 1)
⊢ x.valMinAbs = 0 ↔ x = 0
tactic: cases' n with n
state_before: case succ
m n✝ n : ℕ
x : ZMod (n + 1)
⊢ x.valMinAbs = 0 ↔ x = 0
state_after: case succ
m n✝ n : ℕ
x : ZMod (n + 1)
⊢ x.valMinAbs = valMinAbs 0 ↔ x = 0
tactic: rw [← valMinAbs_zero n.succ]
state_before: case succ
m n✝ n : ℕ
x : ZMod (n + 1)
⊢ x.valMinAbs = valMinAbs 0 ↔ x = 0
state_after: no goals
tactic: apply injective_valMinAbs.eq_iff
Theorem: Nat.eq_sq_add_sq_iff
File: Mathlib/NumberTheory/SumTwoSquares.lean

Proof steps:
state_before: n : ℕ
⊢ (∃ x y, n = x ^ 2 + y ^ 2) ↔ ∀ {q : ℕ}, Prime q → q % 4 = 3 → Even (padicValNat q n)
state_after: case inl

⊢ (∃ x y, 0 = x ^ 2 + y ^ 2) ↔ ∀ {q : ℕ}, Prime q → q % 4 = 3 → Even (padicValNat q 0)

case inr
n : ℕ
hn₀ : n > 0
⊢ (∃ x y, n = x ^ 2 + y ^ 2) ↔ ∀ {q : ℕ}, Prime q → q % 4 = 3 → Even (padicValNat q n)
tactic: rcases n.eq_zero_or_pos with (rfl | hn₀)
state_before: case inr
n : ℕ
hn₀ : n > 0
⊢ (∃ x y, n = x ^ 2 + y ^ 2) ↔ ∀ {q : ℕ}, Prime q → q % 4 = 3 → Even (padicValNat q n)
state_after: case inr
n : ℕ
hn₀ : n > 0
⊢ (∃ a b, n = a ^ 2 * b ∧ IsSquare (-1)) ↔ ∀ {q : ℕ}, Prime q → q % 4 = 3 → Even (padicValNat q n)
tactic: rw [Nat.eq_sq_add_sq_iff_eq_sq_mul]
state_before: case inr
n : ℕ
hn₀ : n > 0
⊢ (∃ a b, n = a ^ 2 * b ∧ IsSquare (-1)) ↔ ∀ {q : ℕ}, Prime q → q % 4 = 3 → Even (padicValNat q n)
state_after: case inr.refine_1
n : ℕ
hn₀ : n > 0
H : ∃ a b, n = a ^ 2 * b ∧ IsSquare (-1)
q : ℕ
hq : Prime q
h : q % 4 = 3
⊢ Even (padicValNat q n)

case inr.refine_2
n : ℕ
hn₀ : n > 0
H : ∀ {q : ℕ}, Prime q → q % 4 = 3 → Even (padicValNat q n)
⊢ ∃ a b, n = a ^ 2 * b ∧ IsSquare (-1)
tactic: refine ⟨fun H q hq h => ?_, fun H => ?_⟩
Theorem: GaussianInt.toComplex_div_re
File: Mathlib/NumberTheory/Zsqrtd/GaussianInt.lean

Proof steps:
state_before: x y : ℤ[i]
⊢ (toComplex (x / y)).re = ↑(round (toComplex x / toComplex y).re)
state_after: x y : ℤ[i]
⊢ (toComplex { re := round ↑(↑(x * star y).re / ↑(norm y)), im := round (↑(x * star y).im / ↑(norm y)) }).re =
    ↑(round (toComplex x / toComplex y).re)
tactic: rw [div_def, ← @Rat.round_cast ℝ _ _]
state_before: x y : ℤ[i]
⊢ (toComplex { re := round ↑(↑(x * star y).re / ↑(norm y)), im := round (↑(x * star y).im / ↑(norm y)) }).re =
    ↑(round (toComplex x / toComplex y).re)
state_after: no goals
tactic: simp [-Rat.round_cast, mul_assoc, div_eq_mul_inv, mul_add, add_mul]
Theorem: AddSubgroup.disjoint_iff_add_eq_zero
File: Mathlib/Algebra/Group/Subgroup/Basic.lean

Proof steps:
state_before: G : Type u_1
G' : Type u_2
G'' : Type u_3
inst✝⁴ : Group G
inst✝³ : Group G'
inst✝² : Group G''
A : Type u_4
inst✝¹ : AddGroup A
N : Type u_5
inst✝ : Group N
H₁ H₂ : Subgroup G
h : ∀ {x y : G}, x ∈ H₁ → y ∈ H₂ → x = y → x = 1
x y : G
hx : x ∈ H₁
hy : y ∈ H₂
hxy : x * y = 1
hx1 : x = 1 := h hx (Subgroup.inv_mem H₂ hy) (eq_inv_iff_mul_eq_one.mpr hxy)
⊢ y = 1
state_after: no goals
tactic: simpa [hx1] using hxy
Theorem: linearIndependent_subtype
File: Mathlib/LinearAlgebra/LinearIndependent.lean

Proof steps:
state_before: ι : Type u'
ι' : Type u_1
R : Type u_2
K : Type u_3
M : Type u_4
M' : Type u_5
M'' : Type u_6
V : Type u
V' : Type u_7
v : ι → M
inst✝⁶ : Semiring R
inst✝⁵ : AddCommMonoid M
inst✝⁴ : AddCommMonoid M'
inst✝³ : AddCommMonoid M''
inst✝² : Module R M
inst✝¹ : Module R M'
inst✝ : Module R M''
a b : R
x y : M
s : Set M
⊢ (LinearIndependent R fun (x : ↑s) => ↑x) ↔ ∀ l ∈ Finsupp.supported R R s, (Finsupp.total M M R id) l = 0 → l = 0
state_after: no goals
tactic: apply linearIndependent_comp_subtype (v := id)
Theorem: Nat.card_fintypeIio
File: Mathlib/Order/Interval/Finset/Nat.lean

Proof steps:
state_before: a b c : ℕ
⊢ Fintype.card ↑(Set.Iio b) = b
state_after: no goals
tactic: rw [Fintype.card_ofFinset, card_Iio]
Theorem: mem_memPartitionSet
File: Mathlib/Data/Set/MemPartition.lean

Proof steps:
state_before: α : Type u_1
f : ℕ → Set α
n : ℕ
a : α
⊢ a ∈ memPartitionSet f n a
state_after: no goals
tactic: induction n with
  | zero => simp [memPartitionSet]
  | succ n ih =>
    classical
    rw [memPartitionSet_succ]
    split_ifs with h <;> exact ⟨ih, h⟩
Theorem: CompHaus.finiteCoproduct.ι_injective
File: Mathlib/Topology/Category/CompHaus/Limits.lean

Proof steps:
state_before: α : Type w
inst✝ : Finite α
X : α → CompHaus
a : α
⊢ Function.Injective ⇑(ι X a)
state_after: α : Type w
inst✝ : Finite α
X : α → CompHaus
a : α
x y : (forget CompHaus).obj (X a)
hxy : (ι X a) x = (ι X a) y
⊢ x = y
tactic: intro x y hxy
state_before: α : Type w
inst✝ : Finite α
X : α → CompHaus
a : α
x y : (forget CompHaus).obj (X a)
hxy : (ι X a) x = (ι X a) y
⊢ x = y
state_after: no goals
tactic: exact eq_of_heq (Sigma.ext_iff.mp hxy).2