ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
Theorem: Bornology.IsBounded.neg
File: Mathlib/Analysis/Normed/Group/Pointwise.lean

Proof steps:
state_before: E : Type u_1
inst✝ : SeminormedGroup E
ε δ : ℝ
s t : Set E
x y : E
⊢ IsBounded s → IsBounded s⁻¹
state_after: E : Type u_1
inst✝ : SeminormedGroup E
ε δ : ℝ
s t : Set E
x y : E
⊢ (∃ C, ∀ ⦃x : E⦄, x ∈ s → ‖x‖ ≤ C) → ∃ C, ∀ ⦃x : E⦄, x ∈ s → ‖x‖ ≤ C
tactic: simp_rw [isBounded_iff_forall_norm_le', ← image_inv, forall_mem_image, norm_inv']
state_before: E : Type u_1
inst✝ : SeminormedGroup E
ε δ : ℝ
s t : Set E
x y : E
⊢ (∃ C, ∀ ⦃x : E⦄, x ∈ s → ‖x‖ ≤ C) → ∃ C, ∀ ⦃x : E⦄, x ∈ s → ‖x‖ ≤ C
state_after: no goals
tactic: exact id
Theorem: isSumSq.nonneg
File: Mathlib/Algebra/Ring/SumsOfSquares.lean

Proof steps:
state_before: R✝ : Type u_1
inst✝² : Mul R✝
R : Type u_2
inst✝¹ : LinearOrderedSemiring R
inst✝ : ExistsAddOfLE R
S : R
pS : isSumSq S
⊢ 0 ≤ S
state_after: no goals
tactic: induction pS with
  | zero             => simp only [le_refl]
  | sq_add x S _ ih  => apply add_nonneg ?_ ih; simp only [← pow_two x, sq_nonneg]
Theorem: Matrix.isHermitian_conjTranspose_mul_mul
File: Mathlib/LinearAlgebra/Matrix/Hermitian.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
m : Type u_3
n : Type u_4
A✝ : Matrix n n α
inst✝⁴ : NonUnitalSemiring α
inst✝³ : StarRing α
inst✝² : NonUnitalSemiring β
inst✝¹ : StarRing β
inst✝ : Fintype m
A : Matrix m m α
B : Matrix m n α
hA : A.IsHermitian
⊢ (Bᴴ * A * B).IsHermitian
state_after: no goals
tactic: simp only [IsHermitian, conjTranspose_mul, conjTranspose_conjTranspose, hA.eq, Matrix.mul_assoc]
Theorem: CategoryTheory.ShortComplex.opcyclesMap_comp_descOpcycles
File: Mathlib/Algebra/Homology/ShortComplex/RightHomology.lean

Proof steps:
state_before: C : Type u_1
inst✝³ : Category.{?u.222391, u_1} C
inst✝² : HasZeroMorphisms C
S S₁ S₂ S₃ : ShortComplex C
h : S.RightHomologyData
A : C
k : S.X₂ ⟶ A
hk : S.f ≫ k = 0
inst✝¹ : S.HasRightHomology
φ : S₁ ⟶ S
inst✝ : S₁.HasRightHomology
⊢ S₁.f ≫ φ.τ₂ ≫ k = 0
state_after: no goals
tactic: rw [← φ.comm₁₂_assoc, hk, comp_zero]
state_before: C : Type u_1
inst✝³ : Category.{u_2, u_1} C
inst✝² : HasZeroMorphisms C
S S₁ S₂ S₃ : ShortComplex C
h : S.RightHomologyData
A : C
k : S.X₂ ⟶ A
hk : S.f ≫ k = 0
inst✝¹ : S.HasRightHomology
φ : S₁ ⟶ S
inst✝ : S₁.HasRightHomology
⊢ opcyclesMap φ ≫ S.descOpcycles k hk = S₁.descOpcycles (φ.τ₂ ≫ k) ⋯
state_after: no goals
tactic: simp only [← cancel_epi (S₁.pOpcycles), p_opcyclesMap_assoc, p_descOpcycles]
Theorem: Nat.floorRoot_eq_zero
File: Mathlib/Data/Nat/Factorization/Root.lean

Proof steps:
state_before: a b n : ℕ
⊢ ¬(n ≠ 0 ∧ a ≠ 0) ↔ n = 0 ∨ a = 0
state_after: no goals
tactic: simp only [not_and_or, ne_eq, not_not]
Theorem: continuousWithinAt_compl_self
File: Mathlib/Topology/ContinuousOn.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
inst✝⁴ : TopologicalSpace α
ι : Type u_5
π : ι → Type u_6
inst✝³ : (i : ι) → TopologicalSpace (π i)
inst✝² : TopologicalSpace β
inst✝¹ : TopologicalSpace γ
inst✝ : TopologicalSpace δ
f : α → β
a : α
⊢ ContinuousWithinAt f {a}ᶜ a ↔ ContinuousAt f a
state_after: no goals
tactic: rw [compl_eq_univ_diff, continuousWithinAt_diff_self, continuousWithinAt_univ]
Theorem: Subgroup.map_subtype_le_map_subtype
File: Mathlib/Algebra/Group/Subgroup/Basic.lean

Proof steps:
state_before: G : Type u_1
G'✝ : Type u_2
G'' : Type u_3
inst✝⁴ : Group G
inst✝³ : Group G'✝
inst✝² : Group G''
A : Type u_4
inst✝¹ : AddGroup A
N : Type u_5
inst✝ : Group N
f : G →* N
G' : Subgroup G
H K : Subgroup ↥G'
⊢ Injective ⇑G'.subtype
state_after: no goals
tactic: apply Subtype.coe_injective
Theorem: MonoidHom.submonoidMap_surjective
File: Mathlib/Algebra/Group/Submonoid/Operations.lean

Proof steps:
state_before: M : Type u_1
N : Type u_2
P : Type u_3
inst✝⁴ : MulOneClass M
inst✝³ : MulOneClass N
inst✝² : MulOneClass P
S : Submonoid M
A : Type u_4
inst✝¹ : SetLike A M
hA : SubmonoidClass A M
S' : A
F : Type u_5
inst✝ : FunLike F M N
mc : MonoidHomClass F M N
f : M →* N
M' : Submonoid M
⊢ Function.Surjective ⇑(f.submonoidMap M')
state_after: case mk.intro.intro
M : Type u_1
N : Type u_2
P : Type u_3
inst✝⁴ : MulOneClass M
inst✝³ : MulOneClass N
inst✝² : MulOneClass P
S : Submonoid M
A : Type u_4
inst✝¹ : SetLike A M
hA : SubmonoidClass A M
S' : A
F : Type u_5
inst✝ : FunLike F M N
mc : MonoidHomClass F M N
f : M →* N
M' : Submonoid M
x : M
hx : x ∈ ↑M'
⊢ ∃ a, (f.submonoidMap M') a = ⟨f x, ⋯⟩
tactic: rintro ⟨_, x, hx, rfl⟩
state_before: case mk.intro.intro
M : Type u_1
N : Type u_2
P : Type u_3
inst✝⁴ : MulOneClass M
inst✝³ : MulOneClass N
inst✝² : MulOneClass P
S : Submonoid M
A : Type u_4
inst✝¹ : SetLike A M
hA : SubmonoidClass A M
S' : A
F : Type u_5
inst✝ : FunLike F M N
mc : MonoidHomClass F M N
f : M →* N
M' : Submonoid M
x : M
hx : x ∈ ↑M'
⊢ ∃ a, (f.submonoidMap M') a = ⟨f x, ⋯⟩
state_after: no goals
tactic: exact ⟨⟨x, hx⟩, rfl⟩
Theorem: multiplicity.multiplicity_le_multiplicity_iff
File: Mathlib/RingTheory/Multiplicity.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
inst✝³ : Monoid α
inst✝² : Monoid β
inst✝¹ : DecidableRel fun x x_1 => x ∣ x_1
inst✝ : DecidableRel fun x x_1 => x ∣ x_1
a b : α
c d : β
h : ∀ (n : ℕ), a ^ n ∣ b → c ^ n ∣ d
this : Decidable (Finite a b) := Classical.dec (Finite a b)
hab : Finite a b
⊢ multiplicity a b ≤ multiplicity c d
state_after: α : Type u_1
β : Type u_2
inst✝³ : Monoid α
inst✝² : Monoid β
inst✝¹ : DecidableRel fun x x_1 => x ∣ x_1
inst✝ : DecidableRel fun x x_1 => x ∣ x_1
a b : α
c d : β
h : ∀ (n : ℕ), a ^ n ∣ b → c ^ n ∣ d
this : Decidable (Finite a b) := Classical.dec (Finite a b)
hab : Finite a b
⊢ ↑((multiplicity a b).get ⋯) ≤ multiplicity c d
tactic: rw [← PartENat.natCast_get (finite_iff_dom.1 hab)]
state_before: α : Type u_1
β : Type u_2
inst✝³ : Monoid α
inst✝² : Monoid β
inst✝¹ : DecidableRel fun x x_1 => x ∣ x_1
inst✝ : DecidableRel fun x x_1 => x ∣ x_1
a b : α
c d : β
h : ∀ (n : ℕ), a ^ n ∣ b → c ^ n ∣ d
this : Decidable (Finite a b) := Classical.dec (Finite a b)
hab : Finite a b
⊢ ↑((multiplicity a b).get ⋯) ≤ multiplicity c d
state_after: no goals
tactic: exact le_multiplicity_of_pow_dvd (h _ (pow_multiplicity_dvd _))
state_before: α : Type u_1
β : Type u_2
inst✝³ : Monoid α
inst✝² : Monoid β
inst✝¹ : DecidableRel fun x x_1 => x ∣ x_1
inst✝ : DecidableRel fun x x_1 => x ∣ x_1
a b : α
c d : β
h : ∀ (n : ℕ), a ^ n ∣ b → c ^ n ∣ d
this : Decidable (Finite a b) := Classical.dec (Finite a b)
hab : ¬Finite a b
⊢ multiplicity a b ≤ multiplicity c d
state_after: α : Type u_1
β : Type u_2
inst✝³ : Monoid α
inst✝² : Monoid β
inst✝¹ : DecidableRel fun x x_1 => x ∣ x_1
inst✝ : DecidableRel fun x x_1 => x ∣ x_1
a b : α
c d : β
h : ∀ (n : ℕ), a ^ n ∣ b → c ^ n ∣ d
this✝ : Decidable (Finite a b) := Classical.dec (Finite a b)
hab : ¬Finite a b
this : ∀ (n : ℕ), c ^ n ∣ d
⊢ multiplicity a b ≤ multiplicity c d
tactic: have : ∀ n : ℕ, c ^ n ∣ d := fun n => h n (not_finite_iff_forall.1 hab _)
state_before: α : Type u_1
β : Type u_2
inst✝³ : Monoid α
inst✝² : Monoid β
inst✝¹ : DecidableRel fun x x_1 => x ∣ x_1
inst✝ : DecidableRel fun x x_1 => x ∣ x_1
a b : α
c d : β
h : ∀ (n : ℕ), a ^ n ∣ b → c ^ n ∣ d
this✝ : Decidable (Finite a b) := Classical.dec (Finite a b)
hab : ¬Finite a b
this : ∀ (n : ℕ), c ^ n ∣ d
⊢ multiplicity a b ≤ multiplicity c d
state_after: no goals
tactic: rw [eq_top_iff_not_finite.2 hab, eq_top_iff_not_finite.2 (not_finite_iff_forall.2 this)]
Theorem: Cardinal.zero_powerlt
File: Mathlib/SetTheory/Cardinal/Basic.lean

Proof steps:
state_before: α β : Type u
c : Cardinal.{?u.255346}
a : Cardinal.{u_1}
h : a ≠ 0
⊢ 0 ^< a = 1
state_after: α β : Type u
c : Cardinal.{?u.255346}
a : Cardinal.{u_1}
h : a ≠ 0
⊢ 1 ≤ 0 ^< a
tactic: apply (powerlt_le.2 fun c _ => zero_power_le _).antisymm
state_before: α β : Type u
c : Cardinal.{?u.255346}
a : Cardinal.{u_1}
h : a ≠ 0
⊢ 1 ≤ 0 ^< a
state_after: α β : Type u
c : Cardinal.{?u.255346}
a : Cardinal.{u_1}
h : a ≠ 0
⊢ ?m.255561 ^ 0 ≤ 0 ^< a

α β : Type u
c : Cardinal.{?u.255346}
a : Cardinal.{u_1}
h : a ≠ 0
⊢ Cardinal.{u_1}
tactic: rw [← power_zero]
state_before: α β : Type u
c : Cardinal.{?u.255346}
a : Cardinal.{u_1}
h : a ≠ 0
⊢ ?m.255561 ^ 0 ≤ 0 ^< a

α β : Type u
c : Cardinal.{?u.255346}
a : Cardinal.{u_1}
h : a ≠ 0
⊢ Cardinal.{u_1}
state_after: no goals
tactic: exact le_powerlt 0 (pos_iff_ne_zero.2 h)
Theorem: Set.indicator_comp_of_zero
File: Mathlib/Algebra/Group/Indicator.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
ι : Type u_3
M : Type u_4
N : Type u_5
inst✝¹ : One M
inst✝ : One N
s t : Set α
f g✝ : α → M
a : α
g : M → N
hg : g 1 = 1
⊢ s.mulIndicator (g ∘ f) = g ∘ s.mulIndicator f
state_after: case h
α : Type u_1
β : Type u_2
ι : Type u_3
M : Type u_4
N : Type u_5
inst✝¹ : One M
inst✝ : One N
s t : Set α
f g✝ : α → M
a : α
g : M → N
hg : g 1 = 1
x✝ : α
⊢ s.mulIndicator (g ∘ f) x✝ = (g ∘ s.mulIndicator f) x✝
tactic: funext
state_before: case h
α : Type u_1
β : Type u_2
ι : Type u_3
M : Type u_4
N : Type u_5
inst✝¹ : One M
inst✝ : One N
s t : Set α
f g✝ : α → M
a : α
g : M → N
hg : g 1 = 1
x✝ : α
⊢ s.mulIndicator (g ∘ f) x✝ = (g ∘ s.mulIndicator f) x✝
state_after: case h
α : Type u_1
β : Type u_2
ι : Type u_3
M : Type u_4
N : Type u_5
inst✝¹ : One M
inst✝ : One N
s t : Set α
f g✝ : α → M
a : α
g : M → N
hg : g 1 = 1
x✝ : α
⊢ (if x✝ ∈ s then (g ∘ f) x✝ else 1) = (g ∘ s.mulIndicator f) x✝
tactic: simp only [mulIndicator]
state_before: case h
α : Type u_1
β : Type u_2
ι : Type u_3
M : Type u_4
N : Type u_5
inst✝¹ : One M
inst✝ : One N
s t : Set α
f g✝ : α → M
a : α
g : M → N
hg : g 1 = 1
x✝ : α
⊢ (if x✝ ∈ s then (g ∘ f) x✝ else 1) = (g ∘ s.mulIndicator f) x✝
state_after: no goals
tactic: split_ifs <;> simp [*]
Theorem: uniformContinuousOn_iff_restrict
File: Mathlib/Topology/UniformSpace/Basic.lean

Proof steps:
state_before: α : Type ua
β : Type ub
γ : Type uc
δ : Type ud
ι : Sort u_1
inst✝¹ : UniformSpace α
inst✝ : UniformSpace β
f : α → β
s : Set α
⊢ UniformContinuousOn f s ↔ UniformContinuous (s.restrict f)
state_after: α : Type ua
β : Type ub
γ : Type uc
δ : Type ud
ι : Sort u_1
inst✝¹ : UniformSpace α
inst✝ : UniformSpace β
f : α → β
s : Set α
⊢ Tendsto (fun x => (f x.1, f x.2)) (𝓤 α ⊓ 𝓟 (s ×ˢ s)) (𝓤 β) ↔
    Tendsto (fun x => (s.restrict f x.1, s.restrict f x.2)) (𝓤 ↑s) (𝓤 β)
tactic: delta UniformContinuousOn UniformContinuous
state_before: α : Type ua
β : Type ub
γ : Type uc
δ : Type ud
ι : Sort u_1
inst✝¹ : UniformSpace α
inst✝ : UniformSpace β
f : α → β
s : Set α
⊢ Tendsto (fun x => (f x.1, f x.2)) (𝓤 α ⊓ 𝓟 (s ×ˢ s)) (𝓤 β) ↔
    Tendsto (fun x => (s.restrict f x.1, s.restrict f x.2)) (𝓤 ↑s) (𝓤 β)
state_after: α : Type ua
β : Type ub
γ : Type uc
δ : Type ud
ι : Sort u_1
inst✝¹ : UniformSpace α
inst✝ : UniformSpace β
f : α → β
s : Set α
⊢ Tendsto ((fun x => (f x.1, f x.2)) ∘ Prod.map Subtype.val Subtype.val) (𝓤 ↑s) (𝓤 β) ↔
    Tendsto (fun x => (s.restrict f x.1, s.restrict f x.2)) (𝓤 ↑s) (𝓤 β)
tactic: rw [← map_uniformity_set_coe, tendsto_map'_iff]
state_before: α : Type ua
β : Type ub
γ : Type uc
δ : Type ud
ι : Sort u_1
inst✝¹ : UniformSpace α
inst✝ : UniformSpace β
f : α → β
s : Set α
⊢ Tendsto ((fun x => (f x.1, f x.2)) ∘ Prod.map Subtype.val Subtype.val) (𝓤 ↑s) (𝓤 β) ↔
    Tendsto (fun x => (s.restrict f x.1, s.restrict f x.2)) (𝓤 ↑s) (𝓤 β)
state_after: no goals
tactic: rfl
Theorem: UniqueDiffWithinAt.univ_pi
File: Mathlib/Analysis/Calculus/TangentCone.lean

Proof steps:
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
x✝ y : E✝
s✝ t : Set E✝
ι : Type u_5
inst✝² : Finite ι
E : ι → Type u_6
inst✝¹ : (i : ι) → NormedAddCommGroup (E i)
inst✝ : (i : ι) → NormedSpace 𝕜 (E i)
s : (i : ι) → Set (E i)
x : (i : ι) → E i
h : ∀ (i : ι), UniqueDiffWithinAt 𝕜 (s i) (x i)
⊢ UniqueDiffWithinAt 𝕜 (univ.pi s) x
state_after: no goals
tactic: classical
  simp only [uniqueDiffWithinAt_iff, closure_pi_set] at h ⊢
  refine ⟨(dense_pi univ fun i _ => (h i).1).mono ?_, fun i _ => (h i).2⟩
  norm_cast
  simp only [← Submodule.iSup_map_single, iSup_le_iff, LinearMap.map_span, Submodule.span_le,
    ← mapsTo']
  exact fun i => (mapsTo_tangentCone_pi fun j _ => (h j).2).mono Subset.rfl Submodule.subset_span
Theorem: IsScalarTower.algebraMap_smul
File: Mathlib/Algebra/Algebra/Tower.lean

Proof steps:
state_before: R : Type u
S : Type v
A : Type w
B : Type u₁
M : Type v₁
inst✝⁵ : CommSemiring R
inst✝⁴ : Semiring A
inst✝³ : Algebra R A
inst✝² : MulAction A M
inst✝¹ : SMul R M
inst✝ : IsScalarTower R A M
r : R
x : M
⊢ (algebraMap R A) r • x = r • x
state_after: no goals
tactic: rw [Algebra.algebraMap_eq_smul_one, smul_assoc, one_smul]
Theorem: Finset.sum_le_sum_of_subset_of_nonneg
File: Mathlib/Algebra/Order/BigOperators/Group/Finset.lean

Proof steps:
state_before: ι : Type u_1
α : Type u_2
β : Type u_3
M : Type u_4
N : Type u_5
G : Type u_6
k : Type u_7
R : Type u_8
inst✝¹ : CommMonoid M
inst✝ : OrderedCommMonoid N
f g : ι → N
s t : Finset ι
h : s ⊆ t
hf : ∀ i ∈ t, i ∉ s → 1 ≤ f i
⊢ ∏ i ∈ s, f i ≤ ∏ i ∈ t, f i
state_after: no goals
tactic: classical calc
      ∏ i ∈ s, f i ≤ (∏ i ∈ t \ s, f i) * ∏ i ∈ s, f i :=
        le_mul_of_one_le_left' <| one_le_prod' <| by simpa only [mem_sdiff, and_imp]
      _ = ∏ i ∈ t \ s ∪ s, f i := (prod_union sdiff_disjoint).symm
      _ = ∏ i ∈ t, f i := by rw [sdiff_union_of_subset h]
Theorem: Homotopy.compLeft_hom
File: Mathlib/Algebra/Homology/Homotopy.lean

Proof steps:
state_before: ι : Type u_1
V : Type u
inst✝¹ : Category.{v, u} V
inst✝ : Preadditive V
c : ComplexShape ι
C D E : HomologicalComplex V c
f✝ g✝ : C ⟶ D
h✝ k : D ⟶ E
i✝ : ι
f g : D ⟶ E
h : Homotopy f g
e : C ⟶ D
i j : ι
w : ¬c.Rel j i
⊢ (fun i j => e.f i ≫ h.hom i j) i j = 0
state_after: ι : Type u_1
V : Type u
inst✝¹ : Category.{v, u} V
inst✝ : Preadditive V
c : ComplexShape ι
C D E : HomologicalComplex V c
f✝ g✝ : C ⟶ D
h✝ k : D ⟶ E
i✝ : ι
f g : D ⟶ E
h : Homotopy f g
e : C ⟶ D
i j : ι
w : ¬c.Rel j i
⊢ e.f i ≫ h.hom i j = 0
tactic: dsimp
state_before: ι : Type u_1
V : Type u
inst✝¹ : Category.{v, u} V
inst✝ : Preadditive V
c : ComplexShape ι
C D E : HomologicalComplex V c
f✝ g✝ : C ⟶ D
h✝ k : D ⟶ E
i✝ : ι
f g : D ⟶ E
h : Homotopy f g
e : C ⟶ D
i j : ι
w : ¬c.Rel j i
⊢ e.f i ≫ h.hom i j = 0
state_after: no goals
tactic: rw [h.zero i j w, comp_zero]
state_before: ι : Type u_1
V : Type u
inst✝¹ : Category.{v, u} V
inst✝ : Preadditive V
c : ComplexShape ι
C D E : HomologicalComplex V c
f✝ g✝ : C ⟶ D
h✝ k : D ⟶ E
i✝ : ι
f g : D ⟶ E
h : Homotopy f g
e : C ⟶ D
i : ι
⊢ (e ≫ f).f i = (((dNext i) fun i j => e.f i ≫ h.hom i j) + (prevD i) fun i j => e.f i ≫ h.hom i j) + (e ≫ g).f i
state_after: no goals
tactic: rw [comp_f, h.comm i, dNext_comp_left, prevD_comp_left, comp_f,
    Preadditive.comp_add, Preadditive.comp_add]
Theorem: Int.negOnePow_eq_iff
File: Mathlib/Algebra/Ring/NegOnePow.lean

Proof steps:
state_before: n₁ n₂ : ℤ
⊢ n₁.negOnePow = n₂.negOnePow ↔ Even (n₁ - n₂)
state_after: case pos
n₁ n₂ : ℤ
h₂ : Even n₂
⊢ n₁.negOnePow = n₂.negOnePow ↔ Even (n₁ - n₂)

case neg
n₁ n₂ : ℤ
h₂ : ¬Even n₂
⊢ n₁.negOnePow = n₂.negOnePow ↔ Even (n₁ - n₂)
tactic: by_cases h₂ : Even n₂
Theorem: Num.ofNat'_eq
File: Mathlib/Data/Num/Lemmas.lean

Proof steps:
state_before: α : Type u_1
⊢ ofNat' 0 = ↑0
state_after: no goals
tactic: simp
state_before: α : Type u_1
b : Bool
n : ℕ
IH : ofNat' n = ↑n
⊢ ofNat' (Nat.bit b n) = ↑(Nat.bit b n)
state_after: α : Type u_1
b : Bool
n : ℕ
IH : Nat.binaryRec 0 (fun b x => bif b then Num.bit1 else Num.bit0) n = ↑n
⊢ Nat.binaryRec 0 (fun b x => bif b then Num.bit1 else Num.bit0) (Nat.bit b n) = ↑(Nat.bit b n)
tactic: rw [ofNat'] at IH ⊢
state_before: α : Type u_1
b : Bool
n : ℕ
IH : Nat.binaryRec 0 (fun b x => bif b then Num.bit1 else Num.bit0) n = ↑n
⊢ Nat.binaryRec 0 (fun b x => bif b then Num.bit1 else Num.bit0) (Nat.bit b n) = ↑(Nat.bit b n)
state_after: α : Type u_1
b : Bool
n : ℕ
IH : Nat.binaryRec 0 (fun b x => bif b then Num.bit1 else Num.bit0) n = ↑n
⊢ (bif b then Num.bit1 else Num.bit0) ↑n = ↑(Nat.bit b n)

case h
α : Type u_1
b : Bool
n : ℕ
IH : Nat.binaryRec 0 (fun b x => bif b then Num.bit1 else Num.bit0) n = ↑n
⊢ (bif false then Num.bit1 else Num.bit0) 0 = 0
tactic: rw [Nat.binaryRec_eq, IH]
Theorem: Cycle.formPerm_apply_mem_eq_next
File: Mathlib/GroupTheory/Perm/Cycle/Concrete.lean

Proof steps:
state_before: α : Type u_1
inst✝ : DecidableEq α
s✝ s' s : Cycle α
h : s.Nodup
x : α
hx : x ∈ s
⊢ (s.formPerm h) x = s.next h x hx
state_after: case h
α : Type u_1
inst✝ : DecidableEq α
s s' : Cycle α
x : α
a✝ : List α
h : Nodup (Quot.mk Setoid.r a✝)
hx : x ∈ Quot.mk Setoid.r a✝
⊢ (formPerm (Quot.mk Setoid.r a✝) h) x = next (Quot.mk Setoid.r a✝) h x hx
tactic: induction s using Quot.inductionOn
state_before: case h
α : Type u_1
inst✝ : DecidableEq α
s s' : Cycle α
x : α
a✝ : List α
h : Nodup (Quot.mk Setoid.r a✝)
hx : x ∈ Quot.mk Setoid.r a✝
⊢ (formPerm (Quot.mk Setoid.r a✝) h) x = next (Quot.mk Setoid.r a✝) h x hx
state_after: no goals
tactic: simpa using List.formPerm_apply_mem_eq_next h _ (by simp_all)
Theorem: Polynomial.isRoot_comp
File: Mathlib/Algebra/Polynomial/Eval.lean

Proof steps:
state_before: R✝ : Type u
S : Type v
T : Type w
ι : Type y
a b : R✝
m n : ℕ
inst✝² : CommSemiring R✝
p✝ q✝ : R✝[X]
x : R✝
inst✝¹ : CommSemiring S
f : R✝ →+* S
R : Type u_1
inst✝ : CommSemiring R
p q : R[X]
r : R
⊢ (p.comp q).IsRoot r ↔ p.IsRoot (eval r q)
state_after: no goals
tactic: simp_rw [IsRoot, eval_comp]
Theorem: Metric.uniformCauchySeqOn_iff
File: Mathlib/Topology/MetricSpace/Cauchy.lean

Proof steps:
state_before: α : Type u
β : Type v
X : Type u_1
ι : Type u_2
inst✝² : PseudoMetricSpace α
inst✝¹ : Nonempty β
inst✝ : SemilatticeSup β
γ : Type u_3
F : β → γ → α
s : Set γ
⊢ UniformCauchySeqOn F atTop s ↔ ∀ ε > 0, ∃ N, ∀ m ≥ N, ∀ n ≥ N, ∀ x ∈ s, dist (F m x) (F n x) < ε
state_after: case mp
α : Type u
β : Type v
X : Type u_1
ι : Type u_2
inst✝² : PseudoMetricSpace α
inst✝¹ : Nonempty β
inst✝ : SemilatticeSup β
γ : Type u_3
F : β → γ → α
s : Set γ
⊢ UniformCauchySeqOn F atTop s → ∀ ε > 0, ∃ N, ∀ m ≥ N, ∀ n ≥ N, ∀ x ∈ s, dist (F m x) (F n x) < ε

case mpr
α : Type u
β : Type v
X : Type u_1
ι : Type u_2
inst✝² : PseudoMetricSpace α
inst✝¹ : Nonempty β
inst✝ : SemilatticeSup β
γ : Type u_3
F : β → γ → α
s : Set γ
⊢ (∀ ε > 0, ∃ N, ∀ m ≥ N, ∀ n ≥ N, ∀ x ∈ s, dist (F m x) (F n x) < ε) → UniformCauchySeqOn F atTop s
tactic: constructor
Theorem: ContractingWith.dist_le_of_fixedPoint
File: Mathlib/Topology/MetricSpace/Contracting.lean

Proof steps:
state_before: α : Type u_1
inst✝ : MetricSpace α
K : ℝ≥0
f : α → α
hf : ContractingWith K f
x y : α
hy : IsFixedPt f y
⊢ dist x y ≤ dist x (f x) / (1 - ↑K)
state_after: no goals
tactic: simpa only [hy.eq, dist_self, add_zero] using hf.dist_inequality x y
Theorem: ProbabilityTheory.mgf_neg
File: Mathlib/Probability/Moments.lean

Proof steps:
state_before: Ω : Type u_1
ι : Type u_2
m : MeasurableSpace Ω
X : Ω → ℝ
p : ℕ
μ : Measure Ω
t : ℝ
⊢ mgf (-X) μ t = mgf X μ (-t)
state_after: no goals
tactic: simp_rw [mgf, Pi.neg_apply, mul_neg, neg_mul]
Theorem: CategoryTheory.Pi.isoApp_hom
File: Mathlib/CategoryTheory/Pi/Basic.lean

Proof steps:
state_before: I : Type w₀
J : Type w₁
C : I → Type u₁
inst✝ : (i : I) → Category.{v₁, u₁} (C i)
X Y : (i : I) → C i
f : X ≅ Y
i : I
⊢ f.hom i ≫ f.inv i = 𝟙 (X i)
state_after: no goals
tactic: rw [← comp_apply, Iso.hom_inv_id, id_apply]
state_before: I : Type w₀
J : Type w₁
C : I → Type u₁
inst✝ : (i : I) → Category.{v₁, u₁} (C i)
X Y : (i : I) → C i
f : X ≅ Y
i : I
⊢ f.inv i ≫ f.hom i = 𝟙 (Y i)
state_after: no goals
tactic: rw [← comp_apply, Iso.inv_hom_id, id_apply]
Theorem: eq_zero_or_one_of_sq_eq_self
File: Mathlib/Algebra/GroupWithZero/Defs.lean

Proof steps:
state_before: G₀ : Type u
M₀ : Type u_1
M₀' : Type u_2
G₀' : Type u_3
inst✝ : CancelMonoidWithZero M₀
x : M₀
hx : x ^ 2 = x
x✝ : ¬x = 0
⊢ (fun a => a * x) x = (fun a => a * x) 1
state_after: no goals
tactic: simpa [sq] using hx
Theorem: TensorAlgebra.rank_eq
File: Mathlib/LinearAlgebra/TensorAlgebra/Basis.lean

Proof steps:
state_before: κ : Type uκ
R : Type uR
M : Type uM
inst✝⁴ : CommRing R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Nontrivial R
inst✝ : Module.Free R M
⊢ Module.rank R (TensorAlgebra R M) = Cardinal.lift.{uR, uM} (sum fun n => Module.rank R M ^ n)
state_after: κ✝ : Type uκ
R : Type uR
M : Type uM
inst✝⁴ : CommRing R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Nontrivial R
inst✝ : Module.Free R M
κ : Type uM
b : Basis κ R M
⊢ Module.rank R (TensorAlgebra R M) = Cardinal.lift.{uR, uM} (sum fun n => Module.rank R M ^ n)
tactic: let ⟨⟨κ, b⟩⟩ := Module.Free.exists_basis (R := R) (M := M)
state_before: κ✝ : Type uκ
R : Type uR
M : Type uM
inst✝⁴ : CommRing R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Nontrivial R
inst✝ : Module.Free R M
κ : Type uM
b : Basis κ R M
⊢ Module.rank R (TensorAlgebra R M) = Cardinal.lift.{uR, uM} (sum fun n => Module.rank R M ^ n)
state_after: no goals
tactic: rw [(equivFreeAlgebra b).toLinearEquiv.rank_eq, FreeAlgebra.rank_eq, mk_list_eq_sum_pow,
    Basis.mk_eq_rank'' b]
Theorem: Subgroup.equivMapOfInjective_coe_mulEquiv
File: Mathlib/Algebra/Group/Subgroup/Basic.lean

Proof steps:
state_before: G : Type u_1
G' : Type u_2
G'' : Type u_3
inst✝⁴ : Group G
inst✝³ : Group G'
inst✝² : Group G''
A : Type u_4
inst✝¹ : AddGroup A
N : Type u_5
inst✝ : Group N
H : Subgroup G
e : G ≃* G'
⊢ H.equivMapOfInjective ↑e ⋯ = e.subgroupMap H
state_after: case h.a
G : Type u_1
G' : Type u_2
G'' : Type u_3
inst✝⁴ : Group G
inst✝³ : Group G'
inst✝² : Group G''
A : Type u_4
inst✝¹ : AddGroup A
N : Type u_5
inst✝ : Group N
H : Subgroup G
e : G ≃* G'
x✝ : ↥H
⊢ ↑((H.equivMapOfInjective ↑e ⋯) x✝) = ↑((e.subgroupMap H) x✝)
tactic: ext
state_before: case h.a
G : Type u_1
G' : Type u_2
G'' : Type u_3
inst✝⁴ : Group G
inst✝³ : Group G'
inst✝² : Group G''
A : Type u_4
inst✝¹ : AddGroup A
N : Type u_5
inst✝ : Group N
H : Subgroup G
e : G ≃* G'
x✝ : ↥H
⊢ ↑((H.equivMapOfInjective ↑e ⋯) x✝) = ↑((e.subgroupMap H) x✝)
state_after: no goals
tactic: rfl
Theorem: Rat.zero_mul
File: .lake/packages/batteries/Batteries/Data/Rat/Lemmas.lean

Proof steps:
state_before: a : Rat
⊢ 0 * a = 0
state_after: no goals
tactic: simp [mul_def]
Theorem: CategoryTheory.IsPushout.of_isBilimit
File: Mathlib/CategoryTheory/Limits/Shapes/Pullback/CommSq.lean

Proof steps:
state_before: C : Type u₁
inst✝² : Category.{v₁, u₁} C
Z X Y P : C
f : Z ⟶ X
g : Z ⟶ Y
inl : X ⟶ P
inr : Y ⟶ P
inst✝¹ : HasZeroObject C
inst✝ : HasZeroMorphisms C
b : BinaryBicone X Y
h : b.IsBilimit
⊢ IsPushout 0 0 b.inl b.inr
state_after: no goals
tactic: convert IsPushout.of_is_coproduct' h.isColimit HasZeroObject.zeroIsInitial
    <;> subsingleton
Theorem: Finset.fold_image_idem
File: Mathlib/Data/Finset/Fold.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
op : β → β → β
hc : Std.Commutative op
ha : Std.Associative op
f : α → β
b : β
s✝ : Finset α
a : α
inst✝ : DecidableEq α
g : γ → α
s : Finset γ
hi : Std.IdempotentOp op
⊢ fold op b f (image g s) = fold op b (f ∘ g) s
state_after: case empty
α : Type u_1
β : Type u_2
γ : Type u_3
op : β → β → β
hc : Std.Commutative op
ha : Std.Associative op
f : α → β
b : β
s : Finset α
a : α
inst✝ : DecidableEq α
g : γ → α
hi : Std.IdempotentOp op
⊢ fold op b f (image g ∅) = fold op b (f ∘ g) ∅

case cons
α : Type u_1
β : Type u_2
γ : Type u_3
op : β → β → β
hc : Std.Commutative op
ha : Std.Associative op
f : α → β
b : β
s : Finset α
a : α
inst✝ : DecidableEq α
g : γ → α
hi : Std.IdempotentOp op
x : γ
xs : Finset γ
hx : x ∉ xs
ih : fold op b f (image g xs) = fold op b (f ∘ g) xs
⊢ fold op b f (image g (cons x xs hx)) = fold op b (f ∘ g) (cons x xs hx)
tactic: induction' s using Finset.cons_induction with x xs hx ih