1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: finprod_mem_finset_product
File: Mathlib/Algebra/BigOperators/Finprod.lean

tactic: classical
  rw [finprod_mem_finset_product']
  simp
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 α
s : Finset (α × β)
f : α × β → M
⊢ ∏ᶠ (ab : α × β) (_ : ab ∈ s), f ab = ∏ᶠ (a : α) (b : β) (_ : (a, b) ∈ s), f (a, b)
state_after: no goals

tactic: rw [finprod_mem_finset_product']
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 α
s : Finset (α × β)
f : α × β → M
⊢ ∏ᶠ (ab : α × β) (_ : ab ∈ s), f ab = ∏ᶠ (a : α) (b : β) (_ : (a, b) ∈ s), f (a, b)
state_after: α : 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 α
s : Finset (α × β)
f : α × β → M
⊢ ∏ᶠ (a : α) (b : β) (_ : b ∈ Finset.image Prod.snd (Finset.filter (fun ab => ab.1 = a) s)), f (a, b) =
    ∏ᶠ (a : α) (b : β) (_ : (a, b) ∈ s), f (a, b)

tactic: simp
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 α
s : Finset (α × β)
f : α × β → M
⊢ ∏ᶠ (a : α) (b : β) (_ : b ∈ Finset.image Prod.snd (Finset.filter (fun ab => ab.1 = a) s)), f (a, b) =
    ∏ᶠ (a : α) (b : β) (_ : (a, b) ∈ s), f (a, b)
state_after: no goals
Theorem: LipschitzWith.prod
File: Mathlib/Topology/EMetricSpace/Lipschitz.lean

tactic: intro x y
state_before: α : Type u
β : Type v
γ : Type w
ι : Type x
inst✝² : PseudoEMetricSpace α
inst✝¹ : PseudoEMetricSpace β
inst✝ : PseudoEMetricSpace γ
K : ℝ≥0
f✝ : α → β
x y : α
r : ℝ≥0∞
f : α → β
Kf : ℝ≥0
hf : LipschitzWith Kf f
g : α → γ
Kg : ℝ≥0
hg : LipschitzWith Kg g
⊢ LipschitzWith (max Kf Kg) fun x => (f x, g x)
state_after: α : Type u
β : Type v
γ : Type w
ι : Type x
inst✝² : PseudoEMetricSpace α
inst✝¹ : PseudoEMetricSpace β
inst✝ : PseudoEMetricSpace γ
K : ℝ≥0
f✝ : α → β
x✝ y✝ : α
r : ℝ≥0∞
f : α → β
Kf : ℝ≥0
hf : LipschitzWith Kf f
g : α → γ
Kg : ℝ≥0
hg : LipschitzWith Kg g
x y : α
⊢ edist ((fun x => (f x, g x)) x) ((fun x => (f x, g x)) y) ≤ ↑(max Kf Kg) * edist x y

tactic: rw [ENNReal.coe_mono.map_max, Prod.edist_eq, ENNReal.max_mul]
state_before: α : Type u
β : Type v
γ : Type w
ι : Type x
inst✝² : PseudoEMetricSpace α
inst✝¹ : PseudoEMetricSpace β
inst✝ : PseudoEMetricSpace γ
K : ℝ≥0
f✝ : α → β
x✝ y✝ : α
r : ℝ≥0∞
f : α → β
Kf : ℝ≥0
hf : LipschitzWith Kf f
g : α → γ
Kg : ℝ≥0
hg : LipschitzWith Kg g
x y : α
⊢ edist ((fun x => (f x, g x)) x) ((fun x => (f x, g x)) y) ≤ ↑(max Kf Kg) * edist x y
state_after: α : Type u
β : Type v
γ : Type w
ι : Type x
inst✝² : PseudoEMetricSpace α
inst✝¹ : PseudoEMetricSpace β
inst✝ : PseudoEMetricSpace γ
K : ℝ≥0
f✝ : α → β
x✝ y✝ : α
r : ℝ≥0∞
f : α → β
Kf : ℝ≥0
hf : LipschitzWith Kf f
g : α → γ
Kg : ℝ≥0
hg : LipschitzWith Kg g
x y : α
⊢ max (edist ((fun x => (f x, g x)) x).1 ((fun x => (f x, g x)) y).1)
      (edist ((fun x => (f x, g x)) x).2 ((fun x => (f x, g x)) y).2) ≤
    max (↑Kf * edist x y) (↑Kg * edist x y)

tactic: exact max_le_max (hf x y) (hg x y)
state_before: α : Type u
β : Type v
γ : Type w
ι : Type x
inst✝² : PseudoEMetricSpace α
inst✝¹ : PseudoEMetricSpace β
inst✝ : PseudoEMetricSpace γ
K : ℝ≥0
f✝ : α → β
x✝ y✝ : α
r : ℝ≥0∞
f : α → β
Kf : ℝ≥0
hf : LipschitzWith Kf f
g : α → γ
Kg : ℝ≥0
hg : LipschitzWith Kg g
x y : α
⊢ max (edist ((fun x => (f x, g x)) x).1 ((fun x => (f x, g x)) y).1)
      (edist ((fun x => (f x, g x)) x).2 ((fun x => (f x, g x)) y).2) ≤
    max (↑Kf * edist x y) (↑Kg * edist x y)
state_after: no goals
Theorem: MeasureTheory.hitting_eq_sInf
File: Mathlib/Probability/Process/HittingTime.lean

tactic: simp only [hitting, Set.mem_Icc, bot_le, le_top, and_self_iff, exists_true_left, Set.Icc_bot,
  Set.Iic_top, Set.univ_inter, ite_eq_left_iff, not_exists]
state_before: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝ : CompleteLattice ι
u : ι → Ω → β
s : Set β
f : Filtration ι m
ω : Ω
⊢ hitting u s ⊥ ⊤ ω = sInf {i | u i ω ∈ s}
state_after: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝ : CompleteLattice ι
u : ι → Ω → β
s : Set β
f : Filtration ι m
ω : Ω
⊢ (∀ (x : ι), ¬(x ∈ Set.univ ∧ u x ω ∈ s)) → ⊤ = sInf {i | u i ω ∈ s}

tactic: intro h_nmem_s
state_before: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝ : CompleteLattice ι
u : ι → Ω → β
s : Set β
f : Filtration ι m
ω : Ω
⊢ (∀ (x : ι), ¬(x ∈ Set.univ ∧ u x ω ∈ s)) → ⊤ = sInf {i | u i ω ∈ s}
state_after: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝ : CompleteLattice ι
u : ι → Ω → β
s : Set β
f : Filtration ι m
ω : Ω
h_nmem_s : ∀ (x : ι), ¬(x ∈ Set.univ ∧ u x ω ∈ s)
⊢ ⊤ = sInf {i | u i ω ∈ s}

tactic: symm
state_before: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝ : CompleteLattice ι
u : ι → Ω → β
s : Set β
f : Filtration ι m
ω : Ω
h_nmem_s : ∀ (x : ι), ¬(x ∈ Set.univ ∧ u x ω ∈ s)
⊢ ⊤ = sInf {i | u i ω ∈ s}
state_after: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝ : CompleteLattice ι
u : ι → Ω → β
s : Set β
f : Filtration ι m
ω : Ω
h_nmem_s : ∀ (x : ι), ¬(x ∈ Set.univ ∧ u x ω ∈ s)
⊢ sInf {i | u i ω ∈ s} = ⊤

tactic: rw [sInf_eq_top]
state_before: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝ : CompleteLattice ι
u : ι → Ω → β
s : Set β
f : Filtration ι m
ω : Ω
h_nmem_s : ∀ (x : ι), ¬(x ∈ Set.univ ∧ u x ω ∈ s)
⊢ sInf {i | u i ω ∈ s} = ⊤
state_after: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝ : CompleteLattice ι
u : ι → Ω → β
s : Set β
f : Filtration ι m
ω : Ω
h_nmem_s : ∀ (x : ι), ¬(x ∈ Set.univ ∧ u x ω ∈ s)
⊢ ∀ a ∈ {i | u i ω ∈ s}, a = ⊤

tactic: simp only [Set.mem_univ, true_and] at h_nmem_s
state_before: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝ : CompleteLattice ι
u : ι → Ω → β
s : Set β
f : Filtration ι m
ω : Ω
h_nmem_s : ∀ (x : ι), ¬(x ∈ Set.univ ∧ u x ω ∈ s)
⊢ ∀ a ∈ {i | u i ω ∈ s}, a = ⊤
state_after: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝ : CompleteLattice ι
u : ι → Ω → β
s : Set β
f : Filtration ι m
ω : Ω
h_nmem_s : ∀ (x : ι), u x ω ∉ s
⊢ ∀ a ∈ {i | u i ω ∈ s}, a = ⊤

tactic: exact fun i hi_mem_s => absurd hi_mem_s (h_nmem_s i)
state_before: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝ : CompleteLattice ι
u : ι → Ω → β
s : Set β
f : Filtration ι m
ω : Ω
h_nmem_s : ∀ (x : ι), u x ω ∉ s
⊢ ∀ a ∈ {i | u i ω ∈ s}, a = ⊤
state_after: no goals
Theorem: pow_nonneg
File: Mathlib/Algebra/Order/Ring/Defs.lean

tactic: rw [pow_zero]
state_before: α : Type u
β : Type u_1
inst✝ : OrderedSemiring α
a b c d : α
H : 0 ≤ a
⊢ 0 ≤ a ^ 0
state_after: α : Type u
β : Type u_1
inst✝ : OrderedSemiring α
a b c d : α
H : 0 ≤ a
⊢ 0 ≤ 1

tactic: exact zero_le_one
state_before: α : Type u
β : Type u_1
inst✝ : OrderedSemiring α
a b c d : α
H : 0 ≤ a
⊢ 0 ≤ 1
state_after: no goals

tactic: rw [pow_succ]
state_before: α : Type u
β : Type u_1
inst✝ : OrderedSemiring α
a b c d : α
H : 0 ≤ a
n : ℕ
⊢ 0 ≤ a ^ (n + 1)
state_after: α : Type u
β : Type u_1
inst✝ : OrderedSemiring α
a b c d : α
H : 0 ≤ a
n : ℕ
⊢ 0 ≤ a ^ n * a

tactic: exact mul_nonneg (pow_nonneg H _) H
state_before: α : Type u
β : Type u_1
inst✝ : OrderedSemiring α
a b c d : α
H : 0 ≤ a
n : ℕ
⊢ 0 ≤ a ^ n * a
state_after: no goals
Theorem: FirstOrder.Language.Ultraproduct.funMap_cast
File: Mathlib/ModelTheory/Ultraproducts.lean

tactic: apply funMap_quotient_mk'
state_before: α : Type u_1
M : α → Type u_2
u : Ultrafilter α
L : Language
inst✝ : (a : α) → L.Structure (M a)
n : ℕ
f : L.Functions n
x : Fin n → (a : α) → M a
⊢ (funMap f fun i => Quotient.mk' (x i)) = Quotient.mk' fun a => funMap f fun i => x i a
state_after: no goals
Theorem: Polynomial.gcd_map
File: Mathlib/Algebra/Polynomial/FieldDivision.lean

tactic: simp_rw [Polynomial.map_zero, EuclideanDomain.gcd_zero_left]
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✝² : Field k
inst✝¹ : DecidableEq R
inst✝ : DecidableEq k
f : R →+* k
x : R[X]
⊢ EuclideanDomain.gcd (map f 0) (map f x) = map f (EuclideanDomain.gcd 0 x)
state_after: no goals

tactic: rw [gcd_val, ← map_mod, ih, ← gcd_val]
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✝² : Field k
inst✝¹ : DecidableEq R
inst✝ : DecidableEq k
f : R →+* k
x y : R[X]
x✝ : x ≠ 0
ih : EuclideanDomain.gcd (map f (y % x)) (map f x) = map f (EuclideanDomain.gcd (y % x) x)
⊢ EuclideanDomain.gcd (map f x) (map f y) = map f (EuclideanDomain.gcd x y)
state_after: no goals
Theorem: Matroid.Basis.iUnion_basis_iUnion
File: Mathlib/Data/Matroid/Basic.lean

tactic: refine h_ind.basis_of_forall_insert
  (iUnion_subset (fun i ↦ (hI i).subset.trans (subset_iUnion _ _))) ?_
state_before: α : Type u_1
M : Matroid α
ι : Type u_2
X I : ι → Set α
hI : ∀ (i : ι), M.Basis (I i) (X i)
h_ind : M.Indep (⋃ i, I i)
⊢ M.Basis (⋃ i, I i) (⋃ i, X i)
state_after: α : Type u_1
M : Matroid α
ι : Type u_2
X I : ι → Set α
hI : ∀ (i : ι), M.Basis (I i) (X i)
h_ind : M.Indep (⋃ i, I i)
⊢ ∀ e ∈ (⋃ i, X i) \ ⋃ i, I i, M.Dep (insert e (⋃ i, I i))

tactic: rintro e ⟨⟨_, ⟨⟨i, hi, rfl⟩, (hes : e ∈ X i)⟩⟩, he'⟩
state_before: α : Type u_1
M : Matroid α
ι : Type u_2
X I : ι → Set α
hI : ∀ (i : ι), M.Basis (I i) (X i)
h_ind : M.Indep (⋃ i, I i)
⊢ ∀ e ∈ (⋃ i, X i) \ ⋃ i, I i, M.Dep (insert e (⋃ i, I i))
state_after: case intro.intro.intro.intro.refl
α : Type u_1
M : Matroid α
ι : Type u_2
X I : ι → Set α
hI : ∀ (i : ι), M.Basis (I i) (X i)
h_ind : M.Indep (⋃ i, I i)
e : α
he' : e ∉ ⋃ i, I i
i : ι
hes : e ∈ X i
⊢ M.Dep (insert e (⋃ i, I i))

tactic: rw [mem_iUnion, not_exists] at he'
state_before: case intro.intro.intro.intro.refl
α : Type u_1
M : Matroid α
ι : Type u_2
X I : ι → Set α
hI : ∀ (i : ι), M.Basis (I i) (X i)
h_ind : M.Indep (⋃ i, I i)
e : α
he' : e ∉ ⋃ i, I i
i : ι
hes : e ∈ X i
⊢ M.Dep (insert e (⋃ i, I i))
state_after: case intro.intro.intro.intro.refl
α : Type u_1
M : Matroid α
ι : Type u_2
X I : ι → Set α
hI : ∀ (i : ι), M.Basis (I i) (X i)
h_ind : M.Indep (⋃ i, I i)
e : α
he' : ∀ (x : ι), e ∉ I x
i : ι
hes : e ∈ X i
⊢ M.Dep (insert e (⋃ i, I i))

tactic: refine ((hI i).insert_dep ⟨hes, he' _⟩).superset (insert_subset_insert (subset_iUnion _ _)) ?_
state_before: case intro.intro.intro.intro.refl
α : Type u_1
M : Matroid α
ι : Type u_2
X I : ι → Set α
hI : ∀ (i : ι), M.Basis (I i) (X i)
h_ind : M.Indep (⋃ i, I i)
e : α
he' : ∀ (x : ι), e ∉ I x
i : ι
hes : e ∈ X i
⊢ M.Dep (insert e (⋃ i, I i))
state_after: case intro.intro.intro.intro.refl
α : Type u_1
M : Matroid α
ι : Type u_2
X I : ι → Set α
hI : ∀ (i : ι), M.Basis (I i) (X i)
h_ind : M.Indep (⋃ i, I i)
e : α
he' : ∀ (x : ι), e ∉ I x
i : ι
hes : e ∈ X i
⊢ insert e (⋃ i, I i) ⊆ M.E

tactic: rw [insert_subset_iff, iUnion_subset_iff, and_iff_left (fun i ↦ (hI i).indep.subset_ground)]
state_before: case intro.intro.intro.intro.refl
α : Type u_1
M : Matroid α
ι : Type u_2
X I : ι → Set α
hI : ∀ (i : ι), M.Basis (I i) (X i)
h_ind : M.Indep (⋃ i, I i)
e : α
he' : ∀ (x : ι), e ∉ I x
i : ι
hes : e ∈ X i
⊢ insert e (⋃ i, I i) ⊆ M.E
state_after: case intro.intro.intro.intro.refl
α : Type u_1
M : Matroid α
ι : Type u_2
X I : ι → Set α
hI : ∀ (i : ι), M.Basis (I i) (X i)
h_ind : M.Indep (⋃ i, I i)
e : α
he' : ∀ (x : ι), e ∉ I x
i : ι
hes : e ∈ X i
⊢ e ∈ M.E

tactic: exact (hI i).subset_ground hes
state_before: case intro.intro.intro.intro.refl
α : Type u_1
M : Matroid α
ι : Type u_2
X I : ι → Set α
hI : ∀ (i : ι), M.Basis (I i) (X i)
h_ind : M.Indep (⋃ i, I i)
e : α
he' : ∀ (x : ι), e ∉ I x
i : ι
hes : e ∈ X i
⊢ e ∈ M.E
state_after: no goals
Theorem: Real.sqrt_mul
File: Mathlib/Data/Real/Sqrt.lean

tactic: simp_rw [Real.sqrt, ← NNReal.coe_mul, NNReal.coe_inj, Real.toNNReal_mul hx, NNReal.sqrt_mul]
state_before: x✝ y✝ x : ℝ
hx : 0 ≤ x
y : ℝ
⊢ √(x * y) = √x * √y
state_after: no goals
Theorem: CategoryTheory.equiv_relation
File: Mathlib/CategoryTheory/IsConnected.lean

tactic: intros j₁ j₂
state_before: J : Type u₁
inst✝² : Category.{v₁, u₁} J
K : Type u₂
inst✝¹ : Category.{v₂, u₂} K
inst✝ : IsPreconnected J
r : J → J → Prop
hr : _root_.Equivalence r
h : ∀ {j₁ j₂ : J}, (j₁ ⟶ j₂) → r j₁ j₂
⊢ ∀ (j₁ j₂ : J), r j₁ j₂
state_after: J : Type u₁
inst✝² : Category.{v₁, u₁} J
K : Type u₂
inst✝¹ : Category.{v₂, u₂} K
inst✝ : IsPreconnected J
r : J → J → Prop
hr : _root_.Equivalence r
h : ∀ {j₁ j₂ : J}, (j₁ ⟶ j₂) → r j₁ j₂
j₁ j₂ : J
⊢ r j₁ j₂

tactic: have z : ∀ j : J, r j₁ j :=
  induct_on_objects {k | r j₁ k} (hr.1 j₁)
    fun f => ⟨fun t => hr.3 t (h f), fun t => hr.3 t (hr.2 (h f))⟩
state_before: J : Type u₁
inst✝² : Category.{v₁, u₁} J
K : Type u₂
inst✝¹ : Category.{v₂, u₂} K
inst✝ : IsPreconnected J
r : J → J → Prop
hr : _root_.Equivalence r
h : ∀ {j₁ j₂ : J}, (j₁ ⟶ j₂) → r j₁ j₂
j₁ j₂ : J
⊢ r j₁ j₂
state_after: J : Type u₁
inst✝² : Category.{v₁, u₁} J
K : Type u₂
inst✝¹ : Category.{v₂, u₂} K
inst✝ : IsPreconnected J
r : J → J → Prop
hr : _root_.Equivalence r
h : ∀ {j₁ j₂ : J}, (j₁ ⟶ j₂) → r j₁ j₂
j₁ j₂ : J
z : ∀ (j : J), r j₁ j
⊢ r j₁ j₂

tactic: exact z j₂
state_before: J : Type u₁
inst✝² : Category.{v₁, u₁} J
K : Type u₂
inst✝¹ : Category.{v₂, u₂} K
inst✝ : IsPreconnected J
r : J → J → Prop
hr : _root_.Equivalence r
h : ∀ {j₁ j₂ : J}, (j₁ ⟶ j₂) → r j₁ j₂
j₁ j₂ : J
z : ∀ (j : J), r j₁ j
⊢ r j₁ j₂
state_after: no goals
Theorem: YoungDiagram.le_of_transpose_le
File: Mathlib/Combinatorics/Young/YoungDiagram.lean

tactic: simp only [mem_cells, mem_transpose]
state_before: μ ν : YoungDiagram
h_le : μ.transpose ≤ ν
c : ℕ × ℕ
hc : c ∈ μ.cells
⊢ c ∈ ν.transpose.cells
state_after: μ ν : YoungDiagram
h_le : μ.transpose ≤ ν
c : ℕ × ℕ
hc : c ∈ μ.cells
⊢ c.swap ∈ ν

tactic: apply h_le
state_before: μ ν : YoungDiagram
h_le : μ.transpose ≤ ν
c : ℕ × ℕ
hc : c ∈ μ.cells
⊢ c.swap ∈ ν
state_after: case a
μ ν : YoungDiagram
h_le : μ.transpose ≤ ν
c : ℕ × ℕ
hc : c ∈ μ.cells
⊢ c.swap ∈ μ.transpose.cells

tactic: simpa
state_before: case a
μ ν : YoungDiagram
h_le : μ.transpose ≤ ν
c : ℕ × ℕ
hc : c ∈ μ.cells
⊢ c.swap ∈ μ.transpose.cells
state_after: no goals
Theorem: Polynomial.cyclotomic'_two
File: Mathlib/RingTheory/Polynomial/Cyclotomic/Basic.lean

tactic: rw [cyclotomic']
state_before: R✝ : Type u_1
inst✝⁴ : CommRing R✝
inst✝³ : IsDomain R✝
R : Type u_2
inst✝² : CommRing R
inst✝¹ : IsDomain R
p : ℕ
inst✝ : CharP R p
hp : p ≠ 2
⊢ cyclotomic' 2 R = X + 1
state_after: R✝ : Type u_1
inst✝⁴ : CommRing R✝
inst✝³ : IsDomain R✝
R : Type u_2
inst✝² : CommRing R
inst✝¹ : IsDomain R
p : ℕ
inst✝ : CharP R p
hp : p ≠ 2
⊢ ∏ μ ∈ primitiveRoots 2 R, (X - C μ) = X + 1

tactic: have prim_root_two : primitiveRoots 2 R = {(-1 : R)} := by
  simp only [Finset.eq_singleton_iff_unique_mem, mem_primitiveRoots two_pos]
  exact ⟨IsPrimitiveRoot.neg_one p hp, fun x => IsPrimitiveRoot.eq_neg_one_of_two_right⟩
state_before: R✝ : Type u_1
inst✝⁴ : CommRing R✝
inst✝³ : IsDomain R✝
R : Type u_2
inst✝² : CommRing R
inst✝¹ : IsDomain R
p : ℕ
inst✝ : CharP R p
hp : p ≠ 2
⊢ ∏ μ ∈ primitiveRoots 2 R, (X - C μ) = X + 1
state_after: R✝ : Type u_1
inst✝⁴ : CommRing R✝
inst✝³ : IsDomain R✝
R : Type u_2
inst✝² : CommRing R
inst✝¹ : IsDomain R
p : ℕ
inst✝ : CharP R p
hp : p ≠ 2
prim_root_two : primitiveRoots 2 R = {-1}
⊢ ∏ μ ∈ primitiveRoots 2 R, (X - C μ) = X + 1

tactic: simp only [prim_root_two, Finset.prod_singleton, RingHom.map_neg, RingHom.map_one, sub_neg_eq_add]
state_before: R✝ : Type u_1
inst✝⁴ : CommRing R✝
inst✝³ : IsDomain R✝
R : Type u_2
inst✝² : CommRing R
inst✝¹ : IsDomain R
p : ℕ
inst✝ : CharP R p
hp : p ≠ 2
prim_root_two : primitiveRoots 2 R = {-1}
⊢ ∏ μ ∈ primitiveRoots 2 R, (X - C μ) = X + 1
state_after: no goals

tactic: simp only [Finset.eq_singleton_iff_unique_mem, mem_primitiveRoots two_pos]
state_before: R✝ : Type u_1
inst✝⁴ : CommRing R✝
inst✝³ : IsDomain R✝
R : Type u_2
inst✝² : CommRing R
inst✝¹ : IsDomain R
p : ℕ
inst✝ : CharP R p
hp : p ≠ 2
⊢ primitiveRoots 2 R = {-1}
state_after: R✝ : Type u_1
inst✝⁴ : CommRing R✝
inst✝³ : IsDomain R✝
R : Type u_2
inst✝² : CommRing R
inst✝¹ : IsDomain R
p : ℕ
inst✝ : CharP R p
hp : p ≠ 2
⊢ IsPrimitiveRoot (-1) 2 ∧ ∀ (x : R), IsPrimitiveRoot x 2 → x = -1

tactic: exact ⟨IsPrimitiveRoot.neg_one p hp, fun x => IsPrimitiveRoot.eq_neg_one_of_two_right⟩
state_before: R✝ : Type u_1
inst✝⁴ : CommRing R✝
inst✝³ : IsDomain R✝
R : Type u_2
inst✝² : CommRing R
inst✝¹ : IsDomain R
p : ℕ
inst✝ : CharP R p
hp : p ≠ 2
⊢ IsPrimitiveRoot (-1) 2 ∧ ∀ (x : R), IsPrimitiveRoot x 2 → x = -1
state_after: no goals
Theorem: single_le_finprod
File: Mathlib/Algebra/BigOperators/Finprod.lean

tactic: classical calc
    f i ≤ ∏ j ∈ insert i hf.toFinset, f j :=
      Finset.single_le_prod' (fun j _ => h j) (Finset.mem_insert_self _ _)
    _ = ∏ᶠ j, f j :=
      (finprod_eq_prod_of_mulSupport_toFinset_subset _ hf (Finset.subset_insert _ _)).symm
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 α
M : Type u_7
inst✝ : OrderedCommMonoid M
i : α
f : α → M
hf : (mulSupport f).Finite
h : ∀ (j : α), 1 ≤ f j
⊢ f i ≤ ∏ᶠ (j : α), f j
state_after: no goals

tactic: calc
f i ≤ ∏ j ∈ insert i hf.toFinset, f j :=
Finset.single_le_prod' (fun j _ => h j) (Finset.mem_insert_self _ _)
_ = ∏ᶠ j, f j :=
(finprod_eq_prod_of_mulSupport_toFinset_subset _ hf (Finset.subset_insert _ _)).symm
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 α
M : Type u_7
inst✝ : OrderedCommMonoid M
i : α
f : α → M
hf : (mulSupport f).Finite
h : ∀ (j : α), 1 ≤ f j
⊢ f i ≤ ∏ᶠ (j : α), f j
state_after: no goals
Theorem: Complex.exp_ofReal_mul_I_re
File: Mathlib/Data/Complex/Exponential.lean

tactic: simp [exp_mul_I, cos_ofReal_re]
state_before: x✝ y : ℂ
x : ℝ
⊢ (cexp (↑x * I)).re = Real.cos x
state_after: no goals
Theorem: Tactic.NormNum.int_gcd_helper'
File: Mathlib/Tactic/NormNum/GCD.lean

tactic: refine Nat.dvd_antisymm ?_ (Int.natCast_dvd_natCast.1 (Int.dvd_gcd h₁ h₂))
state_before: d : ℕ
x y a b : ℤ
h₁ : ↑d ∣ x
h₂ : ↑d ∣ y
h₃ : x * a + y * b = ↑d
⊢ x.gcd y = d
state_after: d : ℕ
x y a b : ℤ
h₁ : ↑d ∣ x
h₂ : ↑d ∣ y
h₃ : x * a + y * b = ↑d
⊢ x.gcd y ∣ d

tactic: rw [← Int.natCast_dvd_natCast, ← h₃]
state_before: d : ℕ
x y a b : ℤ
h₁ : ↑d ∣ x
h₂ : ↑d ∣ y
h₃ : x * a + y * b = ↑d
⊢ x.gcd y ∣ d
state_after: d : ℕ
x y a b : ℤ
h₁ : ↑d ∣ x
h₂ : ↑d ∣ y
h₃ : x * a + y * b = ↑d
⊢ ↑(x.gcd y) ∣ x * a + y * b

tactic: apply dvd_add
state_before: d : ℕ
x y a b : ℤ
h₁ : ↑d ∣ x
h₂ : ↑d ∣ y
h₃ : x * a + y * b = ↑d
⊢ ↑(x.gcd y) ∣ x * a + y * b
state_after: case h₁
d : ℕ
x y a b : ℤ
h₁ : ↑d ∣ x
h₂ : ↑d ∣ y
h₃ : x * a + y * b = ↑d
⊢ ↑(x.gcd y) ∣ x * a

case h₂
d : ℕ
x y a b : ℤ
h₁ : ↑d ∣ x
h₂ : ↑d ∣ y
h₃ : x * a + y * b = ↑d
⊢ ↑(x.gcd y) ∣ y * b

tactic: exact Int.gcd_dvd_left.mul_right _
state_before: case h₁
d : ℕ
x y a b : ℤ
h₁ : ↑d ∣ x
h₂ : ↑d ∣ y
h₃ : x * a + y * b = ↑d
⊢ ↑(x.gcd y) ∣ x * a
state_after: no goals

tactic: exact Int.gcd_dvd_right.mul_right _
state_before: case h₂
d : ℕ
x y a b : ℤ
h₁ : ↑d ∣ x
h₂ : ↑d ∣ y
h₃ : x * a + y * b = ↑d
⊢ ↑(x.gcd y) ∣ y * b
state_after: no goals
Theorem: NNReal.rpow_left_surjective
File: Mathlib/Analysis/SpecialFunctions/Pow/NNReal.lean

tactic: simp_rw [← rpow_mul, _root_.inv_mul_cancel hx, rpow_one]
state_before: w x✝ y✝ z x : ℝ
hx : x ≠ 0
y : ℝ≥0
⊢ (fun y => y ^ x) (y ^ x⁻¹) = y
state_after: no goals
Theorem: TopologicalSpace.eq_induced_by_maps_to_sierpinski
File: Mathlib/Topology/ContinuousFunction/T0Sierpinski.lean

tactic: apply le_antisymm
state_before: X : Type u_1
t : TopologicalSpace X
⊢ t = ⨅ u, induced (fun x => x ∈ u) sierpinskiSpace
state_after: case a
X : Type u_1
t : TopologicalSpace X
⊢ t ≤ ⨅ u, induced (fun x => x ∈ u) sierpinskiSpace

case a
X : Type u_1
t : TopologicalSpace X
⊢ ⨅ u, induced (fun x => x ∈ u) sierpinskiSpace ≤ t

tactic: rw [le_iInf_iff]
state_before: case a
X : Type u_1
t : TopologicalSpace X
⊢ t ≤ ⨅ u, induced (fun x => x ∈ u) sierpinskiSpace
state_after: case a
X : Type u_1
t : TopologicalSpace X
⊢ ∀ (i : Opens X), t ≤ induced (fun x => x ∈ i) sierpinskiSpace

tactic: exact fun u => Continuous.le_induced (isOpen_iff_continuous_mem.mp u.2)
state_before: case a
X : Type u_1
t : TopologicalSpace X
⊢ ∀ (i : Opens X), t ≤ induced (fun x => x ∈ i) sierpinskiSpace
state_after: no goals

tactic: intro u h
state_before: case a
X : Type u_1
t : TopologicalSpace X
⊢ ⨅ u, induced (fun x => x ∈ u) sierpinskiSpace ≤ t
state_after: case a
X : Type u_1
t : TopologicalSpace X
u : Set X
h : IsOpen u
⊢ IsOpen u

tactic: apply isOpen_generateFrom_of_mem
state_before: case a
X : Type u_1
t : TopologicalSpace X
u : Set X
h : IsOpen u
⊢ IsOpen u
state_after: case a.hs
X : Type u_1
t : TopologicalSpace X
u : Set X
h : IsOpen u
⊢ u ∈ ⋃ i, {s | IsOpen s}

tactic: simp only [Set.mem_iUnion, Set.mem_setOf_eq, isOpen_induced_iff]
state_before: case a.hs
X : Type u_1
t : TopologicalSpace X
u : Set X
h : IsOpen u
⊢ u ∈ ⋃ i, {s | IsOpen s}
state_after: case a.hs
X : Type u_1
t : TopologicalSpace X
u : Set X
h : IsOpen u
⊢ ∃ i t_1, IsOpen t_1 ∧ (fun x => x ∈ i) ⁻¹' t_1 = u

tactic: exact ⟨⟨u, h⟩, {True}, isOpen_singleton_true, by simp [Set.preimage]⟩
state_before: case a.hs
X : Type u_1
t : TopologicalSpace X
u : Set X
h : IsOpen u
⊢ ∃ i t_1, IsOpen t_1 ∧ (fun x => x ∈ i) ⁻¹' t_1 = u
state_after: no goals

tactic: simp [Set.preimage]
state_before: X : Type u_1
t : TopologicalSpace X
u : Set X
h : IsOpen u
⊢ (fun x => x ∈ { carrier := u, is_open' := h }) ⁻¹' {True} = u
state_after: no goals
Theorem: Subalgebra.adjoin_rank_le
File: Mathlib/RingTheory/Adjoin/Field.lean

tactic: rw [← rank_toSubmodule, Module.Free.rank_eq_card_chooseBasisIndex F L,
  L.adjoin_eq_span_basis E (Module.Free.chooseBasis F L)]
state_before: R : Type u_1
K✝ : Type u_2
L✝ : Type u_3
M : Type u_4
inst✝¹⁸ : CommRing R
inst✝¹⁷ : Field K✝
inst✝¹⁶ : Field L✝
inst✝¹⁵ : CommRing M
inst✝¹⁴ : Algebra R K✝
inst✝¹³ : Algebra R L✝
inst✝¹² : Algebra R M
x✝ : L✝
int✝ : IsIntegral R x✝
h : Splits (algebraMap R K✝) (minpoly R x✝)
inst✝¹¹ : Algebra K✝ M
inst✝¹⁰ : IsScalarTower R K✝ M
x : M
int : IsIntegral R x
F : Type u_5
E : Type u_6
K : Type u_7
inst✝⁹ : CommRing F
inst✝⁸ : StrongRankCondition F
inst✝⁷ : CommRing E
inst✝⁶ : StrongRankCondition E
inst✝⁵ : Ring K
inst✝⁴ : SMul F E
inst✝³ : Algebra E K
inst✝² : Algebra F K
inst✝¹ : IsScalarTower F E K
L : Subalgebra F K
inst✝ : Module.Free F ↥L
⊢ Module.rank E ↥(Algebra.adjoin E ↑L) ≤ Module.rank F ↥L
state_after: R : Type u_1
K✝ : Type u_2
L✝ : Type u_3
M : Type u_4
inst✝¹⁸ : CommRing R
inst✝¹⁷ : Field K✝
inst✝¹⁶ : Field L✝
inst✝¹⁵ : CommRing M
inst✝¹⁴ : Algebra R K✝
inst✝¹³ : Algebra R L✝
inst✝¹² : Algebra R M
x✝ : L✝
int✝ : IsIntegral R x✝
h : Splits (algebraMap R K✝) (minpoly R x✝)
inst✝¹¹ : Algebra K✝ M
inst✝¹⁰ : IsScalarTower R K✝ M
x : M
int : IsIntegral R x
F : Type u_5
E : Type u_6
K : Type u_7
inst✝⁹ : CommRing F
inst✝⁸ : StrongRankCondition F
inst✝⁷ : CommRing E
inst✝⁶ : StrongRankCondition E
inst✝⁵ : Ring K
inst✝⁴ : SMul F E
inst✝³ : Algebra E K
inst✝² : Algebra F K
inst✝¹ : IsScalarTower F E K
L : Subalgebra F K
inst✝ : Module.Free F ↥L
⊢ Module.rank E ↥(Submodule.span E (Set.range fun i => ↑((Module.Free.chooseBasis F ↥L) i))) ≤
    Cardinal.mk (Module.Free.ChooseBasisIndex F ↥L)

tactic: exact rank_span_le _ |>.trans Cardinal.mk_range_le
state_before: R : Type u_1
K✝ : Type u_2
L✝ : Type u_3
M : Type u_4
inst✝¹⁸ : CommRing R
inst✝¹⁷ : Field K✝
inst✝¹⁶ : Field L✝
inst✝¹⁵ : CommRing M
inst✝¹⁴ : Algebra R K✝
inst✝¹³ : Algebra R L✝
inst✝¹² : Algebra R M
x✝ : L✝
int✝ : IsIntegral R x✝
h : Splits (algebraMap R K✝) (minpoly R x✝)
inst✝¹¹ : Algebra K✝ M
inst✝¹⁰ : IsScalarTower R K✝ M
x : M
int : IsIntegral R x
F : Type u_5
E : Type u_6
K : Type u_7
inst✝⁹ : CommRing F
inst✝⁸ : StrongRankCondition F
inst✝⁷ : CommRing E
inst✝⁶ : StrongRankCondition E
inst✝⁵ : Ring K
inst✝⁴ : SMul F E
inst✝³ : Algebra E K
inst✝² : Algebra F K
inst✝¹ : IsScalarTower F E K
L : Subalgebra F K
inst✝ : Module.Free F ↥L
⊢ Module.rank E ↥(Submodule.span E (Set.range fun i => ↑((Module.Free.chooseBasis F ↥L) i))) ≤
    Cardinal.mk (Module.Free.ChooseBasisIndex F ↥L)
state_after: no goals