1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: DoubleCentralizer.range_toProdMulOpposite
File: Mathlib/Analysis/NormedSpace/Star/Multiplier.lean

tactic: rintro ⟨a, rfl⟩
state_before: 𝕜 : Type u_1
A : Type u_2
inst✝⁴ : NontriviallyNormedField 𝕜
inst✝³ : NonUnitalNormedRing A
inst✝² : NormedSpace 𝕜 A
inst✝¹ : SMulCommClass 𝕜 A A
inst✝ : IsScalarTower 𝕜 A A
x : (A →L[𝕜] A) × (A →L[𝕜] A)ᵐᵒᵖ
⊢ x ∈ Set.range toProdMulOpposite → x ∈ {lr | ∀ (x y : A), (unop lr.2) x * y = x * lr.1 y}
state_after: case intro
𝕜 : Type u_1
A : Type u_2
inst✝⁴ : NontriviallyNormedField 𝕜
inst✝³ : NonUnitalNormedRing A
inst✝² : NormedSpace 𝕜 A
inst✝¹ : SMulCommClass 𝕜 A A
inst✝ : IsScalarTower 𝕜 A A
a : 𝓜(𝕜, A)
⊢ a.toProdMulOpposite ∈ {lr | ∀ (x y : A), (unop lr.2) x * y = x * lr.1 y}

tactic: exact a.central
state_before: case intro
𝕜 : Type u_1
A : Type u_2
inst✝⁴ : NontriviallyNormedField 𝕜
inst✝³ : NonUnitalNormedRing A
inst✝² : NormedSpace 𝕜 A
inst✝¹ : SMulCommClass 𝕜 A A
inst✝ : IsScalarTower 𝕜 A A
a : 𝓜(𝕜, A)
⊢ a.toProdMulOpposite ∈ {lr | ∀ (x y : A), (unop lr.2) x * y = x * lr.1 y}
state_after: no goals
Theorem: CategoryTheory.Iso.map_inv_hom_id
File: Mathlib/CategoryTheory/Iso.lean

tactic: rw [← F.map_comp, e.inv_hom_id, F.map_id]
state_before: C : Type u
inst✝² : Category.{v, u} C
X✝ Y✝ Z : C
D : Type u_1
E : Type u_2
inst✝¹ : Category.{u_3, u_1} D
inst✝ : Category.{?u.30986, u_2} E
X Y : C
e : X ≅ Y
F : C ⥤ D
⊢ F.map e.inv ≫ F.map e.hom = 𝟙 (F.obj Y)
state_after: no goals
Theorem: CategoryTheory.Arrow.hom.congr_left
File: Mathlib/CategoryTheory/Comma/Arrow.lean

tactic: rw [h]
state_before: T : Type u
inst✝ : Category.{v, u} T
f g : Arrow T
φ₁ φ₂ : f ⟶ g
h : φ₁ = φ₂
⊢ φ₁.left = φ₂.left
state_after: no goals
Theorem: Finset.empty_inter
File: Mathlib/Data/Finset/Basic.lean

tactic: simp
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : DecidableEq α
s✝ s₁ s₂ t t₁ t₂ u v : Finset α
a b : α
s : Finset α
x✝ : α
⊢ x✝ ∈ ∅ ∧ x✝ ∈ s ↔ x✝ ∈ ∅
state_after: no goals
Theorem: EuclideanGeometry.Cospherical.two_zsmul_oangle_eq
File: Mathlib/Geometry/Euclidean/Angle/Sphere.lean

tactic: obtain ⟨s, hs⟩ := cospherical_iff_exists_sphere.1 h
state_before: V : Type u_1
P : Type u_2
inst✝⁴ : NormedAddCommGroup V
inst✝³ : InnerProductSpace ℝ V
inst✝² : MetricSpace P
inst✝¹ : NormedAddTorsor V P
hd2 : Fact (finrank ℝ V = 2)
inst✝ : Module.Oriented ℝ V (Fin 2)
p₁ p₂ p₃ p₄ : P
h : Cospherical {p₁, p₂, p₃, p₄}
hp₂p₁ : p₂ ≠ p₁
hp₂p₄ : p₂ ≠ p₄
hp₃p₁ : p₃ ≠ p₁
hp₃p₄ : p₃ ≠ p₄
⊢ 2 • ∡ p₁ p₂ p₄ = 2 • ∡ p₁ p₃ p₄
state_after: case intro
V : Type u_1
P : Type u_2
inst✝⁴ : NormedAddCommGroup V
inst✝³ : InnerProductSpace ℝ V
inst✝² : MetricSpace P
inst✝¹ : NormedAddTorsor V P
hd2 : Fact (finrank ℝ V = 2)
inst✝ : Module.Oriented ℝ V (Fin 2)
p₁ p₂ p₃ p₄ : P
h : Cospherical {p₁, p₂, p₃, p₄}
hp₂p₁ : p₂ ≠ p₁
hp₂p₄ : p₂ ≠ p₄
hp₃p₁ : p₃ ≠ p₁
hp₃p₄ : p₃ ≠ p₄
s : Sphere P
hs : {p₁, p₂, p₃, p₄} ⊆ Metric.sphere s.center s.radius
⊢ 2 • ∡ p₁ p₂ p₄ = 2 • ∡ p₁ p₃ p₄

tactic: simp_rw [Set.insert_subset_iff, Set.singleton_subset_iff, Sphere.mem_coe] at hs
state_before: case intro
V : Type u_1
P : Type u_2
inst✝⁴ : NormedAddCommGroup V
inst✝³ : InnerProductSpace ℝ V
inst✝² : MetricSpace P
inst✝¹ : NormedAddTorsor V P
hd2 : Fact (finrank ℝ V = 2)
inst✝ : Module.Oriented ℝ V (Fin 2)
p₁ p₂ p₃ p₄ : P
h : Cospherical {p₁, p₂, p₃, p₄}
hp₂p₁ : p₂ ≠ p₁
hp₂p₄ : p₂ ≠ p₄
hp₃p₁ : p₃ ≠ p₁
hp₃p₄ : p₃ ≠ p₄
s : Sphere P
hs : {p₁, p₂, p₃, p₄} ⊆ Metric.sphere s.center s.radius
⊢ 2 • ∡ p₁ p₂ p₄ = 2 • ∡ p₁ p₃ p₄
state_after: case intro
V : Type u_1
P : Type u_2
inst✝⁴ : NormedAddCommGroup V
inst✝³ : InnerProductSpace ℝ V
inst✝² : MetricSpace P
inst✝¹ : NormedAddTorsor V P
hd2 : Fact (finrank ℝ V = 2)
inst✝ : Module.Oriented ℝ V (Fin 2)
p₁ p₂ p₃ p₄ : P
h : Cospherical {p₁, p₂, p₃, p₄}
hp₂p₁ : p₂ ≠ p₁
hp₂p₄ : p₂ ≠ p₄
hp₃p₁ : p₃ ≠ p₁
hp₃p₄ : p₃ ≠ p₄
s : Sphere P
hs : p₁ ∈ s ∧ p₂ ∈ s ∧ p₃ ∈ s ∧ p₄ ∈ s
⊢ 2 • ∡ p₁ p₂ p₄ = 2 • ∡ p₁ p₃ p₄

tactic: exact Sphere.two_zsmul_oangle_eq hs.1 hs.2.1 hs.2.2.1 hs.2.2.2 hp₂p₁ hp₂p₄ hp₃p₁ hp₃p₄
state_before: case intro
V : Type u_1
P : Type u_2
inst✝⁴ : NormedAddCommGroup V
inst✝³ : InnerProductSpace ℝ V
inst✝² : MetricSpace P
inst✝¹ : NormedAddTorsor V P
hd2 : Fact (finrank ℝ V = 2)
inst✝ : Module.Oriented ℝ V (Fin 2)
p₁ p₂ p₃ p₄ : P
h : Cospherical {p₁, p₂, p₃, p₄}
hp₂p₁ : p₂ ≠ p₁
hp₂p₄ : p₂ ≠ p₄
hp₃p₁ : p₃ ≠ p₁
hp₃p₄ : p₃ ≠ p₄
s : Sphere P
hs : p₁ ∈ s ∧ p₂ ∈ s ∧ p₃ ∈ s ∧ p₄ ∈ s
⊢ 2 • ∡ p₁ p₂ p₄ = 2 • ∡ p₁ p₃ p₄
state_after: no goals
Theorem: Fintype.card_units
File: Mathlib/Data/Fintype/Units.lean

tactic: rw [@Fintype.card_eq_card_units_add_one α, Nat.add_sub_cancel]
state_before: α : Type u_1
inst✝² : GroupWithZero α
inst✝¹ : Fintype α
inst✝ : DecidableEq α
⊢ card αˣ = card α - 1
state_after: no goals
Theorem: List.self_eq_append_left
File: Mathlib/Data/List/Basic.lean

tactic: rw [eq_comm, append_left_eq_self]
state_before: ι : Type u_1
α : Type u
β : Type v
γ : Type w
l₁ l₂ x y : List α
⊢ y = x ++ y ↔ x = []
state_after: no goals
Theorem: CategoryTheory.FunctorToTypes.inl_comp_binaryCoproductIso_hom
File: Mathlib/CategoryTheory/Limits/Shapes/FunctorToTypes.lean

tactic: simp only [binaryCoproductIso]
state_before: C : Type u
inst✝ : Category.{v, u} C
F G : C ⥤ Type w
⊢ Limits.coprod.inl ≫ (binaryCoproductIso F G).hom = coprod.inl
state_after: C : Type u
inst✝ : Category.{v, u} C
F G : C ⥤ Type w
⊢ Limits.coprod.inl ≫ (colimit.isoColimitCocone (binaryCoproductColimitCocone F G)).hom = coprod.inl

tactic: aesop
state_before: C : Type u
inst✝ : Category.{v, u} C
F G : C ⥤ Type w
⊢ Limits.coprod.inl ≫ (colimit.isoColimitCocone (binaryCoproductColimitCocone F G)).hom = coprod.inl
state_after: no goals
Theorem: BoxIntegral.Prepartition.mem_split_iff
File: Mathlib/Analysis/BoxIntegral/Partition/Split.lean

tactic: simp [split]
state_before: ι : Type u_1
M : Type u_2
n : ℕ
I J : Box ι
i : ι
x : ℝ
⊢ J ∈ split I i x ↔ ↑J = I.splitLower i x ∨ ↑J = I.splitUpper i x
state_after: no goals
Theorem: FirstOrder.Language.Substructure.closure_withConstants_eq
File: Mathlib/ModelTheory/Substructures.lean

tactic: refine closure_eq_of_le ((A.subset_union_right).trans subset_closure) ?_
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
A s : Set M
h : A ⊆ ↑S
⊢ (closure (L[[↑A]])).toFun s = ((closure L).toFun (A ∪ s)).withConstants ⋯
state_after: 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
A s : Set M
h : A ⊆ ↑S
⊢ ((closure L).toFun (A ∪ s)).withConstants ⋯ ≤ (closure (L[[↑A]])).toFun s

tactic: rw [← (L.lhomWithConstants A).substructureReduct.le_iff_le]
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
A s : Set M
h : A ⊆ ↑S
⊢ ((closure L).toFun (A ∪ s)).withConstants ⋯ ≤ (closure (L[[↑A]])).toFun s
state_after: 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
A s : Set M
h : A ⊆ ↑S
⊢ (L.lhomWithConstants ↑A).substructureReduct (((closure L).toFun (A ∪ s)).withConstants ⋯) ≤
    (L.lhomWithConstants ↑A).substructureReduct ((closure (L[[↑A]])).toFun s)

tactic: simp only [subset_closure, reduct_withConstants, closure_le, LHom.coe_substructureReduct,
  Set.union_subset_iff, and_true_iff]
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
A s : Set M
h : A ⊆ ↑S
⊢ (L.lhomWithConstants ↑A).substructureReduct (((closure L).toFun (A ∪ s)).withConstants ⋯) ≤
    (L.lhomWithConstants ↑A).substructureReduct ((closure (L[[↑A]])).toFun s)
state_after: 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
A s : Set M
h : A ⊆ ↑S
⊢ A ⊆ ↑((closure (L[[↑A]])).toFun s)

tactic: exact subset_closure_withConstants
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
A s : Set M
h : A ⊆ ↑S
⊢ A ⊆ ↑((closure (L[[↑A]])).toFun s)
state_after: no goals
Theorem: Finset.lt_sup'_iff
File: Mathlib/Data/Finset/Lattice.lean

tactic: rw [← WithBot.coe_lt_coe, coe_sup', Finset.lt_sup_iff]
state_before: F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
ι : Type u_5
κ : Type u_6
inst✝ : LinearOrder α
s : Finset ι
H : s.Nonempty
f : ι → α
a : α
⊢ a < s.sup' H f ↔ ∃ b ∈ s, a < f b
state_after: F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
ι : Type u_5
κ : Type u_6
inst✝ : LinearOrder α
s : Finset ι
H : s.Nonempty
f : ι → α
a : α
⊢ (∃ b ∈ s, ↑a < (WithBot.some ∘ f) b) ↔ ∃ b ∈ s, a < f b

tactic: exact exists_congr (fun _ => and_congr_right' WithBot.coe_lt_coe)
state_before: F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
ι : Type u_5
κ : Type u_6
inst✝ : LinearOrder α
s : Finset ι
H : s.Nonempty
f : ι → α
a : α
⊢ (∃ b ∈ s, ↑a < (WithBot.some ∘ f) b) ↔ ∃ b ∈ s, a < f b
state_after: no goals
Theorem: Submodule.tmul_mem_baseChange_of_mem
File: Mathlib/LinearAlgebra/TensorProduct/Tower.lean

tactic: rw [← mul_one a, ← smul_eq_mul, ← smul_tmul']
state_before: R : Type u_1
M : Type u_2
A : Type u_3
inst✝⁴ : CommSemiring R
inst✝³ : Semiring A
inst✝² : Algebra R A
inst✝¹ : AddCommMonoid M
inst✝ : Module R M
p : Submodule R M
a : A
m : M
hm : m ∈ p
⊢ a ⊗ₜ[R] m ∈ baseChange A p
state_after: R : Type u_1
M : Type u_2
A : Type u_3
inst✝⁴ : CommSemiring R
inst✝³ : Semiring A
inst✝² : Algebra R A
inst✝¹ : AddCommMonoid M
inst✝ : Module R M
p : Submodule R M
a : A
m : M
hm : m ∈ p
⊢ a • 1 ⊗ₜ[R] m ∈ baseChange A p

tactic: exact smul_mem (baseChange A p) a (subset_span ⟨m, hm, rfl⟩)
state_before: R : Type u_1
M : Type u_2
A : Type u_3
inst✝⁴ : CommSemiring R
inst✝³ : Semiring A
inst✝² : Algebra R A
inst✝¹ : AddCommMonoid M
inst✝ : Module R M
p : Submodule R M
a : A
m : M
hm : m ∈ p
⊢ a • 1 ⊗ₜ[R] m ∈ baseChange A p
state_after: no goals
Theorem: MeasurableSpace.exists_measurableSet_of_ne
File: Mathlib/MeasureTheory/MeasurableSpace/CountablyGenerated.lean

tactic: contrapose! h
state_before: α : Type u_1
β : Type u_2
inst✝¹ : MeasurableSpace α
inst✝ : SeparatesPoints α
x y : α
h : x ≠ y
⊢ ∃ s, MeasurableSet s ∧ x ∈ s ∧ y ∉ s
state_after: α : Type u_1
β : Type u_2
inst✝¹ : MeasurableSpace α
inst✝ : SeparatesPoints α
x y : α
h : ∀ (s : Set α), MeasurableSet s → x ∈ s → y ∈ s
⊢ x = y

tactic: exact separatesPoints_def h
state_before: α : Type u_1
β : Type u_2
inst✝¹ : MeasurableSpace α
inst✝ : SeparatesPoints α
x y : α
h : ∀ (s : Set α), MeasurableSet s → x ∈ s → y ∈ s
⊢ x = y
state_after: no goals
Theorem: SimpleGraph.neighborSet_subgraphOfAdj
File: Mathlib/Combinatorics/SimpleGraph/Subgraph.lean

tactic: split_ifs <;> subst_vars <;> simp [*, Set.singleton_def]
state_before: ι : Sort u_1
V : Type u
W : Type v
G : SimpleGraph V
G' : SimpleGraph W
inst✝ : DecidableEq V
u v w : V
hvw : G.Adj v w
⊢ (G.subgraphOfAdj hvw).neighborSet u = (if u = v then {w} else ∅) ∪ if u = w then {v} else ∅
state_after: no goals
Theorem: FirstOrder.Language.BoundedFormula.semanticallyEquivalent_not_not
File: Mathlib/ModelTheory/Satisfiability.lean

tactic: simp
state_before: L : Language
T : L.Theory
α : Type w
n : ℕ
φ ψ : L.BoundedFormula α n
M : T.ModelType
v : α → ↑M
xs : Fin n → ↑M
⊢ (φ ⇔ ∼∼φ).Realize v xs
state_after: no goals
Theorem: Rat.mul_nonneg
File: Mathlib/Algebra/Order/Ring/Rat.lean

tactic: have d₁0 : 0 < (d₁ : ℤ) := mod_cast Nat.pos_of_ne_zero h₁
state_before: a b c p q : ℚ
n₁ : ℤ
d₁ : ℕ
h₁ : d₁ ≠ 0
n₂ : ℤ
d₂ : ℕ
h₂ : d₂ ≠ 0
⊢ 0 ≤ n₁ /. ↑d₁ → 0 ≤ n₂ /. ↑d₂ → 0 ≤ n₁ /. ↑d₁ * (n₂ /. ↑d₂)
state_after: a b c p q : ℚ
n₁ : ℤ
d₁ : ℕ
h₁ : d₁ ≠ 0
n₂ : ℤ
d₂ : ℕ
h₂ : d₂ ≠ 0
d₁0 : 0 < ↑d₁
⊢ 0 ≤ n₁ /. ↑d₁ → 0 ≤ n₂ /. ↑d₂ → 0 ≤ n₁ /. ↑d₁ * (n₂ /. ↑d₂)

tactic: have d₂0 : 0 < (d₂ : ℤ) := mod_cast Nat.pos_of_ne_zero h₂
state_before: a b c p q : ℚ
n₁ : ℤ
d₁ : ℕ
h₁ : d₁ ≠ 0
n₂ : ℤ
d₂ : ℕ
h₂ : d₂ ≠ 0
d₁0 : 0 < ↑d₁
⊢ 0 ≤ n₁ /. ↑d₁ → 0 ≤ n₂ /. ↑d₂ → 0 ≤ n₁ /. ↑d₁ * (n₂ /. ↑d₂)
state_after: a b c p q : ℚ
n₁ : ℤ
d₁ : ℕ
h₁ : d₁ ≠ 0
n₂ : ℤ
d₂ : ℕ
h₂ : d₂ ≠ 0
d₁0 : 0 < ↑d₁
d₂0 : 0 < ↑d₂
⊢ 0 ≤ n₁ /. ↑d₁ → 0 ≤ n₂ /. ↑d₂ → 0 ≤ n₁ /. ↑d₁ * (n₂ /. ↑d₂)

tactic: simp only [d₁0, d₂0, mul_pos, divInt_nonneg_iff_of_pos_right,
  divInt_mul_divInt _ _ d₁0.ne' d₂0.ne']
state_before: a b c p q : ℚ
n₁ : ℤ
d₁ : ℕ
h₁ : d₁ ≠ 0
n₂ : ℤ
d₂ : ℕ
h₂ : d₂ ≠ 0
d₁0 : 0 < ↑d₁
d₂0 : 0 < ↑d₂
⊢ 0 ≤ n₁ /. ↑d₁ → 0 ≤ n₂ /. ↑d₂ → 0 ≤ n₁ /. ↑d₁ * (n₂ /. ↑d₂)
state_after: a b c p q : ℚ
n₁ : ℤ
d₁ : ℕ
h₁ : d₁ ≠ 0
n₂ : ℤ
d₂ : ℕ
h₂ : d₂ ≠ 0
d₁0 : 0 < ↑d₁
d₂0 : 0 < ↑d₂
⊢ 0 ≤ n₁ → 0 ≤ n₂ → 0 ≤ n₁ * n₂

tactic: apply mul_nonneg
state_before: a b c p q : ℚ
n₁ : ℤ
d₁ : ℕ
h₁ : d₁ ≠ 0
n₂ : ℤ
d₂ : ℕ
h₂ : d₂ ≠ 0
d₁0 : 0 < ↑d₁
d₂0 : 0 < ↑d₂
⊢ 0 ≤ n₁ → 0 ≤ n₂ → 0 ≤ n₁ * n₂
state_after: no goals
Theorem: SimpleGraph.Walk.coe_support_append
File: Mathlib/Combinatorics/SimpleGraph/Connectivity.lean

tactic: rw [support_append, ← Multiset.coe_add, coe_support]
state_before: V : Type u
V' : Type v
V'' : Type w
G : SimpleGraph V
G' : SimpleGraph V'
G'' : SimpleGraph V''
u v w : V
p : G.Walk u v
p' : G.Walk v w
⊢ ↑(p.append p').support = {u} + ↑p.support.tail + ↑p'.support.tail
state_after: no goals
Theorem: list_prod_mem
File: Mathlib/Algebra/Group/Submonoid/Membership.lean

tactic: lift l to List S using hl
state_before: M : Type u_1
A : Type u_2
B : Type u_3
inst✝² : Monoid M
inst✝¹ : SetLike B M
inst✝ : SubmonoidClass B M
S : B
l : List M
hl : ∀ x ∈ l, x ∈ S
⊢ l.prod ∈ S
state_after: case intro
M : Type u_1
A : Type u_2
B : Type u_3
inst✝² : Monoid M
inst✝¹ : SetLike B M
inst✝ : SubmonoidClass B M
S : B
l : List ↥S
⊢ (List.map Subtype.val l).prod ∈ S

tactic: rw [← coe_list_prod]
state_before: case intro
M : Type u_1
A : Type u_2
B : Type u_3
inst✝² : Monoid M
inst✝¹ : SetLike B M
inst✝ : SubmonoidClass B M
S : B
l : List ↥S
⊢ (List.map Subtype.val l).prod ∈ S
state_after: case intro
M : Type u_1
A : Type u_2
B : Type u_3
inst✝² : Monoid M
inst✝¹ : SetLike B M
inst✝ : SubmonoidClass B M
S : B
l : List ↥S
⊢ ↑l.prod ∈ S

tactic: exact l.prod.coe_prop
state_before: case intro
M : Type u_1
A : Type u_2
B : Type u_3
inst✝² : Monoid M
inst✝¹ : SetLike B M
inst✝ : SubmonoidClass B M
S : B
l : List ↥S
⊢ ↑l.prod ∈ S
state_after: no goals
Theorem: IsSquare.mul
File: Mathlib/Algebra/Group/Even.lean

tactic: rintro ⟨a, rfl⟩ ⟨b, rfl⟩
state_before: F : Type u_1
α : Type u_2
β : Type u_3
R : Type u_4
inst✝ : CommSemigroup α
a b : α
⊢ IsSquare a → IsSquare b → IsSquare (a * b)
state_after: case intro.intro
F : Type u_1
α : Type u_2
β : Type u_3
R : Type u_4
inst✝ : CommSemigroup α
a b : α
⊢ IsSquare (a * a * (b * b))

tactic: exact ⟨a * b, mul_mul_mul_comm _ _ _ _⟩
state_before: case intro.intro
F : Type u_1
α : Type u_2
β : Type u_3
R : Type u_4
inst✝ : CommSemigroup α
a b : α
⊢ IsSquare (a * a * (b * b))
state_after: no goals
Theorem: newton_seq_succ_dist
File: Mathlib/NumberTheory/Padics/Hensel.lean

tactic: rw [newton_seq_deriv_norm]
state_before: p : ℕ
inst✝ : Fact (Nat.Prime p)
F : Polynomial ℤ_[p]
a : ℤ_[p]
hnorm : ‖Polynomial.eval a F‖ < ‖Polynomial.eval a (Polynomial.derivative F)‖ ^ 2
hnsol : Polynomial.eval a F ≠ 0
n : ℕ
⊢ ‖Polynomial.eval (newton_seq n) F‖ / ‖Polynomial.eval (newton_seq n) (Polynomial.derivative F)‖ =
    ‖Polynomial.eval (newton_seq n) F‖ / ‖Polynomial.eval a (Polynomial.derivative F)‖
state_after: no goals
Theorem: Set.singleton_vsub_self
File: Mathlib/Algebra/AddTorsor.lean

tactic: rw [Set.singleton_vsub_singleton, vsub_self]
state_before: G : Type u_1
P : Type u_2
inst✝ : AddGroup G
T : AddTorsor G P
p : P
⊢ {p} -ᵥ {p} = {0}
state_after: no goals
Theorem: Quaternion.mul_imK
File: Mathlib/Algebra/Quaternion.lean

tactic: simp only [one_mul, neg_mul, sub_eq_add_neg, neg_neg]
state_before: S : Type u_1
T : Type u_2
R : Type u_3
inst✝ : CommRing R
r x y z : R
a b c : ℍ[R]
⊢ a.re * b.imK + a.imI * b.imJ - a.imJ * b.imI + a.imK * b.re =
    a.re * b.imK + a.imI * b.imJ - a.imJ * b.imI + a.imK * b.re
state_after: no goals
Theorem: Padic.complete''
File: Mathlib/NumberTheory/Padics/PadicNumbers.lean

tactic: obtain ⟨x, hx⟩ := complete' f
state_before: p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ⇑padicNormE
⊢ ∃ q, ∀ ε > 0, ∃ N, ∀ i ≥ N, padicNormE (↑f i - q) < ε
state_after: case intro
p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ⇑padicNormE
x : ℚ_[p]
hx : ∀ ε > 0, ∃ N, ∀ i ≥ N, padicNormE (x - ↑f i) < ε
⊢ ∃ q, ∀ ε > 0, ∃ N, ∀ i ≥ N, padicNormE (↑f i - q) < ε

tactic: refine ⟨x, fun ε hε => ?_⟩
state_before: case intro
p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ⇑padicNormE
x : ℚ_[p]
hx : ∀ ε > 0, ∃ N, ∀ i ≥ N, padicNormE (x - ↑f i) < ε
⊢ ∃ q, ∀ ε > 0, ∃ N, ∀ i ≥ N, padicNormE (↑f i - q) < ε
state_after: case intro
p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ⇑padicNormE
x : ℚ_[p]
hx : ∀ ε > 0, ∃ N, ∀ i ≥ N, padicNormE (x - ↑f i) < ε
ε : ℚ
hε : ε > 0
⊢ ∃ N, ∀ i ≥ N, padicNormE (↑f i - x) < ε

tactic: obtain ⟨N, hN⟩ := hx ε hε
state_before: case intro
p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ⇑padicNormE
x : ℚ_[p]
hx : ∀ ε > 0, ∃ N, ∀ i ≥ N, padicNormE (x - ↑f i) < ε
ε : ℚ
hε : ε > 0
⊢ ∃ N, ∀ i ≥ N, padicNormE (↑f i - x) < ε
state_after: case intro.intro
p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ⇑padicNormE
x : ℚ_[p]
hx : ∀ ε > 0, ∃ N, ∀ i ≥ N, padicNormE (x - ↑f i) < ε
ε : ℚ
hε : ε > 0
N : ℕ
hN : ∀ i ≥ N, padicNormE (x - ↑f i) < ε
⊢ ∃ N, ∀ i ≥ N, padicNormE (↑f i - x) < ε

tactic: refine ⟨N, fun i hi => ?_⟩
state_before: case intro.intro
p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ⇑padicNormE
x : ℚ_[p]
hx : ∀ ε > 0, ∃ N, ∀ i ≥ N, padicNormE (x - ↑f i) < ε
ε : ℚ
hε : ε > 0
N : ℕ
hN : ∀ i ≥ N, padicNormE (x - ↑f i) < ε
⊢ ∃ N, ∀ i ≥ N, padicNormE (↑f i - x) < ε
state_after: case intro.intro
p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ⇑padicNormE
x : ℚ_[p]
hx : ∀ ε > 0, ∃ N, ∀ i ≥ N, padicNormE (x - ↑f i) < ε
ε : ℚ
hε : ε > 0
N : ℕ
hN : ∀ i ≥ N, padicNormE (x - ↑f i) < ε
i : ℕ
hi : i ≥ N
⊢ padicNormE (↑f i - x) < ε

tactic: rw [padicNormE.map_sub]
state_before: case intro.intro
p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ⇑padicNormE
x : ℚ_[p]
hx : ∀ ε > 0, ∃ N, ∀ i ≥ N, padicNormE (x - ↑f i) < ε
ε : ℚ
hε : ε > 0
N : ℕ
hN : ∀ i ≥ N, padicNormE (x - ↑f i) < ε
i : ℕ
hi : i ≥ N
⊢ padicNormE (↑f i - x) < ε
state_after: case intro.intro
p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ⇑padicNormE
x : ℚ_[p]
hx : ∀ ε > 0, ∃ N, ∀ i ≥ N, padicNormE (x - ↑f i) < ε
ε : ℚ
hε : ε > 0
N : ℕ
hN : ∀ i ≥ N, padicNormE (x - ↑f i) < ε
i : ℕ
hi : i ≥ N
⊢ padicNormE (x - ↑f i) < ε

tactic: exact hN i hi
state_before: case intro.intro
p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ⇑padicNormE
x : ℚ_[p]
hx : ∀ ε > 0, ∃ N, ∀ i ≥ N, padicNormE (x - ↑f i) < ε
ε : ℚ
hε : ε > 0
N : ℕ
hN : ∀ i ≥ N, padicNormE (x - ↑f i) < ε
i : ℕ
hi : i ≥ N
⊢ padicNormE (x - ↑f i) < ε
state_after: no goals
Theorem: CochainComplex.HomComplex.Cochain.comp_v
File: Mathlib/Algebra/Homology/HomotopyCategory/HomComplex.lean

tactic: rw [← h₂, ← h₁, ← h, add_assoc]
state_before: C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
R : Type u_1
inst✝¹ : Ring R
inst✝ : Linear R C
F G K L : CochainComplex C ℤ
n m n₁ n₂ n₁₂ : ℤ
z₁ : Cochain F G n₁
z₂ : Cochain G K n₂
h : n₁ + n₂ = n₁₂
p₁ p₂ p₃ : ℤ
h₁ : p₁ + n₁ = p₂
h₂ : p₂ + n₂ = p₃
⊢ p₁ + n₁₂ = p₃
state_after: no goals

tactic: subst h₁
state_before: C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
R : Type u_1
inst✝¹ : Ring R
inst✝ : Linear R C
F G K L : CochainComplex C ℤ
n m n₁ n₂ n₁₂ : ℤ
z₁ : Cochain F G n₁
z₂ : Cochain G K n₂
h : n₁ + n₂ = n₁₂
p₁ p₂ p₃ : ℤ
h₁ : p₁ + n₁ = p₂
h₂ : p₂ + n₂ = p₃
⊢ (z₁.comp z₂ h).v p₁ p₃ ⋯ = z₁.v p₁ p₂ h₁ ≫ z₂.v p₂ p₃ h₂
state_after: C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
R : Type u_1
inst✝¹ : Ring R
inst✝ : Linear R C
F G K L : CochainComplex C ℤ
n m n₁ n₂ n₁₂ : ℤ
z₁ : Cochain F G n₁
z₂ : Cochain G K n₂
h : n₁ + n₂ = n₁₂
p₁ p₃ : ℤ
h₂ : p₁ + n₁ + n₂ = p₃
⊢ (z₁.comp z₂ h).v p₁ p₃ ⋯ = z₁.v p₁ (p₁ + n₁) ⋯ ≫ z₂.v (p₁ + n₁) p₃ h₂

tactic: rfl
state_before: C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
R : Type u_1
inst✝¹ : Ring R
inst✝ : Linear R C
F G K L : CochainComplex C ℤ
n m n₁ n₂ n₁₂ : ℤ
z₁ : Cochain F G n₁
z₂ : Cochain G K n₂
h : n₁ + n₂ = n₁₂
p₁ p₃ : ℤ
h₂ : p₁ + n₁ + n₂ = p₃
⊢ (z₁.comp z₂ h).v p₁ p₃ ⋯ = z₁.v p₁ (p₁ + n₁) ⋯ ≫ z₂.v (p₁ + n₁) p₃ h₂
state_after: no goals
Theorem: Finset.sup'_id_eq_csSup
File: Mathlib/Order/ConditionallyCompleteLattice/Finset.lean

tactic: rw [sup'_eq_csSup_image s hs, Set.image_id]
state_before: ι : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
inst✝ : ConditionallyCompleteLattice α
s : Finset α
hs : s.Nonempty
⊢ s.sup' hs id = sSup ↑s
state_after: no goals
Theorem: mem_nhdsWithin_prod_iff
File: Mathlib/Topology/Constructions.lean

tactic: rw [nhdsWithin_prod_eq, mem_prod_iff]
state_before: X : Type u
Y : Type v
Z : Type u_1
W : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝⁵ : TopologicalSpace X
inst✝⁴ : TopologicalSpace Y
inst✝³ : TopologicalSpace Z
inst✝² : TopologicalSpace W
inst✝¹ : TopologicalSpace ε
inst✝ : TopologicalSpace ζ
x : X
y : Y
s : Set (X × Y)
tx : Set X
ty : Set Y
⊢ s ∈ 𝓝[tx ×ˢ ty] (x, y) ↔ ∃ u ∈ 𝓝[tx] x, ∃ v ∈ 𝓝[ty] y, u ×ˢ v ⊆ s
state_after: no goals
Theorem: Set.MapsTo.extendDomain
File: Mathlib/Data/Set/Function.lean

tactic: rintro _ ⟨a, ha, rfl⟩
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
ι : Sort u_4
π : α → Type u_5
p : β → Prop
inst✝ : DecidablePred p
f : α ≃ Subtype p
g g₁ g₂ : Perm α
s t : Set α
h : MapsTo (⇑g) s t
⊢ MapsTo (⇑(g.extendDomain f)) (Subtype.val ∘ ⇑f '' s) (Subtype.val ∘ ⇑f '' t)
state_after: case intro.intro
α : Type u_1
β : Type u_2
γ : Type u_3
ι : Sort u_4
π : α → Type u_5
p : β → Prop
inst✝ : DecidablePred p
f : α ≃ Subtype p
g g₁ g₂ : Perm α
s t : Set α
h : MapsTo (⇑g) s t
a : α
ha : a ∈ s
⊢ (g.extendDomain f) ((Subtype.val ∘ ⇑f) a) ∈ Subtype.val ∘ ⇑f '' t

tactic: exact ⟨_, h ha, by simp_rw [Function.comp_apply, extendDomain_apply_image]⟩
state_before: case intro.intro
α : Type u_1
β : Type u_2
γ : Type u_3
ι : Sort u_4
π : α → Type u_5
p : β → Prop
inst✝ : DecidablePred p
f : α ≃ Subtype p
g g₁ g₂ : Perm α
s t : Set α
h : MapsTo (⇑g) s t
a : α
ha : a ∈ s
⊢ (g.extendDomain f) ((Subtype.val ∘ ⇑f) a) ∈ Subtype.val ∘ ⇑f '' t
state_after: no goals

tactic: simp_rw [Function.comp_apply, extendDomain_apply_image]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
ι : Sort u_4
π : α → Type u_5
p : β → Prop
inst✝ : DecidablePred p
f : α ≃ Subtype p
g g₁ g₂ : Perm α
s t : Set α
h : MapsTo (⇑g) s t
a : α
ha : a ∈ s
⊢ (Subtype.val ∘ ⇑f) (g a) = (g.extendDomain f) ((Subtype.val ∘ ⇑f) a)
state_after: no goals
Theorem: WfDvdMonoid.iff_wellFounded_associates
File: Mathlib/RingTheory/UniqueFactorizationDomain.lean

tactic: apply WfDvdMonoid.wellFounded_associates
state_before: α : Type u_1
inst✝ : CancelCommMonoidWithZero α
⊢ WfDvdMonoid α → WellFounded fun x x_1 => x < x_1
state_after: no goals
Theorem: Polynomial.leval_eq_smeval.linearMap
File: Mathlib/Algebra/Polynomial/Smeval.lean

tactic: refine LinearMap.ext ?_
state_before: R✝ : Type u_1
inst✝⁴ : Semiring R✝
p q : R✝[X]
S : Type u_2
inst✝³ : AddCommMonoid S
inst✝² : Pow S ℕ
inst✝¹ : Module R✝ S
x : S
R : Type u_3
inst✝ : Semiring R
r : R
⊢ leval r = smeval.linearMap R r
state_after: R✝ : Type u_1
inst✝⁴ : Semiring R✝
p q : R✝[X]
S : Type u_2
inst✝³ : AddCommMonoid S
inst✝² : Pow S ℕ
inst✝¹ : Module R✝ S
x : S
R : Type u_3
inst✝ : Semiring R
r : R
⊢ ∀ (x : R[X]), (leval r) x = (smeval.linearMap R r) x

tactic: intro
state_before: R✝ : Type u_1
inst✝⁴ : Semiring R✝
p q : R✝[X]
S : Type u_2
inst✝³ : AddCommMonoid S
inst✝² : Pow S ℕ
inst✝¹ : Module R✝ S
x : S
R : Type u_3
inst✝ : Semiring R
r : R
⊢ ∀ (x : R[X]), (leval r) x = (smeval.linearMap R r) x
state_after: R✝ : Type u_1
inst✝⁴ : Semiring R✝
p q : R✝[X]
S : Type u_2
inst✝³ : AddCommMonoid S
inst✝² : Pow S ℕ
inst✝¹ : Module R✝ S
x : S
R : Type u_3
inst✝ : Semiring R
r : R
x✝ : R[X]
⊢ (leval r) x✝ = (smeval.linearMap R r) x✝

tactic: rw [leval_apply, smeval.linearMap_apply, eval_eq_smeval]
state_before: R✝ : Type u_1
inst✝⁴ : Semiring R✝
p q : R✝[X]
S : Type u_2
inst✝³ : AddCommMonoid S
inst✝² : Pow S ℕ
inst✝¹ : Module R✝ S
x : S
R : Type u_3
inst✝ : Semiring R
r : R
x✝ : R[X]
⊢ (leval r) x✝ = (smeval.linearMap R r) x✝
state_after: no goals