ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
Theorem: SetTheory.PGame.Numeric.isOption
File: Mathlib/SetTheory/Surreal/Basic.lean

Proof steps:
state_before: x' x : PGame
h : x'.IsOption x
hx : x.Numeric
⊢ x'.Numeric
state_after: case moveLeft
x : PGame
hx : x.Numeric
i✝ : x.LeftMoves
⊢ (x.moveLeft i✝).Numeric

case moveRight
x : PGame
hx : x.Numeric
i✝ : x.RightMoves
⊢ (x.moveRight i✝).Numeric
tactic: cases h
Theorem: Multiset.gcd_add
File: Mathlib/Algebra/GCDMonoid/Multiset.lean

Proof steps:
state_before: α : Type u_1
inst✝¹ : CancelCommMonoidWithZero α
inst✝ : NormalizedGCDMonoid α
s₁ s₂ : Multiset α
⊢ (s₁ + s₂).gcd = fold GCDMonoid.gcd (GCDMonoid.gcd 0 0) (s₁ + s₂)
state_after: no goals
tactic: simp [gcd]
Theorem: ProbabilityTheory.Kernel.iIndepFun_iff_measure_inter_preimage_eq_mul
File: Mathlib/Probability/Independence/Kernel.lean

Proof steps:
state_before: α : Type u_1
Ω : Type u_2
ι✝ : Type u_3
β✝ : Type u_4
β' : Type u_5
γ : Type u_6
γ' : Type u_7
_mα : MeasurableSpace α
_mΩ : MeasurableSpace Ω
κ : Kernel α Ω
μ : Measure α
f✝ : Ω → β✝
g : Ω → β'
ι : Type u_8
β : ι → Type u_9
m : (x : ι) → MeasurableSpace (β x)
f : (i : ι) → Ω → β i
⊢ iIndepFun m f κ μ ↔
    ∀ (S : Finset ι) {sets : (i : ι) → Set (β i)},
      (∀ i ∈ S, MeasurableSet (sets i)) →
        ∀ᵐ (a : α) ∂μ, (κ a) (⋂ i ∈ S, f i ⁻¹' sets i) = ∏ i ∈ S, (κ a) (f i ⁻¹' sets i)
state_after: α : Type u_1
Ω : Type u_2
ι✝ : Type u_3
β✝ : Type u_4
β' : Type u_5
γ : Type u_6
γ' : Type u_7
_mα : MeasurableSpace α
_mΩ : MeasurableSpace Ω
κ : Kernel α Ω
μ : Measure α
f✝ : Ω → β✝
g : Ω → β'
ι : Type u_8
β : ι → Type u_9
m : (x : ι) → MeasurableSpace (β x)
f : (i : ι) → Ω → β i
⊢ (∀ (S : Finset ι) {sets : (i : ι) → Set (β i)},
      (∀ i ∈ S, MeasurableSet (sets i)) →
        ∀ᵐ (a : α) ∂μ, (κ a) (⋂ i ∈ S, f i ⁻¹' sets i) = ∏ i ∈ S, (κ a) (f i ⁻¹' sets i)) →
    iIndepFun m f κ μ
tactic: refine ⟨fun h S sets h_meas => h _ fun i hi_mem => ⟨sets i, h_meas i hi_mem, rfl⟩, ?_⟩
state_before: α : Type u_1
Ω : Type u_2
ι✝ : Type u_3
β✝ : Type u_4
β' : Type u_5
γ : Type u_6
γ' : Type u_7
_mα : MeasurableSpace α
_mΩ : MeasurableSpace Ω
κ : Kernel α Ω
μ : Measure α
f✝ : Ω → β✝
g : Ω → β'
ι : Type u_8
β : ι → Type u_9
m : (x : ι) → MeasurableSpace (β x)
f : (i : ι) → Ω → β i
⊢ (∀ (S : Finset ι) {sets : (i : ι) → Set (β i)},
      (∀ i ∈ S, MeasurableSet (sets i)) →
        ∀ᵐ (a : α) ∂μ, (κ a) (⋂ i ∈ S, f i ⁻¹' sets i) = ∏ i ∈ S, (κ a) (f i ⁻¹' sets i)) →
    iIndepFun m f κ μ
state_after: α : Type u_1
Ω : Type u_2
ι✝ : Type u_3
β✝ : Type u_4
β' : Type u_5
γ : Type u_6
γ' : Type u_7
_mα : MeasurableSpace α
_mΩ : MeasurableSpace Ω
κ : Kernel α Ω
μ : Measure α
f✝ : Ω → β✝
g : Ω → β'
ι : Type u_8
β : ι → Type u_9
m : (x : ι) → MeasurableSpace (β x)
f : (i : ι) → Ω → β i
h :
  ∀ (S : Finset ι) {sets : (i : ι) → Set (β i)},
    (∀ i ∈ S, MeasurableSet (sets i)) → ∀ᵐ (a : α) ∂μ, (κ a) (⋂ i ∈ S, f i ⁻¹' sets i) = ∏ i ∈ S, (κ a) (f i ⁻¹' sets i)
S : Finset ι
setsΩ : ι → Set Ω
h_meas : ∀ i ∈ S, setsΩ i ∈ (fun x => {s | MeasurableSet s}) i
⊢ ∀ᵐ (a : α) ∂μ, (κ a) (⋂ i ∈ S, setsΩ i) = ∏ i ∈ S, (κ a) (setsΩ i)
tactic: intro h S setsΩ h_meas
Theorem: Polynomial.natCast_coeff_zero
File: Mathlib/Algebra/Polynomial/Coeff.lean

Proof steps:
state_before: R✝ : Type u
S : Type v
a b : R✝
n✝ m : ℕ
inst✝¹ : Semiring R✝
p q r : R✝[X]
n : ℕ
R : Type u_1
inst✝ : Semiring R
⊢ (↑n).coeff 0 = ↑n
state_after: no goals
tactic: simp only [coeff_natCast_ite, ite_true]
Theorem: Nat.totient_div_of_dvd
File: Mathlib/Data/Nat/Totient.lean

Proof steps:
state_before: n d : ℕ
hnd : d ∣ n
⊢ φ (n / d) = (filter (fun k => n.gcd k = d) (range n)).card
state_after: case inl
n : ℕ
hnd : 0 ∣ n
⊢ φ (n / 0) = (filter (fun k => n.gcd k = 0) (range n)).card

case inr
n d : ℕ
hnd : d ∣ n
hd0 : d > 0
⊢ φ (n / d) = (filter (fun k => n.gcd k = d) (range n)).card
tactic: rcases d.eq_zero_or_pos with (rfl | hd0)
state_before: case inr
n d : ℕ
hnd : d ∣ n
hd0 : d > 0
⊢ φ (n / d) = (filter (fun k => n.gcd k = d) (range n)).card
state_after: case inr.intro
d : ℕ
hd0 : d > 0
x : ℕ
⊢ φ (d * x / d) = (filter (fun k => (d * x).gcd k = d) (range (d * x))).card
tactic: rcases hnd with ⟨x, rfl⟩
state_before: case inr.intro
d : ℕ
hd0 : d > 0
x : ℕ
⊢ φ (d * x / d) = (filter (fun k => (d * x).gcd k = d) (range (d * x))).card
state_after: case inr.intro
d : ℕ
hd0 : d > 0
x : ℕ
⊢ φ x = (filter (fun k => (d * x).gcd k = d) (range (d * x))).card
tactic: rw [Nat.mul_div_cancel_left x hd0]
state_before: case inr.intro
d : ℕ
hd0 : d > 0
x : ℕ
⊢ φ x = (filter (fun k => (d * x).gcd k = d) (range (d * x))).card
state_after: case inr.intro.hi
d : ℕ
hd0 : d > 0
x : ℕ
⊢ ∀ a ∈ filter x.Coprime (range x), d * a ∈ filter (fun k => (d * x).gcd k = d) (range (d * x))

case inr.intro.i_inj
d : ℕ
hd0 : d > 0
x : ℕ
⊢ ∀ a₁ ∈ filter x.Coprime (range x), ∀ a₂ ∈ filter x.Coprime (range x), d * a₁ = d * a₂ → a₁ = a₂

case inr.intro.i_surj
d : ℕ
hd0 : d > 0
x : ℕ
⊢ ∀ b ∈ filter (fun k => (d * x).gcd k = d) (range (d * x)), ∃ a, ∃ (_ : a ∈ filter x.Coprime (range x)), d * a = b
tactic: apply Finset.card_bij fun k _ => d * k
Theorem: Seminorm.closedBall_finset_sup'
File: Mathlib/Analysis/Seminorm.lean

Proof steps:
state_before: R : Type u_1
R' : Type u_2
𝕜 : Type u_3
𝕜₂ : Type u_4
𝕜₃ : Type u_5
𝕝 : Type u_6
E : Type u_7
E₂ : Type u_8
E₃ : Type u_9
F : Type u_10
G : Type u_11
ι : Type u_12
inst✝² : SeminormedRing 𝕜
inst✝¹ : AddCommGroup E
inst✝ : SMul 𝕜 E
p✝ : Seminorm 𝕜 E
x y : E
r✝ : ℝ
p : ι → Seminorm 𝕜 E
s : Finset ι
H : s.Nonempty
e : E
r : ℝ
⊢ (s.sup' H p).closedBall e r = s.inf' H fun i => (p i).closedBall e r
state_after: no goals
tactic: induction H using Finset.Nonempty.cons_induction with
  | singleton => simp
  | cons _ _ _ hs ih =>
    rw [Finset.sup'_cons hs, Finset.inf'_cons hs, closedBall_sup]
    -- Porting note: `rw` can't use `inf_eq_inter` here, but `simp` can?
    simp only [inf_eq_inter, ih]
Theorem: SupIrred.ne_bot
File: Mathlib/Order/Irreducible.lean

Proof steps:
state_before: ι : Type u_1
α : Type u_2
inst✝¹ : SemilatticeSup α
a b c : α
inst✝ : OrderBot α
s : Finset ι
f : ι → α
ha : SupIrred a
⊢ a ≠ ⊥
state_after: ι : Type u_1
α : Type u_2
inst✝¹ : SemilatticeSup α
b c : α
inst✝ : OrderBot α
s : Finset ι
f : ι → α
ha : SupIrred ⊥
⊢ False
tactic: rintro rfl
state_before: ι : Type u_1
α : Type u_2
inst✝¹ : SemilatticeSup α
b c : α
inst✝ : OrderBot α
s : Finset ι
f : ι → α
ha : SupIrred ⊥
⊢ False
state_after: no goals
tactic: exact not_supIrred_bot ha
Theorem: SetTheory.PGame.Impartial.equiv_iff_add_equiv_zero
File: Mathlib/SetTheory/Game/Impartial.lean

Proof steps:
state_before: G : PGame
inst✝ : G.Impartial
H : PGame
⊢ H ≈ G ↔ H + G ≈ 0
state_after: G : PGame
inst✝ : G.Impartial
H : PGame
⊢ ⟦H + G⟧ = 0 ↔ ⟦H + G⟧ = ⟦0⟧
tactic: rw [Game.PGame.equiv_iff_game_eq, ← @add_right_cancel_iff _ _ _ ⟦G⟧, mk'_add_self, ← quot_add,
    Game.PGame.equiv_iff_game_eq]
state_before: G : PGame
inst✝ : G.Impartial
H : PGame
⊢ ⟦H + G⟧ = 0 ↔ ⟦H + G⟧ = ⟦0⟧
state_after: no goals
tactic: rfl
Theorem: Submodule.LinearDisjoint.linearIndependent_mul_of_flat
File: Mathlib/LinearAlgebra/LinearDisjoint.lean

Proof steps:
state_before: R : Type u
S : Type v
inst✝² : CommRing R
inst✝¹ : Ring S
inst✝ : Algebra R S
M N : Submodule R S
H : M.LinearDisjoint N
hf : Module.Flat R ↥M ∨ Module.Flat R ↥N
κ : Type u_1
ι : Type u_2
m : κ → ↥M
n : ι → ↥N
hm : LinearIndependent R m
hn : LinearIndependent R n
⊢ LinearIndependent R fun i => ↑(m i.1) * ↑(n i.2)
state_after: case inl
R : Type u
S : Type v
inst✝² : CommRing R
inst✝¹ : Ring S
inst✝ : Algebra R S
M N : Submodule R S
H : M.LinearDisjoint N
κ : Type u_1
ι : Type u_2
m : κ → ↥M
n : ι → ↥N
hm : LinearIndependent R m
hn : LinearIndependent R n
h✝ : Module.Flat R ↥M
⊢ LinearIndependent R fun i => ↑(m i.1) * ↑(n i.2)

case inr
R : Type u
S : Type v
inst✝² : CommRing R
inst✝¹ : Ring S
inst✝ : Algebra R S
M N : Submodule R S
H : M.LinearDisjoint N
κ : Type u_1
ι : Type u_2
m : κ → ↥M
n : ι → ↥N
hm : LinearIndependent R m
hn : LinearIndependent R n
h✝ : Module.Flat R ↥N
⊢ LinearIndependent R fun i => ↑(m i.1) * ↑(n i.2)
tactic: rcases hf with _ | _
Theorem: IsClosed.continuous_piecewise_of_specializes
File: Mathlib/Topology/Inseparable.lean

Proof steps:
state_before: X : Type u_1
Y : Type u_2
Z : Type u_3
α : Type u_4
ι : Type u_5
π : ι → Type u_6
inst✝⁴ : TopologicalSpace X
inst✝³ : TopologicalSpace Y
inst✝² : TopologicalSpace Z
inst✝¹ : (i : ι) → TopologicalSpace (π i)
x y z : X
s : Set X
f g : X → Y
inst✝ : DecidablePred fun x => x ∈ s
hs : IsClosed s
hf : Continuous f
hg : Continuous g
hspec : ∀ (x : X), g x ⤳ f x
⊢ Continuous (s.piecewise f g)
state_after: no goals
tactic: simpa only [piecewise_compl] using hs.isOpen_compl.continuous_piecewise_of_specializes hg hf hspec
Theorem: Trivialization.coordChange_coordChange
File: Mathlib/Topology/FiberBundle/Trivialization.lean

Proof steps:
state_before: ι : Type u_1
B : Type u_2
F : Type u_3
E : B → Type u_4
Z : Type u_5
inst✝³ : TopologicalSpace B
inst✝² : TopologicalSpace F
proj : Z → B
inst✝¹ : TopologicalSpace Z
inst✝ : TopologicalSpace (TotalSpace F E)
e : Trivialization F proj
x✝ : Z
e' : Trivialization F TotalSpace.proj
x' : TotalSpace F E
b✝ : B
y : E b✝
e₁ e₂ e₃ : Trivialization F proj
b : B
h₁ : b ∈ e₁.baseSet
h₂ : b ∈ e₂.baseSet
x : F
⊢ e₂.coordChange e₃ b (e₁.coordChange e₂ b x) = e₁.coordChange e₃ b x
state_after: ι : Type u_1
B : Type u_2
F : Type u_3
E : B → Type u_4
Z : Type u_5
inst✝³ : TopologicalSpace B
inst✝² : TopologicalSpace F
proj : Z → B
inst✝¹ : TopologicalSpace Z
inst✝ : TopologicalSpace (TotalSpace F E)
e : Trivialization F proj
x✝ : Z
e' : Trivialization F TotalSpace.proj
x' : TotalSpace F E
b✝ : B
y : E b✝
e₁ e₂ e₃ : Trivialization F proj
b : B
h₁ : b ∈ e₁.baseSet
h₂ : b ∈ e₂.baseSet
x : F
⊢ ↑e₁.symm (b, x) ∈ e₂.source
tactic: rw [coordChange, e₁.mk_coordChange _ h₁ h₂, ← e₂.coe_coe, e₂.left_inv, coordChange]
state_before: ι : Type u_1
B : Type u_2
F : Type u_3
E : B → Type u_4
Z : Type u_5
inst✝³ : TopologicalSpace B
inst✝² : TopologicalSpace F
proj : Z → B
inst✝¹ : TopologicalSpace Z
inst✝ : TopologicalSpace (TotalSpace F E)
e : Trivialization F proj
x✝ : Z
e' : Trivialization F TotalSpace.proj
x' : TotalSpace F E
b✝ : B
y : E b✝
e₁ e₂ e₃ : Trivialization F proj
b : B
h₁ : b ∈ e₁.baseSet
h₂ : b ∈ e₂.baseSet
x : F
⊢ ↑e₁.symm (b, x) ∈ e₂.source
state_after: no goals
tactic: rwa [e₂.mem_source, e₁.proj_symm_apply' h₁]
Theorem: op_smul_coe_set
File: Mathlib/Algebra/Group/Subgroup/Pointwise.lean

Proof steps:
state_before: α : Type u_1
G : Type u_2
A : Type u_3
S : Type u_4
inst✝² : Group G
inst✝¹ : SetLike S G
inst✝ : SubgroupClass S G
s : S
a : G
ha : a ∈ s
⊢ MulOpposite.op a • ↑s = ↑s
state_after: case h
α : Type u_1
G : Type u_2
A : Type u_3
S : Type u_4
inst✝² : Group G
inst✝¹ : SetLike S G
inst✝ : SubgroupClass S G
s : S
a : G
ha : a ∈ s
x✝ : G
⊢ x✝ ∈ MulOpposite.op a • ↑s ↔ x✝ ∈ ↑s
tactic: ext
state_before: case h
α : Type u_1
G : Type u_2
A : Type u_3
S : Type u_4
inst✝² : Group G
inst✝¹ : SetLike S G
inst✝ : SubgroupClass S G
s : S
a : G
ha : a ∈ s
x✝ : G
⊢ x✝ ∈ MulOpposite.op a • ↑s ↔ x✝ ∈ ↑s
state_after: no goals
tactic: simp [Set.mem_smul_set_iff_inv_smul_mem, mul_mem_cancel_right, ha]
Theorem: CategoryTheory.congrArg_mpr_hom_right
File: Mathlib/CategoryTheory/EqToHom.lean

Proof steps:
state_before: C : Type u₁
inst✝ : Category.{v₁, u₁} C
β : Sort u_1
X Y Z : C
p : X ⟶ Y
q : Z = Y
⊢ ⋯.mpr p = p ≫ eqToHom ⋯
state_after: case refl
C : Type u₁
inst✝ : Category.{v₁, u₁} C
β : Sort u_1
X Y : C
p : X ⟶ Y
⊢ ⋯.mpr p = p ≫ eqToHom ⋯
tactic: cases q
state_before: case refl
C : Type u₁
inst✝ : Category.{v₁, u₁} C
β : Sort u_1
X Y : C
p : X ⟶ Y
⊢ ⋯.mpr p = p ≫ eqToHom ⋯
state_after: no goals
tactic: simp
Theorem: CategoryTheory.oppositeShiftFunctorAdd_hom_app
File: Mathlib/CategoryTheory/Shift/Opposite.lean

Proof steps:
state_before: C : Type u_1
inst✝² : Category.{u_3, u_1} C
A : Type u_2
inst✝¹ : AddMonoid A
inst✝ : HasShift C A
X : OppositeShift C A
a b c : A
h : a + b = c
⊢ (shiftFunctorAdd (OppositeShift C A) a b).hom.app X = ((shiftFunctorAdd C a b).inv.app (Opposite.unop X)).op
state_after: C : Type u_1
inst✝² : Category.{u_3, u_1} C
A : Type u_2
inst✝¹ : AddMonoid A
inst✝ : HasShift C A
X : OppositeShift C A
a b c : A
h : a + b = c
⊢ 𝟙 ((shiftFunctor (OppositeShift C A) (a + b)).obj X) =
    𝟙 (Opposite.op ((shiftFunctor C (a + b)).obj (Opposite.unop X)))
tactic: rw [← cancel_mono ((shiftFunctorAdd (OppositeShift C A) a b).inv.app X),
    Iso.hom_inv_id_app, oppositeShiftFunctorAdd_inv_app, ← op_comp,
    Iso.hom_inv_id_app, op_id]
state_before: C : Type u_1
inst✝² : Category.{u_3, u_1} C
A : Type u_2
inst✝¹ : AddMonoid A
inst✝ : HasShift C A
X : OppositeShift C A
a b c : A
h : a + b = c
⊢ 𝟙 ((shiftFunctor (OppositeShift C A) (a + b)).obj X) =
    𝟙 (Opposite.op ((shiftFunctor C (a + b)).obj (Opposite.unop X)))
state_after: no goals
tactic: rfl
Theorem: Metric.closure_eq_iInter_cthickening'
File: Mathlib/Topology/MetricSpace/Thickening.lean

Proof steps:
state_before: ι : Sort u_1
α : Type u
β : Type v
inst✝ : PseudoEMetricSpace α
δ ε : ℝ
s✝ t : Set α
x : α
E : Set α
s : Set ℝ
hs : ∀ (ε : ℝ), 0 < ε → (s ∩ Ioc 0 ε).Nonempty
⊢ closure E = ⋂ δ ∈ s, cthickening δ E
state_after: case pos
ι : Sort u_1
α : Type u
β : Type v
inst✝ : PseudoEMetricSpace α
δ ε : ℝ
s✝ t : Set α
x : α
E : Set α
s : Set ℝ
hs : ∀ (ε : ℝ), 0 < ε → (s ∩ Ioc 0 ε).Nonempty
hs₀ : s ⊆ Ioi 0
⊢ closure E = ⋂ δ ∈ s, cthickening δ E

case neg
ι : Sort u_1
α : Type u
β : Type v
inst✝ : PseudoEMetricSpace α
δ ε : ℝ
s✝ t : Set α
x : α
E : Set α
s : Set ℝ
hs : ∀ (ε : ℝ), 0 < ε → (s ∩ Ioc 0 ε).Nonempty
hs₀ : ¬s ⊆ Ioi 0
⊢ closure E = ⋂ δ ∈ s, cthickening δ E
tactic: by_cases hs₀ : s ⊆ Ioi 0
state_before: case neg
ι : Sort u_1
α : Type u
β : Type v
inst✝ : PseudoEMetricSpace α
δ ε : ℝ
s✝ t : Set α
x : α
E : Set α
s : Set ℝ
hs : ∀ (ε : ℝ), 0 < ε → (s ∩ Ioc 0 ε).Nonempty
hs₀ : ¬s ⊆ Ioi 0
⊢ closure E = ⋂ δ ∈ s, cthickening δ E
state_after: case neg.intro.intro
ι : Sort u_1
α : Type u
β : Type v
inst✝ : PseudoEMetricSpace α
δ✝ ε : ℝ
s✝ t : Set α
x : α
E : Set α
s : Set ℝ
hs : ∀ (ε : ℝ), 0 < ε → (s ∩ Ioc 0 ε).Nonempty
hs₀ : ¬s ⊆ Ioi 0
δ : ℝ
hδs : δ ∈ s
δ_nonpos : δ ∉ Ioi 0
⊢ closure E = ⋂ δ ∈ s, cthickening δ E
tactic: obtain ⟨δ, hδs, δ_nonpos⟩ := not_subset.mp hs₀
state_before: case neg.intro.intro
ι : Sort u_1
α : Type u
β : Type v
inst✝ : PseudoEMetricSpace α
δ✝ ε : ℝ
s✝ t : Set α
x : α
E : Set α
s : Set ℝ
hs : ∀ (ε : ℝ), 0 < ε → (s ∩ Ioc 0 ε).Nonempty
hs₀ : ¬s ⊆ Ioi 0
δ : ℝ
hδs : δ ∈ s
δ_nonpos : δ ∉ Ioi 0
⊢ closure E = ⋂ δ ∈ s, cthickening δ E
state_after: case neg.intro.intro
ι : Sort u_1
α : Type u
β : Type v
inst✝ : PseudoEMetricSpace α
δ✝ ε : ℝ
s✝ t : Set α
x : α
E : Set α
s : Set ℝ
hs : ∀ (ε : ℝ), 0 < ε → (s ∩ Ioc 0 ε).Nonempty
hs₀ : ¬s ⊆ Ioi 0
δ : ℝ
hδs : δ ∈ s
δ_nonpos : δ ≤ 0
⊢ closure E = ⋂ δ ∈ s, cthickening δ E
tactic: rw [Set.mem_Ioi, not_lt] at δ_nonpos
state_before: case neg.intro.intro
ι : Sort u_1
α : Type u
β : Type v
inst✝ : PseudoEMetricSpace α
δ✝ ε : ℝ
s✝ t : Set α
x : α
E : Set α
s : Set ℝ
hs : ∀ (ε : ℝ), 0 < ε → (s ∩ Ioc 0 ε).Nonempty
hs₀ : ¬s ⊆ Ioi 0
δ : ℝ
hδs : δ ∈ s
δ_nonpos : δ ≤ 0
⊢ closure E = ⋂ δ ∈ s, cthickening δ E
state_after: case neg.intro.intro.h₁
ι : Sort u_1
α : Type u
β : Type v
inst✝ : PseudoEMetricSpace α
δ✝ ε : ℝ
s✝ t : Set α
x : α
E : Set α
s : Set ℝ
hs : ∀ (ε : ℝ), 0 < ε → (s ∩ Ioc 0 ε).Nonempty
hs₀ : ¬s ⊆ Ioi 0
δ : ℝ
hδs : δ ∈ s
δ_nonpos : δ ≤ 0
⊢ closure E ⊆ ⋂ δ ∈ s, cthickening δ E

case neg.intro.intro.h₂
ι : Sort u_1
α : Type u
β : Type v
inst✝ : PseudoEMetricSpace α
δ✝ ε : ℝ
s✝ t : Set α
x : α
E : Set α
s : Set ℝ
hs : ∀ (ε : ℝ), 0 < ε → (s ∩ Ioc 0 ε).Nonempty
hs₀ : ¬s ⊆ Ioi 0
δ : ℝ
hδs : δ ∈ s
δ_nonpos : δ ≤ 0
⊢ ⋂ δ ∈ s, cthickening δ E ⊆ closure E
tactic: apply Subset.antisymm
Theorem: antivary_iff_smul_rearrangement
File: Mathlib/Algebra/Order/Monovary.lean

Proof steps:
state_before: ι : Type u_1
α : Type u_2
β : Type u_3
inst✝³ : LinearOrderedRing α
inst✝² : LinearOrderedAddCommGroup β
inst✝¹ : Module α β
inst✝ : OrderedSMul α β
f : ι → α
g : ι → β
s : Set ι
a a₁ a₂ : α
b b₁ b₂ : β
⊢ Monovary f (⇑OrderDual.toDual ∘ g) ↔ ∀ (i j : ι), f i • g i + f j • g j ≤ f i • g j + f j • g i
state_after: ι : Type u_1
α : Type u_2
β : Type u_3
inst✝³ : LinearOrderedRing α
inst✝² : LinearOrderedAddCommGroup β
inst✝¹ : Module α β
inst✝ : OrderedSMul α β
f : ι → α
g : ι → β
s : Set ι
a a₁ a₂ : α
b b₁ b₂ : β
⊢ (∀ (i j : ι),
      f i • (⇑OrderDual.toDual ∘ g) j + f j • (⇑OrderDual.toDual ∘ g) i ≤
        f i • (⇑OrderDual.toDual ∘ g) i + f j • (⇑OrderDual.toDual ∘ g) j) ↔
    ∀ (i j : ι), f i • g i + f j • g j ≤ f i • g j + f j • g i
tactic: rw [monovary_iff_smul_rearrangement]
state_before: ι : Type u_1
α : Type u_2
β : Type u_3
inst✝³ : LinearOrderedRing α
inst✝² : LinearOrderedAddCommGroup β
inst✝¹ : Module α β
inst✝ : OrderedSMul α β
f : ι → α
g : ι → β
s : Set ι
a a₁ a₂ : α
b b₁ b₂ : β
⊢ (∀ (i j : ι),
      f i • (⇑OrderDual.toDual ∘ g) j + f j • (⇑OrderDual.toDual ∘ g) i ≤
        f i • (⇑OrderDual.toDual ∘ g) i + f j • (⇑OrderDual.toDual ∘ g) j) ↔
    ∀ (i j : ι), f i • g i + f j • g j ≤ f i • g j + f j • g i
state_after: no goals
tactic: rfl
Theorem: Mathlib.Meta.NormNum.ble_eq_false
File: Mathlib/Tactic/NormNum/Basic.lean

Proof steps:
state_before: α : Type u
x y : ℕ
⊢ x.ble y = false ↔ y < x
state_after: no goals
tactic: rw [← Nat.not_le, ← Bool.not_eq_true, Nat.ble_eq]
Theorem: Nat.nth_zero_of_exists
File: Mathlib/Data/Nat/Nth.lean

Proof steps:
state_before: p : ℕ → Prop
inst✝ : DecidablePred p
h : ∃ n, p n
⊢ nth p 0 = Nat.find h
state_after: p : ℕ → Prop
inst✝ : DecidablePred p
h : ∃ n, p n
⊢ sInf (setOf p) = Nat.find h
tactic: rw [nth_zero]
state_before: p : ℕ → Prop
inst✝ : DecidablePred p
h : ∃ n, p n
⊢ sInf (setOf p) = Nat.find h
state_after: no goals
tactic: convert Nat.sInf_def h
Theorem: le_rank_iff_exists_linearIndependent_finset
File: Mathlib/LinearAlgebra/Dimension/FreeAndStrongRankCondition.lean

Proof steps:
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
n : ℕ
⊢ ↑n ≤ Module.rank K V ↔ ∃ s, s.card = n ∧ LinearIndependent (ι := { x // x ∈ ↑s }) K Subtype.val
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
n : ℕ
⊢ (∃ s, (∃ t, ↑t = s ∧ t.card = n) ∧ LinearIndependent (ι := { x // x ∈ s }) K Subtype.val) ↔
    ∃ s, s.card = n ∧ LinearIndependent (ι := { x // x ∈ ↑s }) K Subtype.val
tactic: simp only [le_rank_iff_exists_linearIndependent, mk_set_eq_nat_iff_finset]
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
n : ℕ
⊢ (∃ s, (∃ t, ↑t = s ∧ t.card = n) ∧ LinearIndependent (ι := { x // x ∈ s }) K Subtype.val) ↔
    ∃ s, s.card = n ∧ LinearIndependent (ι := { x // x ∈ ↑s }) K Subtype.val
state_after: case mp
K : Type u
V : Type v
inst✝⁴ : Ring K
inst✝³ : StrongRankCondition K
inst✝² : AddCommGroup V
inst✝¹ : Module K V
inst✝ : Module.Free K V
n : ℕ
⊢ (∃ s, (∃ t, ↑t = s ∧ t.card = n) ∧ LinearIndependent (ι := { x // x ∈ s }) K Subtype.val) →
    ∃ s, s.card = n ∧ LinearIndependent (ι := { x // x ∈ ↑s }) K Subtype.val

case mpr
K : Type u
V : Type v
inst✝⁴ : Ring K
inst✝³ : StrongRankCondition K
inst✝² : AddCommGroup V
inst✝¹ : Module K V
inst✝ : Module.Free K V
n : ℕ
⊢ (∃ s, s.card = n ∧ LinearIndependent (ι := { x // x ∈ ↑s }) K Subtype.val) →
    ∃ s, (∃ t, ↑t = s ∧ t.card = n) ∧ LinearIndependent (ι := { x // x ∈ s }) K Subtype.val
tactic: constructor
Theorem: Turing.PartrecToTM2.codeSupp_fix
File: Mathlib/Computability/TMToPartrec.lean

Proof steps:
state_before: f : Code
k : Cont'
⊢ codeSupp f.fix k = trStmts₁ (trNormal f.fix k) ∪ codeSupp f (Cont'.fix f k)
state_after: no goals
tactic: simp [codeSupp, codeSupp', contSupp, Finset.union_assoc, Finset.union_left_comm,
    Finset.union_left_idem]
Theorem: Dense.Ioi_eq_biUnion
File: Mathlib/Topology/Order/OrderClosed.lean

Proof steps:
state_before: α : Type u
β : Type v
γ : Type w
inst✝³ : TopologicalSpace α
inst✝² : LinearOrder α
inst✝¹ : OrderClosedTopology α
f g : β → α
inst✝ : DenselyOrdered α
s : Set α
hs : Dense s
x : α
⊢ Ioi x = ⋃ y ∈ s ∩ Ioi x, Ioi y
state_after: α : Type u
β : Type v
γ : Type w
inst✝³ : TopologicalSpace α
inst✝² : LinearOrder α
inst✝¹ : OrderClosedTopology α
f g : β → α
inst✝ : DenselyOrdered α
s : Set α
hs : Dense s
x z : α
hz : z ∈ Ioi x
⊢ z ∈ ⋃ y ∈ s ∩ Ioi x, Ioi y
tactic: refine Subset.antisymm (fun z hz ↦ ?_) (iUnion₂_subset fun y hy ↦ Ioi_subset_Ioi (le_of_lt hy.2))
state_before: α : Type u
β : Type v
γ : Type w
inst✝³ : TopologicalSpace α
inst✝² : LinearOrder α
inst✝¹ : OrderClosedTopology α
f g : β → α
inst✝ : DenselyOrdered α
s : Set α
hs : Dense s
x z : α
hz : z ∈ Ioi x
⊢ z ∈ ⋃ y ∈ s ∩ Ioi x, Ioi y
state_after: case intro.intro.intro
α : Type u
β : Type v
γ : Type w
inst✝³ : TopologicalSpace α
inst✝² : LinearOrder α
inst✝¹ : OrderClosedTopology α
f g : β → α
inst✝ : DenselyOrdered α
s : Set α
hs : Dense s
x z : α
hz : z ∈ Ioi x
y : α
hys : y ∈ s
hxy : x < y
hyz : y < z
⊢ z ∈ ⋃ y ∈ s ∩ Ioi x, Ioi y
tactic: rcases hs.exists_between hz with ⟨y, hys, hxy, hyz⟩
state_before: case intro.intro.intro
α : Type u
β : Type v
γ : Type w
inst✝³ : TopologicalSpace α
inst✝² : LinearOrder α
inst✝¹ : OrderClosedTopology α
f g : β → α
inst✝ : DenselyOrdered α
s : Set α
hs : Dense s
x z : α
hz : z ∈ Ioi x
y : α
hys : y ∈ s
hxy : x < y
hyz : y < z
⊢ z ∈ ⋃ y ∈ s ∩ Ioi x, Ioi y
state_after: no goals
tactic: exact mem_iUnion₂.2 ⟨y, ⟨hys, hxy⟩, hyz⟩
Theorem: Monoid.PushoutI.NormalWord.prod_smul_empty
File: Mathlib/GroupTheory/PushoutI.lean

Proof steps:
state_before: ι : Type u_1
G : ι → Type u_2
H : Type u_3
K : Type u_4
inst✝⁴ : Monoid K
inst✝³ : (i : ι) → Group (G i)
inst✝² : Group H
φ : (i : ι) → H →* G i
d : Transversal φ
inst✝¹ : DecidableEq ι
inst✝ : (i : ι) → DecidableEq (G i)
w : NormalWord d
⊢ w.prod • empty = w
state_after: no goals
tactic: induction w using consRecOn with
  | h_empty => simp
  | h_cons i g w _ _ _ _ ih =>
    rw [prod_cons, mul_smul, ih, cons_eq_smul]
  | h_base h w _ ih =>
    rw [prod_smul, mul_smul, ih]
Theorem: List.findIdxs_cons
File: .lake/packages/batteries/Batteries/Data/List/Lemmas.lean

Proof steps:
state_before: α : Type u_1
x : α
xs : List α
p : α → Bool
⊢ findIdxs p (x :: xs) =
    bif p x then 0 :: map (fun x => x + 1) (findIdxs p xs) else map (fun x => x + 1) (findIdxs p xs)
state_after: α : Type u_1
x : α
xs : List α
p : α → Bool
⊢ (if p x = true then 0 :: foldrIdx (fun i a is => if p a = true then i :: is else is) [] xs 1
    else foldrIdx (fun i a is => if p a = true then i :: is else is) [] xs 1) =
    bif p x then 0 :: map (fun x => x + 1) (foldrIdx (fun i a is => if p a = true then i :: is else is) [] xs)
    else map (fun x => x + 1) (foldrIdx (fun i a is => if p a = true then i :: is else is) [] xs)
tactic: dsimp [findIdxs]
state_before: α : Type u_1
x : α
xs : List α
p : α → Bool
⊢ (if p x = true then 0 :: foldrIdx (fun i a is => if p a = true then i :: is else is) [] xs 1
    else foldrIdx (fun i a is => if p a = true then i :: is else is) [] xs 1) =
    bif p x then 0 :: map (fun x => x + 1) (foldrIdx (fun i a is => if p a = true then i :: is else is) [] xs)
    else map (fun x => x + 1) (foldrIdx (fun i a is => if p a = true then i :: is else is) [] xs)
state_after: α : Type u_1
x : α
xs : List α
p : α → Bool
⊢ (if p x = true then 0 :: foldrIdx (fun i a is => if p a = true then i :: is else is) [] xs 1
    else foldrIdx (fun i a is => if p a = true then i :: is else is) [] xs 1) =
    if p x = true then 0 :: map (fun x => x + 1) (foldrIdx (fun i a is => if p a = true then i :: is else is) [] xs)
    else map (fun x => x + 1) (foldrIdx (fun i a is => if p a = true then i :: is else is) [] xs)
tactic: rw [cond_eq_if]