1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: Nat.cast_pow
File: Mathlib/Data/Nat/Cast/Basic.lean

tactic: simp
state_before: α : Type u_1
β : Type u_2
inst✝ : Semiring α
m✝ n m : ℕ
⊢ ↑(m ^ 0) = ↑m ^ 0
state_after: no goals

tactic: rw [_root_.pow_succ', _root_.pow_succ', cast_mul, cast_pow m n]
state_before: α : Type u_1
β : Type u_2
inst✝ : Semiring α
m✝ n✝ m n : ℕ
⊢ ↑(m ^ (n + 1)) = ↑m ^ (n + 1)
state_after: no goals
Theorem: inv_pos
File: Mathlib/Algebra/Order/Field/Defs.lean

tactic: simp [ne_of_gt ha, zero_lt_one]
state_before: α : Type u_1
inst✝ : LinearOrderedSemifield α
a✝ b a : α
ha : 0 < a
⊢ a * 0 < a * a⁻¹
state_after: no goals
Theorem: LaurentPolynomial.induction_on'
File: Mathlib/Algebra/Polynomial/Laurent.lean

tactic: refine p.induction_on (fun a => ?_) (fun {p q} => h_add p q) ?_ ?_ <;>
    try exact fun n f _ => h_C_mul_T _ f
state_before: R : Type u_1
inst✝ : Semiring R
M : R[T;T⁻¹] → Prop
p : R[T;T⁻¹]
h_add : ∀ (p q : R[T;T⁻¹]), M p → M q → M (p + q)
h_C_mul_T : ∀ (n : ℤ) (a : R), M (C a * T n)
⊢ M p
state_after: case refine_1
R : Type u_1
inst✝ : Semiring R
M : R[T;T⁻¹] → Prop
p : R[T;T⁻¹]
h_add : ∀ (p q : R[T;T⁻¹]), M p → M q → M (p + q)
h_C_mul_T : ∀ (n : ℤ) (a : R), M (C a * T n)
a : R
⊢ M (C a)

tactic: convert h_C_mul_T 0 a
state_before: case refine_1
R : Type u_1
inst✝ : Semiring R
M : R[T;T⁻¹] → Prop
p : R[T;T⁻¹]
h_add : ∀ (p q : R[T;T⁻¹]), M p → M q → M (p + q)
h_C_mul_T : ∀ (n : ℤ) (a : R), M (C a * T n)
a : R
⊢ M (C a)
state_after: case h.e'_1
R : Type u_1
inst✝ : Semiring R
M : R[T;T⁻¹] → Prop
p : R[T;T⁻¹]
h_add : ∀ (p q : R[T;T⁻¹]), M p → M q → M (p + q)
h_C_mul_T : ∀ (n : ℤ) (a : R), M (C a * T n)
a : R
⊢ C a = C a * T 0

tactic: exact (mul_one _).symm
state_before: case h.e'_1
R : Type u_1
inst✝ : Semiring R
M : R[T;T⁻¹] → Prop
p : R[T;T⁻¹]
h_add : ∀ (p q : R[T;T⁻¹]), M p → M q → M (p + q)
h_C_mul_T : ∀ (n : ℤ) (a : R), M (C a * T n)
a : R
⊢ C a = C a * T 0
state_after: no goals

tactic: exact fun n f _ => h_C_mul_T _ f
state_before: case refine_3
R : Type u_1
inst✝ : Semiring R
M : R[T;T⁻¹] → Prop
p : R[T;T⁻¹]
h_add : ∀ (p q : R[T;T⁻¹]), M p → M q → M (p + q)
h_C_mul_T : ∀ (n : ℤ) (a : R), M (C a * T n)
⊢ ∀ (n : ℕ) (a : R), M (C a * T (-↑n)) → M (C a * T (-↑n - 1))
state_after: no goals
Theorem: FirstOrder.Language.Hom.range_eq_top
File: Mathlib/ModelTheory/Substructures.lean

tactic: rw [SetLike.ext'_iff, range_coe, coe_top, Set.range_iff_surjective]
state_before: L : Language
M : Type w
N : Type u_1
P : Type u_2
inst✝² : L.Structure M
inst✝¹ : L.Structure N
inst✝ : L.Structure P
S : L.Substructure M
f : M →[L] N
⊢ f.range = ⊤ ↔ Function.Surjective ⇑f
state_after: no goals
Theorem: CategoryTheory.Functor.leftDerived_map_eq
File: Mathlib/CategoryTheory/Abelian/LeftDerived.lean

tactic: rw [← cancel_mono (Q.isoLeftDerivedObj F n).hom,
  ProjectiveResolution.isoLeftDerivedObj_hom_naturality f P Q g _ F n,
  assoc, assoc, Iso.inv_hom_id, comp_id]
state_before: C : Type u
inst✝⁵ : Category.{v, u} C
D : Type u_1
inst✝⁴ : Category.{u_2, u_1} D
inst✝³ : Abelian C
inst✝² : HasProjectiveResolutions C
inst✝¹ : Abelian D
F : C ⥤ D
inst✝ : F.Additive
n : ℕ
X Y : C
f : X ⟶ Y
P : ProjectiveResolution X
Q : ProjectiveResolution Y
g : P.complex ⟶ Q.complex
w : g ≫ Q.π = P.π ≫ (ChainComplex.single₀ C).map f
⊢ (F.leftDerived n).map f =
    (P.isoLeftDerivedObj F n).hom ≫
      (F.mapHomologicalComplex (ComplexShape.down ℕ) ⋙ HomologicalComplex.homologyFunctor D (ComplexShape.down ℕ) n).map
          g ≫
        (Q.isoLeftDerivedObj F n).inv
state_after: C : Type u
inst✝⁵ : Category.{v, u} C
D : Type u_1
inst✝⁴ : Category.{u_2, u_1} D
inst✝³ : Abelian C
inst✝² : HasProjectiveResolutions C
inst✝¹ : Abelian D
F : C ⥤ D
inst✝ : F.Additive
n : ℕ
X Y : C
f : X ⟶ Y
P : ProjectiveResolution X
Q : ProjectiveResolution Y
g : P.complex ⟶ Q.complex
w : g ≫ Q.π = P.π ≫ (ChainComplex.single₀ C).map f
⊢ g.f 0 ≫ Q.π.f 0 = P.π.f 0 ≫ f

tactic: rw [← HomologicalComplex.comp_f, w, HomologicalComplex.comp_f,
  ChainComplex.single₀_map_f_zero]
state_before: C : Type u
inst✝⁵ : Category.{v, u} C
D : Type u_1
inst✝⁴ : Category.{u_2, u_1} D
inst✝³ : Abelian C
inst✝² : HasProjectiveResolutions C
inst✝¹ : Abelian D
F : C ⥤ D
inst✝ : F.Additive
n : ℕ
X Y : C
f : X ⟶ Y
P : ProjectiveResolution X
Q : ProjectiveResolution Y
g : P.complex ⟶ Q.complex
w : g ≫ Q.π = P.π ≫ (ChainComplex.single₀ C).map f
⊢ g.f 0 ≫ Q.π.f 0 = P.π.f 0 ≫ f
state_after: no goals
Theorem: Finset.prod_mul_distrib
File: Mathlib/Algebra/BigOperators/Group/Finset.lean

tactic: rw [one_mul]
state_before: ι : Type u_1
κ : Type u_2
α : Type u_3
β : Type u_4
γ : Type u_5
s s₁ s₂ : Finset α
a : α
f g : α → β
inst✝ : CommMonoid β
⊢ ∏ x ∈ s, f x * g x = fold (fun x x_1 => x * x_1) (1 * 1) (fun x => f x * g x) s
state_after: ι : Type u_1
κ : Type u_2
α : Type u_3
β : Type u_4
γ : Type u_5
s s₁ s₂ : Finset α
a : α
f g : α → β
inst✝ : CommMonoid β
⊢ ∏ x ∈ s, f x * g x = fold (fun x x_1 => x * x_1) 1 (fun x => f x * g x) s

tactic: rfl
state_before: ι : Type u_1
κ : Type u_2
α : Type u_3
β : Type u_4
γ : Type u_5
s s₁ s₂ : Finset α
a : α
f g : α → β
inst✝ : CommMonoid β
⊢ ∏ x ∈ s, f x * g x = fold (fun x x_1 => x * x_1) 1 (fun x => f x * g x) s
state_after: no goals
Theorem: List.Perm.kreplace
File: Mathlib/Data/List/Sigma.lean

tactic: refine nd.pairwise_ne.imp ?_
state_before: α : Type u
β : α → Type v
l l₁✝ l₂✝ : List (Sigma β)
inst✝ : DecidableEq α
a : α
b : β a
l₁ l₂ : List (Sigma β)
nd : l₁.NodupKeys
⊢ Pairwise
    (fun a_1 b_1 =>
      ∀ c ∈ if a = a_1.fst then some ⟨a, b⟩ else none,
        ∀ d ∈ if a = b_1.fst then some ⟨a, b⟩ else none, a_1 = b_1 ∧ c = d)
    l₁
state_after: α : Type u
β : α → Type v
l l₁✝ l₂✝ : List (Sigma β)
inst✝ : DecidableEq α
a : α
b : β a
l₁ l₂ : List (Sigma β)
nd : l₁.NodupKeys
⊢ ∀ {a_1 b_1 : Sigma β},
    a_1.fst ≠ b_1.fst →
      ∀ c ∈ if a = a_1.fst then some ⟨a, b⟩ else none,
        ∀ d ∈ if a = b_1.fst then some ⟨a, b⟩ else none, a_1 = b_1 ∧ c = d

tactic: intro x y h z h₁ w h₂
state_before: α : Type u
β : α → Type v
l l₁✝ l₂✝ : List (Sigma β)
inst✝ : DecidableEq α
a : α
b : β a
l₁ l₂ : List (Sigma β)
nd : l₁.NodupKeys
⊢ ∀ {a_1 b_1 : Sigma β},
    a_1.fst ≠ b_1.fst →
      ∀ c ∈ if a = a_1.fst then some ⟨a, b⟩ else none,
        ∀ d ∈ if a = b_1.fst then some ⟨a, b⟩ else none, a_1 = b_1 ∧ c = d
state_after: α : Type u
β : α → Type v
l l₁✝ l₂✝ : List (Sigma β)
inst✝ : DecidableEq α
a : α
b : β a
l₁ l₂ : List (Sigma β)
nd : l₁.NodupKeys
x y : Sigma β
h : x.fst ≠ y.fst
z : Sigma β
h₁ : z ∈ if a = x.fst then some ⟨a, b⟩ else none
w : Sigma β
h₂ : w ∈ if a = y.fst then some ⟨a, b⟩ else none
⊢ x = y ∧ z = w

tactic: split_ifs at h₁ h₂ with h_2 h_1 <;> cases h₁ <;> cases h₂
state_before: α : Type u
β : α → Type v
l l₁✝ l₂✝ : List (Sigma β)
inst✝ : DecidableEq α
a : α
b : β a
l₁ l₂ : List (Sigma β)
nd : l₁.NodupKeys
x y : Sigma β
h : x.fst ≠ y.fst
z : Sigma β
h₁ : z ∈ if a = x.fst then some ⟨a, b⟩ else none
w : Sigma β
h₂ : w ∈ if a = y.fst then some ⟨a, b⟩ else none
⊢ x = y ∧ z = w
state_after: case pos.refl.refl
α : Type u
β : α → Type v
l l₁✝ l₂✝ : List (Sigma β)
inst✝ : DecidableEq α
a : α
b : β a
l₁ l₂ : List (Sigma β)
nd : l₁.NodupKeys
x y : Sigma β
h : x.fst ≠ y.fst
h_2 : a = x.fst
h_1 : a = y.fst
⊢ x = y ∧ ⟨a, b⟩ = ⟨a, b⟩

tactic: exact (h (h_2.symm.trans h_1)).elim
state_before: case pos.refl.refl
α : Type u
β : α → Type v
l l₁✝ l₂✝ : List (Sigma β)
inst✝ : DecidableEq α
a : α
b : β a
l₁ l₂ : List (Sigma β)
nd : l₁.NodupKeys
x y : Sigma β
h : x.fst ≠ y.fst
h_2 : a = x.fst
h_1 : a = y.fst
⊢ x = y ∧ ⟨a, b⟩ = ⟨a, b⟩
state_after: no goals
Theorem: contDiffOn_succ_iff_fderiv_of_isOpen
File: Mathlib/Analysis/Calculus/ContDiff/Defs.lean

tactic: rw [contDiffOn_succ_iff_fderivWithin hs.uniqueDiffOn]
state_before: 𝕜 : Type u
inst✝⁸ : NontriviallyNormedField 𝕜
E : Type uE
inst✝⁷ : NormedAddCommGroup E
inst✝⁶ : NormedSpace 𝕜 E
F : Type uF
inst✝⁵ : NormedAddCommGroup F
inst✝⁴ : NormedSpace 𝕜 F
G : Type uG
inst✝³ : NormedAddCommGroup G
inst✝² : NormedSpace 𝕜 G
X : Type uX
inst✝¹ : NormedAddCommGroup X
inst✝ : NormedSpace 𝕜 X
s s₁ t u : Set E
f f₁ : E → F
g : F → G
x x₀ : E
c : F
m n✝ : ℕ∞
p : E → FormalMultilinearSeries 𝕜 E F
n : ℕ
hs : IsOpen s
⊢ ContDiffOn 𝕜 (↑(n + 1)) f s ↔ DifferentiableOn 𝕜 f s ∧ ContDiffOn 𝕜 (↑n) (fun y => fderiv 𝕜 f y) s
state_after: 𝕜 : Type u
inst✝⁸ : NontriviallyNormedField 𝕜
E : Type uE
inst✝⁷ : NormedAddCommGroup E
inst✝⁶ : NormedSpace 𝕜 E
F : Type uF
inst✝⁵ : NormedAddCommGroup F
inst✝⁴ : NormedSpace 𝕜 F
G : Type uG
inst✝³ : NormedAddCommGroup G
inst✝² : NormedSpace 𝕜 G
X : Type uX
inst✝¹ : NormedAddCommGroup X
inst✝ : NormedSpace 𝕜 X
s s₁ t u : Set E
f f₁ : E → F
g : F → G
x x₀ : E
c : F
m n✝ : ℕ∞
p : E → FormalMultilinearSeries 𝕜 E F
n : ℕ
hs : IsOpen s
⊢ DifferentiableOn 𝕜 f s ∧ ContDiffOn 𝕜 (↑n) (fun y => fderivWithin 𝕜 f s y) s ↔
    DifferentiableOn 𝕜 f s ∧ ContDiffOn 𝕜 (↑n) (fun y => fderiv 𝕜 f y) s

tactic: exact Iff.rfl.and (contDiffOn_congr fun x hx ↦ fderivWithin_of_isOpen hs hx)
state_before: 𝕜 : Type u
inst✝⁸ : NontriviallyNormedField 𝕜
E : Type uE
inst✝⁷ : NormedAddCommGroup E
inst✝⁶ : NormedSpace 𝕜 E
F : Type uF
inst✝⁵ : NormedAddCommGroup F
inst✝⁴ : NormedSpace 𝕜 F
G : Type uG
inst✝³ : NormedAddCommGroup G
inst✝² : NormedSpace 𝕜 G
X : Type uX
inst✝¹ : NormedAddCommGroup X
inst✝ : NormedSpace 𝕜 X
s s₁ t u : Set E
f f₁ : E → F
g : F → G
x x₀ : E
c : F
m n✝ : ℕ∞
p : E → FormalMultilinearSeries 𝕜 E F
n : ℕ
hs : IsOpen s
⊢ DifferentiableOn 𝕜 f s ∧ ContDiffOn 𝕜 (↑n) (fun y => fderivWithin 𝕜 f s y) s ↔
    DifferentiableOn 𝕜 f s ∧ ContDiffOn 𝕜 (↑n) (fun y => fderiv 𝕜 f y) s
state_after: no goals
Theorem: Finset.weightedVSub_apply_const
File: Mathlib/LinearAlgebra/AffineSpace/Combination.lean

tactic: rw [weightedVSub, weightedVSubOfPoint_apply_const, h, zero_smul]
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 ι₂
w : ι → k
p : P
h : ∑ i ∈ s, w i = 0
⊢ (s.weightedVSub fun x => p) w = 0
state_after: no goals
Theorem: filter_collapse_eq
File: Mathlib/Combinatorics/SetFamily/FourFunctions.lean

tactic: ext t
state_before: α : Type u_1
β : Type u_2
inst✝² : DecidableEq α
inst✝¹ : LinearOrderedCommSemiring β
inst✝ : ExistsAddOfLE β
𝒜✝ ℬ : Finset (Finset α)
a : α
f f₁ f₂ f₃ f₄ g μ : Finset α → β
s t u : Finset α
ha : a ∉ s
𝒜 : Finset (Finset α)
⊢ filter (fun t => t.erase a = s) 𝒜 =
    if s ∈ 𝒜 then if insert a s ∈ 𝒜 then {s, insert a s} else {s} else if insert a s ∈ 𝒜 then {insert a s} else ∅
state_after: case a
α : Type u_1
β : Type u_2
inst✝² : DecidableEq α
inst✝¹ : LinearOrderedCommSemiring β
inst✝ : ExistsAddOfLE β
𝒜✝ ℬ : Finset (Finset α)
a : α
f f₁ f₂ f₃ f₄ g μ : Finset α → β
s t✝ u : Finset α
ha : a ∉ s
𝒜 : Finset (Finset α)
t : Finset α
⊢ t ∈ filter (fun t => t.erase a = s) 𝒜 ↔
    t ∈ if s ∈ 𝒜 then if insert a s ∈ 𝒜 then {s, insert a s} else {s} else if insert a s ∈ 𝒜 then {insert a s} else ∅

tactic: split_ifs <;> simp [erase_eq_iff ha] <;> aesop
state_before: case a
α : Type u_1
β : Type u_2
inst✝² : DecidableEq α
inst✝¹ : LinearOrderedCommSemiring β
inst✝ : ExistsAddOfLE β
𝒜✝ ℬ : Finset (Finset α)
a : α
f f₁ f₂ f₃ f₄ g μ : Finset α → β
s t✝ u : Finset α
ha : a ∉ s
𝒜 : Finset (Finset α)
t : Finset α
⊢ t ∈ filter (fun t => t.erase a = s) 𝒜 ↔
    t ∈ if s ∈ 𝒜 then if insert a s ∈ 𝒜 then {s, insert a s} else {s} else if insert a s ∈ 𝒜 then {insert a s} else ∅
state_after: no goals
Theorem: dense_pi
File: Mathlib/Topology/ContinuousOn.lean

tactic: simp only [dense_iff_closure_eq, closure_pi_set, pi_congr rfl fun i hi => (hs i hi).closure_eq,
  pi_univ]
state_before: α✝ : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
inst✝² : TopologicalSpace α✝
ι✝ : Type u_5
π : ι✝ → Type u_6
inst✝¹ : (i : ι✝) → TopologicalSpace (π i)
ι : Type u_7
α : ι → Type u_8
inst✝ : (i : ι) → TopologicalSpace (α i)
s : (i : ι) → Set (α i)
I : Set ι
hs : ∀ i ∈ I, Dense (s i)
⊢ Dense (I.pi s)
state_after: no goals
Theorem: toIocMod_add_right_eq_add
File: Mathlib/Algebra/Order/ToIntervalMod.lean

tactic: simp_rw [toIocMod, toIocDiv_sub_eq_toIocDiv_add', sub_add_eq_add_sub]
state_before: α : Type u_1
inst✝ : LinearOrderedAddCommGroup α
hα : Archimedean α
p : α
hp : 0 < p
a✝ b✝ c✝ : α
n : ℤ
a b c : α
⊢ toIocMod hp a (b + c) = toIocMod hp (a - c) b + c
state_after: no goals
Theorem: FormalMultilinearSeries.changeOriginSeries_summable_aux₂
File: Mathlib/Analysis/Analytic/Basic.lean

tactic: rcases ENNReal.lt_iff_exists_add_pos_lt.1 hr with ⟨r', h0, hr'⟩
state_before: 𝕜 : Type u_1
E : Type u_2
F : Type u_3
G : Type u_4
inst✝⁶ : NontriviallyNormedField 𝕜
inst✝⁵ : NormedAddCommGroup E
inst✝⁴ : NormedSpace 𝕜 E
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
inst✝¹ : NormedAddCommGroup G
inst✝ : NormedSpace 𝕜 G
p : FormalMultilinearSeries 𝕜 E F
x y : E
r R : ℝ≥0
hr : ↑r < p.radius
k : ℕ
⊢ Summable fun s => ‖p (k + s.fst)‖₊ * r ^ s.fst
state_after: case intro.intro
𝕜 : Type u_1
E : Type u_2
F : Type u_3
G : Type u_4
inst✝⁶ : NontriviallyNormedField 𝕜
inst✝⁵ : NormedAddCommGroup E
inst✝⁴ : NormedSpace 𝕜 E
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
inst✝¹ : NormedAddCommGroup G
inst✝ : NormedSpace 𝕜 G
p : FormalMultilinearSeries 𝕜 E F
x y : E
r R : ℝ≥0
hr : ↑r < p.radius
k : ℕ
r' : ℝ≥0
h0 : 0 < r'
hr' : ↑r + ↑r' < p.radius
⊢ Summable fun s => ‖p (k + s.fst)‖₊ * r ^ s.fst

tactic: simpa only [mul_inv_cancel_right₀ (pow_pos h0 _).ne'] using
  ((NNReal.summable_sigma.1 (p.changeOriginSeries_summable_aux₁ hr')).1 k).mul_right (r' ^ k)⁻¹
state_before: case intro.intro
𝕜 : Type u_1
E : Type u_2
F : Type u_3
G : Type u_4
inst✝⁶ : NontriviallyNormedField 𝕜
inst✝⁵ : NormedAddCommGroup E
inst✝⁴ : NormedSpace 𝕜 E
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
inst✝¹ : NormedAddCommGroup G
inst✝ : NormedSpace 𝕜 G
p : FormalMultilinearSeries 𝕜 E F
x y : E
r R : ℝ≥0
hr : ↑r < p.radius
k : ℕ
r' : ℝ≥0
h0 : 0 < r'
hr' : ↑r + ↑r' < p.radius
⊢ Summable fun s => ‖p (k + s.fst)‖₊ * r ^ s.fst
state_after: no goals
Theorem: Polynomial.content_C_mul
File: Mathlib/RingTheory/Polynomial/Content.lean

tactic: by_cases h0 : r = 0
state_before: R : Type u_1
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : NormalizedGCDMonoid R
r : R
p : R[X]
⊢ (C r * p).content = normalize r * p.content
state_after: case pos
R : Type u_1
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : NormalizedGCDMonoid R
r : R
p : R[X]
h0 : r = 0
⊢ (C r * p).content = normalize r * p.content

case neg
R : Type u_1
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : NormalizedGCDMonoid R
r : R
p : R[X]
h0 : ¬r = 0
⊢ (C r * p).content = normalize r * p.content

tactic: rw [content]
state_before: case neg
R : Type u_1
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : NormalizedGCDMonoid R
r : R
p : R[X]
h0 : ¬r = 0
⊢ (C r * p).content = normalize r * p.content
state_after: case neg
R : Type u_1
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : NormalizedGCDMonoid R
r : R
p : R[X]
h0 : ¬r = 0
⊢ (C r * p).support.gcd (C r * p).coeff = normalize r * p.content

tactic: rw [content]
state_before: case neg
R : Type u_1
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : NormalizedGCDMonoid R
r : R
p : R[X]
h0 : ¬r = 0
⊢ (C r * p).support.gcd (C r * p).coeff = normalize r * p.content
state_after: case neg
R : Type u_1
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : NormalizedGCDMonoid R
r : R
p : R[X]
h0 : ¬r = 0
⊢ (C r * p).support.gcd (C r * p).coeff = normalize r * p.support.gcd p.coeff

tactic: rw [← Finset.gcd_mul_left]
state_before: case neg
R : Type u_1
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : NormalizedGCDMonoid R
r : R
p : R[X]
h0 : ¬r = 0
⊢ (C r * p).support.gcd (C r * p).coeff = normalize r * p.support.gcd p.coeff
state_after: case neg
R : Type u_1
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : NormalizedGCDMonoid R
r : R
p : R[X]
h0 : ¬r = 0
⊢ (C r * p).support.gcd (C r * p).coeff = p.support.gcd fun x => r * p.coeff x

tactic: refine congr (congr rfl ?_) ?_ <;> ext <;> simp [h0, mem_support_iff]
state_before: case neg
R : Type u_1
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : NormalizedGCDMonoid R
r : R
p : R[X]
h0 : ¬r = 0
⊢ (C r * p).support.gcd (C r * p).coeff = p.support.gcd fun x => r * p.coeff x
state_after: no goals

tactic: simp [h0]
state_before: case pos
R : Type u_1
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : NormalizedGCDMonoid R
r : R
p : R[X]
h0 : r = 0
⊢ (C r * p).content = normalize r * p.content
state_after: no goals
Theorem: CategoryTheory.Functor.OfSequence.map_le_succ
File: Mathlib/CategoryTheory/Functor/OfSequence.lean

tactic: omega
state_before: C : Type u_1
inst✝ : Category.{?u.3521, u_1} C
X : ℕ → C
f : (n : ℕ) → X n ⟶ X (n + 1)
i : ℕ
⊢ i ≤ i + 1
state_after: no goals

tactic: revert X f
state_before: C : Type u_1
inst✝ : Category.{u_2, u_1} C
X : ℕ → C
f : (n : ℕ) → X n ⟶ X (n + 1)
i : ℕ
⊢ map f i (i + 1) ⋯ = f i
state_after: C : Type u_1
inst✝ : Category.{u_2, u_1} C
i : ℕ
⊢ ∀ {X : ℕ → C} (f : (n : ℕ) → X n ⟶ X (n + 1)), map f i (i + 1) ⋯ = f i

tactic: induction i with
| zero => intros; rfl
| succ _ hi =>
    intro X f
    apply hi
state_before: C : Type u_1
inst✝ : Category.{u_2, u_1} C
i : ℕ
⊢ ∀ {X : ℕ → C} (f : (n : ℕ) → X n ⟶ X (n + 1)), map f i (i + 1) ⋯ = f i
state_after: no goals

tactic: intros
state_before: case zero
C : Type u_1
inst✝ : Category.{u_2, u_1} C
⊢ ∀ {X : ℕ → C} (f : (n : ℕ) → X n ⟶ X (n + 1)), map f 0 (0 + 1) ⋯ = f 0
state_after: case zero
C : Type u_1
inst✝ : Category.{u_2, u_1} C
X✝ : ℕ → C
f✝ : (n : ℕ) → X✝ n ⟶ X✝ (n + 1)
⊢ map f✝ 0 (0 + 1) ⋯ = f✝ 0

tactic: rfl
state_before: case zero
C : Type u_1
inst✝ : Category.{u_2, u_1} C
X✝ : ℕ → C
f✝ : (n : ℕ) → X✝ n ⟶ X✝ (n + 1)
⊢ map f✝ 0 (0 + 1) ⋯ = f✝ 0
state_after: no goals

tactic: intro X f
state_before: case succ
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n✝ : ℕ
hi : ∀ {X : ℕ → C} (f : (n : ℕ) → X n ⟶ X (n + 1)), map f n✝ (n✝ + 1) ⋯ = f n✝
⊢ ∀ {X : ℕ → C} (f : (n : ℕ) → X n ⟶ X (n + 1)), map f (n✝ + 1) (n✝ + 1 + 1) ⋯ = f (n✝ + 1)
state_after: case succ
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n✝ : ℕ
hi : ∀ {X : ℕ → C} (f : (n : ℕ) → X n ⟶ X (n + 1)), map f n✝ (n✝ + 1) ⋯ = f n✝
X : ℕ → C
f : (n : ℕ) → X n ⟶ X (n + 1)
⊢ map f (n✝ + 1) (n✝ + 1 + 1) ⋯ = f (n✝ + 1)

tactic: apply hi
state_before: case succ
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n✝ : ℕ
hi : ∀ {X : ℕ → C} (f : (n : ℕ) → X n ⟶ X (n + 1)), map f n✝ (n✝ + 1) ⋯ = f n✝
X : ℕ → C
f : (n : ℕ) → X n ⟶ X (n + 1)
⊢ map f (n✝ + 1) (n✝ + 1 + 1) ⋯ = f (n✝ + 1)
state_after: no goals
Theorem: ProbabilityTheory.kernel.ae_compProd_of_ae_ae
File: Mathlib/Probability/Kernel/Composition.lean

tactic: simp_rw [ae_iff] at h ⊢
state_before: α : Type u_1
β : Type u_2
ι : Type u_3
mα : MeasurableSpace α
mβ : MeasurableSpace β
γ : Type u_4
mγ : MeasurableSpace γ
s : Set (β × γ)
κ : ↥(kernel α β)
inst✝¹ : IsSFiniteKernel κ
η : ↥(kernel (α × β) γ)
inst✝ : IsSFiniteKernel η
a : α
p : β × γ → Prop
hp : MeasurableSet {x | p x}
h : ∀ᵐ (b : β) ∂κ a, ∀ᵐ (c : γ) ∂η (a, b), p (b, c)
⊢ ∀ᵐ (bc : β × γ) ∂(κ ⊗ₖ η) a, p bc
state_after: α : Type u_1
β : Type u_2
ι : Type u_3
mα : MeasurableSpace α
mβ : MeasurableSpace β
γ : Type u_4
mγ : MeasurableSpace γ
s : Set (β × γ)
κ : ↥(kernel α β)
inst✝¹ : IsSFiniteKernel κ
η : ↥(kernel (α × β) γ)
inst✝ : IsSFiniteKernel η
a : α
p : β × γ → Prop
hp : MeasurableSet {x | p x}
h : (κ a) {a_1 | ¬(η (a, a_1)) {a | ¬p (a_1, a)} = 0} = 0
⊢ ((κ ⊗ₖ η) a) {a | ¬p a} = 0

tactic: rw [compProd_null]
state_before: α : Type u_1
β : Type u_2
ι : Type u_3
mα : MeasurableSpace α
mβ : MeasurableSpace β
γ : Type u_4
mγ : MeasurableSpace γ
s : Set (β × γ)
κ : ↥(kernel α β)
inst✝¹ : IsSFiniteKernel κ
η : ↥(kernel (α × β) γ)
inst✝ : IsSFiniteKernel η
a : α
p : β × γ → Prop
hp : MeasurableSet {x | p x}
h : (κ a) {a_1 | ¬(η (a, a_1)) {a | ¬p (a_1, a)} = 0} = 0
⊢ ((κ ⊗ₖ η) a) {a | ¬p a} = 0
state_after: α : Type u_1
β : Type u_2
ι : Type u_3
mα : MeasurableSpace α
mβ : MeasurableSpace β
γ : Type u_4
mγ : MeasurableSpace γ
s : Set (β × γ)
κ : ↥(kernel α β)
inst✝¹ : IsSFiniteKernel κ
η : ↥(kernel (α × β) γ)
inst✝ : IsSFiniteKernel η
a : α
p : β × γ → Prop
hp : MeasurableSet {x | p x}
h : (κ a) {a_1 | ¬(η (a, a_1)) {a | ¬p (a_1, a)} = 0} = 0
⊢ (fun b => (η (a, b)) (Prod.mk b ⁻¹' {a | ¬p a})) =ᶠ[ae (κ a)] 0

case hs
α : Type u_1
β : Type u_2
ι : Type u_3
mα : MeasurableSpace α
mβ : MeasurableSpace β
γ : Type u_4
mγ : MeasurableSpace γ
s : Set (β × γ)
κ : ↥(kernel α β)
inst✝¹ : IsSFiniteKernel κ
η : ↥(kernel (α × β) γ)
inst✝ : IsSFiniteKernel η
a : α
p : β × γ → Prop
hp : MeasurableSet {x | p x}
h : (κ a) {a_1 | ¬(η (a, a_1)) {a | ¬p (a_1, a)} = 0} = 0
⊢ MeasurableSet {a | ¬p a}

tactic: exact h
state_before: α : Type u_1
β : Type u_2
ι : Type u_3
mα : MeasurableSpace α
mβ : MeasurableSpace β
γ : Type u_4
mγ : MeasurableSpace γ
s : Set (β × γ)
κ : ↥(kernel α β)
inst✝¹ : IsSFiniteKernel κ
η : ↥(kernel (α × β) γ)
inst✝ : IsSFiniteKernel η
a : α
p : β × γ → Prop
hp : MeasurableSet {x | p x}
h : (κ a) {a_1 | ¬(η (a, a_1)) {a | ¬p (a_1, a)} = 0} = 0
⊢ (fun b => (η (a, b)) (Prod.mk b ⁻¹' {a | ¬p a})) =ᶠ[ae (κ a)] 0
state_after: no goals

tactic: exact hp.compl
state_before: case hs
α : Type u_1
β : Type u_2
ι : Type u_3
mα : MeasurableSpace α
mβ : MeasurableSpace β
γ : Type u_4
mγ : MeasurableSpace γ
s : Set (β × γ)
κ : ↥(kernel α β)
inst✝¹ : IsSFiniteKernel κ
η : ↥(kernel (α × β) γ)
inst✝ : IsSFiniteKernel η
a : α
p : β × γ → Prop
hp : MeasurableSet {x | p x}
h : (κ a) {a_1 | ¬(η (a, a_1)) {a | ¬p (a_1, a)} = 0} = 0
⊢ MeasurableSet {a | ¬p a}
state_after: no goals
Theorem: List.get?_set_ne
File: .lake/packages/batteries/Batteries/Data/List/Lemmas.lean

tactic: simp [h]
state_before: α : Type u_1
a : α
m n : Nat
l : List α
h : m ≠ n
⊢ (l.set m a).get? n = l.get? n
state_after: no goals
Theorem: ofMul_list_prod
File: Mathlib/Algebra/BigOperators/Group/Finset.lean

tactic: simp [ofMul]
state_before: ι : Type u_1
κ : Type u_2
α : Type u_3
β : Type u_4
γ : Type u_5
s✝ s₁ s₂ : Finset α
a : α
f g : α → β
inst✝ : Monoid α
s : List α
⊢ ofMul s.prod = (List.map (⇑ofMul) s).sum
state_after: ι : Type u_1
κ : Type u_2
α : Type u_3
β : Type u_4
γ : Type u_5
s✝ s₁ s₂ : Finset α
a : α
f g : α → β
inst✝ : Monoid α
s : List α
⊢ s.prod = s.sum

tactic: rfl
state_before: ι : Type u_1
κ : Type u_2
α : Type u_3
β : Type u_4
γ : Type u_5
s✝ s₁ s₂ : Finset α
a : α
f g : α → β
inst✝ : Monoid α
s : List α
⊢ s.prod = s.sum
state_after: no goals
Theorem: LinearMap.baseChange_sub
File: Mathlib/RingTheory/TensorProduct/Basic.lean

tactic: ext
state_before: R : Type u_1
A : Type u_2
B : Type u_3
M : Type u_4
N : Type u_5
inst✝⁸ : CommRing R
inst✝⁷ : Ring A
inst✝⁶ : Algebra R A
inst✝⁵ : Ring B
inst✝⁴ : Algebra R B
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : AddCommGroup N
inst✝ : Module R N
f g : M →ₗ[R] N
⊢ baseChange A (f - g) = baseChange A f - baseChange A g
state_after: case a.h.h
R : Type u_1
A : Type u_2
B : Type u_3
M : Type u_4
N : Type u_5
inst✝⁸ : CommRing R
inst✝⁷ : Ring A
inst✝⁶ : Algebra R A
inst✝⁵ : Ring B
inst✝⁴ : Algebra R B
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : AddCommGroup N
inst✝ : Module R N
f g : M →ₗ[R] N
x✝ : M
⊢ ((AlgebraTensorModule.curry (baseChange A (f - g))) 1) x✝ =
    ((AlgebraTensorModule.curry (baseChange A f - baseChange A g)) 1) x✝

tactic: simp [baseChange_eq_ltensor, tmul_sub]
state_before: case a.h.h
R : Type u_1
A : Type u_2
B : Type u_3
M : Type u_4
N : Type u_5
inst✝⁸ : CommRing R
inst✝⁷ : Ring A
inst✝⁶ : Algebra R A
inst✝⁵ : Ring B
inst✝⁴ : Algebra R B
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : AddCommGroup N
inst✝ : Module R N
f g : M →ₗ[R] N
x✝ : M
⊢ ((AlgebraTensorModule.curry (baseChange A (f - g))) 1) x✝ =
    ((AlgebraTensorModule.curry (baseChange A f - baseChange A g)) 1) x✝
state_after: no goals
Theorem: CategoryTheory.NonPreadditiveAbelian.add_comp
File: Mathlib/CategoryTheory/Abelian/NonPreadditive.lean

tactic: rw [add_def, sub_comp, neg_def, sub_comp, zero_comp, add_def, neg_def]
state_before: C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : NonPreadditiveAbelian C
X Y Z : C
f g : X ⟶ Y
h : Y ⟶ Z
⊢ (f + g) ≫ h = f ≫ h + g ≫ h
state_after: no goals