ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
Theorem: Nat.lt_size_self
File: Mathlib/Data/Nat/Size.lean

Proof steps:
state_before: n : ℕ
⊢ n < 2 ^ n.size
state_after: n : ℕ
⊢ n < 1 <<< n.size
tactic: rw [← one_shiftLeft]
state_before: n : ℕ
⊢ n < 1 <<< n.size
state_after: n : ℕ
this : ∀ {n : ℕ}, n = 0 → n < 1 <<< n.size
⊢ n < 1 <<< n.size
tactic: have : ∀ {n}, n = 0 → n < 1 <<< (size n) := by simp
state_before: n : ℕ
this : ∀ {n : ℕ}, n = 0 → n < 1 <<< n.size
⊢ n < 1 <<< n.size
state_after: n : ℕ
this : ∀ {n : ℕ}, n = 0 → n < 1 <<< n.size
⊢ 0 < 1 <<< size 0

n : ℕ
this : ∀ {n : ℕ}, n = 0 → n < 1 <<< n.size
⊢ ∀ (b : Bool) (n : ℕ), n < 1 <<< n.size → bit b n < 1 <<< (bit b n).size
tactic: apply binaryRec _ _ n
state_before: n : ℕ
this : ∀ {n : ℕ}, n = 0 → n < 1 <<< n.size
⊢ ∀ (b : Bool) (n : ℕ), n < 1 <<< n.size → bit b n < 1 <<< (bit b n).size
state_after: n✝ : ℕ
this : ∀ {n : ℕ}, n = 0 → n < 1 <<< n.size
b : Bool
n : ℕ
IH : n < 1 <<< n.size
⊢ bit b n < 1 <<< (bit b n).size
tactic: intro b n IH
state_before: n✝ : ℕ
this : ∀ {n : ℕ}, n = 0 → n < 1 <<< n.size
b : Bool
n : ℕ
IH : n < 1 <<< n.size
⊢ bit b n < 1 <<< (bit b n).size
state_after: case pos
n✝ : ℕ
this : ∀ {n : ℕ}, n = 0 → n < 1 <<< n.size
b : Bool
n : ℕ
IH : n < 1 <<< n.size
h : bit b n = 0
⊢ bit b n < 1 <<< (bit b n).size

case neg
n✝ : ℕ
this : ∀ {n : ℕ}, n = 0 → n < 1 <<< n.size
b : Bool
n : ℕ
IH : n < 1 <<< n.size
h : ¬bit b n = 0
⊢ bit b n < 1 <<< (bit b n).size
tactic: by_cases h : bit b n = 0
state_before: case neg
n✝ : ℕ
this : ∀ {n : ℕ}, n = 0 → n < 1 <<< n.size
b : Bool
n : ℕ
IH : n < 1 <<< n.size
h : ¬bit b n = 0
⊢ bit b n < 1 <<< (bit b n).size
state_after: case neg
n✝ : ℕ
this : ∀ {n : ℕ}, n = 0 → n < 1 <<< n.size
b : Bool
n : ℕ
IH : n < 1 <<< n.size
h : ¬bit b n = 0
⊢ bit b n < 2 * 2 ^ n.size
tactic: rw [size_bit h, shiftLeft_succ, shiftLeft_eq, one_mul]
state_before: case neg
n✝ : ℕ
this : ∀ {n : ℕ}, n = 0 → n < 1 <<< n.size
b : Bool
n : ℕ
IH : n < 1 <<< n.size
h : ¬bit b n = 0
⊢ bit b n < 2 * 2 ^ n.size
state_after: no goals
tactic: cases b <;> dsimp [bit] <;> omega
Theorem: Set.image_iInter
File: Mathlib/Data/Set/Lattice.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
ι : Sort u_4
ι' : Sort u_5
ι₂ : Sort u_6
κ : ι → Sort u_7
κ₁ : ι → Sort u_8
κ₂ : ι → Sort u_9
κ' : ι' → Sort u_10
f : α → β
hf : Bijective f
s : ι → Set α
⊢ f '' ⋂ i, s i = ⋂ i, f '' s i
state_after: case inl
α : Type u_1
β : Type u_2
γ : Type u_3
ι : Sort u_4
ι' : Sort u_5
ι₂ : Sort u_6
κ : ι → Sort u_7
κ₁ : ι → Sort u_8
κ₂ : ι → Sort u_9
κ' : ι' → Sort u_10
f : α → β
hf : Bijective f
s : ι → Set α
h✝ : IsEmpty ι
⊢ f '' ⋂ i, s i = ⋂ i, f '' s i

case inr
α : Type u_1
β : Type u_2
γ : Type u_3
ι : Sort u_4
ι' : Sort u_5
ι₂ : Sort u_6
κ : ι → Sort u_7
κ₁ : ι → Sort u_8
κ₂ : ι → Sort u_9
κ' : ι' → Sort u_10
f : α → β
hf : Bijective f
s : ι → Set α
h✝ : Nonempty ι
⊢ f '' ⋂ i, s i = ⋂ i, f '' s i
tactic: cases isEmpty_or_nonempty ι
Theorem: QuotientAddGroup.rangeKerLift_injective
File: Mathlib/GroupTheory/QuotientGroup.lean

Proof steps:
state_before: G : Type u
inst✝² : Group G
N : Subgroup G
nN : N.Normal
H : Type v
inst✝¹ : Group H
M : Type x
inst✝ : Monoid M
φ : G →* H
a✝ b✝ : G ⧸ φ.ker
a b : G
h : φ.rangeRestrict a = φ.rangeRestrict b
⊢ Setoid.r a b
state_after: no goals
tactic: rw [leftRel_apply, ← ker_rangeRestrict, mem_ker, φ.rangeRestrict.map_mul, ← h,
        φ.rangeRestrict.map_inv, inv_mul_self]
Theorem: mul_pow_sub_one
File: Mathlib/Algebra/Group/Basic.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
G : Type u_3
M : Type u_4
inst✝ : Monoid M
a✝ b c : M
m n : ℕ
hn : n ≠ 0
a : M
⊢ a * a ^ (n - 1) = a ^ n
state_after: no goals
tactic: rw [← pow_succ', Nat.sub_add_cancel $ Nat.one_le_iff_ne_zero.2 hn]
Theorem: LinearMap.baseChange_add
File: Mathlib/RingTheory/TensorProduct/Basic.lean

Proof steps:
state_before: R : Type u_1
A : Type u_2
B : Type u_3
M : Type u_4
N : Type u_5
P : Type u_6
inst✝¹⁰ : CommSemiring R
inst✝⁹ : Semiring A
inst✝⁸ : Algebra R A
inst✝⁷ : Semiring B
inst✝⁶ : Algebra R B
inst✝⁵ : AddCommMonoid M
inst✝⁴ : AddCommMonoid N
inst✝³ : AddCommMonoid P
inst✝² : Module R M
inst✝¹ : Module R N
inst✝ : Module R P
r : R
f g : M →ₗ[R] N
⊢ baseChange A (f + g) = baseChange A f + baseChange A g
state_after: case a.h.h
R : Type u_1
A : Type u_2
B : Type u_3
M : Type u_4
N : Type u_5
P : Type u_6
inst✝¹⁰ : CommSemiring R
inst✝⁹ : Semiring A
inst✝⁸ : Algebra R A
inst✝⁷ : Semiring B
inst✝⁶ : Algebra R B
inst✝⁵ : AddCommMonoid M
inst✝⁴ : AddCommMonoid N
inst✝³ : AddCommMonoid P
inst✝² : Module R M
inst✝¹ : Module R N
inst✝ : Module R P
r : R
f g : M →ₗ[R] N
x✝ : M
⊢ ((AlgebraTensorModule.curry (baseChange A (f + g))) 1) x✝ =
    ((AlgebraTensorModule.curry (baseChange A f + baseChange A g)) 1) x✝
tactic: ext
state_before: case a.h.h
R : Type u_1
A : Type u_2
B : Type u_3
M : Type u_4
N : Type u_5
P : Type u_6
inst✝¹⁰ : CommSemiring R
inst✝⁹ : Semiring A
inst✝⁸ : Algebra R A
inst✝⁷ : Semiring B
inst✝⁶ : Algebra R B
inst✝⁵ : AddCommMonoid M
inst✝⁴ : AddCommMonoid N
inst✝³ : AddCommMonoid P
inst✝² : Module R M
inst✝¹ : Module R N
inst✝ : Module R P
r : R
f g : M →ₗ[R] N
x✝ : M
⊢ ((AlgebraTensorModule.curry (baseChange A (f + g))) 1) x✝ =
    ((AlgebraTensorModule.curry (baseChange A f + baseChange A g)) 1) x✝
state_after: no goals
tactic: simp [baseChange_eq_ltensor, -baseChange_tmul]
Theorem: Function.bijOn_ptsOfPeriod
File: Mathlib/Dynamics/PeriodicPts.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
f✝ fa : α → α
fb : β → β
x✝ y : α
m n✝ : ℕ
f : α → α
n : ℕ
hn : 0 < n
x : α
hx : x ∈ ptsOfPeriod f n
⊢ f (f^[n.pred] x) = x
state_after: no goals
tactic: rw [← comp_apply (f := f), comp_iterate_pred_of_pos f hn, hx.eq]
Theorem: mem_vectorSpan_pair
File: Mathlib/LinearAlgebra/AffineSpace/AffineSubspace.lean

Proof steps:
state_before: k : Type u_1
V : Type u_2
P : Type u_3
inst✝³ : Ring k
inst✝² : AddCommGroup V
inst✝¹ : Module k V
inst✝ : AffineSpace V P
ι : Type u_4
p₁ p₂ : P
v : V
⊢ v ∈ vectorSpan k {p₁, p₂} ↔ ∃ r, r • (p₁ -ᵥ p₂) = v
state_after: no goals
tactic: rw [vectorSpan_pair, Submodule.mem_span_singleton]
Theorem: iSup₂_le_iff
File: Mathlib/Order/CompleteLattice.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
β₂ : Type u_3
γ : Type u_4
ι : Sort u_5
ι' : Sort u_6
κ : ι → Sort u_7
κ' : ι' → Sort u_8
inst✝ : CompleteLattice α
f✝ g s t : ι → α
a b : α
f : (i : ι) → κ i → α
⊢ ⨆ i, ⨆ j, f i j ≤ a ↔ ∀ (i : ι) (j : κ i), f i j ≤ a
state_after: no goals
tactic: simp_rw [iSup_le_iff]
Theorem: Finset.filter_image
File: Mathlib/Data/Finset/Image.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
inst✝¹ : DecidableEq β
f g : α → β
s : Finset α
t : Finset β
a : α
b✝ c : β
p : β → Prop
inst✝ : DecidablePred p
b : β
⊢ b ∈ filter p (image f s) ↔ b ∈ image f (filter (fun a => p (f a)) s)
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
inst✝¹ : DecidableEq β
f g : α → β
s : Finset α
t : Finset β
a : α
b✝ c : β
p : β → Prop
inst✝ : DecidablePred p
b : β
⊢ (∃ a ∈ s, f a = b) ∧ p b ↔ ∃ a, (a ∈ s ∧ p (f a)) ∧ f a = b
tactic: simp only [mem_filter, mem_image, exists_prop]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
inst✝¹ : DecidableEq β
f g : α → β
s : Finset α
t : Finset β
a : α
b✝ c : β
p : β → Prop
inst✝ : DecidablePred p
b : β
⊢ (∃ a ∈ s, f a = b) ∧ p b ↔ ∃ a, (a ∈ s ∧ p (f a)) ∧ f a = b
state_after: no goals
tactic: exact
      ⟨by rintro ⟨⟨x, h1, rfl⟩, h2⟩; exact ⟨x, ⟨h1, h2⟩, rfl⟩,
       by rintro ⟨x, ⟨h1, h2⟩, rfl⟩; exact ⟨⟨x, h1, rfl⟩, h2⟩⟩
Theorem: Set.prod_univ_range_eq
File: Mathlib/Data/Set/Prod.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
s s₁ s₂ : Set α
t t₁ t₂ : Set β
a : α
b : β
m₂ : β → δ
⊢ ∀ (x : α × δ), x ∈ univ ×ˢ range m₂ ↔ x ∈ range fun p => (p.1, m₂ p.2)
state_after: no goals
tactic: simp [range]
Theorem: cfcₙ_mul
File: Mathlib/Analysis/CstarAlgebra/ContinuousFunctionalCalculus/NonUnital.lean

Proof steps:
state_before: R : Type u_1
A : Type u_2
p : A → Prop
inst✝¹² : CommSemiring R
inst✝¹¹ : Nontrivial R
inst✝¹⁰ : StarRing R
inst✝⁹ : MetricSpace R
inst✝⁸ : TopologicalSemiring R
inst✝⁷ : ContinuousStar R
inst✝⁶ : NonUnitalRing A
inst✝⁵ : StarRing A
inst✝⁴ : TopologicalSpace A
inst✝³ : Module R A
inst✝² : IsScalarTower R A A
inst✝¹ : SMulCommClass R A A
inst✝ : NonUnitalContinuousFunctionalCalculus R p
f g : R → R
a : A
hf : autoParam (ContinuousOn f (σₙ R a)) _auto✝
hf0 : autoParam (f 0 = 0) _auto✝
hg : autoParam (ContinuousOn g (σₙ R a)) _auto✝
hg0 : autoParam (g 0 = 0) _auto✝
ha : autoParam (p a) _auto✝
⊢ cfcₙ (fun x => f x * g x) a = cfcₙ f a * cfcₙ g a
state_after: case pos
R : Type u_1
A : Type u_2
p : A → Prop
inst✝¹² : CommSemiring R
inst✝¹¹ : Nontrivial R
inst✝¹⁰ : StarRing R
inst✝⁹ : MetricSpace R
inst✝⁸ : TopologicalSemiring R
inst✝⁷ : ContinuousStar R
inst✝⁶ : NonUnitalRing A
inst✝⁵ : StarRing A
inst✝⁴ : TopologicalSpace A
inst✝³ : Module R A
inst✝² : IsScalarTower R A A
inst✝¹ : SMulCommClass R A A
inst✝ : NonUnitalContinuousFunctionalCalculus R p
f g : R → R
a : A
hf : autoParam (ContinuousOn f (σₙ R a)) _auto✝
hf0 : autoParam (f 0 = 0) _auto✝
hg : autoParam (ContinuousOn g (σₙ R a)) _auto✝
hg0 : autoParam (g 0 = 0) _auto✝
ha✝ : autoParam (p a) _auto✝
ha : p a
⊢ cfcₙ (fun x => f x * g x) a = cfcₙ f a * cfcₙ g a

case neg
R : Type u_1
A : Type u_2
p : A → Prop
inst✝¹² : CommSemiring R
inst✝¹¹ : Nontrivial R
inst✝¹⁰ : StarRing R
inst✝⁹ : MetricSpace R
inst✝⁸ : TopologicalSemiring R
inst✝⁷ : ContinuousStar R
inst✝⁶ : NonUnitalRing A
inst✝⁵ : StarRing A
inst✝⁴ : TopologicalSpace A
inst✝³ : Module R A
inst✝² : IsScalarTower R A A
inst✝¹ : SMulCommClass R A A
inst✝ : NonUnitalContinuousFunctionalCalculus R p
f g : R → R
a : A
hf : autoParam (ContinuousOn f (σₙ R a)) _auto✝
hf0 : autoParam (f 0 = 0) _auto✝
hg : autoParam (ContinuousOn g (σₙ R a)) _auto✝
hg0 : autoParam (g 0 = 0) _auto✝
ha✝ : autoParam (p a) _auto✝
ha : ¬p a
⊢ cfcₙ (fun x => f x * g x) a = cfcₙ f a * cfcₙ g a
tactic: by_cases ha : p a
Theorem: PrimeSpectrum.vanishingIdeal_mem_minimalPrimes
File: Mathlib/AlgebraicGeometry/PrimeSpectrum/Basic.lean

Proof steps:
state_before: R : Type u
S : Type v
inst✝ : CommSemiring R
s : Set (PrimeSpectrum R)
⊢ vanishingIdeal s ∈ minimalPrimes R ↔ closure s ∈ irreducibleComponents (PrimeSpectrum R)
state_after: case mp
R : Type u
S : Type v
inst✝ : CommSemiring R
s : Set (PrimeSpectrum R)
⊢ vanishingIdeal s ∈ minimalPrimes R → closure s ∈ irreducibleComponents (PrimeSpectrum R)

case mpr
R : Type u
S : Type v
inst✝ : CommSemiring R
s : Set (PrimeSpectrum R)
⊢ closure s ∈ irreducibleComponents (PrimeSpectrum R) → vanishingIdeal s ∈ minimalPrimes R
tactic: constructor
Theorem: ConvexOn.secant_mono_aux3
File: Mathlib/Analysis/Convex/Slope.lean

Proof steps:
state_before: 𝕜 : Type u_1
inst✝ : LinearOrderedField 𝕜
s : Set 𝕜
f : 𝕜 → 𝕜
hf : ConvexOn 𝕜 s f
x y z : 𝕜
hx : x ∈ s
hz : z ∈ s
hxy : x < y
hyz : y < z
⊢ (f z - f x) / (z - x) ≤ (f z - f y) / (z - y)
state_after: 𝕜 : Type u_1
inst✝ : LinearOrderedField 𝕜
s : Set 𝕜
f : 𝕜 → 𝕜
hf : ConvexOn 𝕜 s f
x y z : 𝕜
hx : x ∈ s
hz : z ∈ s
hxy : x < y
hyz : y < z
hyz' : 0 < z - y
⊢ (f z - f x) / (z - x) ≤ (f z - f y) / (z - y)
tactic: have hyz' : 0 < z - y := by linarith
state_before: 𝕜 : Type u_1
inst✝ : LinearOrderedField 𝕜
s : Set 𝕜
f : 𝕜 → 𝕜
hf : ConvexOn 𝕜 s f
x y z : 𝕜
hx : x ∈ s
hz : z ∈ s
hxy : x < y
hyz : y < z
hyz' : 0 < z - y
⊢ (f z - f x) / (z - x) ≤ (f z - f y) / (z - y)
state_after: 𝕜 : Type u_1
inst✝ : LinearOrderedField 𝕜
s : Set 𝕜
f : 𝕜 → 𝕜
hf : ConvexOn 𝕜 s f
x y z : 𝕜
hx : x ∈ s
hz : z ∈ s
hxy : x < y
hyz : y < z
hyz' : 0 < z - y
hxz' : 0 < z - x
⊢ (f z - f x) / (z - x) ≤ (f z - f y) / (z - y)
tactic: have hxz' : 0 < z - x := by linarith
state_before: 𝕜 : Type u_1
inst✝ : LinearOrderedField 𝕜
s : Set 𝕜
f : 𝕜 → 𝕜
hf : ConvexOn 𝕜 s f
x y z : 𝕜
hx : x ∈ s
hz : z ∈ s
hxy : x < y
hyz : y < z
hyz' : 0 < z - y
hxz' : 0 < z - x
⊢ (f z - f x) / (z - x) ≤ (f z - f y) / (z - y)
state_after: 𝕜 : Type u_1
inst✝ : LinearOrderedField 𝕜
s : Set 𝕜
f : 𝕜 → 𝕜
hf : ConvexOn 𝕜 s f
x y z : 𝕜
hx : x ∈ s
hz : z ∈ s
hxy : x < y
hyz : y < z
hyz' : 0 < z - y
hxz' : 0 < z - x
⊢ (f z - f x) * (z - y) ≤ (f z - f y) * (z - x)
tactic: rw [div_le_div_iff hxz' hyz']
state_before: 𝕜 : Type u_1
inst✝ : LinearOrderedField 𝕜
s : Set 𝕜
f : 𝕜 → 𝕜
hf : ConvexOn 𝕜 s f
x y z : 𝕜
hx : x ∈ s
hz : z ∈ s
hxy : x < y
hyz : y < z
hyz' : 0 < z - y
hxz' : 0 < z - x
⊢ (f z - f x) * (z - y) ≤ (f z - f y) * (z - x)
state_after: no goals
tactic: linarith only [hf.secant_mono_aux1 hx hz hxy hyz]
Theorem: List.count_cons
File: .lake/packages/batteries/Batteries/Data/List/Count.lean

Proof steps:
state_before: α : Type u_1
inst✝ : DecidableEq α
a b : α
l : List α
⊢ count a (b :: l) = count a l + if a = b then 1 else 0
state_after: no goals
tactic: simp [count, countP_cons, eq_comm (a := a)]
Theorem: Submodule.map_equiv_eq_comap_symm
File: Mathlib/Algebra/Module/Submodule/Map.lean

Proof steps:
state_before: R : Type u_1
R₁ : Type u_2
R₂ : Type u_3
R₃ : Type u_4
M : Type u_5
M₁ : Type u_6
M₂ : Type u_7
M₃ : Type u_8
inst✝⁷ : Semiring R
inst✝⁶ : Semiring R₂
inst✝⁵ : AddCommMonoid M
inst✝⁴ : AddCommMonoid M₂
inst✝³ : Module R M
inst✝² : Module R₂ M₂
τ₁₂ : R →+* R₂
τ₂₁ : R₂ →+* R
inst✝¹ : RingHomInvPair τ₁₂ τ₂₁
inst✝ : RingHomInvPair τ₂₁ τ₁₂
p : Submodule R M
q : Submodule R₂ M₂
e : M ≃ₛₗ[τ₁₂] M₂
K : Submodule R M
x✝ : M₂
⊢ x✝ ∈ map (↑e) K ↔ x✝ ∈ comap (↑e.symm) K
state_after: no goals
tactic: rw [mem_map_equiv, mem_comap, LinearEquiv.coe_coe]
Theorem: Commute.isNilpotent_sub
File: Mathlib/RingTheory/Nilpotent/Basic.lean

Proof steps:
state_before: R : Type u_1
S : Type u_2
x y : R
inst✝ : Ring R
h_comm : Commute x y
hx : IsNilpotent x
hy : IsNilpotent y
⊢ IsNilpotent (x - y)
state_after: R : Type u_1
S : Type u_2
x y : R
inst✝ : Ring R
h_comm : Commute x (-y)
hx : IsNilpotent x
hy : IsNilpotent y
⊢ IsNilpotent (x - y)
tactic: rw [← neg_right_iff] at h_comm
state_before: R : Type u_1
S : Type u_2
x y : R
inst✝ : Ring R
h_comm : Commute x (-y)
hx : IsNilpotent x
hy : IsNilpotent y
⊢ IsNilpotent (x - y)
state_after: R : Type u_1
S : Type u_2
x y : R
inst✝ : Ring R
h_comm : Commute x (-y)
hx : IsNilpotent x
hy : IsNilpotent (-y)
⊢ IsNilpotent (x - y)
tactic: rw [← isNilpotent_neg_iff] at hy
state_before: R : Type u_1
S : Type u_2
x y : R
inst✝ : Ring R
h_comm : Commute x (-y)
hx : IsNilpotent x
hy : IsNilpotent (-y)
⊢ IsNilpotent (x - y)
state_after: R : Type u_1
S : Type u_2
x y : R
inst✝ : Ring R
h_comm : Commute x (-y)
hx : IsNilpotent x
hy : IsNilpotent (-y)
⊢ IsNilpotent (x + -y)
tactic: rw [sub_eq_add_neg]
state_before: R : Type u_1
S : Type u_2
x y : R
inst✝ : Ring R
h_comm : Commute x (-y)
hx : IsNilpotent x
hy : IsNilpotent (-y)
⊢ IsNilpotent (x + -y)
state_after: no goals
tactic: exact h_comm.isNilpotent_add hx hy
Theorem: OreLocalization.mul_inv_cancel
File: Mathlib/RingTheory/OreLocalization/Ring.lean

Proof steps:
state_before: R : Type u_1
inst✝³ : Ring R
inst✝² : Nontrivial R
inst✝¹ : OreSet R⁰
inst✝ : NoZeroDivisors R
x : OreLocalization R⁰ R
h : x ≠ 0
⊢ x * x⁻¹ = 1
state_after: case c
R : Type u_1
inst✝³ : Ring R
inst✝² : Nontrivial R
inst✝¹ : OreSet R⁰
inst✝ : NoZeroDivisors R
r : R
s : ↥R⁰
h : r /ₒ s ≠ 0
⊢ r /ₒ s * (r /ₒ s)⁻¹ = 1
tactic: induction' x with r s
state_before: case c
R : Type u_1
inst✝³ : Ring R
inst✝² : Nontrivial R
inst✝¹ : OreSet R⁰
inst✝ : NoZeroDivisors R
r : R
s : ↥R⁰
h : r /ₒ s ≠ 0
⊢ r /ₒ s * (r /ₒ s)⁻¹ = 1
state_after: case c
R : Type u_1
inst✝³ : Ring R
inst✝² : Nontrivial R
inst✝¹ : OreSet R⁰
inst✝ : NoZeroDivisors R
r : R
s : ↥R⁰
h : r /ₒ s ≠ 0
⊢ (r /ₒ s * if hr : r = 0 then 0 else ↑s /ₒ ⟨r, ⋯⟩) = 1 /ₒ 1
tactic: rw [OreLocalization.inv_def, OreLocalization.one_def]
state_before: case c
R : Type u_1
inst✝³ : Ring R
inst✝² : Nontrivial R
inst✝¹ : OreSet R⁰
inst✝ : NoZeroDivisors R
r : R
s : ↥R⁰
h : r /ₒ s ≠ 0
⊢ (r /ₒ s * if hr : r = 0 then 0 else ↑s /ₒ ⟨r, ⋯⟩) = 1 /ₒ 1
state_after: case c
R : Type u_1
inst✝³ : Ring R
inst✝² : Nontrivial R
inst✝¹ : OreSet R⁰
inst✝ : NoZeroDivisors R
r : R
s : ↥R⁰
h : r /ₒ s ≠ 0
hr : r ≠ 0
⊢ (r /ₒ s * if hr : r = 0 then 0 else ↑s /ₒ ⟨r, ⋯⟩) = 1 /ₒ 1
tactic: have hr : r ≠ 0 := by
    rintro rfl
    simp at h
state_before: case c
R : Type u_1
inst✝³ : Ring R
inst✝² : Nontrivial R
inst✝¹ : OreSet R⁰
inst✝ : NoZeroDivisors R
r : R
s : ↥R⁰
h : r /ₒ s ≠ 0
hr : r ≠ 0
⊢ (r /ₒ s * if hr : r = 0 then 0 else ↑s /ₒ ⟨r, ⋯⟩) = 1 /ₒ 1
state_after: case c
R : Type u_1
inst✝³ : Ring R
inst✝² : Nontrivial R
inst✝¹ : OreSet R⁰
inst✝ : NoZeroDivisors R
r : R
s : ↥R⁰
h : r /ₒ s ≠ 0
hr : r ≠ 0
⊢ (r /ₒ s * if h : False then 0 else ↑s /ₒ ⟨r, ⋯⟩) = 1 /ₒ 1
tactic: simp only [hr]
state_before: case c
R : Type u_1
inst✝³ : Ring R
inst✝² : Nontrivial R
inst✝¹ : OreSet R⁰
inst✝ : NoZeroDivisors R
r : R
s : ↥R⁰
h : r /ₒ s ≠ 0
hr : r ≠ 0
⊢ (r /ₒ s * if h : False then 0 else ↑s /ₒ ⟨r, ⋯⟩) = 1 /ₒ 1
state_after: no goals
tactic: with_unfolding_all apply OreLocalization.mul_inv ⟨r, _⟩
Theorem: EisensteinSeries.norm_eq_max_natAbs
File: Mathlib/NumberTheory/ModularForms/EisensteinSeries/UniformConvergence.lean

Proof steps:
state_before: z : ℍ
x : Fin 2 → ℤ
⊢ ‖x‖ = ↑(max (x 0).natAbs (x 1).natAbs)
state_after: z : ℍ
x : Fin 2 → ℤ
⊢ ‖x‖₊ = max ↑(x 0).natAbs ↑(x 1).natAbs
tactic: rw [← coe_nnnorm, ← NNReal.coe_natCast, NNReal.coe_inj, Nat.cast_max]
state_before: z : ℍ
x : Fin 2 → ℤ
⊢ ‖x‖₊ = max ↑(x 0).natAbs ↑(x 1).natAbs
state_after: z : ℍ
x : Fin 2 → ℤ
c : NNReal
⊢ ‖x‖₊ ≤ c ↔ max ↑(x 0).natAbs ↑(x 1).natAbs ≤ c
tactic: refine eq_of_forall_ge_iff fun c ↦ ?_
state_before: z : ℍ
x : Fin 2 → ℤ
c : NNReal
⊢ ‖x‖₊ ≤ c ↔ max ↑(x 0).natAbs ↑(x 1).natAbs ≤ c
state_after: no goals
tactic: simp only [pi_nnnorm_le_iff, Fin.forall_fin_two, max_le_iff, NNReal.natCast_natAbs]
Theorem: Multiset.map_eq_singleton
File: Mathlib/Data/Multiset/Basic.lean

Proof steps:
state_before: α : Type u_1
β : Type v
γ : Type u_2
f : α → β
s : Multiset α
b : β
⊢ map f s = {b} ↔ ∃ a, s = {a} ∧ f a = b
state_after: case mp
α : Type u_1
β : Type v
γ : Type u_2
f : α → β
s : Multiset α
b : β
⊢ map f s = {b} → ∃ a, s = {a} ∧ f a = b

case mpr
α : Type u_1
β : Type v
γ : Type u_2
f : α → β
s : Multiset α
b : β
⊢ (∃ a, s = {a} ∧ f a = b) → map f s = {b}
tactic: constructor
Theorem: AlgebraicGeometry.ProjIsoSpecTopComponent.ToSpec.isPrime_carrier
File: Mathlib/AlgebraicGeometry/ProjectiveSpectrum/Scheme.lean

Proof steps:
state_before: R : Type u_1
A : Type u_2
inst✝³ : CommRing R
inst✝² : CommRing A
inst✝¹ : Algebra R A
𝒜 : ℕ → Submodule R A
inst✝ : GradedAlgebra 𝒜
f : A
m : ℕ
f_deg : f ∈ 𝒜 m
x : ↑(Proj.restrict ⋯).toTopCat
⊢ (carrier x).IsPrime
state_after: R : Type u_1
A : Type u_2
inst✝³ : CommRing R
inst✝² : CommRing A
inst✝¹ : Algebra R A
𝒜 : ℕ → Submodule R A
inst✝ : GradedAlgebra 𝒜
f : A
m : ℕ
f_deg : f ∈ 𝒜 m
x : ↑(Proj.restrict ⋯).toTopCat
⊢ (Ideal.map (algebraMap A (Away f)) (↑x).asHomogeneousIdeal.toIdeal).IsPrime
tactic: refine Ideal.IsPrime.comap _ (hK := ?_)
state_before: R : Type u_1
A : Type u_2
inst✝³ : CommRing R
inst✝² : CommRing A
inst✝¹ : Algebra R A
𝒜 : ℕ → Submodule R A
inst✝ : GradedAlgebra 𝒜
f : A
m : ℕ
f_deg : f ∈ 𝒜 m
x : ↑(Proj.restrict ⋯).toTopCat
⊢ (Ideal.map (algebraMap A (Away f)) (↑x).asHomogeneousIdeal.toIdeal).IsPrime
state_after: no goals
tactic: exact IsLocalization.isPrime_of_isPrime_disjoint
    (Submonoid.powers f) _ _ inferInstance
    ((disjoint_powers_iff_not_mem _ (Ideal.IsPrime.isRadical inferInstance)).mpr x.2)
Theorem: Pell.eq_of_xn_modEq_lem1
File: Mathlib/NumberTheory/PellMatiyasevic.lean

Proof steps:
state_before: a : ℕ
a1 : 1 < a
i n j : ℕ
ij : i < j + 1
jn : j + 1 < n
⊢ xn a1 i % xn a1 n < xn a1 (j + 1) % xn a1 n
state_after: a : ℕ
a1 : 1 < a
i n j : ℕ
ij : i < j + 1
jn : j + 1 < n
⊢ xn a1 j % xn a1 n < xn a1 (j + 1) % xn a1 n
tactic: suffices xn a1 j % xn a1 n < xn a1 (j + 1) % xn a1 n from
      (lt_or_eq_of_le (Nat.le_of_succ_le_succ ij)).elim
        (fun h => lt_trans (eq_of_xn_modEq_lem1 h (le_of_lt jn)) this) fun h => by
        rw [h]; exact this
state_before: a : ℕ
a1 : 1 < a
i n j : ℕ
ij : i < j + 1
jn : j + 1 < n
⊢ xn a1 j % xn a1 n < xn a1 (j + 1) % xn a1 n
state_after: a : ℕ
a1 : 1 < a
i n j : ℕ
ij : i < j + 1
jn : j + 1 < n
⊢ xn a1 j < xn a1 (j + 1)
tactic: rw [Nat.mod_eq_of_lt (strictMono_x _ (Nat.lt_of_succ_lt jn)),
        Nat.mod_eq_of_lt (strictMono_x _ jn)]
state_before: a : ℕ
a1 : 1 < a
i n j : ℕ
ij : i < j + 1
jn : j + 1 < n
⊢ xn a1 j < xn a1 (j + 1)
state_after: no goals
tactic: exact strictMono_x _ (Nat.lt_succ_self _)
Theorem: Ordinal.nmul_comm
File: Mathlib/SetTheory/Ordinal/NaturalOps.lean

Proof steps:
state_before: a✝ b✝ c d : Ordinal.{u}
a b : Ordinal.{u_1}
⊢ a ⨳ b = b ⨳ a
state_after: a✝ b✝ c d : Ordinal.{u}
a b : Ordinal.{u_1}
⊢ sInf {c | ∀ a' < a, ∀ b' < b, a' ⨳ b ♯ a ⨳ b' < c ♯ a' ⨳ b'} =
    sInf {c | ∀ a' < b, ∀ b' < a, a' ⨳ a ♯ b ⨳ b' < c ♯ a' ⨳ b'}
tactic: rw [nmul, nmul]
state_before: a✝ b✝ c d : Ordinal.{u}
a b : Ordinal.{u_1}
⊢ sInf {c | ∀ a' < a, ∀ b' < b, a' ⨳ b ♯ a ⨳ b' < c ♯ a' ⨳ b'} =
    sInf {c | ∀ a' < b, ∀ b' < a, a' ⨳ a ♯ b ⨳ b' < c ♯ a' ⨳ b'}
state_after: case e_a
a✝ b✝ c d : Ordinal.{u}
a b : Ordinal.{u_1}
⊢ {c | ∀ a' < a, ∀ b' < b, a' ⨳ b ♯ a ⨳ b' < c ♯ a' ⨳ b'} = {c | ∀ a' < b, ∀ b' < a, a' ⨳ a ♯ b ⨳ b' < c ♯ a' ⨳ b'}
tactic: congr
state_before: case e_a
a✝ b✝ c d : Ordinal.{u}
a b : Ordinal.{u_1}
⊢ {c | ∀ a' < a, ∀ b' < b, a' ⨳ b ♯ a ⨳ b' < c ♯ a' ⨳ b'} = {c | ∀ a' < b, ∀ b' < a, a' ⨳ a ♯ b ⨳ b' < c ♯ a' ⨳ b'}
state_after: case e_a.h
a✝ b✝ c d : Ordinal.{u}
a b x : Ordinal.{u_1}
⊢ x ∈ {c | ∀ a' < a, ∀ b' < b, a' ⨳ b ♯ a ⨳ b' < c ♯ a' ⨳ b'} ↔
    x ∈ {c | ∀ a' < b, ∀ b' < a, a' ⨳ a ♯ b ⨳ b' < c ♯ a' ⨳ b'}
tactic: ext x
state_before: case e_a.h
a✝ b✝ c d : Ordinal.{u}
a b x : Ordinal.{u_1}
⊢ x ∈ {c | ∀ a' < a, ∀ b' < b, a' ⨳ b ♯ a ⨳ b' < c ♯ a' ⨳ b'} ↔
    x ∈ {c | ∀ a' < b, ∀ b' < a, a' ⨳ a ♯ b ⨳ b' < c ♯ a' ⨳ b'}
state_after: case e_a.h.mp
a✝ b✝ c✝ d✝ : Ordinal.{u}
a b x : Ordinal.{u_1}
H : x ∈ {c | ∀ a' < a, ∀ b' < b, a' ⨳ b ♯ a ⨳ b' < c ♯ a' ⨳ b'}
c : Ordinal.{u_1}
hc : c < b
d : Ordinal.{u_1}
hd : d < a
⊢ c ⨳ a ♯ b ⨳ d < x ♯ c ⨳ d

case e_a.h.mpr
a✝ b✝ c✝ d✝ : Ordinal.{u}
a b x : Ordinal.{u_1}
H : x ∈ {c | ∀ a' < b, ∀ b' < a, a' ⨳ a ♯ b ⨳ b' < c ♯ a' ⨳ b'}
c : Ordinal.{u_1}
hc : c < a
d : Ordinal.{u_1}
hd : d < b
⊢ c ⨳ b ♯ a ⨳ d < x ♯ c ⨳ d
tactic: constructor <;> intro H c hc d hd
Theorem: BoundedContinuousFunction.norm_lt_iff_of_nonempty_compact
File: Mathlib/Topology/ContinuousFunction/Bounded.lean

Proof steps:
state_before: F : Type u_1
α : Type u
β : Type v
γ : Type w
inst✝³ : TopologicalSpace α
inst✝² : SeminormedAddCommGroup β
f✝ g : α →ᵇ β
x : α
C : ℝ
inst✝¹ : Nonempty α
inst✝ : CompactSpace α
f : α →ᵇ β
M : ℝ
⊢ ‖f‖ < M ↔ ∀ (x : α), ‖f x‖ < M
state_after: F : Type u_1
α : Type u
β : Type v
γ : Type w
inst✝³ : TopologicalSpace α
inst✝² : SeminormedAddCommGroup β
f✝ g : α →ᵇ β
x : α
C : ℝ
inst✝¹ : Nonempty α
inst✝ : CompactSpace α
f : α →ᵇ β
M : ℝ
⊢ dist f 0 < M ↔ ∀ (x : α), dist (f x) 0 < M
tactic: simp_rw [norm_def, ← dist_zero_right]
state_before: F : Type u_1
α : Type u
β : Type v
γ : Type w
inst✝³ : TopologicalSpace α
inst✝² : SeminormedAddCommGroup β
f✝ g : α →ᵇ β
x : α
C : ℝ
inst✝¹ : Nonempty α
inst✝ : CompactSpace α
f : α →ᵇ β
M : ℝ
⊢ dist f 0 < M ↔ ∀ (x : α), dist (f x) 0 < M
state_after: no goals
tactic: exact dist_lt_iff_of_nonempty_compact
Theorem: Set.insert_diff_singleton_comm
File: Mathlib/Data/Set/Basic.lean

Proof steps:
state_before: α : Type u
β : Type v
γ : Type w
ι : Sort x
a b : α
s✝ s₁ s₂ t t₁ t₂ u : Set α
hab : a ≠ b
s : Set α
⊢ insert a (s \ {b}) = insert a s \ {b}
state_after: no goals
tactic: simp_rw [← union_singleton, union_diff_distrib,
    diff_singleton_eq_self (mem_singleton_iff.not.2 hab.symm)]