ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
Theorem: spectrum_diagonal
File: Mathlib/LinearAlgebra/Eigenspace/Matrix.lean

Proof steps:
state_before: R : Type u_1
n : Type u_2
M : Type u_3
inst✝² : DecidableEq n
inst✝¹ : Fintype n
inst✝ : Field R
d : n → R
⊢ spectrum R (diagonal d) = Set.range d
state_after: case h
R : Type u_1
n : Type u_2
M : Type u_3
inst✝² : DecidableEq n
inst✝¹ : Fintype n
inst✝ : Field R
d : n → R
μ : R
⊢ μ ∈ spectrum R (diagonal d) ↔ μ ∈ Set.range d
tactic: ext μ
state_before: case h
R : Type u_1
n : Type u_2
M : Type u_3
inst✝² : DecidableEq n
inst✝¹ : Fintype n
inst✝ : Field R
d : n → R
μ : R
⊢ μ ∈ spectrum R (diagonal d) ↔ μ ∈ Set.range d
state_after: case h
R : Type u_1
n : Type u_2
M : Type u_3
inst✝² : DecidableEq n
inst✝¹ : Fintype n
inst✝ : Field R
d : n → R
μ : R
⊢ HasEigenvalue ((toLinAlgEquiv (Pi.basisFun R n)) (diagonal d)) μ ↔ μ ∈ Set.range d
tactic: rw [← AlgEquiv.spectrum_eq (toLinAlgEquiv <| Pi.basisFun R n), ← hasEigenvalue_iff_mem_spectrum]
state_before: case h
R : Type u_1
n : Type u_2
M : Type u_3
inst✝² : DecidableEq n
inst✝¹ : Fintype n
inst✝ : Field R
d : n → R
μ : R
⊢ HasEigenvalue ((toLinAlgEquiv (Pi.basisFun R n)) (diagonal d)) μ ↔ μ ∈ Set.range d
state_after: no goals
tactic: exact hasEigenvalue_toLin'_diagonal_iff d
Theorem: List.pairwise_filter
File: .lake/packages/batteries/Batteries/Data/List/Pairwise.lean

Proof steps:
state_before: α : Type u_1
R : α → α → Prop
p : α → Prop
inst✝ : DecidablePred p
l : List α
⊢ Pairwise R (filter (fun b => decide (p b)) l) ↔ Pairwise (fun x y => p x → p y → R x y) l
state_after: α : Type u_1
R : α → α → Prop
p : α → Prop
inst✝ : DecidablePred p
l : List α
⊢ Pairwise
      (fun a a' =>
        ∀ (b : α),
          b ∈ Option.guard (fun x => decide (p x) = true) a →
            ∀ (b' : α), b' ∈ Option.guard (fun x => decide (p x) = true) a' → R b b')
      l ↔
    Pairwise (fun x y => p x → p y → R x y) l
tactic: rw [← filterMap_eq_filter, pairwise_filterMap]
state_before: α : Type u_1
R : α → α → Prop
p : α → Prop
inst✝ : DecidablePred p
l : List α
⊢ Pairwise
      (fun a a' =>
        ∀ (b : α),
          b ∈ Option.guard (fun x => decide (p x) = true) a →
            ∀ (b' : α), b' ∈ Option.guard (fun x => decide (p x) = true) a' → R b b')
      l ↔
    Pairwise (fun x y => p x → p y → R x y) l
state_after: no goals
tactic: simp
Theorem: Multiset.Ico_add_Ico_eq_Ico
File: Mathlib/Order/Interval/Multiset.lean

Proof steps:
state_before: α : Type u_1
inst✝¹ : LinearOrder α
inst✝ : LocallyFiniteOrder α
a✝ b✝ c✝ d a b c : α
hab : a ≤ b
hbc : b ≤ c
⊢ Ico a b + Ico b c = Ico a c
state_after: no goals
tactic: rw [add_eq_union_iff_disjoint.2 (Ico_disjoint_Ico le_rfl), Ico, Ico, Ico, ← Finset.union_val,
    Finset.Ico_union_Ico_eq_Ico hab hbc]
Theorem: summable_dirichletSummand
File: Mathlib/NumberTheory/EulerProduct/DirichletLSeries.lean

Proof steps:
state_before: s : ℂ
N : ℕ
χ : DirichletCharacter ℂ N
hs : 1 < s.re
⊢ Summable fun n => ‖(dirichletSummandHom χ ⋯) n‖
state_after: s : ℂ
N : ℕ
χ : DirichletCharacter ℂ N
hs : 1 < s.re
⊢ Summable fun n => ‖χ ↑n‖ * ‖↑n ^ (-s)‖
tactic: simp only [dirichletSummandHom, MonoidWithZeroHom.coe_mk, ZeroHom.coe_mk, norm_mul]
state_before: s : ℂ
N : ℕ
χ : DirichletCharacter ℂ N
hs : 1 < s.re
⊢ Summable fun n => ‖χ ↑n‖ * ‖↑n ^ (-s)‖
state_after: no goals
tactic: exact (summable_riemannZetaSummand hs).of_nonneg_of_le (fun _ ↦ by positivity)
    (fun n ↦ mul_le_of_le_one_left (norm_nonneg _) <| χ.norm_le_one n)
Theorem: MvPolynomial.exists_rename_eq_of_vars_subset_range
File: Mathlib/Algebra/MvPolynomial/Variables.lean

Proof steps:
state_before: R : Type u
S : Type v
σ : Type u_1
τ : Type u_2
r : R
e : ℕ
n m : σ
s : σ →₀ ℕ
inst✝¹ : CommSemiring R
p✝ q : MvPolynomial σ R
inst✝ : CommSemiring S
p : MvPolynomial σ R
f : τ → σ
hfi : Injective f
hf : ↑p.vars ⊆ range f
⊢ (rename f) ((aeval fun i => Option.elim' 0 X (partialInv f i)) p) = p
state_after: R : Type u
S : Type v
σ : Type u_1
τ : Type u_2
r : R
e : ℕ
n m : σ
s : σ →₀ ℕ
inst✝¹ : CommSemiring R
p✝ q : MvPolynomial σ R
inst✝ : CommSemiring S
p : MvPolynomial σ R
f : τ → σ
hfi : Injective f
hf : ↑p.vars ⊆ range f
⊢ ((rename f).comp (aeval fun i => Option.elim' 0 X (partialInv f i)).toRingHom) p = (RingHom.id (MvPolynomial σ R)) p
tactic: show (rename f).toRingHom.comp _ p = RingHom.id _ p
state_before: R : Type u
S : Type v
σ : Type u_1
τ : Type u_2
r : R
e : ℕ
n m : σ
s : σ →₀ ℕ
inst✝¹ : CommSemiring R
p✝ q : MvPolynomial σ R
inst✝ : CommSemiring S
p : MvPolynomial σ R
f : τ → σ
hfi : Injective f
hf : ↑p.vars ⊆ range f
⊢ ((rename f).comp (aeval fun i => Option.elim' 0 X (partialInv f i)).toRingHom) p = (RingHom.id (MvPolynomial σ R)) p
state_after: case refine_1
R : Type u
S : Type v
σ : Type u_1
τ : Type u_2
r : R
e : ℕ
n m : σ
s : σ →₀ ℕ
inst✝¹ : CommSemiring R
p✝ q : MvPolynomial σ R
inst✝ : CommSemiring S
p : MvPolynomial σ R
f : τ → σ
hfi : Injective f
hf : ↑p.vars ⊆ range f
⊢ ((rename f).comp (aeval fun i => Option.elim' 0 X (partialInv f i)).toRingHom).comp C =
    (RingHom.id (MvPolynomial σ R)).comp C

case refine_2
R : Type u
S : Type v
σ : Type u_1
τ : Type u_2
r : R
e : ℕ
n m : σ
s : σ →₀ ℕ
inst✝¹ : CommSemiring R
p✝ q : MvPolynomial σ R
inst✝ : CommSemiring S
p : MvPolynomial σ R
f : τ → σ
hfi : Injective f
hf : ↑p.vars ⊆ range f
⊢ ∀ i ∈ p.vars,
    i ∈ p.vars →
      ((rename f).comp (aeval fun i => Option.elim' 0 X (partialInv f i)).toRingHom) (X i) =
        (RingHom.id (MvPolynomial σ R)) (X i)

case refine_3
R : Type u
S : Type v
σ : Type u_1
τ : Type u_2
r : R
e : ℕ
n m : σ
s : σ →₀ ℕ
inst✝¹ : CommSemiring R
p✝ q : MvPolynomial σ R
inst✝ : CommSemiring S
p : MvPolynomial σ R
f : τ → σ
hfi : Injective f
hf : ↑p.vars ⊆ range f
⊢ p = p
tactic: refine hom_congr_vars ?_ ?_ ?_
Theorem: HomologicalComplex₂.D₂_totalShift₂XIso_hom
File: Mathlib/Algebra/Homology/TotalComplexShift.lean

Proof steps:
state_before: C : Type u_1
inst✝² : Category.{u_2, u_1} C
inst✝¹ : Preadditive C
K L : HomologicalComplex₂ C (up ℤ) (up ℤ)
f : K ⟶ L
x y : ℤ
inst✝ : K.HasTotal (up ℤ)
n₀ n₁ n₀' n₁' : ℤ
h₀ : n₀ + y = n₀'
h₁ : n₁ + y = n₁'
⊢ ((shiftFunctor₂ C y).obj K).D₂ (up ℤ) n₀ n₁ ≫ (K.totalShift₂XIso y n₁ n₁' h₁).hom =
    y.negOnePow • (K.totalShift₂XIso y n₀ n₀' h₀).hom ≫ K.D₂ (up ℤ) n₀' n₁'
state_after: case pos
C : Type u_1
inst✝² : Category.{u_2, u_1} C
inst✝¹ : Preadditive C
K L : HomologicalComplex₂ C (up ℤ) (up ℤ)
f : K ⟶ L
x y : ℤ
inst✝ : K.HasTotal (up ℤ)
n₀ n₁ n₀' n₁' : ℤ
h₀ : n₀ + y = n₀'
h₁ : n₁ + y = n₁'
h : (up ℤ).Rel n₀ n₁
⊢ ((shiftFunctor₂ C y).obj K).D₂ (up ℤ) n₀ n₁ ≫ (K.totalShift₂XIso y n₁ n₁' h₁).hom =
    y.negOnePow • (K.totalShift₂XIso y n₀ n₀' h₀).hom ≫ K.D₂ (up ℤ) n₀' n₁'

case neg
C : Type u_1
inst✝² : Category.{u_2, u_1} C
inst✝¹ : Preadditive C
K L : HomologicalComplex₂ C (up ℤ) (up ℤ)
f : K ⟶ L
x y : ℤ
inst✝ : K.HasTotal (up ℤ)
n₀ n₁ n₀' n₁' : ℤ
h₀ : n₀ + y = n₀'
h₁ : n₁ + y = n₁'
h : ¬(up ℤ).Rel n₀ n₁
⊢ ((shiftFunctor₂ C y).obj K).D₂ (up ℤ) n₀ n₁ ≫ (K.totalShift₂XIso y n₁ n₁' h₁).hom =
    y.negOnePow • (K.totalShift₂XIso y n₀ n₀' h₀).hom ≫ K.D₂ (up ℤ) n₀' n₁'
tactic: by_cases h : (up ℤ).Rel n₀ n₁
Theorem: OreLocalization.zero_smul
File: Mathlib/RingTheory/OreLocalization/Ring.lean

Proof steps:
state_before: R : Type u_1
inst✝³ : Semiring R
S : Submonoid R
inst✝² : OreSet S
X : Type u_2
inst✝¹ : AddCommMonoid X
inst✝ : Module R X
x : OreLocalization S X
⊢ 0 • x = 0
state_after: case c
R : Type u_1
inst✝³ : Semiring R
S : Submonoid R
inst✝² : OreSet S
X : Type u_2
inst✝¹ : AddCommMonoid X
inst✝ : Module R X
r : X
s : ↥S
⊢ 0 • (r /ₒ s) = 0
tactic: induction' x with r s
state_before: case c
R : Type u_1
inst✝³ : Semiring R
S : Submonoid R
inst✝² : OreSet S
X : Type u_2
inst✝¹ : AddCommMonoid X
inst✝ : Module R X
r : X
s : ↥S
⊢ 0 • (r /ₒ s) = 0
state_after: case c
R : Type u_1
inst✝³ : Semiring R
S : Submonoid R
inst✝² : OreSet S
X : Type u_2
inst✝¹ : AddCommMonoid X
inst✝ : Module R X
r : X
s : ↥S
⊢ 0 • r /ₒ (1 * 1) = 0
tactic: rw [OreLocalization.zero_def, oreDiv_smul_char 0 r 1 s 0 1 (by simp)]
state_before: case c
R : Type u_1
inst✝³ : Semiring R
S : Submonoid R
inst✝² : OreSet S
X : Type u_2
inst✝¹ : AddCommMonoid X
inst✝ : Module R X
r : X
s : ↥S
⊢ 0 • r /ₒ (1 * 1) = 0
state_after: no goals
tactic: simp
Theorem: sub_one_div_inv_le_two
File: Mathlib/Algebra/Order/Field/Basic.lean

Proof steps:
state_before: ι : Type u_1
α : Type u_2
β : Type u_3
inst✝ : LinearOrderedField α
a b c d : α
n : ℤ
a2 : 2 ≤ a
⊢ (1 - 1 / a)⁻¹ ≤ 2
state_after: ι : Type u_1
α : Type u_2
β : Type u_3
inst✝ : LinearOrderedField α
a b c d : α
n : ℤ
a2 : 2 ≤ a
⊢ 2⁻¹ ≤ 1 - 1 / a
tactic: refine (inv_le_inv_of_le (inv_pos (α := α) |>.2 <| zero_lt_two' α) ?_).trans_eq (inv_inv (2 : α))
state_before: ι : Type u_1
α : Type u_2
β : Type u_3
inst✝ : LinearOrderedField α
a b c d : α
n : ℤ
a2 : 2 ≤ a
⊢ 2⁻¹ ≤ 1 - 1 / a
state_after: ι : Type u_1
α : Type u_2
β : Type u_3
inst✝ : LinearOrderedField α
a b c d : α
n : ℤ
a2 : 2 ≤ a
⊢ 1 / a ≤ 1 - 2⁻¹
tactic: rw [le_sub_iff_add_le, add_comm, ← le_sub_iff_add_le]
state_before: ι : Type u_1
α : Type u_2
β : Type u_3
inst✝ : LinearOrderedField α
a b c d : α
n : ℤ
a2 : 2 ≤ a
⊢ 1 / a ≤ 1 - 2⁻¹
state_after: case h.e'_4
ι : Type u_1
α : Type u_2
β : Type u_3
inst✝ : LinearOrderedField α
a b c d : α
n : ℤ
a2 : 2 ≤ a
⊢ 1 - 2⁻¹ = 2⁻¹
tactic: convert (one_div a).le.trans (inv_le_inv_of_le zero_lt_two a2) using 1
state_before: case h.e'_4
ι : Type u_1
α : Type u_2
β : Type u_3
inst✝ : LinearOrderedField α
a b c d : α
n : ℤ
a2 : 2 ≤ a
⊢ 1 - 2⁻¹ = 2⁻¹
state_after: no goals
tactic: rw [sub_eq_iff_eq_add, ← two_mul, mul_inv_cancel two_ne_zero]
Theorem: CompHaus.Sigma.ι_comp_toFiniteCoproduct
File: Mathlib/Topology/Category/CompHaus/Limits.lean

Proof steps:
state_before: α : Type w
inst✝ : Finite α
X : α → CompHaus
a : α
⊢ Sigma.ι X a ≫ (coproductIsoCoproduct X).inv = finiteCoproduct.ι X a
state_after: no goals
tactic: simp [coproductIsoCoproduct]
Theorem: IsSepClosed.separableClosure_eq_bot_iff
File: Mathlib/FieldTheory/SeparableClosure.lean

Proof steps:
state_before: F : Type u
E : Type v
inst✝⁵ : Field F
inst✝⁴ : Field E
inst✝³ : Algebra F E
K : Type w
inst✝² : Field K
inst✝¹ : Algebra F K
inst✝ : IsSepClosed E
⊢ separableClosure F E = ⊥ ↔ IsSepClosed F
state_after: F : Type u
E : Type v
inst✝⁵ : Field F
inst✝⁴ : Field E
inst✝³ : Algebra F E
K : Type w
inst✝² : Field K
inst✝¹ : Algebra F K
inst✝ : IsSepClosed E
h : separableClosure F E = ⊥
p : F[X]
x✝ : p.Monic
hirr : Irreducible p
hsep : p.Separable
⊢ ∃ x, eval x p = 0
tactic: refine ⟨fun h ↦ IsSepClosed.of_exists_root _ fun p _ hirr hsep ↦ ?_,
    fun _ ↦ IntermediateField.eq_bot_of_isSepClosed_of_isSeparable _⟩
state_before: F : Type u
E : Type v
inst✝⁵ : Field F
inst✝⁴ : Field E
inst✝³ : Algebra F E
K : Type w
inst✝² : Field K
inst✝¹ : Algebra F K
inst✝ : IsSepClosed E
h : separableClosure F E = ⊥
p : F[X]
x✝ : p.Monic
hirr : Irreducible p
hsep : p.Separable
⊢ ∃ x, eval x p = 0
state_after: case intro
F : Type u
E : Type v
inst✝⁵ : Field F
inst✝⁴ : Field E
inst✝³ : Algebra F E
K : Type w
inst✝² : Field K
inst✝¹ : Algebra F K
inst✝ : IsSepClosed E
h : separableClosure F E = ⊥
p : F[X]
x✝ : p.Monic
hirr : Irreducible p
hsep : p.Separable
x : E
hx : (aeval x) p = 0
⊢ ∃ x, eval x p = 0
tactic: obtain ⟨x, hx⟩ := IsSepClosed.exists_aeval_eq_zero E p (degree_pos_of_irreducible hirr).ne' hsep
state_before: case intro
F : Type u
E : Type v
inst✝⁵ : Field F
inst✝⁴ : Field E
inst✝³ : Algebra F E
K : Type w
inst✝² : Field K
inst✝¹ : Algebra F K
inst✝ : IsSepClosed E
h : separableClosure F E = ⊥
p : F[X]
x✝ : p.Monic
hirr : Irreducible p
hsep : p.Separable
x : E
hx : (aeval x) p = 0
⊢ ∃ x, eval x p = 0
state_after: case intro.intro
F : Type u
E : Type v
inst✝⁵ : Field F
inst✝⁴ : Field E
inst✝³ : Algebra F E
K : Type w
inst✝² : Field K
inst✝¹ : Algebra F K
inst✝ : IsSepClosed E
h : separableClosure F E = ⊥
p : F[X]
x✝ : p.Monic
hirr : Irreducible p
hsep : p.Separable
x : F
hx : (aeval ((Algebra.ofId F E).toRingHom x)) p = 0
⊢ ∃ x, eval x p = 0
tactic: obtain ⟨x, rfl⟩ := h ▸ mem_separableClosure_iff.2 (hsep.of_dvd <| minpoly.dvd _ x hx)
state_before: case intro.intro
F : Type u
E : Type v
inst✝⁵ : Field F
inst✝⁴ : Field E
inst✝³ : Algebra F E
K : Type w
inst✝² : Field K
inst✝¹ : Algebra F K
inst✝ : IsSepClosed E
h : separableClosure F E = ⊥
p : F[X]
x✝ : p.Monic
hirr : Irreducible p
hsep : p.Separable
x : F
hx : (aeval ((Algebra.ofId F E).toRingHom x)) p = 0
⊢ ∃ x, eval x p = 0
state_after: no goals
tactic: exact ⟨x, by simpa [Algebra.ofId_apply] using hx⟩
Theorem: Mathlib.Vector.toList_take
File: Mathlib/Data/Vector/Defs.lean

Proof steps:
state_before: α : Type u
β : Type v
φ : Type w
n✝ n m : ℕ
v : Vector α m
⊢ (take n v).toList = List.take n v.toList
state_after: case mk
α : Type u
β : Type v
φ : Type w
n✝ n m : ℕ
val✝ : List α
property✝ : val✝.length = m
⊢ (take n ⟨val✝, property✝⟩).toList = List.take n (toList ⟨val✝, property✝⟩)
tactic: cases v
state_before: case mk
α : Type u
β : Type v
φ : Type w
n✝ n m : ℕ
val✝ : List α
property✝ : val✝.length = m
⊢ (take n ⟨val✝, property✝⟩).toList = List.take n (toList ⟨val✝, property✝⟩)
state_after: no goals
tactic: rfl
Theorem: Multiset.powersetCard_mono
File: Mathlib/Data/Multiset/Powerset.lean

Proof steps:
state_before: α : Type u_1
n : ℕ
s t : Multiset α
h✝ : s ≤ t
l₁ l₂ : List α
h : l₁ <+ l₂
⊢ powersetCard n ↑l₁ ≤ powersetCard n ↑l₂
state_after: α : Type u_1
n : ℕ
s t : Multiset α
h✝ : s ≤ t
l₁ l₂ : List α
h : l₁ <+ l₂
⊢ List.map ofList (sublistsLen n l₁) <+~ List.map ofList (sublistsLen n l₂)
tactic: simp only [powersetCard_coe, coe_le]
state_before: α : Type u_1
n : ℕ
s t : Multiset α
h✝ : s ≤ t
l₁ l₂ : List α
h : l₁ <+ l₂
⊢ List.map ofList (sublistsLen n l₁) <+~ List.map ofList (sublistsLen n l₂)
state_after: no goals
tactic: exact ((sublistsLen_sublist_of_sublist _ h).map _).subperm
Theorem: Stream'.Seq.ofList_cons
File: Mathlib/Data/Seq/Seq.lean

Proof steps:
state_before: α : Type u
β : Type v
γ : Type w
a : α
l : List α
⊢ ↑(a :: l) = cons a ↑l
state_after: no goals
tactic: ext1 (_ | n) <;> rfl
Theorem: ContinuousLinearEquiv.comp_right_hasFDerivWithinAt_iff'
File: Mathlib/Analysis/Calculus/FDeriv/Equiv.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
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
iso : E ≃L[𝕜] F
f : F → G
s : Set F
x : E
f' : E →L[𝕜] G
⊢ HasFDerivWithinAt (f ∘ ⇑iso) f' (⇑iso ⁻¹' s) x ↔ HasFDerivWithinAt f (f'.comp ↑iso.symm) s (iso x)
state_after: no goals
tactic: rw [← iso.comp_right_hasFDerivWithinAt_iff, ContinuousLinearMap.comp_assoc,
    iso.coe_symm_comp_coe, ContinuousLinearMap.comp_id]
Theorem: AddMonoidAlgebra.support_gen_of_gen'
File: Mathlib/RingTheory/FiniteType.lean

Proof steps:
state_before: R : Type u_1
M : Type u_2
inst✝¹ : CommSemiring R
inst✝ : AddMonoid M
S : Set R[M]
hS : adjoin R S = ⊤
⊢ adjoin R (of' R M '' ⋃ f ∈ S, ↑f.support) = ⊤
state_after: R : Type u_1
M : Type u_2
inst✝¹ : CommSemiring R
inst✝ : AddMonoid M
S : Set R[M]
hS : adjoin R S = ⊤
⊢ of' R M '' ⋃ f ∈ S, ↑f.support = ⋃ f ∈ S, of' R M '' ↑f.support
tactic: suffices (of' R M '' ⋃ f ∈ S, (f.support : Set M)) = ⋃ f ∈ S, of' R M '' (f.support : Set M) by
    rw [this]
    exact support_gen_of_gen hS
state_before: R : Type u_1
M : Type u_2
inst✝¹ : CommSemiring R
inst✝ : AddMonoid M
S : Set R[M]
hS : adjoin R S = ⊤
⊢ of' R M '' ⋃ f ∈ S, ↑f.support = ⋃ f ∈ S, of' R M '' ↑f.support
state_after: no goals
tactic: simp only [Set.image_iUnion]
Theorem: AddUnits.neg_unique
File: Mathlib/Algebra/Group/Units.lean

Proof steps:
state_before: α : Type u
inst✝ : Monoid α
a b c u u₁ u₂ : αˣ
h : ↑u₁ = ↑u₂
⊢ ↑u₁ * ↑u₂⁻¹ = 1
state_after: no goals
tactic: rw [h, u₂.mul_inv]
Theorem: Int.erdos_ginzburg_ziv_multiset
File: Mathlib/Combinatorics/Additive/ErdosGinzburgZiv.lean

Proof steps:
state_before: ι : Type u_1
n : ℕ
s✝ : Finset ι
s : Multiset ℤ
hs : 2 * n - 1 ≤ Multiset.card s
⊢ ∃ t ≤ s, Multiset.card t = n ∧ ↑n ∣ t.sum
state_after: case intro.intro
ι : Type u_1
n : ℕ
s✝ : Finset ι
s : Multiset ℤ
hs : 2 * n - 1 ≤ Multiset.card s
t : Finset (ℤ × ℕ)
hts : t ⊆ s.toEnumFinset
ht : t.card = n ∧ ↑n ∣ ∑ i ∈ t, i.1
⊢ ∃ t ≤ s, Multiset.card t = n ∧ ↑n ∣ t.sum
tactic: obtain ⟨t, hts, ht⟩ := Int.erdos_ginzburg_ziv (s := s.toEnumFinset) Prod.fst (by simpa using hs)
state_before: case intro.intro
ι : Type u_1
n : ℕ
s✝ : Finset ι
s : Multiset ℤ
hs : 2 * n - 1 ≤ Multiset.card s
t : Finset (ℤ × ℕ)
hts : t ⊆ s.toEnumFinset
ht : t.card = n ∧ ↑n ∣ ∑ i ∈ t, i.1
⊢ ∃ t ≤ s, Multiset.card t = n ∧ ↑n ∣ t.sum
state_after: no goals
tactic: exact ⟨t.1.map Prod.fst, Multiset.map_fst_le_of_subset_toEnumFinset hts, by simpa using ht⟩
Theorem: MvPolynomial.vars_mul
File: Mathlib/Algebra/MvPolynomial/Variables.lean

Proof steps:
state_before: R : Type u
S : Type v
σ : Type u_1
τ : Type u_2
r : R
e : ℕ
n m : σ
s : σ →₀ ℕ
inst✝¹ : CommSemiring R
p q : MvPolynomial σ R
inst✝ : DecidableEq σ
φ ψ : MvPolynomial σ R
⊢ (φ * ψ).vars ⊆ φ.vars ∪ ψ.vars
state_after: R : Type u
S : Type v
σ : Type u_1
τ : Type u_2
r : R
e : ℕ
n m : σ
s : σ →₀ ℕ
inst✝¹ : CommSemiring R
p q : MvPolynomial σ R
inst✝ : DecidableEq σ
φ ψ : MvPolynomial σ R
⊢ (φ * ψ).degrees ⊆ φ.degrees + ψ.degrees
tactic: simp_rw [vars_def, ← Multiset.toFinset_add, Multiset.toFinset_subset]
state_before: R : Type u
S : Type v
σ : Type u_1
τ : Type u_2
r : R
e : ℕ
n m : σ
s : σ →₀ ℕ
inst✝¹ : CommSemiring R
p q : MvPolynomial σ R
inst✝ : DecidableEq σ
φ ψ : MvPolynomial σ R
⊢ (φ * ψ).degrees ⊆ φ.degrees + ψ.degrees
state_after: no goals
tactic: exact Multiset.subset_of_le (degrees_mul φ ψ)
Theorem: Matrix.Fin.circulant_ite
File: Mathlib/LinearAlgebra/Matrix/Circulant.lean

Proof steps:
state_before: α✝ : Type u_1
β : Type u_2
m : Type u_3
n : Type u_4
R : Type u_5
α : Type u_6
inst✝¹ : Zero α
inst✝ : One α
⊢ (circulant fun i => if ↑i = 0 then 1 else 0) = 1
state_after: no goals
tactic: simp [Injective, eq_iff_true_of_subsingleton]
state_before: α✝ : Type u_1
β : Type u_2
m : Type u_3
n✝ : Type u_4
R : Type u_5
α : Type u_6
inst✝¹ : Zero α
inst✝ : One α
n : ℕ
⊢ (circulant fun i => if ↑i = 0 then 1 else 0) = 1
state_after: α✝ : Type u_1
β : Type u_2
m : Type u_3
n✝ : Type u_4
R : Type u_5
α : Type u_6
inst✝¹ : Zero α
inst✝ : One α
n : ℕ
⊢ (circulant fun i => if ↑i = 0 then 1 else 0) = circulant (Pi.single 0 1)
tactic: rw [← circulant_single_one]
state_before: α✝ : Type u_1
β : Type u_2
m : Type u_3
n✝ : Type u_4
R : Type u_5
α : Type u_6
inst✝¹ : Zero α
inst✝ : One α
n : ℕ
⊢ (circulant fun i => if ↑i = 0 then 1 else 0) = circulant (Pi.single 0 1)
state_after: case a
α✝ : Type u_1
β : Type u_2
m : Type u_3
n✝ : Type u_4
R : Type u_5
α : Type u_6
inst✝¹ : Zero α
inst✝ : One α
n : ℕ
j j✝ : Fin (n + 1)
⊢ circulant (fun i => if ↑i = 0 then 1 else 0) j j✝ = circulant (Pi.single 0 1) j j✝
tactic: congr with j
state_before: case a
α✝ : Type u_1
β : Type u_2
m : Type u_3
n✝ : Type u_4
R : Type u_5
α : Type u_6
inst✝¹ : Zero α
inst✝ : One α
n : ℕ
j j✝ : Fin (n + 1)
⊢ circulant (fun i => if ↑i = 0 then 1 else 0) j j✝ = circulant (Pi.single 0 1) j j✝
state_after: no goals
tactic: simp [Pi.single_apply, Fin.ext_iff]
Theorem: min_lt_of_mul_lt_sq
File: Mathlib/Algebra/Order/Monoid/Unbundled/Pow.lean

Proof steps:
state_before: β : Type u_1
G : Type u_2
M : Type u_3
inst✝³ : Monoid M
inst✝² : LinearOrder M
inst✝¹ : CovariantClass M M (fun x x_1 => x * x_1) fun x x_1 => x ≤ x_1
inst✝ : CovariantClass M M (swap fun x x_1 => x * x_1) fun x x_1 => x ≤ x_1
a b c : M
h : a * b < c ^ 2
⊢ min a b < c
state_after: no goals
tactic: simpa using min_lt_max_of_mul_lt_mul (h.trans_eq <| pow_two _)
Theorem: Sum.lex_inr_inr
File: .lake/packages/batteries/Batteries/Data/Sum/Basic.lean

Proof steps:
state_before: α✝ : Type u_1
r : α✝ → α✝ → Prop
β✝ : Type u_2
s : β✝ → β✝ → Prop
b₁ b₂ : β✝
h : Lex r s (inr b₁) (inr b₂)
⊢ s b₁ b₂
state_after: case inr
α✝ : Type u_1
r : α✝ → α✝ → Prop
β✝ : Type u_2
s : β✝ → β✝ → Prop
b₁ b₂ : β✝
h✝ : s b₁ b₂
⊢ s b₁ b₂
tactic: cases h
state_before: case inr
α✝ : Type u_1
r : α✝ → α✝ → Prop
β✝ : Type u_2
s : β✝ → β✝ → Prop
b₁ b₂ : β✝
h✝ : s b₁ b₂
⊢ s b₁ b₂
state_after: no goals
tactic: assumption
Theorem: Filter.exists_seq_forall_of_frequently
File: Mathlib/Order/Filter/AtTopBot.lean

Proof steps:
state_before: ι✝ : Type u_1
ι' : Type u_2
α : Type u_3
β : Type u_4
γ : Type u_5
ι : Type u_6
l : Filter ι
p : ι → Prop
inst✝ : l.IsCountablyGenerated
h : ∃ᶠ (n : ι) in l, p n
⊢ ∃ ns, Tendsto ns atTop l ∧ ∀ (n : ℕ), p (ns n)
state_after: ι✝ : Type u_1
ι' : Type u_2
α : Type u_3
β : Type u_4
γ : Type u_5
ι : Type u_6
l : Filter ι
p : ι → Prop
inst✝ : l.IsCountablyGenerated
h : ∃ x, Tendsto x atTop l ∧ ∃ᶠ (n : ℕ) in atTop, p (x n)
⊢ ∃ ns, Tendsto ns atTop l ∧ ∀ (n : ℕ), p (ns n)
tactic: rw [frequently_iff_seq_frequently] at h
state_before: ι✝ : Type u_1
ι' : Type u_2
α : Type u_3
β : Type u_4
γ : Type u_5
ι : Type u_6
l : Filter ι
p : ι → Prop
inst✝ : l.IsCountablyGenerated
h : ∃ x, Tendsto x atTop l ∧ ∃ᶠ (n : ℕ) in atTop, p (x n)
⊢ ∃ ns, Tendsto ns atTop l ∧ ∀ (n : ℕ), p (ns n)
state_after: case intro.intro
ι✝ : Type u_1
ι' : Type u_2
α : Type u_3
β : Type u_4
γ : Type u_5
ι : Type u_6
l : Filter ι
p : ι → Prop
inst✝ : l.IsCountablyGenerated
x : ℕ → ι
hx_tendsto : Tendsto x atTop l
hx_freq : ∃ᶠ (n : ℕ) in atTop, p (x n)
⊢ ∃ ns, Tendsto ns atTop l ∧ ∀ (n : ℕ), p (ns n)
tactic: obtain ⟨x, hx_tendsto, hx_freq⟩ := h
state_before: case intro.intro
ι✝ : Type u_1
ι' : Type u_2
α : Type u_3
β : Type u_4
γ : Type u_5
ι : Type u_6
l : Filter ι
p : ι → Prop
inst✝ : l.IsCountablyGenerated
x : ℕ → ι
hx_tendsto : Tendsto x atTop l
hx_freq : ∃ᶠ (n : ℕ) in atTop, p (x n)
⊢ ∃ ns, Tendsto ns atTop l ∧ ∀ (n : ℕ), p (ns n)
state_after: case intro.intro.intro.intro
ι✝ : Type u_1
ι' : Type u_2
α : Type u_3
β : Type u_4
γ : Type u_5
ι : Type u_6
l : Filter ι
p : ι → Prop
inst✝ : l.IsCountablyGenerated
x : ℕ → ι
hx_tendsto : Tendsto x atTop l
hx_freq : ∃ᶠ (n : ℕ) in atTop, p (x n)
n_to_n : ℕ → ℕ
h_tendsto : Tendsto (fun n => x (n_to_n n)) atTop l
h_freq : ∀ (n : ℕ), p (x (n_to_n n))
⊢ ∃ ns, Tendsto ns atTop l ∧ ∀ (n : ℕ), p (ns n)
tactic: obtain ⟨n_to_n, h_tendsto, h_freq⟩ := subseq_forall_of_frequently hx_tendsto hx_freq
state_before: case intro.intro.intro.intro
ι✝ : Type u_1
ι' : Type u_2
α : Type u_3
β : Type u_4
γ : Type u_5
ι : Type u_6
l : Filter ι
p : ι → Prop
inst✝ : l.IsCountablyGenerated
x : ℕ → ι
hx_tendsto : Tendsto x atTop l
hx_freq : ∃ᶠ (n : ℕ) in atTop, p (x n)
n_to_n : ℕ → ℕ
h_tendsto : Tendsto (fun n => x (n_to_n n)) atTop l
h_freq : ∀ (n : ℕ), p (x (n_to_n n))
⊢ ∃ ns, Tendsto ns atTop l ∧ ∀ (n : ℕ), p (ns n)
state_after: no goals
tactic: exact ⟨x ∘ n_to_n, h_tendsto, h_freq⟩
Theorem: SimpleGraph.Walk.connected_induce_support
File: Mathlib/Combinatorics/SimpleGraph/Connectivity/Subgraph.lean

Proof steps:
state_before: V : Type u
V' : Type v
G : SimpleGraph V
G' : SimpleGraph V'
u v : V
p : G.Walk u v
⊢ (induce {v_1 | v_1 ∈ p.support} G).Connected
state_after: V : Type u
V' : Type v
G : SimpleGraph V
G' : SimpleGraph V'
u v : V
p : G.Walk u v
⊢ (induce p.toSubgraph.verts G).Connected
tactic: rw [← p.verts_toSubgraph]
state_before: V : Type u
V' : Type v
G : SimpleGraph V
G' : SimpleGraph V'
u v : V
p : G.Walk u v
⊢ (induce p.toSubgraph.verts G).Connected
state_after: no goals
tactic: exact p.toSubgraph_connected.induce_verts
Theorem: IsLowerSet.cthickening
File: Mathlib/Analysis/Normed/Order/UpperLower.lean

Proof steps:
state_before: α : Type u_1
ι : Type u_2
inst✝ : NormedOrderedGroup α
s : Set α
hs : IsLowerSet s
ε : ℝ
⊢ IsLowerSet (cthickening ε s)
state_after: α : Type u_1
ι : Type u_2
inst✝ : NormedOrderedGroup α
s : Set α
hs : IsLowerSet s
ε : ℝ
⊢ IsLowerSet (⋂ ε_1, ⋂ (_ : max 0 ε < ε_1), thickening ε_1 s)
tactic: rw [cthickening_eq_iInter_thickening'']
state_before: α : Type u_1
ι : Type u_2
inst✝ : NormedOrderedGroup α
s : Set α
hs : IsLowerSet s
ε : ℝ
⊢ IsLowerSet (⋂ ε_1, ⋂ (_ : max 0 ε < ε_1), thickening ε_1 s)
state_after: no goals
tactic: exact isLowerSet_iInter₂ fun δ _ => hs.thickening' _