ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
Theorem: add_not_mem_of_addOrderOf_eq_two
File: Mathlib/GroupTheory/Exponent.lean

Proof steps:
state_before: G : Type u
inst✝ : Group G
x y : G
hx : orderOf x = 2
hy : orderOf y = 2
hxy : x ≠ y
⊢ x * y ∉ {x, y, 1}
state_after: G : Type u
inst✝ : Group G
x y : G
hx : orderOf x = 2
hy : orderOf y = 2
hxy : x ≠ y
⊢ ¬y = 1 ∧ ¬x = 1 ∧ ¬x = y
tactic: simp only [Set.mem_singleton_iff, Set.mem_insert_iff, mul_right_eq_self, mul_left_eq_self,
    mul_eq_one_iff_eq_inv, inv_eq_self_of_orderOf_eq_two hy, not_or]
state_before: G : Type u
inst✝ : Group G
x y : G
hx : orderOf x = 2
hy : orderOf y = 2
hxy : x ≠ y
⊢ ¬y = 1 ∧ ¬x = 1 ∧ ¬x = y
state_after: no goals
tactic: aesop
Theorem: MeasurableSet.const_vadd
File: Mathlib/MeasureTheory/Group/Pointwise.lean

Proof steps:
state_before: G : Type u_1
α : Type u_2
inst✝⁴ : Group G
inst✝³ : MulAction G α
inst✝² : MeasurableSpace G
inst✝¹ : MeasurableSpace α
inst✝ : MeasurableSMul G α
s : Set α
hs : MeasurableSet s
a : G
⊢ MeasurableSet (a • s)
state_after: G : Type u_1
α : Type u_2
inst✝⁴ : Group G
inst✝³ : MulAction G α
inst✝² : MeasurableSpace G
inst✝¹ : MeasurableSpace α
inst✝ : MeasurableSMul G α
s : Set α
hs : MeasurableSet s
a : G
⊢ MeasurableSet ((fun x => a⁻¹ • x) ⁻¹' s)
tactic: rw [← preimage_smul_inv]
state_before: G : Type u_1
α : Type u_2
inst✝⁴ : Group G
inst✝³ : MulAction G α
inst✝² : MeasurableSpace G
inst✝¹ : MeasurableSpace α
inst✝ : MeasurableSMul G α
s : Set α
hs : MeasurableSet s
a : G
⊢ MeasurableSet ((fun x => a⁻¹ • x) ⁻¹' s)
state_after: no goals
tactic: exact measurable_const_smul _ hs
Theorem: Function.mulSupport_along_fiber_subset
File: Mathlib/Algebra/Group/Support.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
A : Type u_3
B : Type u_4
M : Type u_5
M' : Type u_6
N : Type u_7
P : Type u_8
G : Type u_9
inst✝² : One M
inst✝¹ : One N
inst✝ : One P
f : α × β → M
a : α
x : β
hx : x ∈ mulSupport fun b => f (a, b)
⊢ (a, x) ∈ mulSupport f ∧ (a, x).2 = x
state_after: no goals
tactic: simpa using hx
Theorem: MeasureTheory.Measure.restrict_apply_eq_zero'
File: Mathlib/MeasureTheory/Measure/Restrict.lean

Proof steps:
state_before: R : Type u_1
α : Type u_2
β : Type u_3
δ : Type u_4
γ : Type u_5
ι : Type u_6
m0 : MeasurableSpace α
inst✝¹ : MeasurableSpace β
inst✝ : MeasurableSpace γ
μ μ₁ μ₂ μ₃ ν ν' ν₁ ν₂ : Measure α
s s' t : Set α
hs : MeasurableSet s
⊢ (μ.restrict s) t = 0 ↔ μ (t ∩ s) = 0
state_after: no goals
tactic: rw [restrict_apply' hs]
Theorem: ProbabilityTheory.integral_truncation_le_integral_of_nonneg
File: Mathlib/Probability/StrongLaw.lean

Proof steps:
state_before: α : Type u_1
m : MeasurableSpace α
μ : Measure α
f : α → ℝ
hf : Integrable f μ
h'f : 0 ≤ f
A : ℝ
⊢ ∫ (x : α), truncation f A x ∂μ ≤ ∫ (x : α), f x ∂μ
state_after: α : Type u_1
m : MeasurableSpace α
μ : Measure α
f : α → ℝ
hf : Integrable f μ
h'f : 0 ≤ f
A : ℝ
x : α
⊢ 0 x ≤ truncation f A x

α : Type u_1
m : MeasurableSpace α
μ : Measure α
f : α → ℝ
hf : Integrable f μ
h'f : 0 ≤ f
A : ℝ
x : α
⊢ truncation f A x ≤ f x
tactic: apply integral_mono_of_nonneg
    (eventually_of_forall fun x => ?_) hf (eventually_of_forall fun x => ?_)
Theorem: ModuleCat.MonoidalCategory.tensor_id
File: Mathlib/Algebra/Category/ModuleCat/Monoidal/Basic.lean

Proof steps:
state_before: R : Type u
inst✝ : CommRing R
M : ModuleCat R
N : ModuleCat R
⊢ tensorHom (𝟙 M) (𝟙 N) = 𝟙 (of R (↑M ⊗[R] ↑N))
state_after: case H
R : Type u
inst✝ : CommRing R
M : ModuleCat R
N : ModuleCat R
⊢ (TensorProduct.mk R ↑M ↑N).compr₂ (tensorHom (𝟙 M) (𝟙 N)) = (TensorProduct.mk R ↑M ↑N).compr₂ (𝟙 (of R (↑M ⊗[R] ↑N)))
tactic: apply TensorProduct.ext
state_before: case H
R : Type u
inst✝ : CommRing R
M : ModuleCat R
N : ModuleCat R
⊢ (TensorProduct.mk R ↑M ↑N).compr₂ (tensorHom (𝟙 M) (𝟙 N)) = (TensorProduct.mk R ↑M ↑N).compr₂ (𝟙 (of R (↑M ⊗[R] ↑N)))
state_after: no goals
tactic: rfl
Theorem: PowerSeries.X_pow_order_dvd
File: Mathlib/RingTheory/PowerSeries/Order.lean

Proof steps:
state_before: R : Type u_1
inst✝ : Semiring R
φ : R⟦X⟧
h : φ.order.Dom
⊢ X ^ φ.order.get h ∣ φ
state_after: R : Type u_1
inst✝ : Semiring R
φ : R⟦X⟧
h : φ.order.Dom
⊢ φ = X ^ φ.order.get h * mk fun n => (coeff R (n + φ.order.get h)) φ
tactic: refine ⟨PowerSeries.mk fun n => coeff R (n + (order φ).get h) φ, ?_⟩
state_before: R : Type u_1
inst✝ : Semiring R
φ : R⟦X⟧
h : φ.order.Dom
⊢ φ = X ^ φ.order.get h * mk fun n => (coeff R (n + φ.order.get h)) φ
state_after: case h
R : Type u_1
inst✝ : Semiring R
φ : R⟦X⟧
h : φ.order.Dom
n : ℕ
⊢ (coeff R n) φ = (coeff R n) (X ^ φ.order.get h * mk fun n => (coeff R (n + φ.order.get h)) φ)
tactic: ext n
state_before: case h
R : Type u_1
inst✝ : Semiring R
φ : R⟦X⟧
h : φ.order.Dom
n : ℕ
⊢ (coeff R n) φ = (coeff R n) (X ^ φ.order.get h * mk fun n => (coeff R (n + φ.order.get h)) φ)
state_after: case h
R : Type u_1
inst✝ : Semiring R
φ : R⟦X⟧
h : φ.order.Dom
n : ℕ
⊢ (coeff R n) φ = ∑ x ∈ Finset.filter (fun x => x.1 = φ.order.get h) (antidiagonal n), (coeff R (x.2 + φ.order.get h)) φ
tactic: simp only [coeff_mul, coeff_X_pow, coeff_mk, boole_mul, Finset.sum_ite,
    Finset.sum_const_zero, add_zero]
state_before: case h
R : Type u_1
inst✝ : Semiring R
φ : R⟦X⟧
h : φ.order.Dom
n : ℕ
⊢ (coeff R n) φ = ∑ x ∈ Finset.filter (fun x => x.1 = φ.order.get h) (antidiagonal n), (coeff R (x.2 + φ.order.get h)) φ
state_after: case h
R : Type u_1
inst✝ : Semiring R
φ : R⟦X⟧
h : φ.order.Dom
n : ℕ
⊢ (coeff R n) φ =
    ∑ x ∈ if φ.order.get h ≤ n then {(φ.order.get h, n - φ.order.get h)} else ∅, (coeff R (x.2 + φ.order.get h)) φ
tactic: rw [Finset.filter_fst_eq_antidiagonal n (Part.get (order φ) h)]
state_before: case h
R : Type u_1
inst✝ : Semiring R
φ : R⟦X⟧
h : φ.order.Dom
n : ℕ
⊢ (coeff R n) φ =
    ∑ x ∈ if φ.order.get h ≤ n then {(φ.order.get h, n - φ.order.get h)} else ∅, (coeff R (x.2 + φ.order.get h)) φ
state_after: case pos
R : Type u_1
inst✝ : Semiring R
φ : R⟦X⟧
h : φ.order.Dom
n : ℕ
hn : φ.order.get h ≤ n
⊢ (coeff R n) φ = ∑ x ∈ {(φ.order.get h, n - φ.order.get h)}, (coeff R (x.2 + φ.order.get h)) φ

case neg
R : Type u_1
inst✝ : Semiring R
φ : R⟦X⟧
h : φ.order.Dom
n : ℕ
hn : ¬φ.order.get h ≤ n
⊢ (coeff R n) φ = ∑ x ∈ ∅, (coeff R (x.2 + φ.order.get h)) φ
tactic: split_ifs with hn
Theorem: Matrix.GeneralLinearGroup.val_det_apply
File: Mathlib/LinearAlgebra/Matrix/GeneralLinearGroup/Defs.lean

Proof steps:
state_before: n : Type u
inst✝² : DecidableEq n
inst✝¹ : Fintype n
R : Type v
inst✝ : CommRing R
A : GL n R
⊢ (↑A).det * (↑A⁻¹).det = 1
state_after: no goals
tactic: rw [← det_mul, A.mul_inv, det_one]
state_before: n : Type u
inst✝² : DecidableEq n
inst✝¹ : Fintype n
R : Type v
inst✝ : CommRing R
A : GL n R
⊢ (↑A⁻¹).det * (↑A).det = 1
state_after: no goals
tactic: rw [← det_mul, A.inv_mul, det_one]
Theorem: Fin.succAbove_ne_zero_zero
File: Mathlib/Data/Fin/Basic.lean

Proof steps:
state_before: n m : ℕ
p : Fin (n + 1)
i j : Fin n
inst✝ : NeZero n
a : Fin (n + 1)
ha : a ≠ 0
⊢ a.succAbove 0 = 0
state_after: n m : ℕ
p : Fin (n + 1)
i j : Fin n
inst✝ : NeZero n
a : Fin (n + 1)
ha : a ≠ 0
⊢ castSucc 0 = 0

case h
n m : ℕ
p : Fin (n + 1)
i j : Fin n
inst✝ : NeZero n
a : Fin (n + 1)
ha : a ≠ 0
⊢ castSucc 0 < a
tactic: rw [Fin.succAbove_of_castSucc_lt]
Theorem: CochainComplex.HomComplex.Cocycle.rightUnshift_coe
File: Mathlib/Algebra/Homology/HomotopyCategory/HomComplexShift.lean

Proof steps:
state_before: C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
R : Type u_1
inst✝¹ : Ring R
inst✝ : Linear R C
K L M : CochainComplex C ℤ
n✝ n' a : ℤ
γ : Cocycle K ((CategoryTheory.shiftFunctor (CochainComplex C ℤ) a).obj L) n'
n : ℤ
hn : n' + a = n
⊢ δ n (n + 1) ((↑γ).rightUnshift n hn) = 0
state_after: no goals
tactic: rw [Cochain.δ_rightUnshift _ n hn (n + 1) (n + 1 - a) (by omega),
      δ_eq_zero, Cochain.rightUnshift_zero, smul_zero]
Theorem: Rat.divInt_num_den
File: .lake/packages/batteries/Batteries/Data/Rat/Lemmas.lean

Proof steps:
state_before: d n n' : Int
d' : Nat
z' : d' ≠ 0
c : n'.natAbs.Coprime d'
z : d ≠ 0
h : n /. d = { num := n', den := d', den_nz := z', reduced := c }
⊢ ∃ m, m ≠ 0 ∧ n = n' * m ∧ d = ↑d' * m
state_after: case intro.inl
n n' : Int
d' : Nat
z' : d' ≠ 0
c : n'.natAbs.Coprime d'
w✝ : Nat
z : ¬w✝ = 0
h : mkRat n w✝ = { num := n', den := d', den_nz := z', reduced := c }
⊢ ∃ m, ¬m = 0 ∧ n = n' * m ∧ ↑w✝ = ↑d' * m

case intro.inr
n n' : Int
d' : Nat
z' : d' ≠ 0
c : n'.natAbs.Coprime d'
w✝ : Nat
z : ¬w✝ = 0
h : mkRat (-n) w✝ = { num := n', den := d', den_nz := z', reduced := c }
⊢ ∃ m, ¬m = 0 ∧ n = n' * m ∧ -↑w✝ = ↑d' * m
tactic: rcases Int.eq_nat_or_neg d with ⟨_, rfl | rfl⟩ <;>
    simp_all [divInt_neg', Int.ofNat_eq_zero, Int.neg_eq_zero]
Theorem: GenContFract.get?_of_eq_some_of_get?_intFractPair_stream_fr_ne_zero
File: Mathlib/Algebra/ContinuedFractions/Computation/Translations.lean

Proof steps:
state_before: K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
n : ℕ
ifp_n : IntFractPair K
stream_nth_eq : IntFractPair.stream v n = some ifp_n
nth_fr_ne_zero : ifp_n.fr ≠ 0
⊢ IntFractPair.stream v (n + 1) = some (IntFractPair.of ifp_n.fr⁻¹)
state_after: case mk
K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
n : ℕ
b✝ : ℤ
fr✝ : K
stream_nth_eq : IntFractPair.stream v n = some { b := b✝, fr := fr✝ }
nth_fr_ne_zero : { b := b✝, fr := fr✝ }.fr ≠ 0
⊢ IntFractPair.stream v (n + 1) = some (IntFractPair.of { b := b✝, fr := fr✝ }.fr⁻¹)
tactic: cases ifp_n
state_before: case mk
K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
n : ℕ
b✝ : ℤ
fr✝ : K
stream_nth_eq : IntFractPair.stream v n = some { b := b✝, fr := fr✝ }
nth_fr_ne_zero : { b := b✝, fr := fr✝ }.fr ≠ 0
⊢ IntFractPair.stream v (n + 1) = some (IntFractPair.of { b := b✝, fr := fr✝ }.fr⁻¹)
state_after: case mk
K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
n : ℕ
b✝ : ℤ
fr✝ : K
stream_nth_eq : IntFractPair.stream v n = some { b := b✝, fr := fr✝ }
nth_fr_ne_zero : { b := b✝, fr := fr✝ }.fr ≠ 0
⊢ fr✝ = 0 → False
tactic: simp only [IntFractPair.stream, Nat.add_eq, add_zero, stream_nth_eq, Option.some_bind,
      ite_eq_right_iff]
state_before: case mk
K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
n : ℕ
b✝ : ℤ
fr✝ : K
stream_nth_eq : IntFractPair.stream v n = some { b := b✝, fr := fr✝ }
nth_fr_ne_zero : { b := b✝, fr := fr✝ }.fr ≠ 0
⊢ fr✝ = 0 → False
state_after: case mk
K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
n : ℕ
b✝ : ℤ
fr✝ : K
stream_nth_eq : IntFractPair.stream v n = some { b := b✝, fr := fr✝ }
nth_fr_ne_zero : { b := b✝, fr := fr✝ }.fr ≠ 0
a✝ : fr✝ = 0
⊢ False
tactic: intro
state_before: case mk
K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
n : ℕ
b✝ : ℤ
fr✝ : K
stream_nth_eq : IntFractPair.stream v n = some { b := b✝, fr := fr✝ }
nth_fr_ne_zero : { b := b✝, fr := fr✝ }.fr ≠ 0
a✝ : fr✝ = 0
⊢ False
state_after: no goals
tactic: contradiction
Theorem: _private.Mathlib.NumberTheory.FLT.Three.0.cube_of_not_dvd
File: Mathlib/NumberTheory/FLT/Three.lean

Proof steps:
state_before: n : ℤ
h : ¬3 ∣ n
⊢ ↑n ^ 3 = 1 ∨ ↑n ^ 3 = 8
state_after: case a
n : ℤ
h : ¬3 ∣ n
⊢ (castHom ⋯ (ZMod 3)) ↑n ≠ 0
tactic: apply cube_of_castHom_ne_zero
state_before: case a
n : ℤ
h : ¬3 ∣ n
⊢ (castHom ⋯ (ZMod 3)) ↑n ≠ 0
state_after: no goals
tactic: rwa [map_intCast, Ne, ZMod.intCast_zmod_eq_zero_iff_dvd]
Theorem: CategoryTheory.Iso.comp_hom_eq_id
File: Mathlib/CategoryTheory/Iso.lean

Proof steps:
state_before: C : Type u
inst✝ : Category.{v, u} C
X Y Z : C
α : X ≅ Y
f : Y ⟶ X
⊢ f ≫ α.hom = 𝟙 Y ↔ f = α.inv
state_after: no goals
tactic: rw [← eq_comp_inv, id_comp]
Theorem: Sym.card_sym_fin_eq_multichoose
File: Mathlib/Data/Sym/Card.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
n✝ n : ℕ
⊢ Fintype.card (Sym (Fin n) 0) = n.multichoose 0
state_after: no goals
tactic: simp
state_before: α : Type u_1
β : Type u_2
n k : ℕ
⊢ Fintype.card (Sym (Fin 0) (k + 1)) = multichoose 0 (k + 1)
state_after: α : Type u_1
β : Type u_2
n k : ℕ
⊢ Fintype.card (Sym (Fin 0) (k + 1)) = 0
tactic: rw [multichoose_zero_succ]
state_before: α : Type u_1
β : Type u_2
n k : ℕ
⊢ Fintype.card (Sym (Fin 0) (k + 1)) = 0
state_after: no goals
tactic: exact card_eq_zero
state_before: α : Type u_1
β : Type u_2
n k : ℕ
⊢ Fintype.card (Sym (Fin 1) (k + 1)) = multichoose 1 (k + 1)
state_after: no goals
tactic: simp
state_before: α : Type u_1
β : Type u_2
n✝ n k : ℕ
⊢ Fintype.card (Sym (Fin (n + 2)) (k + 1)) = (n + 2).multichoose (k + 1)
state_after: α : Type u_1
β : Type u_2
n✝ n k : ℕ
⊢ Fintype.card (Sym (Fin (n + 2)) (k + 1)) = Fintype.card (Sym (Fin (n + 2)) k ⊕ Sym (Fin (n + 1)) (k + 1))
tactic: rw [multichoose_succ_succ, ← card_sym_fin_eq_multichoose (n + 1) (k + 1),
      ← card_sym_fin_eq_multichoose (n + 2) k, add_comm (Fintype.card _), ← card_sum]
state_before: α : Type u_1
β : Type u_2
n✝ n k : ℕ
⊢ Fintype.card (Sym (Fin (n + 2)) (k + 1)) = Fintype.card (Sym (Fin (n + 2)) k ⊕ Sym (Fin (n + 1)) (k + 1))
state_after: α : Type u_1
β : Type u_2
n✝ n k : ℕ
⊢ Sym (Fin (n + 2)) k ⊕ Sym (Fin (n + 1)) (k + 1) ≃ Sym (Fin (n + 2)) (k + 1)
tactic: refine Fintype.card_congr (Equiv.symm ?_)
state_before: α : Type u_1
β : Type u_2
n✝ n k : ℕ
⊢ Sym (Fin (n + 2)) k ⊕ Sym (Fin (n + 1)) (k + 1) ≃ Sym (Fin (n + 2)) (k + 1)
state_after: α : Type u_1
β : Type u_2
n✝ n k : ℕ
⊢ { s // 0 ∈ s } ⊕ { s // 0 ∉ s } ≃ Sym (Fin (n + 2)) (k + 1)
tactic: apply (Sym.e1.symm.sumCongr Sym.e2.symm).trans
state_before: α : Type u_1
β : Type u_2
n✝ n k : ℕ
⊢ { s // 0 ∈ s } ⊕ { s // 0 ∉ s } ≃ Sym (Fin (n + 2)) (k + 1)
state_after: no goals
tactic: apply Equiv.sumCompl
Theorem: Complex.abs_cpow_eq_rpow_re_of_nonneg
File: Mathlib/Analysis/SpecialFunctions/Pow/Real.lean

Proof steps:
state_before: x : ℝ
hx : 0 ≤ x
y : ℂ
hy : y.re ≠ 0
⊢ abs (↑x ^ y) = x ^ y.re
state_after: no goals
tactic: rw [abs_cpow_of_imp] <;> simp [*, arg_ofReal_of_nonneg, _root_.abs_of_nonneg]
Theorem: AkraBazziRecurrence.eventually_one_add_smoothingFn_nonneg
File: Mathlib/Computability/AkraBazzi/AkraBazzi.lean

Proof steps:
state_before: α : Type u_1
inst✝¹ : Fintype α
inst✝ : Nonempty α
T : ℕ → ℝ
g : ℝ → ℝ
a b : α → ℝ
r : α → ℕ → ℕ
R : AkraBazziRecurrence T g a b r
⊢ ∀ᶠ (n : ℕ) in atTop, 0 ≤ 1 + ε ↑n
state_after: case h
α : Type u_1
inst✝¹ : Fintype α
inst✝ : Nonempty α
T : ℕ → ℝ
g : ℝ → ℝ
a b : α → ℝ
r : α → ℕ → ℕ
R : AkraBazziRecurrence T g a b r
n : ℕ
hn : 0 < 1 + ε ↑n
⊢ 0 ≤ 1 + ε ↑n
tactic: filter_upwards [eventually_one_add_smoothingFn_pos] with n hn
state_before: case h
α : Type u_1
inst✝¹ : Fintype α
inst✝ : Nonempty α
T : ℕ → ℝ
g : ℝ → ℝ
a b : α → ℝ
r : α → ℕ → ℕ
R : AkraBazziRecurrence T g a b r
n : ℕ
hn : 0 < 1 + ε ↑n
⊢ 0 ≤ 1 + ε ↑n
state_after: no goals
tactic: exact le_of_lt hn
Theorem: Orientation.tan_oangle_add_left_smul_rotation_pi_div_two
File: Mathlib/Geometry/Euclidean/Angle/Oriented/RightAngle.lean

Proof steps:
state_before: V : Type u_1
inst✝¹ : NormedAddCommGroup V
inst✝ : InnerProductSpace ℝ V
hd2 : Fact (finrank ℝ V = 2)
o : Orientation ℝ V (Fin 2)
x : V
h : x ≠ 0
r : ℝ
⊢ (o.oangle (x + r • (o.rotation ↑(π / 2)) x) (r • (o.rotation ↑(π / 2)) x)).tan = r⁻¹
state_after: no goals
tactic: rw [o.oangle_add_left_smul_rotation_pi_div_two h, Real.Angle.tan_coe, Real.tan_arctan]
Theorem: IsAddKleinFour.add_self
File: Mathlib/GroupTheory/SpecificGroups/KleinFour.lean

Proof steps:
state_before: G : Type u_1
inst✝¹ : Group G
inst✝ : IsKleinFour G
x : G
⊢ x * x = 1
state_after: no goals
tactic: rw [mul_eq_one_iff_eq_inv, inv_eq_self]
Theorem: Polynomial.bernoulli_succ_eval
File: Mathlib/NumberTheory/BernoulliPolynomials.lean

Proof steps:
state_before: n p : ℕ
⊢ eval (↑n) (bernoulli p.succ) = _root_.bernoulli p.succ + (↑p + 1) * ∑ k ∈ range n, ↑k ^ p
state_after: case h
n p : ℕ
⊢ eval (↑n) (bernoulli p.succ) - _root_.bernoulli p.succ = (↑p + 1) * ∑ k ∈ range n, ↑k ^ p
tactic: apply eq_add_of_sub_eq'
state_before: case h
n p : ℕ
⊢ eval (↑n) (bernoulli p.succ) - _root_.bernoulli p.succ = (↑p + 1) * ∑ k ∈ range n, ↑k ^ p
state_after: no goals
tactic: rw [sum_range_pow_eq_bernoulli_sub]
Theorem: _private.Mathlib.RingTheory.AdicCompletion.AsTensorProduct.0.AdicCompletion.piEquivOfFintype_comp_ofTensorProduct_eq
File: Mathlib/RingTheory/AdicCompletion/AsTensorProduct.lean

Proof steps:
state_before: R : Type u_1
inst✝⁶ : CommRing R
I : Ideal R
M : Type u_2
inst✝⁵ : AddCommGroup M
inst✝⁴ : Module R M
N : Type u_3
inst✝³ : AddCommGroup N
inst✝² : Module R N
ι : Type u_4
inst✝¹ : Fintype ι
inst✝ : DecidableEq ι
⊢ ↑(piEquivOfFintype I fun x => R) ∘ₗ ofTensorProduct I (ι → R) =
    ↑(piScalarRight R (AdicCompletion I R) (AdicCompletion I R) ι)
state_after: case a.h.h.h.h.h
R : Type u_1
inst✝⁶ : CommRing R
I : Ideal R
M : Type u_2
inst✝⁵ : AddCommGroup M
inst✝⁴ : Module R M
N : Type u_3
inst✝³ : AddCommGroup N
inst✝² : Module R N
ι : Type u_4
inst✝¹ : Fintype ι
inst✝ : DecidableEq ι
i j : ι
k : ℕ
⊢ ↑(((AlgebraTensorModule.curry (↑(piEquivOfFintype I fun x => R) ∘ₗ ofTensorProduct I (ι → R))) 1 ∘ₗ
            LinearMap.single i)
          1 j)
      k =
    ↑(((AlgebraTensorModule.curry ↑(piScalarRight R (AdicCompletion I R) (AdicCompletion I R) ι)) 1 ∘ₗ
            LinearMap.single i)
          1 j)
      k
tactic: ext i j k
state_before: case a.h.h.h.h.h
R : Type u_1
inst✝⁶ : CommRing R
I : Ideal R
M : Type u_2
inst✝⁵ : AddCommGroup M
inst✝⁴ : Module R M
N : Type u_3
inst✝³ : AddCommGroup N
inst✝² : Module R N
ι : Type u_4
inst✝¹ : Fintype ι
inst✝ : DecidableEq ι
i j : ι
k : ℕ
⊢ ↑(((AlgebraTensorModule.curry (↑(piEquivOfFintype I fun x => R) ∘ₗ ofTensorProduct I (ι → R))) 1 ∘ₗ
            LinearMap.single i)
          1 j)
      k =
    ↑(((AlgebraTensorModule.curry ↑(piScalarRight R (AdicCompletion I R) (AdicCompletion I R) ι)) 1 ∘ₗ
            LinearMap.single i)
          1 j)
      k
state_after: case a.h.h.h.h.h
R : Type u_1
inst✝⁶ : CommRing R
I : Ideal R
M : Type u_2
inst✝⁵ : AddCommGroup M
inst✝⁴ : Module R M
N : Type u_3
inst✝³ : AddCommGroup N
inst✝² : Module R N
ι : Type u_4
inst✝¹ : Fintype ι
inst✝ : DecidableEq ι
i j : ι
k : ℕ
⊢ (if j = i then 1 else 0) = ↑(if j = i then 1 else 0) k
tactic: suffices h : (if j = i then 1 else 0) = (if j = i then 1 else 0 : AdicCompletion I R).val k by
    simpa [Pi.single_apply, -smul_eq_mul, -Algebra.id.smul_eq_mul]
state_before: case a.h.h.h.h.h
R : Type u_1
inst✝⁶ : CommRing R
I : Ideal R
M : Type u_2
inst✝⁵ : AddCommGroup M
inst✝⁴ : Module R M
N : Type u_3
inst✝³ : AddCommGroup N
inst✝² : Module R N
ι : Type u_4
inst✝¹ : Fintype ι
inst✝ : DecidableEq ι
i j : ι
k : ℕ
⊢ (if j = i then 1 else 0) = ↑(if j = i then 1 else 0) k
state_after: no goals
tactic: split <;> simp only [smul_eq_mul, val_zero, val_one]
Theorem: HomologicalComplex.XIsoOfEq_hom_comp_XIsoOfEq_hom
File: Mathlib/Algebra/Homology/HomologicalComplex.lean

Proof steps:
state_before: ι : Type u_1
V : Type u
inst✝¹ : Category.{v, u} V
inst✝ : HasZeroMorphisms V
c : ComplexShape ι
K : HomologicalComplex V c
p₁ p₂ p₃ : ι
h₁₂ : p₁ = p₂
h₂₃ : p₂ = p₃
⊢ (K.XIsoOfEq h₁₂).hom ≫ (K.XIsoOfEq h₂₃).hom = (K.XIsoOfEq ⋯).hom
state_after: ι : Type u_1
V : Type u
inst✝¹ : Category.{v, u} V
inst✝ : HasZeroMorphisms V
c : ComplexShape ι
K : HomologicalComplex V c
p₁ p₂ p₃ : ι
h₁₂ : p₁ = p₂
h₂₃ : p₂ = p₃
⊢ eqToHom ⋯ ≫ eqToHom ⋯ = eqToHom ⋯
tactic: dsimp [XIsoOfEq]
state_before: ι : Type u_1
V : Type u
inst✝¹ : Category.{v, u} V
inst✝ : HasZeroMorphisms V
c : ComplexShape ι
K : HomologicalComplex V c
p₁ p₂ p₃ : ι
h₁₂ : p₁ = p₂
h₂₃ : p₂ = p₃
⊢ eqToHom ⋯ ≫ eqToHom ⋯ = eqToHom ⋯
state_after: no goals
tactic: simp only [eqToHom_trans]
Theorem: Polynomial.derivative_mul
File: Mathlib/Algebra/Polynomial/Derivative.lean

Proof steps:
state_before: R : Type u
S : Type v
T : Type w
ι : Type y
A : Type z
a b : R
n : ℕ
inst✝ : Semiring R
f g : R[X]
⊢ derivative (f * g) = derivative f * g + f * derivative g
state_after: no goals
tactic: induction f using Polynomial.induction_on' with
  | h_add => simp only [add_mul, map_add, add_assoc, add_left_comm, *]
  | h_monomial m a =>
  induction g using Polynomial.induction_on' with
  | h_add => simp only [mul_add, map_add, add_assoc, add_left_comm, *]
  | h_monomial n b =>
  simp only [monomial_mul_monomial, derivative_monomial]
  simp only [mul_assoc, (Nat.cast_commute _ _).eq, Nat.cast_add, mul_add, map_add]
  cases m with
  | zero => simp only [zero_add, Nat.cast_zero, mul_zero, map_zero]
  | succ m =>
  cases n with
  | zero => simp only [add_zero, Nat.cast_zero, mul_zero, map_zero]
  | succ n =>
  simp only [Nat.add_succ_sub_one, add_tsub_cancel_right]
  rw [add_assoc, add_comm n 1]
Theorem: Polynomial.coeff_one_zero
File: Mathlib/Algebra/Polynomial/Basic.lean

Proof steps:
state_before: R : Type u
a b : R
m n : ℕ
inst✝ : Semiring R
p q : R[X]
⊢ coeff 1 0 = 1
state_after: no goals
tactic: simp [coeff_one]
Theorem: OrthonormalBasis.sum_repr'
File: Mathlib/Analysis/InnerProductSpace/PiL2.lean

Proof steps:
state_before: ι : Type u_1
ι' : Type u_2
𝕜 : Type u_3
inst✝⁹ : _root_.RCLike 𝕜
E : Type u_4
inst✝⁸ : NormedAddCommGroup E
inst✝⁷ : InnerProductSpace 𝕜 E
E' : Type u_5
inst✝⁶ : NormedAddCommGroup E'
inst✝⁵ : InnerProductSpace 𝕜 E'
F : Type u_6
inst✝⁴ : NormedAddCommGroup F
inst✝³ : InnerProductSpace ℝ F
F' : Type u_7
inst✝² : NormedAddCommGroup F'
inst✝¹ : InnerProductSpace ℝ F'
inst✝ : Fintype ι
b : OrthonormalBasis ι 𝕜 E
x : E
⊢ ∑ i : ι, ⟪b i, x⟫_𝕜 • b i = x
state_after: ι : Type u_1
ι' : Type u_2
𝕜 : Type u_3
inst✝⁹ : _root_.RCLike 𝕜
E : Type u_4
inst✝⁸ : NormedAddCommGroup E
inst✝⁷ : InnerProductSpace 𝕜 E
E' : Type u_5
inst✝⁶ : NormedAddCommGroup E'
inst✝⁵ : InnerProductSpace 𝕜 E'
F : Type u_6
inst✝⁴ : NormedAddCommGroup F
inst✝³ : InnerProductSpace ℝ F
F' : Type u_7
inst✝² : NormedAddCommGroup F'
inst✝¹ : InnerProductSpace ℝ F'
inst✝ : Fintype ι
b : OrthonormalBasis ι 𝕜 E
x : E
⊢ ∑ i : ι, ⟪b i, x⟫_𝕜 • b i = ∑ i : ι, b.repr x i • b i
tactic: nth_rw 2 [← (b.sum_repr x)]
state_before: ι : Type u_1
ι' : Type u_2
𝕜 : Type u_3
inst✝⁹ : _root_.RCLike 𝕜
E : Type u_4
inst✝⁸ : NormedAddCommGroup E
inst✝⁷ : InnerProductSpace 𝕜 E
E' : Type u_5
inst✝⁶ : NormedAddCommGroup E'
inst✝⁵ : InnerProductSpace 𝕜 E'
F : Type u_6
inst✝⁴ : NormedAddCommGroup F
inst✝³ : InnerProductSpace ℝ F
F' : Type u_7
inst✝² : NormedAddCommGroup F'
inst✝¹ : InnerProductSpace ℝ F'
inst✝ : Fintype ι
b : OrthonormalBasis ι 𝕜 E
x : E
⊢ ∑ i : ι, ⟪b i, x⟫_𝕜 • b i = ∑ i : ι, b.repr x i • b i
state_after: no goals
tactic: simp_rw [b.repr_apply_apply x]
Theorem: Prod.mk_covBy_mk_iff
File: Mathlib/Order/Cover.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
inst✝¹ : PartialOrder α
inst✝ : PartialOrder β
a a₁ a₂ : α
b b₁ b₂ : β
x y : α × β
⊢ (a₁, b₁) ⋖ (a₂, b₂) ↔ a₁ ⋖ a₂ ∧ b₁ = b₂ ∨ b₁ ⋖ b₂ ∧ a₁ = a₂
state_after: case refine_1
α : Type u_1
β : Type u_2
inst✝¹ : PartialOrder α
inst✝ : PartialOrder β
a a₁ a₂ : α
b b₁ b₂ : β
x y : α × β
h : (a₁, b₁) ⋖ (a₂, b₂)
⊢ a₁ ⋖ a₂ ∧ b₁ = b₂ ∨ b₁ ⋖ b₂ ∧ a₁ = a₂

case refine_2
α : Type u_1
β : Type u_2
inst✝¹ : PartialOrder α
inst✝ : PartialOrder β
a a₁ a₂ : α
b b₁ b₂ : β
x y : α × β
⊢ a₁ ⋖ a₂ ∧ b₁ = b₂ ∨ b₁ ⋖ b₂ ∧ a₁ = a₂ → (a₁, b₁) ⋖ (a₂, b₂)
tactic: refine ⟨fun h => ?_, ?_⟩
Theorem: Interval.mul_eq_one_iff
File: Mathlib/Algebra/Order/Interval/Basic.lean

Proof steps:
state_before: ι : Type u_1
α : Type u_2
inst✝ : OrderedCommGroup α
s t : Interval α
⊢ s * t = 1 ↔ ∃ a b, s = pure a ∧ t = pure b ∧ a * b = 1
state_after: case bot
ι : Type u_1
α : Type u_2
inst✝ : OrderedCommGroup α
t : Interval α
⊢ ⊥ * t = 1 ↔ ∃ a b, ⊥ = pure a ∧ t = pure b ∧ a * b = 1

case coe
ι : Type u_1
α : Type u_2
inst✝ : OrderedCommGroup α
t : Interval α
a✝ : NonemptyInterval α
⊢ ↑a✝ * t = 1 ↔ ∃ a b, ↑a✝ = pure a ∧ t = pure b ∧ a * b = 1
tactic: cases s
state_before: case coe
ι : Type u_1
α : Type u_2
inst✝ : OrderedCommGroup α
t : Interval α
a✝ : NonemptyInterval α
⊢ ↑a✝ * t = 1 ↔ ∃ a b, ↑a✝ = pure a ∧ t = pure b ∧ a * b = 1
state_after: case coe.bot
ι : Type u_1
α : Type u_2
inst✝ : OrderedCommGroup α
a✝ : NonemptyInterval α
⊢ ↑a✝ * ⊥ = 1 ↔ ∃ a b, ↑a✝ = pure a ∧ ⊥ = pure b ∧ a * b = 1

case coe.coe
ι : Type u_1
α : Type u_2
inst✝ : OrderedCommGroup α
a✝¹ a✝ : NonemptyInterval α
⊢ ↑a✝¹ * ↑a✝ = 1 ↔ ∃ a b, ↑a✝¹ = pure a ∧ ↑a✝ = pure b ∧ a * b = 1
tactic: cases t