1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: UniqueFactorizationMonoid.dvdNotUnit_iff_normalizedFactors_lt_normalizedFactors
File: Mathlib/RingTheory/UniqueFactorizationDomain.lean

tactic: constructor
state_before: α : Type u_1
inst✝² : CancelCommMonoidWithZero α
inst✝¹ : NormalizationMonoid α
inst✝ : UniqueFactorizationMonoid α
x y : α
hx : x ≠ 0
hy : y ≠ 0
⊢ DvdNotUnit x y ↔ normalizedFactors x < normalizedFactors y
state_after: case mp
α : Type u_1
inst✝² : CancelCommMonoidWithZero α
inst✝¹ : NormalizationMonoid α
inst✝ : UniqueFactorizationMonoid α
x y : α
hx : x ≠ 0
hy : y ≠ 0
⊢ DvdNotUnit x y → normalizedFactors x < normalizedFactors y

case mpr
α : Type u_1
inst✝² : CancelCommMonoidWithZero α
inst✝¹ : NormalizationMonoid α
inst✝ : UniqueFactorizationMonoid α
x y : α
hx : x ≠ 0
hy : y ≠ 0
⊢ normalizedFactors x < normalizedFactors y → DvdNotUnit x y

tactic: rintro ⟨_, c, hc, rfl⟩
state_before: case mp
α : Type u_1
inst✝² : CancelCommMonoidWithZero α
inst✝¹ : NormalizationMonoid α
inst✝ : UniqueFactorizationMonoid α
x y : α
hx : x ≠ 0
hy : y ≠ 0
⊢ DvdNotUnit x y → normalizedFactors x < normalizedFactors y
state_after: case mp.intro.intro.intro
α : Type u_1
inst✝² : CancelCommMonoidWithZero α
inst✝¹ : NormalizationMonoid α
inst✝ : UniqueFactorizationMonoid α
x : α
hx left✝ : x ≠ 0
c : α
hc : ¬IsUnit c
hy : x * c ≠ 0
⊢ normalizedFactors x < normalizedFactors (x * c)

tactic: simp only [hx, right_ne_zero_of_mul hy, normalizedFactors_mul, Ne, not_false_iff,
  lt_add_iff_pos_right, normalizedFactors_pos, hc]
state_before: case mp.intro.intro.intro
α : Type u_1
inst✝² : CancelCommMonoidWithZero α
inst✝¹ : NormalizationMonoid α
inst✝ : UniqueFactorizationMonoid α
x : α
hx left✝ : x ≠ 0
c : α
hc : ¬IsUnit c
hy : x * c ≠ 0
⊢ normalizedFactors x < normalizedFactors (x * c)
state_after: no goals

tactic: intro h
state_before: case mpr
α : Type u_1
inst✝² : CancelCommMonoidWithZero α
inst✝¹ : NormalizationMonoid α
inst✝ : UniqueFactorizationMonoid α
x y : α
hx : x ≠ 0
hy : y ≠ 0
⊢ normalizedFactors x < normalizedFactors y → DvdNotUnit x y
state_after: case mpr
α : Type u_1
inst✝² : CancelCommMonoidWithZero α
inst✝¹ : NormalizationMonoid α
inst✝ : UniqueFactorizationMonoid α
x y : α
hx : x ≠ 0
hy : y ≠ 0
h : normalizedFactors x < normalizedFactors y
⊢ DvdNotUnit x y

tactic: exact
  dvdNotUnit_of_dvd_of_not_dvd
    ((dvd_iff_normalizedFactors_le_normalizedFactors hx hy).mpr h.le)
    (mt (dvd_iff_normalizedFactors_le_normalizedFactors hy hx).mp h.not_le)
state_before: case mpr
α : Type u_1
inst✝² : CancelCommMonoidWithZero α
inst✝¹ : NormalizationMonoid α
inst✝ : UniqueFactorizationMonoid α
x y : α
hx : x ≠ 0
hy : y ≠ 0
h : normalizedFactors x < normalizedFactors y
⊢ DvdNotUnit x y
state_after: no goals
Theorem: ExteriorAlgebra.liftAlternating_one
File: Mathlib/LinearAlgebra/ExteriorAlgebra/OfAlternating.lean

tactic: dsimp [liftAlternating]
state_before: R : Type u_1
M : Type u_2
N : Type u_3
N' : Type u_4
inst✝⁶ : CommRing R
inst✝⁵ : AddCommGroup M
inst✝⁴ : AddCommGroup N
inst✝³ : AddCommGroup N'
inst✝² : Module R M
inst✝¹ : Module R N
inst✝ : Module R N'
f : (i : ℕ) → M [⋀^Fin i]→ₗ[R] N
⊢ (liftAlternating f) 1 = (f 0) 0
state_after: R : Type u_1
M : Type u_2
N : Type u_3
N' : Type u_4
inst✝⁶ : CommRing R
inst✝⁵ : AddCommGroup M
inst✝⁴ : AddCommGroup N
inst✝³ : AddCommGroup N'
inst✝² : Module R M
inst✝¹ : Module R N
inst✝ : Module R N'
f : (i : ℕ) → M [⋀^Fin i]→ₗ[R] N
⊢ (((foldl 0 (LinearMap.mk₂ R (fun m f i => (f (i + 1)).curryLeft m) ⋯ ⋯ ⋯ ⋯) ⋯) f) 1 0) 0 = (f 0) 0

tactic: rw [foldl_one]
state_before: R : Type u_1
M : Type u_2
N : Type u_3
N' : Type u_4
inst✝⁶ : CommRing R
inst✝⁵ : AddCommGroup M
inst✝⁴ : AddCommGroup N
inst✝³ : AddCommGroup N'
inst✝² : Module R M
inst✝¹ : Module R N
inst✝ : Module R N'
f : (i : ℕ) → M [⋀^Fin i]→ₗ[R] N
⊢ (((foldl 0 (LinearMap.mk₂ R (fun m f i => (f (i + 1)).curryLeft m) ⋯ ⋯ ⋯ ⋯) ⋯) f) 1 0) 0 = (f 0) 0
state_after: no goals
Theorem: Function.Antiperiodic.nat_mul_sub_eq
File: Mathlib/Algebra/Periodic.lean

tactic: simpa only [nsmul_eq_mul, zsmul_eq_mul, Int.cast_pow, Int.cast_neg,
  Int.cast_one] using h.nsmul_sub_eq n
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
f g : α → β
c c₁ c₂ x : α
inst✝¹ : Ring α
inst✝ : Ring β
h : Antiperiodic f c
n : ℕ
⊢ f (↑n * c - x) = (-1) ^ n * f (-x)
state_after: no goals
Theorem: Complex.sinh_add_aux
File: Mathlib/Data/Complex/Exponential.lean

tactic: ring
state_before: x y a b c d : ℂ
⊢ (a - b) * (c + d) + (a + b) * (c - d) = 2 * (a * c - b * d)
state_after: no goals
Theorem: Polynomial.eval_C_mul
File: Mathlib/Algebra/Polynomial/Eval.lean

tactic: induction p using Polynomial.induction_on' with
| h_add p q ph qh =>
  simp only [mul_add, eval_add, ph, qh]
| h_monomial n b =>
  simp only [mul_assoc, C_mul_monomial, eval_monomial]
state_before: R : Type u
S : Type v
T : Type w
ι : Type y
a b : R
m n : ℕ
inst✝ : Semiring R
p q r : R[X]
x : R
⊢ eval x (C a * p) = a * eval x p
state_after: no goals

tactic: simp only [mul_add, eval_add, ph, qh]
state_before: case h_add
R : Type u
S : Type v
T : Type w
ι : Type y
a b : R
m n : ℕ
inst✝ : Semiring R
p✝ q✝ r : R[X]
x : R
p q : R[X]
ph : eval x (C a * p) = a * eval x p
qh : eval x (C a * q) = a * eval x q
⊢ eval x (C a * (p + q)) = a * eval x (p + q)
state_after: no goals

tactic: simp only [mul_assoc, C_mul_monomial, eval_monomial]
state_before: case h_monomial
R : Type u
S : Type v
T : Type w
ι : Type y
a b✝ : R
m n✝ : ℕ
inst✝ : Semiring R
p q r : R[X]
x : R
n : ℕ
b : R
⊢ eval x (C a * (monomial n) b) = a * eval x ((monomial n) b)
state_after: no goals
Theorem: Matrix.fromColumns_mul_fromRows_eq_one_comm
File: Mathlib/Data/Matrix/ColumnRowPartitioned.lean

tactic: calc fromColumns A₁ A₂ * fromRows B₁ B₂ = 1
_ ↔ submatrix (fromColumns A₁ A₂) id e * submatrix (fromRows B₁ B₂) e id = 1 := by
  simp
_ ↔ submatrix (fromRows B₁ B₂) e id * submatrix (fromColumns A₁ A₂) id e = 1 :=
  mul_eq_one_comm
_ ↔ reindex e.symm e.symm (fromRows B₁ B₂ * fromColumns A₁ A₂) = reindex e.symm e.symm 1 := by
  simp only [reindex_apply, Equiv.symm_symm, submatrix_one_equiv,
      submatrix_mul (he₂ := Function.bijective_id)]
_ ↔ fromRows B₁ B₂ * fromColumns A₁ A₂ = 1 :=
  (reindex _ _).injective.eq_iff
state_before: R : Type u_1
m : Type u_2
m₁ : Type u_3
m₂ : Type u_4
n : Type u_5
n₁ : Type u_6
n₂ : Type u_7
inst✝¹² : Fintype m
inst✝¹¹ : Fintype m₁
inst✝¹⁰ : Fintype m₂
inst✝⁹ : Fintype n
inst✝⁸ : Fintype n₁
inst✝⁷ : Fintype n₂
inst✝⁶ : DecidableEq m
inst✝⁵ : DecidableEq m₁
inst✝⁴ : DecidableEq m₂
inst✝³ : DecidableEq n
inst✝² : DecidableEq n₁
inst✝¹ : DecidableEq n₂
inst✝ : CommRing R
e : n ≃ n₁ ⊕ n₂
A₁ : Matrix n n₁ R
A₂ : Matrix n n₂ R
B₁ : Matrix n₁ n R
B₂ : Matrix n₂ n R
⊢ A₁.fromColumns A₂ * B₁.fromRows B₂ = 1 ↔ B₁.fromRows B₂ * A₁.fromColumns A₂ = 1
state_after: no goals

tactic: simp
state_before: R : Type u_1
m : Type u_2
m₁ : Type u_3
m₂ : Type u_4
n : Type u_5
n₁ : Type u_6
n₂ : Type u_7
inst✝¹² : Fintype m
inst✝¹¹ : Fintype m₁
inst✝¹⁰ : Fintype m₂
inst✝⁹ : Fintype n
inst✝⁸ : Fintype n₁
inst✝⁷ : Fintype n₂
inst✝⁶ : DecidableEq m
inst✝⁵ : DecidableEq m₁
inst✝⁴ : DecidableEq m₂
inst✝³ : DecidableEq n
inst✝² : DecidableEq n₁
inst✝¹ : DecidableEq n₂
inst✝ : CommRing R
e : n ≃ n₁ ⊕ n₂
A₁ : Matrix n n₁ R
A₂ : Matrix n n₂ R
B₁ : Matrix n₁ n R
B₂ : Matrix n₂ n R
⊢ A₁.fromColumns A₂ * B₁.fromRows B₂ = 1 ↔ (A₁.fromColumns A₂).submatrix id ⇑e * (B₁.fromRows B₂).submatrix (⇑e) id = 1
state_after: no goals

tactic: simp only [reindex_apply, Equiv.symm_symm, submatrix_one_equiv,
    submatrix_mul (he₂ := Function.bijective_id)]
state_before: R : Type u_1
m : Type u_2
m₁ : Type u_3
m₂ : Type u_4
n : Type u_5
n₁ : Type u_6
n₂ : Type u_7
inst✝¹² : Fintype m
inst✝¹¹ : Fintype m₁
inst✝¹⁰ : Fintype m₂
inst✝⁹ : Fintype n
inst✝⁸ : Fintype n₁
inst✝⁷ : Fintype n₂
inst✝⁶ : DecidableEq m
inst✝⁵ : DecidableEq m₁
inst✝⁴ : DecidableEq m₂
inst✝³ : DecidableEq n
inst✝² : DecidableEq n₁
inst✝¹ : DecidableEq n₂
inst✝ : CommRing R
e : n ≃ n₁ ⊕ n₂
A₁ : Matrix n n₁ R
A₂ : Matrix n n₂ R
B₁ : Matrix n₁ n R
B₂ : Matrix n₂ n R
⊢ (B₁.fromRows B₂).submatrix (⇑e) id * (A₁.fromColumns A₂).submatrix id ⇑e = 1 ↔
    (reindex e.symm e.symm) (B₁.fromRows B₂ * A₁.fromColumns A₂) = (reindex e.symm e.symm) 1
state_after: no goals
Theorem: Cardinal.mk_fin
File: Mathlib/SetTheory/Cardinal/Basic.lean

tactic: simp
state_before: α β : Type u
n : ℕ
⊢ #(Fin n) = ↑n
state_after: no goals
Theorem: MeasureTheory.IsSetSemiring.diff_sUnion_eq_sUnion_diffFinset₀
File: Mathlib/MeasureTheory/SetSemiring.lean

tactic: classical
rw [(hC.exists_disjoint_finset_diff_eq hs hI).choose_spec.2.2]
simp only [diffFinset₀, coe_sdiff, coe_singleton, diff_singleton_subset_iff]
rw [sUnion_diff_singleton_empty]
state_before: α : Type u_1
C : Set (Set α)
s t : Set α
I : Finset (Set α)
hC : IsSetSemiring C
hs : s ∈ C
hI : ↑I ⊆ C
⊢ s \ ⋃₀ ↑I = ⋃₀ ↑(hC.diffFinset₀ hs hI)
state_after: no goals

tactic: rw [(hC.exists_disjoint_finset_diff_eq hs hI).choose_spec.2.2]
state_before: α : Type u_1
C : Set (Set α)
s t : Set α
I : Finset (Set α)
hC : IsSetSemiring C
hs : s ∈ C
hI : ↑I ⊆ C
⊢ s \ ⋃₀ ↑I = ⋃₀ ↑(hC.diffFinset₀ hs hI)
state_after: α : Type u_1
C : Set (Set α)
s t : Set α
I : Finset (Set α)
hC : IsSetSemiring C
hs : s ∈ C
hI : ↑I ⊆ C
⊢ ⋃₀ ↑⋯.choose = ⋃₀ ↑(hC.diffFinset₀ hs hI)

tactic: simp only [diffFinset₀, coe_sdiff, coe_singleton, diff_singleton_subset_iff]
state_before: α : Type u_1
C : Set (Set α)
s t : Set α
I : Finset (Set α)
hC : IsSetSemiring C
hs : s ∈ C
hI : ↑I ⊆ C
⊢ ⋃₀ ↑⋯.choose = ⋃₀ ↑(hC.diffFinset₀ hs hI)
state_after: α : Type u_1
C : Set (Set α)
s t : Set α
I : Finset (Set α)
hC : IsSetSemiring C
hs : s ∈ C
hI : ↑I ⊆ C
⊢ ⋃₀ ↑⋯.choose = ⋃₀ (↑⋯.choose \ {∅})

tactic: rw [sUnion_diff_singleton_empty]
state_before: α : Type u_1
C : Set (Set α)
s t : Set α
I : Finset (Set α)
hC : IsSetSemiring C
hs : s ∈ C
hI : ↑I ⊆ C
⊢ ⋃₀ ↑⋯.choose = ⋃₀ (↑⋯.choose \ {∅})
state_after: no goals
Theorem: frobenius_comp_frobeniusEquiv_symm
File: Mathlib/FieldTheory/Perfect.lean

tactic: ext
state_before: R : Type u_1
p m n : ℕ
inst✝² : CommSemiring R
inst✝¹ : ExpChar R p
inst✝ : PerfectRing R p
⊢ (frobenius R p).comp ↑(frobeniusEquiv R p).symm = RingHom.id R
state_after: case a
R : Type u_1
p m n : ℕ
inst✝² : CommSemiring R
inst✝¹ : ExpChar R p
inst✝ : PerfectRing R p
x✝ : R
⊢ ((frobenius R p).comp ↑(frobeniusEquiv R p).symm) x✝ = (RingHom.id R) x✝

tactic: simp
state_before: case a
R : Type u_1
p m n : ℕ
inst✝² : CommSemiring R
inst✝¹ : ExpChar R p
inst✝ : PerfectRing R p
x✝ : R
⊢ ((frobenius R p).comp ↑(frobeniusEquiv R p).symm) x✝ = (RingHom.id R) x✝
state_after: no goals
Theorem: CategoryTheory.BicartesianSq.of_has_biproduct₂
File: Mathlib/CategoryTheory/Limits/Shapes/CommSq.lean

tactic: convert of_is_biproduct₂ (BinaryBiproduct.isBilimit X Y)
state_before: C : Type u₁
inst✝³ : Category.{v₁, u₁} C
W X Y Z : C
f : W ⟶ X
g : W ⟶ Y
h : X ⟶ Z
i : Y ⟶ Z
inst✝² : HasZeroObject C
inst✝¹ : HasZeroMorphisms C
inst✝ : HasBinaryBiproduct X Y
⊢ BicartesianSq 0 0 biprod.inl biprod.inr
state_after: no goals
Theorem: CliffordAlgebra.ofBaseChange_tmul_one
File: Mathlib/LinearAlgebra/CliffordAlgebra/BaseChange.lean

tactic: show algebraMap _ _ z * ofBaseChangeAux A Q 1 = _
state_before: R : Type u_1
A : Type u_2
V : Type u_3
inst✝⁷ : CommRing R
inst✝⁶ : CommRing A
inst✝⁵ : AddCommGroup V
inst✝⁴ : Algebra R A
inst✝³ : Module R V
inst✝² : Module A V
inst✝¹ : IsScalarTower R A V
inst✝ : Invertible 2
Q : QuadraticForm R V
z : A
⊢ (ofBaseChange A Q) (z ⊗ₜ[R] 1) = (algebraMap A (CliffordAlgebra (QuadraticForm.baseChange A Q))) z
state_after: R : Type u_1
A : Type u_2
V : Type u_3
inst✝⁷ : CommRing R
inst✝⁶ : CommRing A
inst✝⁵ : AddCommGroup V
inst✝⁴ : Algebra R A
inst✝³ : Module R V
inst✝² : Module A V
inst✝¹ : IsScalarTower R A V
inst✝ : Invertible 2
Q : QuadraticForm R V
z : A
⊢ (algebraMap A (CliffordAlgebra (QuadraticForm.baseChange A Q))) z * (ofBaseChangeAux A Q) 1 =
    (algebraMap A (CliffordAlgebra (QuadraticForm.baseChange A Q))) z

tactic: rw [map_one, mul_one]
state_before: R : Type u_1
A : Type u_2
V : Type u_3
inst✝⁷ : CommRing R
inst✝⁶ : CommRing A
inst✝⁵ : AddCommGroup V
inst✝⁴ : Algebra R A
inst✝³ : Module R V
inst✝² : Module A V
inst✝¹ : IsScalarTower R A V
inst✝ : Invertible 2
Q : QuadraticForm R V
z : A
⊢ (algebraMap A (CliffordAlgebra (QuadraticForm.baseChange A Q))) z * (ofBaseChangeAux A Q) 1 =
    (algebraMap A (CliffordAlgebra (QuadraticForm.baseChange A Q))) z
state_after: no goals
Theorem: Real.Angle.sin_pi_div_two_sub
File: Mathlib/Analysis/SpecialFunctions/Trigonometric/Angle.lean

tactic: induction θ using Real.Angle.induction_on
state_before: θ : Angle
⊢ (↑(π / 2) - θ).sin = θ.cos
state_after: case h
x✝ : ℝ
⊢ (↑(π / 2) - ↑x✝).sin = (↑x✝).cos

tactic: exact Real.sin_pi_div_two_sub _
state_before: case h
x✝ : ℝ
⊢ (↑(π / 2) - ↑x✝).sin = (↑x✝).cos
state_after: no goals
Theorem: finrank_eq_one_iff'
File: Mathlib/LinearAlgebra/Dimension/FreeAndStrongRankCondition.lean

tactic: rw [← rank_eq_one_iff]
state_before: K : Type u
V : Type v
inst✝⁴ : Ring K
inst✝³ : StrongRankCondition K
inst✝² : AddCommGroup V
inst✝¹ : Module K V
inst✝ : Module.Free K V
⊢ finrank K V = 1 ↔ ∃ v, v ≠ 0 ∧ ∀ (w : V), ∃ c, c • v = w
state_after: K : Type u
V : Type v
inst✝⁴ : Ring K
inst✝³ : StrongRankCondition K
inst✝² : AddCommGroup V
inst✝¹ : Module K V
inst✝ : Module.Free K V
⊢ finrank K V = 1 ↔ Module.rank K V = 1

tactic: exact toNat_eq_iff one_ne_zero
state_before: K : Type u
V : Type v
inst✝⁴ : Ring K
inst✝³ : StrongRankCondition K
inst✝² : AddCommGroup V
inst✝¹ : Module K V
inst✝ : Module.Free K V
⊢ finrank K V = 1 ↔ Module.rank K V = 1
state_after: no goals
Theorem: IsPrimitiveRoot.isIntegral
File: Mathlib/RingTheory/RootsOfUnity/Minpoly.lean

tactic: use X ^ n - 1
state_before: n : ℕ
K : Type u_1
inst✝ : CommRing K
μ : K
h : IsPrimitiveRoot μ n
hpos : 0 < n
⊢ IsIntegral ℤ μ
state_after: case h
n : ℕ
K : Type u_1
inst✝ : CommRing K
μ : K
h : IsPrimitiveRoot μ n
hpos : 0 < n
⊢ (X ^ n - 1).Monic ∧ eval₂ (algebraMap ℤ K) μ (X ^ n - 1) = 0

tactic: constructor
state_before: case h
n : ℕ
K : Type u_1
inst✝ : CommRing K
μ : K
h : IsPrimitiveRoot μ n
hpos : 0 < n
⊢ (X ^ n - 1).Monic ∧ eval₂ (algebraMap ℤ K) μ (X ^ n - 1) = 0
state_after: case h.left
n : ℕ
K : Type u_1
inst✝ : CommRing K
μ : K
h : IsPrimitiveRoot μ n
hpos : 0 < n
⊢ (X ^ n - 1).Monic

case h.right
n : ℕ
K : Type u_1
inst✝ : CommRing K
μ : K
h : IsPrimitiveRoot μ n
hpos : 0 < n
⊢ eval₂ (algebraMap ℤ K) μ (X ^ n - 1) = 0

tactic: exact monic_X_pow_sub_C 1 (ne_of_lt hpos).symm
state_before: case h.left
n : ℕ
K : Type u_1
inst✝ : CommRing K
μ : K
h : IsPrimitiveRoot μ n
hpos : 0 < n
⊢ (X ^ n - 1).Monic
state_after: no goals

tactic: simp only [((IsPrimitiveRoot.iff_def μ n).mp h).left, eval₂_one, eval₂_X_pow, eval₂_sub,
  sub_self]
state_before: case h.right
n : ℕ
K : Type u_1
inst✝ : CommRing K
μ : K
h : IsPrimitiveRoot μ n
hpos : 0 < n
⊢ eval₂ (algebraMap ℤ K) μ (X ^ n - 1) = 0
state_after: no goals
Theorem: Matrix.IsHermitian.det_eq_prod_eigenvalues
File: Mathlib/LinearAlgebra/Matrix/Spectrum.lean

tactic: convert congr_arg det hA.spectral_theorem
state_before: 𝕜 : Type u_1
inst✝² : RCLike 𝕜
n : Type u_2
inst✝¹ : Fintype n
A : Matrix n n 𝕜
inst✝ : DecidableEq n
hA : A.IsHermitian
⊢ A.det = ∏ i : n, ↑(hA.eigenvalues i)
state_after: case h.e'_3
𝕜 : Type u_1
inst✝² : RCLike 𝕜
n : Type u_2
inst✝¹ : Fintype n
A : Matrix n n 𝕜
inst✝ : DecidableEq n
hA : A.IsHermitian
⊢ ∏ i : n, ↑(hA.eigenvalues i) =
    (↑hA.eigenvectorUnitary * diagonal (RCLike.ofReal ∘ hA.eigenvalues) * star ↑hA.eigenvectorUnitary).det

tactic: rw [det_mul_right_comm]
state_before: case h.e'_3
𝕜 : Type u_1
inst✝² : RCLike 𝕜
n : Type u_2
inst✝¹ : Fintype n
A : Matrix n n 𝕜
inst✝ : DecidableEq n
hA : A.IsHermitian
⊢ ∏ i : n, ↑(hA.eigenvalues i) =
    (↑hA.eigenvectorUnitary * diagonal (RCLike.ofReal ∘ hA.eigenvalues) * star ↑hA.eigenvectorUnitary).det
state_after: case h.e'_3
𝕜 : Type u_1
inst✝² : RCLike 𝕜
n : Type u_2
inst✝¹ : Fintype n
A : Matrix n n 𝕜
inst✝ : DecidableEq n
hA : A.IsHermitian
⊢ ∏ i : n, ↑(hA.eigenvalues i) =
    (↑hA.eigenvectorUnitary * star ↑hA.eigenvectorUnitary * diagonal (RCLike.ofReal ∘ hA.eigenvalues)).det

tactic: simp
state_before: case h.e'_3
𝕜 : Type u_1
inst✝² : RCLike 𝕜
n : Type u_2
inst✝¹ : Fintype n
A : Matrix n n 𝕜
inst✝ : DecidableEq n
hA : A.IsHermitian
⊢ ∏ i : n, ↑(hA.eigenvalues i) =
    (↑hA.eigenvectorUnitary * star ↑hA.eigenvectorUnitary * diagonal (RCLike.ofReal ∘ hA.eigenvalues)).det
state_after: no goals
Theorem: PNat.card_Ioo
File: Mathlib/Data/PNat/Interval.lean

tactic: rw [← Nat.card_Ioo]
state_before: a b : ℕ+
⊢ (Ioo a b).card = ↑b - ↑a - 1
state_after: a b : ℕ+
⊢ (Ioo a b).card = (Ioo ↑a ↑b).card

tactic: erw [← Finset.map_subtype_embedding_Ioo _ a b (fun c x _ hx _ hc _ => hc.trans_le hx)]
state_before: a b : ℕ+
⊢ (Ioo a b).card = (Ioo ↑a ↑b).card
state_after: a b : ℕ+
⊢ (Ioo a b).card = (map (Embedding.subtype fun n => 0 < n) (Ioo a b)).card

tactic: rw [card_map]
state_before: a b : ℕ+
⊢ (Ioo a b).card = (map (Embedding.subtype fun n => 0 < n) (Ioo a b)).card
state_after: no goals
Theorem: Polynomial.div_eq_zero_iff
File: Mathlib/Algebra/Polynomial/FieldDivision.lean

tactic: have := EuclideanDomain.div_add_mod p q
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]
hq0 : q ≠ 0
h : p / q = 0
⊢ p.degree < q.degree
state_after: R : Type u
S : Type v
k : Type y
A : Type z
a b : R
n : ℕ
inst✝ : Field R
p q : R[X]
hq0 : q ≠ 0
h : p / q = 0
this : q * (p / q) + p % q = p
⊢ p.degree < q.degree

tactic: rwa [h, mul_zero, zero_add, mod_eq_self_iff hq0] at this
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]
hq0 : q ≠ 0
h : p / q = 0
this : q * (p / q) + p % q = p
⊢ p.degree < q.degree
state_after: no goals

tactic: have hlt : degree p < degree (q * C (leadingCoeff q)⁻¹) := by
  rwa [degree_mul_leadingCoeff_inv q hq0]
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]
hq0 : q ≠ 0
h : p.degree < q.degree
⊢ p / q = 0
state_after: R : Type u
S : Type v
k : Type y
A : Type z
a b : R
n : ℕ
inst✝ : Field R
p q : R[X]
hq0 : q ≠ 0
h : p.degree < q.degree
hlt : p.degree < (q * C q.leadingCoeff⁻¹).degree
⊢ p / q = 0

tactic: have hm : Monic (q * C (leadingCoeff q)⁻¹) := monic_mul_leadingCoeff_inv hq0
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]
hq0 : q ≠ 0
h : p.degree < q.degree
hlt : p.degree < (q * C q.leadingCoeff⁻¹).degree
⊢ p / q = 0
state_after: R : Type u
S : Type v
k : Type y
A : Type z
a b : R
n : ℕ
inst✝ : Field R
p q : R[X]
hq0 : q ≠ 0
h : p.degree < q.degree
hlt : p.degree < (q * C q.leadingCoeff⁻¹).degree
hm : (q * C q.leadingCoeff⁻¹).Monic
⊢ p / q = 0

tactic: rw [div_def, (divByMonic_eq_zero_iff hm).2 hlt, mul_zero]
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]
hq0 : q ≠ 0
h : p.degree < q.degree
hlt : p.degree < (q * C q.leadingCoeff⁻¹).degree
hm : (q * C q.leadingCoeff⁻¹).Monic
⊢ p / q = 0
state_after: no goals

tactic: rwa [degree_mul_leadingCoeff_inv q hq0]
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]
hq0 : q ≠ 0
h : p.degree < q.degree
⊢ p.degree < (q * C q.leadingCoeff⁻¹).degree
state_after: no goals
Theorem: Stream'.WSeq.exists_of_mem_bind
File: Mathlib/Data/Seq/WSeq.lean

tactic: rwa [e]
state_before: α : Type u
β : Type v
γ : Type w
s : WSeq α
f : α → WSeq β
b : β
h : b ∈ s.bind f
t : WSeq β
tm : t ∈ map f s
bt : b ∈ t
a : α
as : a ∈ s
e : f a = t
⊢ b ∈ f a
state_after: no goals
Theorem: List.rotate_rotate
File: Mathlib/Data/List/Rotate.lean

tactic: rw [rotate_eq_rotate', rotate_eq_rotate', rotate_eq_rotate', rotate'_rotate']
state_before: α : Type u
l : List α
n m : ℕ
⊢ (l.rotate n).rotate m = l.rotate (n + m)
state_after: no goals
Theorem: isLocalizedModule_id
File: Mathlib/Algebra/Module/LocalizedModule.lean

tactic: rw [← (Algebra.lsmul R (A := R') R M).commutes]
state_before: R : Type u_1
inst✝¹⁶ : CommSemiring R
S : Submonoid R
M : Type u_2
M' : Type u_3
M'' : Type u_4
inst✝¹⁵ : AddCommMonoid M
inst✝¹⁴ : AddCommMonoid M'
inst✝¹³ : AddCommMonoid M''
A : Type u_5
inst✝¹² : CommSemiring A
inst✝¹¹ : Algebra R A
inst✝¹⁰ : Module A M'
inst✝⁹ : IsLocalization S A
inst✝⁸ : Module R M
inst✝⁷ : Module R M'
inst✝⁶ : Module R M''
inst✝⁵ : IsScalarTower R A M'
f : M →ₗ[R] M'
g : M →ₗ[R] M''
R' : Type u_6
inst✝⁴ : CommSemiring R'
inst✝³ : Algebra R R'
inst✝² : IsLocalization S R'
inst✝¹ : Module R' M
inst✝ : IsScalarTower R R' M
s : ↥S
⊢ IsUnit ((algebraMap R (Module.End R M)) ↑s)
state_after: R : Type u_1
inst✝¹⁶ : CommSemiring R
S : Submonoid R
M : Type u_2
M' : Type u_3
M'' : Type u_4
inst✝¹⁵ : AddCommMonoid M
inst✝¹⁴ : AddCommMonoid M'
inst✝¹³ : AddCommMonoid M''
A : Type u_5
inst✝¹² : CommSemiring A
inst✝¹¹ : Algebra R A
inst✝¹⁰ : Module A M'
inst✝⁹ : IsLocalization S A
inst✝⁸ : Module R M
inst✝⁷ : Module R M'
inst✝⁶ : Module R M''
inst✝⁵ : IsScalarTower R A M'
f : M →ₗ[R] M'
g : M →ₗ[R] M''
R' : Type u_6
inst✝⁴ : CommSemiring R'
inst✝³ : Algebra R R'
inst✝² : IsLocalization S R'
inst✝¹ : Module R' M
inst✝ : IsScalarTower R R' M
s : ↥S
⊢ IsUnit ((Algebra.lsmul R R M) ((algebraMap R R') ↑s))

tactic: exact (IsLocalization.map_units R' s).map _
state_before: R : Type u_1
inst✝¹⁶ : CommSemiring R
S : Submonoid R
M : Type u_2
M' : Type u_3
M'' : Type u_4
inst✝¹⁵ : AddCommMonoid M
inst✝¹⁴ : AddCommMonoid M'
inst✝¹³ : AddCommMonoid M''
A : Type u_5
inst✝¹² : CommSemiring A
inst✝¹¹ : Algebra R A
inst✝¹⁰ : Module A M'
inst✝⁹ : IsLocalization S A
inst✝⁸ : Module R M
inst✝⁷ : Module R M'
inst✝⁶ : Module R M''
inst✝⁵ : IsScalarTower R A M'
f : M →ₗ[R] M'
g : M →ₗ[R] M''
R' : Type u_6
inst✝⁴ : CommSemiring R'
inst✝³ : Algebra R R'
inst✝² : IsLocalization S R'
inst✝¹ : Module R' M
inst✝ : IsScalarTower R R' M
s : ↥S
⊢ IsUnit ((Algebra.lsmul R R M) ((algebraMap R R') ↑s))
state_after: no goals
Theorem: Finsupp.apply_total
File: Mathlib/LinearAlgebra/Finsupp.lean

tactic: apply Finsupp.induction_linear l <;> simp (config := { contextual := true })
state_before: α : Type u_1
M : Type u_2
N : Type u_3
P : Type u_4
R : Type u_5
S : Type u_6
inst✝⁹ : Semiring R
inst✝⁸ : Semiring S
inst✝⁷ : AddCommMonoid M
inst✝⁶ : Module R M
inst✝⁵ : AddCommMonoid N
inst✝⁴ : Module R N
inst✝³ : AddCommMonoid P
inst✝² : Module R P
α' : Type u_7
M' : Type u_8
inst✝¹ : AddCommMonoid M'
inst✝ : Module R M'
v✝ : α → M
v' : α' → M'
f : M →ₗ[R] M'
v : α → M
l : α →₀ R
⊢ f ((Finsupp.total α M R v) l) = (Finsupp.total α M' R (⇑f ∘ v)) l
state_after: no goals
Theorem: Finset.prod_erase_eq_div
File: Mathlib/Algebra/BigOperators/Group/Finset.lean

tactic: rw [eq_div_iff_mul_eq', prod_erase_mul _ _ h]
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✝¹ : CommGroup β
inst✝ : DecidableEq α
a : α
h : a ∈ s
⊢ ∏ x ∈ s.erase a, f x = (∏ x ∈ s, f x) / f a
state_after: no goals