1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: EReal.add_sub_cancel_right
File: Mathlib/Data/Real/EReal.lean

tactic: induction a
state_before: a : EReal
b : ℝ
⊢ a + ↑b - ↑b = a
state_after: case h_bot
b : ℝ
⊢ ⊥ + ↑b - ↑b = ⊥

case h_real
b a✝ : ℝ
⊢ ↑a✝ + ↑b - ↑b = ↑a✝

case h_top
b : ℝ
⊢ ⊤ + ↑b - ↑b = ⊤

tactic: rw [bot_add b, bot_sub b]
state_before: case h_bot
b : ℝ
⊢ ⊥ + ↑b - ↑b = ⊥
state_after: no goals

tactic: norm_cast
state_before: case h_real
b a✝ : ℝ
⊢ ↑a✝ + ↑b - ↑b = ↑a✝
state_after: case h_real
b a✝ : ℝ
⊢ a✝ + b - b = a✝

tactic: linarith
state_before: case h_real
b a✝ : ℝ
⊢ a✝ + b - b = a✝
state_after: no goals

tactic: rw [top_add_of_ne_bot (coe_ne_bot b), top_sub_coe]
state_before: case h_top
b : ℝ
⊢ ⊤ + ↑b - ↑b = ⊤
state_after: no goals
Theorem: FreeAlgebra.adjoin_range_ι
File: Mathlib/Algebra/FreeAlgebra.lean

tactic: set S := Algebra.adjoin R (Set.range (ι R : X → FreeAlgebra R X))
state_before: R : Type u_1
inst✝ : CommSemiring R
X : Type u_2
⊢ Algebra.adjoin R (Set.range (ι R)) = ⊤
state_after: R : Type u_1
inst✝ : CommSemiring R
X : Type u_2
S : Subalgebra R (FreeAlgebra R X) := Algebra.adjoin R (Set.range (ι R))
⊢ S = ⊤

tactic: refine top_unique fun x hx => ?_
state_before: R : Type u_1
inst✝ : CommSemiring R
X : Type u_2
S : Subalgebra R (FreeAlgebra R X) := Algebra.adjoin R (Set.range (ι R))
⊢ S = ⊤
state_after: R : Type u_1
inst✝ : CommSemiring R
X : Type u_2
S : Subalgebra R (FreeAlgebra R X) := Algebra.adjoin R (Set.range (ι R))
x : FreeAlgebra R X
hx : x ∈ ⊤
⊢ x ∈ S

tactic: clear hx
state_before: R : Type u_1
inst✝ : CommSemiring R
X : Type u_2
S : Subalgebra R (FreeAlgebra R X) := Algebra.adjoin R (Set.range (ι R))
x : FreeAlgebra R X
hx : x ∈ ⊤
⊢ x ∈ S
state_after: R : Type u_1
inst✝ : CommSemiring R
X : Type u_2
S : Subalgebra R (FreeAlgebra R X) := Algebra.adjoin R (Set.range (ι R))
x : FreeAlgebra R X
⊢ x ∈ S

tactic: induction x with
| h_grade0 => exact S.algebraMap_mem _
| h_add x y hx hy => exact S.add_mem hx hy
| h_mul x y hx hy => exact S.mul_mem hx hy
| h_grade1 x => exact Algebra.subset_adjoin (Set.mem_range_self _)
state_before: R : Type u_1
inst✝ : CommSemiring R
X : Type u_2
S : Subalgebra R (FreeAlgebra R X) := Algebra.adjoin R (Set.range (ι R))
x : FreeAlgebra R X
⊢ x ∈ S
state_after: no goals

tactic: exact S.algebraMap_mem _
state_before: case h_grade0
R : Type u_1
inst✝ : CommSemiring R
X : Type u_2
S : Subalgebra R (FreeAlgebra R X) := Algebra.adjoin R (Set.range (ι R))
r✝ : R
⊢ (algebraMap R (FreeAlgebra R X)) r✝ ∈ S
state_after: no goals

tactic: exact S.add_mem hx hy
state_before: case h_add
R : Type u_1
inst✝ : CommSemiring R
X : Type u_2
S : Subalgebra R (FreeAlgebra R X) := Algebra.adjoin R (Set.range (ι R))
x y : FreeAlgebra R X
hx : x ∈ S
hy : y ∈ S
⊢ x + y ∈ S
state_after: no goals

tactic: exact S.mul_mem hx hy
state_before: case h_mul
R : Type u_1
inst✝ : CommSemiring R
X : Type u_2
S : Subalgebra R (FreeAlgebra R X) := Algebra.adjoin R (Set.range (ι R))
x y : FreeAlgebra R X
hx : x ∈ S
hy : y ∈ S
⊢ x * y ∈ S
state_after: no goals

tactic: exact Algebra.subset_adjoin (Set.mem_range_self _)
state_before: case h_grade1
R : Type u_1
inst✝ : CommSemiring R
X : Type u_2
S : Subalgebra R (FreeAlgebra R X) := Algebra.adjoin R (Set.range (ι R))
x : X
⊢ ι R x ∈ S
state_after: no goals
Theorem: PEquiv.single_subsingleton_eq_refl
File: Mathlib/Data/PEquiv.lean

tactic: ext i j
state_before: α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝³ : DecidableEq α
inst✝² : DecidableEq β
inst✝¹ : DecidableEq γ
inst✝ : Subsingleton α
a b : α
⊢ single a b = PEquiv.refl α
state_after: case h.a
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝³ : DecidableEq α
inst✝² : DecidableEq β
inst✝¹ : DecidableEq γ
inst✝ : Subsingleton α
a b i j : α
⊢ j ∈ (single a b) i ↔ j ∈ (PEquiv.refl α) i

tactic: dsimp [single]
state_before: case h.a
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝³ : DecidableEq α
inst✝² : DecidableEq β
inst✝¹ : DecidableEq γ
inst✝ : Subsingleton α
a b i j : α
⊢ j ∈ (single a b) i ↔ j ∈ (PEquiv.refl α) i
state_after: case h.a
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝³ : DecidableEq α
inst✝² : DecidableEq β
inst✝¹ : DecidableEq γ
inst✝ : Subsingleton α
a b i j : α
⊢ (j ∈ if i = a then some b else none) ↔ j ∈ some i

tactic: rw [if_pos (Subsingleton.elim i a), Subsingleton.elim i j, Subsingleton.elim b j]
state_before: case h.a
α : Type u
β : Type v
γ : Type w
δ : Type x
inst✝³ : DecidableEq α
inst✝² : DecidableEq β
inst✝¹ : DecidableEq γ
inst✝ : Subsingleton α
a b i j : α
⊢ (j ∈ if i = a then some b else none) ↔ j ∈ some i
state_after: no goals
Theorem: eval_minpolyDiv_self
File: Mathlib/FieldTheory/Minpoly/MinpolyDiv.lean

tactic: rw [aeval_def, ← eval_map, ← derivative_map, ← minpolyDiv_spec R x]
state_before: R : Type u_2
K : Type ?u.21767
L : Type ?u.21770
S : Type u_1
inst✝⁵ : CommRing R
inst✝⁴ : Field K
inst✝³ : Field L
inst✝² : CommRing S
inst✝¹ : Algebra R S
inst✝ : Algebra K L
x : S
hx : IsIntegral R x
⊢ eval x (minpolyDiv R x) = (aeval x) (derivative (minpoly R x))
state_after: R : Type u_2
K : Type ?u.21767
L : Type ?u.21770
S : Type u_1
inst✝⁵ : CommRing R
inst✝⁴ : Field K
inst✝³ : Field L
inst✝² : CommRing S
inst✝¹ : Algebra R S
inst✝ : Algebra K L
x : S
hx : IsIntegral R x
⊢ eval x (minpolyDiv R x) = eval x (derivative (minpolyDiv R x * (X - C x)))

tactic: simp
state_before: R : Type u_2
K : Type ?u.21767
L : Type ?u.21770
S : Type u_1
inst✝⁵ : CommRing R
inst✝⁴ : Field K
inst✝³ : Field L
inst✝² : CommRing S
inst✝¹ : Algebra R S
inst✝ : Algebra K L
x : S
hx : IsIntegral R x
⊢ eval x (minpolyDiv R x) = eval x (derivative (minpolyDiv R x * (X - C x)))
state_after: no goals
Theorem: WeierstrassCurve.Affine.nonsingular_iff'
File: Mathlib/AlgebraicGeometry/EllipticCurve/Affine.lean

tactic: rw [Nonsingular, equation_iff', evalEval_polynomialX, evalEval_polynomialY]
state_before: R : Type u
inst✝ : CommRing R
W : Affine R
x y : R
⊢ W.Nonsingular x y ↔ W.Equation x y ∧ (W.a₁ * y - (3 * x ^ 2 + 2 * W.a₂ * x + W.a₄) ≠ 0 ∨ 2 * y + W.a₁ * x + W.a₃ ≠ 0)
state_after: no goals
Theorem: nilpotencyClass_le_of_surjective
File: Mathlib/GroupTheory/Nilpotent.lean

tactic: refine @Nat.find_mono _ _ (Classical.decPred _) (Classical.decPred _) ?_ _ _
state_before: G : Type u_1
inst✝² : Group G
H : Subgroup G
inst✝¹ : H.Normal
G' : Type u_2
inst✝ : Group G'
f : G →* G'
hf : Function.Surjective ⇑f
h : Group.IsNilpotent G
⊢ Group.nilpotencyClass G' ≤ Group.nilpotencyClass G
state_after: G : Type u_1
inst✝² : Group G
H : Subgroup G
inst✝¹ : H.Normal
G' : Type u_2
inst✝ : Group G'
f : G →* G'
hf : Function.Surjective ⇑f
h : Group.IsNilpotent G
⊢ ∀ (n : ℕ), upperCentralSeries G n = ⊤ → upperCentralSeries G' n = ⊤

tactic: intro n hn
state_before: G : Type u_1
inst✝² : Group G
H : Subgroup G
inst✝¹ : H.Normal
G' : Type u_2
inst✝ : Group G'
f : G →* G'
hf : Function.Surjective ⇑f
h : Group.IsNilpotent G
⊢ ∀ (n : ℕ), upperCentralSeries G n = ⊤ → upperCentralSeries G' n = ⊤
state_after: G : Type u_1
inst✝² : Group G
H : Subgroup G
inst✝¹ : H.Normal
G' : Type u_2
inst✝ : Group G'
f : G →* G'
hf : Function.Surjective ⇑f
h : Group.IsNilpotent G
n : ℕ
hn : upperCentralSeries G n = ⊤
⊢ upperCentralSeries G' n = ⊤

tactic: rw [eq_top_iff]
state_before: G : Type u_1
inst✝² : Group G
H : Subgroup G
inst✝¹ : H.Normal
G' : Type u_2
inst✝ : Group G'
f : G →* G'
hf : Function.Surjective ⇑f
h : Group.IsNilpotent G
n : ℕ
hn : upperCentralSeries G n = ⊤
⊢ upperCentralSeries G' n = ⊤
state_after: G : Type u_1
inst✝² : Group G
H : Subgroup G
inst✝¹ : H.Normal
G' : Type u_2
inst✝ : Group G'
f : G →* G'
hf : Function.Surjective ⇑f
h : Group.IsNilpotent G
n : ℕ
hn : upperCentralSeries G n = ⊤
⊢ ⊤ ≤ upperCentralSeries G' n

tactic: calc
  ⊤ = f.range := symm (f.range_top_of_surjective hf)
  _ = Subgroup.map f ⊤ := MonoidHom.range_eq_map _
  _ = Subgroup.map f (upperCentralSeries G n) := by rw [hn]
  _ ≤ upperCentralSeries G' n := upperCentralSeries.map hf n
state_before: G : Type u_1
inst✝² : Group G
H : Subgroup G
inst✝¹ : H.Normal
G' : Type u_2
inst✝ : Group G'
f : G →* G'
hf : Function.Surjective ⇑f
h : Group.IsNilpotent G
n : ℕ
hn : upperCentralSeries G n = ⊤
⊢ ⊤ ≤ upperCentralSeries G' n
state_after: no goals

tactic: rw [hn]
state_before: G : Type u_1
inst✝² : Group G
H : Subgroup G
inst✝¹ : H.Normal
G' : Type u_2
inst✝ : Group G'
f : G →* G'
hf : Function.Surjective ⇑f
h : Group.IsNilpotent G
n : ℕ
hn : upperCentralSeries G n = ⊤
⊢ Subgroup.map f ⊤ = Subgroup.map f (upperCentralSeries G n)
state_after: no goals
Theorem: Lagrange.nodalWeight_eq_eval_nodal_derative
File: Mathlib/LinearAlgebra/Lagrange.lean

tactic: rw [eval_nodal_derivative_eval_node_eq hi, nodalWeight_eq_eval_nodal_erase_inv]
state_before: F : Type u_1
inst✝¹ : Field F
ι : Type u_2
inst✝ : DecidableEq ι
s : Finset ι
v : ι → F
i : ι
hi : i ∈ s
⊢ nodalWeight s v i = (eval (v i) (derivative (nodal s v)))⁻¹
state_after: no goals
Theorem: Order.pred_lt_pred_iff
File: Mathlib/Order/SuccPred/Basic.lean

tactic: simp
state_before: α : Type u_1
β : Type u_2
inst✝² : Preorder α
inst✝¹ : PredOrder α
a b : α
inst✝ : NoMinOrder α
⊢ pred a < pred b ↔ a < b
state_after: no goals
Theorem: Equiv.Perm.isConj_iff_cycleType_eq
File: Mathlib/GroupTheory/Perm/Cycle/Type.lean

tactic: obtain ⟨π, rfl⟩ := isConj_iff.1 h
state_before: α : Type u_1
inst✝¹ : Fintype α
inst✝ : DecidableEq α
σ τ : Perm α
h : IsConj σ τ
⊢ σ.cycleType = τ.cycleType
state_after: case intro
α : Type u_1
inst✝¹ : Fintype α
inst✝ : DecidableEq α
σ π : Perm α
h : IsConj σ (π * σ * π⁻¹)
⊢ σ.cycleType = (π * σ * π⁻¹).cycleType

tactic: rw [cycleType_conj]
state_before: case intro
α : Type u_1
inst✝¹ : Fintype α
inst✝ : DecidableEq α
σ π : Perm α
h : IsConj σ (π * σ * π⁻¹)
⊢ σ.cycleType = (π * σ * π⁻¹).cycleType
state_after: no goals
Theorem: CategoryTheory.Iso.trans_refl
File: Mathlib/CategoryTheory/Iso.lean

tactic: ext
state_before: C : Type u
inst✝ : Category.{v, u} C
X Y Z : C
α : X ≅ Y
⊢ α ≪≫ refl Y = α
state_after: case w
C : Type u
inst✝ : Category.{v, u} C
X Y Z : C
α : X ≅ Y
⊢ (α ≪≫ refl Y).hom = α.hom

tactic: apply Category.comp_id
state_before: case w
C : Type u
inst✝ : Category.{v, u} C
X Y Z : C
α : X ≅ Y
⊢ (α ≪≫ refl Y).hom = α.hom
state_after: no goals
Theorem: FirstOrder.Language.BoundedFormula.realize_iSup
File: Mathlib/ModelTheory/Semantics.lean

tactic: simp only [iSup, realize_foldr_sup, List.mem_map, Finset.mem_toList,
  exists_exists_and_eq_and]
state_before: L : Language
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
α : Type u'
β : Type v'
γ : Type u_3
n : ℕ
T : L.Theory
s : Finset β
f : β → L.BoundedFormula α n
v : α → M
v' : Fin n → M
⊢ (iSup s f).Realize v v' ↔ ∃ b ∈ s, (f b).Realize v v'
state_after: no goals
Theorem: TensorProduct.exists_finset
File: Mathlib/LinearAlgebra/TensorProduct/Finiteness.lean

tactic: obtain ⟨S, h⟩ := exists_finsupp_left x
state_before: R : Type u_1
M : Type u_2
N : Type u_3
inst✝⁴ : CommSemiring R
inst✝³ : AddCommMonoid M
inst✝² : AddCommMonoid N
inst✝¹ : Module R M
inst✝ : Module R N
M₁ M₂ : Submodule R M
N₁ N₂ : Submodule R N
x : M ⊗[R] N
⊢ ∃ S, x = ∑ i ∈ S, i.1 ⊗ₜ[R] i.2
state_after: case intro
R : Type u_1
M : Type u_2
N : Type u_3
inst✝⁴ : CommSemiring R
inst✝³ : AddCommMonoid M
inst✝² : AddCommMonoid N
inst✝¹ : Module R M
inst✝ : Module R N
M₁ M₂ : Submodule R M
N₁ N₂ : Submodule R N
x : M ⊗[R] N
S : M →₀ N
h : x = S.sum fun m n => m ⊗ₜ[R] n
⊢ ∃ S, x = ∑ i ∈ S, i.1 ⊗ₜ[R] i.2

tactic: use S.graph
state_before: case intro
R : Type u_1
M : Type u_2
N : Type u_3
inst✝⁴ : CommSemiring R
inst✝³ : AddCommMonoid M
inst✝² : AddCommMonoid N
inst✝¹ : Module R M
inst✝ : Module R N
M₁ M₂ : Submodule R M
N₁ N₂ : Submodule R N
x : M ⊗[R] N
S : M →₀ N
h : x = S.sum fun m n => m ⊗ₜ[R] n
⊢ ∃ S, x = ∑ i ∈ S, i.1 ⊗ₜ[R] i.2
state_after: case h
R : Type u_1
M : Type u_2
N : Type u_3
inst✝⁴ : CommSemiring R
inst✝³ : AddCommMonoid M
inst✝² : AddCommMonoid N
inst✝¹ : Module R M
inst✝ : Module R N
M₁ M₂ : Submodule R M
N₁ N₂ : Submodule R N
x : M ⊗[R] N
S : M →₀ N
h : x = S.sum fun m n => m ⊗ₜ[R] n
⊢ x = ∑ i ∈ S.graph, i.1 ⊗ₜ[R] i.2

tactic: rw [h, Finsupp.sum]
state_before: case h
R : Type u_1
M : Type u_2
N : Type u_3
inst✝⁴ : CommSemiring R
inst✝³ : AddCommMonoid M
inst✝² : AddCommMonoid N
inst✝¹ : Module R M
inst✝ : Module R N
M₁ M₂ : Submodule R M
N₁ N₂ : Submodule R N
x : M ⊗[R] N
S : M →₀ N
h : x = S.sum fun m n => m ⊗ₜ[R] n
⊢ x = ∑ i ∈ S.graph, i.1 ⊗ₜ[R] i.2
state_after: case h
R : Type u_1
M : Type u_2
N : Type u_3
inst✝⁴ : CommSemiring R
inst✝³ : AddCommMonoid M
inst✝² : AddCommMonoid N
inst✝¹ : Module R M
inst✝ : Module R N
M₁ M₂ : Submodule R M
N₁ N₂ : Submodule R N
x : M ⊗[R] N
S : M →₀ N
h : x = S.sum fun m n => m ⊗ₜ[R] n
⊢ ∑ a ∈ S.support, a ⊗ₜ[R] S a = ∑ i ∈ S.graph, i.1 ⊗ₜ[R] i.2

tactic: apply Finset.sum_nbij' (fun m ↦ ⟨m, S m⟩) Prod.fst <;> simp
state_before: case h
R : Type u_1
M : Type u_2
N : Type u_3
inst✝⁴ : CommSemiring R
inst✝³ : AddCommMonoid M
inst✝² : AddCommMonoid N
inst✝¹ : Module R M
inst✝ : Module R N
M₁ M₂ : Submodule R M
N₁ N₂ : Submodule R N
x : M ⊗[R] N
S : M →₀ N
h : x = S.sum fun m n => m ⊗ₜ[R] n
⊢ ∑ a ∈ S.support, a ⊗ₜ[R] S a = ∑ i ∈ S.graph, i.1 ⊗ₜ[R] i.2
state_after: no goals
Theorem: Polynomial.prod_cyclotomic_eq_geom_sum
File: Mathlib/RingTheory/Polynomial/Cyclotomic/Basic.lean

tactic: suffices (∏ i ∈ n.divisors.erase 1, cyclotomic i ℤ) = ∑ i ∈ Finset.range n, X ^ i by
  simpa only [Polynomial.map_prod, map_cyclotomic_int, Polynomial.map_sum, Polynomial.map_pow,
    Polynomial.map_X] using congr_arg (map (Int.castRingHom R)) this
state_before: n : ℕ
h : 0 < n
R : Type u_1
inst✝ : CommRing R
⊢ ∏ i ∈ n.divisors.erase 1, cyclotomic i R = ∑ i ∈ range n, X ^ i
state_after: n : ℕ
h : 0 < n
R : Type u_1
inst✝ : CommRing R
⊢ ∏ i ∈ n.divisors.erase 1, cyclotomic i ℤ = ∑ i ∈ range n, X ^ i

tactic: rw [← mul_left_inj' (cyclotomic_ne_zero 1 ℤ), prod_erase_mul _ _ (Nat.one_mem_divisors.2 h.ne'),
  cyclotomic_one, geom_sum_mul, prod_cyclotomic_eq_X_pow_sub_one h]
state_before: n : ℕ
h : 0 < n
R : Type u_1
inst✝ : CommRing R
⊢ ∏ i ∈ n.divisors.erase 1, cyclotomic i ℤ = ∑ i ∈ range n, X ^ i
state_after: no goals

tactic: simpa only [Polynomial.map_prod, map_cyclotomic_int, Polynomial.map_sum, Polynomial.map_pow,
  Polynomial.map_X] using congr_arg (map (Int.castRingHom R)) this
state_before: n : ℕ
h : 0 < n
R : Type u_1
inst✝ : CommRing R
this : ∏ i ∈ n.divisors.erase 1, cyclotomic i ℤ = ∑ i ∈ range n, X ^ i
⊢ ∏ i ∈ n.divisors.erase 1, cyclotomic i R = ∑ i ∈ range n, X ^ i
state_after: no goals
Theorem: CategoryTheory.Limits.Types.descSet_univ
File: Mathlib/CategoryTheory/Limits/Preserves/Ulift.lean

tactic: simp [descSet_spec]
state_before: J : Type u_1
inst✝ : Category.{u_2, u_1} J
K : J ⥤ Type u
c : Cocone K
hc : IsColimit c
lc : Cocone (K ⋙ uliftFunctor.{v, u})
⊢ descSet hc Set.univ = Set.univ
state_after: no goals
Theorem: Matroid.Base.basis_of_subset
File: Mathlib/Data/Matroid/Basic.lean

tactic: rw [basis_iff, and_iff_right hB.indep, and_iff_right hBX]
state_before: α : Type u_1
M : Matroid α
X B : Set α
hX : autoParam (X ⊆ M.E) _auto✝
hB : M.Base B
hBX : B ⊆ X
⊢ M.Basis B X
state_after: α : Type u_1
M : Matroid α
X B : Set α
hX : autoParam (X ⊆ M.E) _auto✝
hB : M.Base B
hBX : B ⊆ X
⊢ ∀ (J : Set α), M.Indep J → B ⊆ J → J ⊆ X → B = J

tactic: exact fun J hJ hBJ _ ↦ hB.eq_of_subset_indep hJ hBJ
state_before: α : Type u_1
M : Matroid α
X B : Set α
hX : autoParam (X ⊆ M.E) _auto✝
hB : M.Base B
hBX : B ⊆ X
⊢ ∀ (J : Set α), M.Indep J → B ⊆ J → J ⊆ X → B = J
state_after: no goals
Theorem: InnerProductGeometry.angle_sub_eq_arcsin_of_inner_eq_zero
File: Mathlib/Geometry/Euclidean/Angle/Unoriented/RightAngle.lean

tactic: rw [← neg_eq_zero, ← inner_neg_right] at h
state_before: V : Type u_1
inst✝¹ : NormedAddCommGroup V
inst✝ : InnerProductSpace ℝ V
x y : V
h : ⟪x, y⟫_ℝ = 0
h0 : x ≠ 0 ∨ y ≠ 0
⊢ angle x (x - y) = Real.arcsin (‖y‖ / ‖x - y‖)
state_after: V : Type u_1
inst✝¹ : NormedAddCommGroup V
inst✝ : InnerProductSpace ℝ V
x y : V
h : ⟪x, -y⟫_ℝ = 0
h0 : x ≠ 0 ∨ y ≠ 0
⊢ angle x (x - y) = Real.arcsin (‖y‖ / ‖x - y‖)

tactic: rw [or_comm, ← neg_ne_zero, or_comm] at h0
state_before: V : Type u_1
inst✝¹ : NormedAddCommGroup V
inst✝ : InnerProductSpace ℝ V
x y : V
h : ⟪x, -y⟫_ℝ = 0
h0 : x ≠ 0 ∨ y ≠ 0
⊢ angle x (x - y) = Real.arcsin (‖y‖ / ‖x - y‖)
state_after: V : Type u_1
inst✝¹ : NormedAddCommGroup V
inst✝ : InnerProductSpace ℝ V
x y : V
h : ⟪x, -y⟫_ℝ = 0
h0 : x ≠ 0 ∨ -y ≠ 0
⊢ angle x (x - y) = Real.arcsin (‖y‖ / ‖x - y‖)

tactic: rw [sub_eq_add_neg, angle_add_eq_arcsin_of_inner_eq_zero h h0, norm_neg]
state_before: V : Type u_1
inst✝¹ : NormedAddCommGroup V
inst✝ : InnerProductSpace ℝ V
x y : V
h : ⟪x, -y⟫_ℝ = 0
h0 : x ≠ 0 ∨ -y ≠ 0
⊢ angle x (x - y) = Real.arcsin (‖y‖ / ‖x - y‖)
state_after: no goals
Theorem: EuclideanGeometry.circumsphere_eq_of_cospherical
File: Mathlib/Geometry/Euclidean/Circumcenter.lean

tactic: rcases exists_circumsphere_eq_of_cospherical hd hc with ⟨r, hr⟩
state_before: V : Type u_1
P : Type u_2
inst✝⁴ : NormedAddCommGroup V
inst✝³ : InnerProductSpace ℝ V
inst✝² : MetricSpace P
inst✝¹ : NormedAddTorsor V P
ps : Set P
n : ℕ
inst✝ : FiniteDimensional ℝ V
hd : finrank ℝ V = n
hc : Cospherical ps
sx₁ sx₂ : Simplex ℝ P n
hsx₁ : Set.range sx₁.points ⊆ ps
hsx₂ : Set.range sx₂.points ⊆ ps
⊢ sx₁.circumsphere = sx₂.circumsphere
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
ps : Set P
n : ℕ
inst✝ : FiniteDimensional ℝ V
hd : finrank ℝ V = n
hc : Cospherical ps
sx₁ sx₂ : Simplex ℝ P n
hsx₁ : Set.range sx₁.points ⊆ ps
hsx₂ : Set.range sx₂.points ⊆ ps
r : Sphere P
hr : ∀ (sx : Simplex ℝ P n), Set.range sx.points ⊆ ps → sx.circumsphere = r
⊢ sx₁.circumsphere = sx₂.circumsphere

tactic: rw [hr sx₁ hsx₁, hr sx₂ hsx₂]
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
ps : Set P
n : ℕ
inst✝ : FiniteDimensional ℝ V
hd : finrank ℝ V = n
hc : Cospherical ps
sx₁ sx₂ : Simplex ℝ P n
hsx₁ : Set.range sx₁.points ⊆ ps
hsx₂ : Set.range sx₂.points ⊆ ps
r : Sphere P
hr : ∀ (sx : Simplex ℝ P n), Set.range sx.points ⊆ ps → sx.circumsphere = r
⊢ sx₁.circumsphere = sx₂.circumsphere
state_after: no goals
Theorem: Bool.coe_sort_true
File: Mathlib/Init/Data/Bool/Lemmas.lean

tactic: simp
state_before: ⊢ (true = true) = True
state_after: no goals
Theorem: hasStrictFDerivAt_const
File: Mathlib/Analysis/Calculus/FDeriv/Basic.lean

tactic: simp only [zero_apply, sub_self]
state_before: 𝕜 : Type u_1
inst✝⁸ : NontriviallyNormedField 𝕜
E : Type u_2
inst✝⁷ : NormedAddCommGroup E
inst✝⁶ : NormedSpace 𝕜 E
F : Type u_3
inst✝⁵ : NormedAddCommGroup F
inst✝⁴ : NormedSpace 𝕜 F
G : Type u_4
inst✝³ : NormedAddCommGroup G
inst✝² : NormedSpace 𝕜 G
G' : Type u_5
inst✝¹ : NormedAddCommGroup G'
inst✝ : NormedSpace 𝕜 G'
f f₀ f₁ g : E → F
f' f₀' f₁' g' e : E →L[𝕜] F
x✝¹ : E
s t : Set E
L L₁ L₂ : Filter E
c : F
x : E
x✝ : E × E
⊢ 0 = (fun x => c) x✝.1 - (fun x => c) x✝.2 - 0 (x✝.1 - x✝.2)
state_after: no goals
Theorem: MeasureTheory.HasFiniteIntegral.mono
File: Mathlib/MeasureTheory/Function/L1Space.lean

tactic: simp only [hasFiniteIntegral_iff_norm] at *
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
m : MeasurableSpace α
μ ν : Measure α
inst✝² : MeasurableSpace δ
inst✝¹ : NormedAddCommGroup β
inst✝ : NormedAddCommGroup γ
f : α → β
g : α → γ
hg : HasFiniteIntegral g μ
h : ∀ᵐ (a : α) ∂μ, ‖f a‖ ≤ ‖g a‖
⊢ HasFiniteIntegral f μ
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
m : MeasurableSpace α
μ ν : Measure α
inst✝² : MeasurableSpace δ
inst✝¹ : NormedAddCommGroup β
inst✝ : NormedAddCommGroup γ
f : α → β
g : α → γ
h : ∀ᵐ (a : α) ∂μ, ‖f a‖ ≤ ‖g a‖
hg : ∫⁻ (a : α), ENNReal.ofReal ‖g a‖ ∂μ < ⊤
⊢ ∫⁻ (a : α), ENNReal.ofReal ‖f a‖ ∂μ < ⊤

tactic: calc
  (∫⁻ a, ENNReal.ofReal ‖f a‖ ∂μ) ≤ ∫⁻ a : α, ENNReal.ofReal ‖g a‖ ∂μ :=
    lintegral_mono_ae (h.mono fun a h => ofReal_le_ofReal h)
  _ < ∞ := hg
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
m : MeasurableSpace α
μ ν : Measure α
inst✝² : MeasurableSpace δ
inst✝¹ : NormedAddCommGroup β
inst✝ : NormedAddCommGroup γ
f : α → β
g : α → γ
h : ∀ᵐ (a : α) ∂μ, ‖f a‖ ≤ ‖g a‖
hg : ∫⁻ (a : α), ENNReal.ofReal ‖g a‖ ∂μ < ⊤
⊢ ∫⁻ (a : α), ENNReal.ofReal ‖f a‖ ∂μ < ⊤
state_after: no goals
Theorem: CategoryTheory.Limits.kernelZeroIsoSource_inv
File: Mathlib/CategoryTheory/Limits/Shapes/Kernels.lean

tactic: simp
state_before: C : Type u
inst✝² : Category.{v, u} C
inst✝¹ : HasZeroMorphisms C
X Y : C
f : X ⟶ Y
inst✝ : HasKernel f
⊢ 𝟙 X ≫ 0 = 0
state_after: no goals

tactic: ext
state_before: C : Type u
inst✝² : Category.{v, u} C
inst✝¹ : HasZeroMorphisms C
X Y : C
f : X ⟶ Y
inst✝ : HasKernel f
⊢ kernelZeroIsoSource.inv = kernel.lift 0 (𝟙 X) ⋯
state_after: case h
C : Type u
inst✝² : Category.{v, u} C
inst✝¹ : HasZeroMorphisms C
X Y : C
f : X ⟶ Y
inst✝ : HasKernel f
⊢ kernelZeroIsoSource.inv ≫ equalizer.ι 0 0 = kernel.lift 0 (𝟙 X) ⋯ ≫ equalizer.ι 0 0

tactic: simp [kernelZeroIsoSource]
state_before: case h
C : Type u
inst✝² : Category.{v, u} C
inst✝¹ : HasZeroMorphisms C
X Y : C
f : X ⟶ Y
inst✝ : HasKernel f
⊢ kernelZeroIsoSource.inv ≫ equalizer.ι 0 0 = kernel.lift 0 (𝟙 X) ⋯ ≫ equalizer.ι 0 0
state_after: no goals
Theorem: CategoryTheory.Limits.coprod.map_desc
File: Mathlib/CategoryTheory/Limits/Shapes/BinaryProducts.lean

tactic: ext <;> simp
state_before: C : Type u
inst✝² : Category.{v, u} C
X Y S T U V W : C
inst✝¹ : HasBinaryCoproduct U W
inst✝ : HasBinaryCoproduct T V
f : U ⟶ S
g : W ⟶ S
h : T ⟶ U
k : V ⟶ W
⊢ map h k ≫ desc f g = desc (h ≫ f) (k ≫ g)
state_after: no goals
Theorem: Matrix.det_updateColumn_sum
File: Mathlib/LinearAlgebra/Matrix/Determinant/Basic.lean

tactic: rw [← det_transpose, ← updateRow_transpose, ← det_transpose A]
state_before: m : Type u_1
n : Type u_2
inst✝⁴ : DecidableEq n
inst✝³ : Fintype n
inst✝² : DecidableEq m
inst✝¹ : Fintype m
R : Type v
inst✝ : CommRing R
A : Matrix n n R
j : n
c : n → R
⊢ (A.updateColumn j fun k => ∑ i : n, c i • A k i).det = c j • A.det
state_after: m : Type u_1
n : Type u_2
inst✝⁴ : DecidableEq n
inst✝³ : Fintype n
inst✝² : DecidableEq m
inst✝¹ : Fintype m
R : Type v
inst✝ : CommRing R
A : Matrix n n R
j : n
c : n → R
⊢ (Aᵀ.updateRow j fun k => ∑ i : n, c i • A k i).det = c j • Aᵀ.det

tactic: convert det_updateRow_sum A.transpose j c
state_before: m : Type u_1
n : Type u_2
inst✝⁴ : DecidableEq n
inst✝³ : Fintype n
inst✝² : DecidableEq m
inst✝¹ : Fintype m
R : Type v
inst✝ : CommRing R
A : Matrix n n R
j : n
c : n → R
⊢ (Aᵀ.updateRow j fun k => ∑ i : n, c i • A k i).det = c j • Aᵀ.det
state_after: case h.e'_2.h.e'_6.h.e'_7.h
m : Type u_1
n : Type u_2
inst✝⁴ : DecidableEq n
inst✝³ : Fintype n
inst✝² : DecidableEq m
inst✝¹ : Fintype m
R : Type v
inst✝ : CommRing R
A : Matrix n n R
j : n
c : n → R
x✝ : n
⊢ ∑ i : n, c i • A x✝ i = (∑ k : n, c k • Aᵀ k) x✝

tactic: simp only [smul_eq_mul, Finset.sum_apply, Pi.smul_apply, transpose_apply]
state_before: case h.e'_2.h.e'_6.h.e'_7.h
m : Type u_1
n : Type u_2
inst✝⁴ : DecidableEq n
inst✝³ : Fintype n
inst✝² : DecidableEq m
inst✝¹ : Fintype m
R : Type v
inst✝ : CommRing R
A : Matrix n n R
j : n
c : n → R
x✝ : n
⊢ ∑ i : n, c i • A x✝ i = (∑ k : n, c k • Aᵀ k) x✝
state_after: no goals
Theorem: BoxIntegral.Box.splitLower_def
File: Mathlib/Analysis/BoxIntegral/Partition/Split.lean

tactic: simp (config := { unfoldPartialApp := true }) only [splitLower, mk'_eq_coe, min_eq_left h.2.le,
  update, and_self]
state_before: ι : Type u_1
M : Type u_2
n : ℕ
I : Box ι
i✝ : ι
x✝ : ℝ
y : ι → ℝ
inst✝ : DecidableEq ι
i : ι
x : ℝ
h : x ∈ Ioo (I.lower i) (I.upper i)
h' : optParam (∀ (j : ι), I.lower j < update I.upper i x j) ⋯
⊢ I.splitLower i x = ↑{ lower := I.lower, upper := update I.upper i x, lower_lt_upper := h' }
state_after: no goals
Theorem: Trivialization.preimageSingletonHomeomorph_symm_apply
File: Mathlib/Topology/FiberBundle/Trivialization.lean

tactic: rw [mem_preimage, e.proj_symm_apply' hb, mem_singleton_iff]
state_before: ι : Type u_1
B : Type u_2
F : Type u_3
E : B → Type u_4
Z : Type u_5
inst✝³ : TopologicalSpace B
inst✝² : TopologicalSpace F
proj : Z → B
inst✝¹ : TopologicalSpace Z
inst✝ : TopologicalSpace (TotalSpace F E)
e : Trivialization F proj
x : Z
b : B
hb : b ∈ e.baseSet
p : F
⊢ ↑e.symm (b, p) ∈ proj ⁻¹' {b}
state_after: no goals