ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
Theorem: Int.sq_add_sq_of_two_mul_sq_add_sq
File: Mathlib/NumberTheory/SumFourSquares.lean

Proof steps:
state_before: m x y : ℤ
h : 2 * m = x ^ 2 + y ^ 2
⊢ Even (x ^ 2 + y ^ 2)
state_after: no goals
tactic: simp [← h, even_mul]
state_before: m x y : ℤ
h : 2 * m = x ^ 2 + y ^ 2
this : Even (x ^ 2 + y ^ 2)
⊢ Even (x + y)
state_after: no goals
tactic: simpa [sq, parity_simps]
state_before: m x y : ℤ
h : 2 * m = x ^ 2 + y ^ 2
this : Even (x ^ 2 + y ^ 2)
hxaddy : Even (x + y)
⊢ Even (x - y)
state_after: no goals
tactic: simpa [sq, parity_simps]
state_before: m x y : ℤ
h : 2 * m = x ^ 2 + y ^ 2
this : Even (x ^ 2 + y ^ 2)
hxaddy : Even (x + y)
hxsuby : Even (x - y)
⊢ 2 * 2 ≠ 0
state_after: no goals
tactic: decide
state_before: m x y : ℤ
h : 2 * m = x ^ 2 + y ^ 2
this : Even (x ^ 2 + y ^ 2)
hxaddy : Even (x + y)
hxsuby : Even (x - y)
⊢ 2 * 2 * m = (x - y) ^ 2 + (x + y) ^ 2
state_after: m x y : ℤ
h : 2 * m = x ^ 2 + y ^ 2
this : Even (x ^ 2 + y ^ 2)
hxaddy : Even (x + y)
hxsuby : Even (x - y)
⊢ 2 * (x ^ 2 + y ^ 2) = (x - y) ^ 2 + (x + y) ^ 2
tactic: rw [mul_assoc, h]
state_before: m x y : ℤ
h : 2 * m = x ^ 2 + y ^ 2
this : Even (x ^ 2 + y ^ 2)
hxaddy : Even (x + y)
hxsuby : Even (x - y)
⊢ 2 * (x ^ 2 + y ^ 2) = (x - y) ^ 2 + (x + y) ^ 2
state_after: no goals
tactic: ring
state_before: m x y : ℤ
h : 2 * m = x ^ 2 + y ^ 2
this : Even (x ^ 2 + y ^ 2)
hxaddy : Even (x + y)
hxsuby : Even (x - y)
⊢ (x - y) ^ 2 + (x + y) ^ 2 = (2 * ((x - y) / 2)) ^ 2 + (2 * ((x + y) / 2)) ^ 2
state_after: m x y : ℤ
h : 2 * m = x ^ 2 + y ^ 2
this : Even (x ^ 2 + y ^ 2)
hxaddy : 2 ∣ x + y
hxsuby : 2 ∣ x - y
⊢ (x - y) ^ 2 + (x + y) ^ 2 = (2 * ((x - y) / 2)) ^ 2 + (2 * ((x + y) / 2)) ^ 2
tactic: rw [even_iff_two_dvd] at hxsuby hxaddy
state_before: m x y : ℤ
h : 2 * m = x ^ 2 + y ^ 2
this : Even (x ^ 2 + y ^ 2)
hxaddy : 2 ∣ x + y
hxsuby : 2 ∣ x - y
⊢ (x - y) ^ 2 + (x + y) ^ 2 = (2 * ((x - y) / 2)) ^ 2 + (2 * ((x + y) / 2)) ^ 2
state_after: no goals
tactic: rw [Int.mul_ediv_cancel' hxsuby, Int.mul_ediv_cancel' hxaddy]
state_before: m x y : ℤ
h : 2 * m = x ^ 2 + y ^ 2
this : Even (x ^ 2 + y ^ 2)
hxaddy : Even (x + y)
hxsuby : Even (x - y)
⊢ (2 * ((x - y) / 2)) ^ 2 + (2 * ((x + y) / 2)) ^ 2 = 2 * 2 * (((x - y) / 2) ^ 2 + ((x + y) / 2) ^ 2)
state_after: no goals
tactic: set_option simprocs false in
        simp [mul_add, pow_succ, mul_comm, mul_assoc, mul_left_comm]
Theorem: DirectSum.decompose_of_mem_ne
File: Mathlib/Algebra/DirectSum/Decomposition.lean

Proof steps:
state_before: ι : Type u_1
R : Type u_2
M : Type u_3
σ : Type u_4
inst✝⁴ : DecidableEq ι
inst✝³ : AddCommMonoid M
inst✝² : SetLike σ M
inst✝¹ : AddSubmonoidClass σ M
ℳ : ι → σ
inst✝ : Decomposition ℳ
x : M
i j : ι
hx : x ∈ ℳ i
hij : i ≠ j
⊢ ↑(((decompose ℳ) x) j) = 0
state_after: no goals
tactic: rw [decompose_of_mem _ hx, DirectSum.of_eq_of_ne _ _ _ hij, ZeroMemClass.coe_zero]
Theorem: Equiv.Perm.sign_permCongr
File: Mathlib/GroupTheory/Perm/Sign.lean

Proof steps:
state_before: α : Type u
inst✝³ : DecidableEq α
β : Type v
inst✝² : Fintype α
inst✝¹ : DecidableEq β
inst✝ : Fintype β
e : α ≃ β
p : Perm α
⊢ ∀ (x : β), e.symm ((e.permCongr p) x) = p (e.symm x)
state_after: no goals
tactic: simp
Theorem: IntermediateField.normal_iff_forall_map_le'
File: Mathlib/FieldTheory/NormalClosure.lean

Proof steps:
state_before: F : Type u_1
K✝¹ : Type u_2
L : Type u_3
inst✝⁵ : Field F
inst✝⁴ : Field K✝¹
inst✝³ : Field L
inst✝² : Algebra F K✝¹
inst✝¹ : Algebra F L
K✝ K' : IntermediateField F L
inst✝ : Normal F L
K : IntermediateField F L
⊢ Normal F ↥K ↔ ∀ (σ : L ≃ₐ[F] L), map (↑σ) K ≤ K
state_after: no goals
tactic: rw [normal_iff_normalClosure_le, normalClosure_def'', iSup_le_iff]
Theorem: Algebra.transcendental_iff_not_isAlgebraic
File: Mathlib/RingTheory/Algebraic.lean

Proof steps:
state_before: R : Type u
A : Type v
inst✝² : CommRing R
inst✝¹ : Ring A
inst✝ : Algebra R A
⊢ Algebra.Transcendental R A ↔ ¬Algebra.IsAlgebraic R A
state_after: no goals
tactic: simp [isAlgebraic_def, transcendental_def, Transcendental]
Theorem: gramSchmidt_def'
File: Mathlib/Analysis/InnerProductSpace/GramSchmidtOrtho.lean

Proof steps:
state_before: 𝕜 : Type u_1
E : Type u_2
inst✝⁵ : RCLike 𝕜
inst✝⁴ : NormedAddCommGroup E
inst✝³ : InnerProductSpace 𝕜 E
ι : Type u_3
inst✝² : LinearOrder ι
inst✝¹ : LocallyFiniteOrderBot ι
inst✝ : IsWellOrder ι fun x x_1 => x < x_1
f : ι → E
n : ι
⊢ f n = gramSchmidt 𝕜 f n + ∑ i ∈ Iio n, ↑((orthogonalProjection (span 𝕜 {gramSchmidt 𝕜 f i})) (f n))
state_after: no goals
tactic: rw [gramSchmidt_def, sub_add_cancel]
Theorem: CategoryTheory.braiding_tensorUnit_right
File: Mathlib/CategoryTheory/Monoidal/Braided/Basic.lean

Proof steps:
state_before: C : Type u₁
inst✝² : Category.{v₁, u₁} C
inst✝¹ : MonoidalCategory C
inst✝ : BraidedCategory C
X : C
⊢ (β_ X (𝟙_ C)).hom = (ρ_ X).hom ≫ (λ_ X).inv
state_after: no goals
tactic: simp [← rightUnitor_inv_braiding]
Theorem: GenContFract.abs_sub_convergents_le'
File: Mathlib/Algebra/ContinuedFractions/Computation/Approximations.lean

Proof steps:
state_before: K : Type u_1
v : K
n : ℕ
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
b : K
nth_partDen_eq : (of v).partDens.get? n = some b
⊢ |v - (of v).convs n| ≤ 1 / (b * (of v).dens n * (of v).dens n)
state_after: K : Type u_1
v : K
n : ℕ
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
b : K
nth_partDen_eq : (of v).partDens.get? n = some b
not_terminatedAt_n : ¬(of v).TerminatedAt n
⊢ |v - (of v).convs n| ≤ 1 / (b * (of v).dens n * (of v).dens n)
tactic: have not_terminatedAt_n : ¬(of v).TerminatedAt n := by
    simp [terminatedAt_iff_partDen_none, nth_partDen_eq]
state_before: K : Type u_1
v : K
n : ℕ
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
b : K
nth_partDen_eq : (of v).partDens.get? n = some b
not_terminatedAt_n : ¬(of v).TerminatedAt n
⊢ |v - (of v).convs n| ≤ 1 / (b * (of v).dens n * (of v).dens n)
state_after: K : Type u_1
v : K
n : ℕ
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
b : K
nth_partDen_eq : (of v).partDens.get? n = some b
not_terminatedAt_n : ¬(of v).TerminatedAt n
⊢ 1 / ((of v).dens n * (of v).dens (n + 1)) ≤ 1 / (b * (of v).dens n * (of v).dens n)
tactic: refine (abs_sub_convs_le not_terminatedAt_n).trans ?_
state_before: K : Type u_1
v : K
n : ℕ
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
b : K
nth_partDen_eq : (of v).partDens.get? n = some b
not_terminatedAt_n : ¬(of v).TerminatedAt n
⊢ 1 / ((of v).dens n * (of v).dens (n + 1)) ≤ 1 / (b * (of v).dens n * (of v).dens n)
state_after: case inl
K : Type u_1
v : K
n : ℕ
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
b : K
nth_partDen_eq : (of v).partDens.get? n = some b
not_terminatedAt_n : ¬(of v).TerminatedAt n
hB : (of v).dens n = 0
⊢ 1 / ((of v).dens n * (of v).dens (n + 1)) ≤ 1 / (b * (of v).dens n * (of v).dens n)

case inr
K : Type u_1
v : K
n : ℕ
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
b : K
nth_partDen_eq : (of v).partDens.get? n = some b
not_terminatedAt_n : ¬(of v).TerminatedAt n
hB : 0 < (of v).dens n
⊢ 1 / ((of v).dens n * (of v).dens (n + 1)) ≤ 1 / (b * (of v).dens n * (of v).dens n)
tactic: rcases (zero_le_of_den (K := K)).eq_or_gt with
    ((hB : (GenContFract.of v).dens n = 0) | hB)
Theorem: IsAbsoluteValue.abv_sub_le
File: Mathlib/Algebra/Order/AbsoluteValue.lean

Proof steps:
state_before: ι : Type u_1
α : Type u_2
R✝ : Type u_3
S✝ : Type u_4
S : Type u_5
inst✝² : OrderedRing S
R : Type u_6
inst✝¹ : Ring R
abv : R → S
inst✝ : IsAbsoluteValue abv
a b c : R
⊢ abv (a - c) ≤ abv (a - b) + abv (b - c)
state_after: no goals
tactic: simpa [sub_eq_add_neg, add_assoc] using abv_add abv (a - b) (b - c)
Theorem: ConvexOn.le_left_of_right_le
File: Mathlib/Analysis/Convex/Function.lean

Proof steps:
state_before: 𝕜 : Type u_1
E : Type u_2
F : Type u_3
α : Type u_4
β : Type u_5
ι : Type u_6
inst✝⁶ : OrderedSemiring 𝕜
inst✝⁵ : AddCommMonoid E
inst✝⁴ : AddCommMonoid F
inst✝³ : LinearOrderedCancelAddCommMonoid β
inst✝² : SMul 𝕜 E
inst✝¹ : Module 𝕜 β
inst✝ : OrderedSMul 𝕜 β
s : Set E
f g : E → β
hf : ConvexOn 𝕜 s f
x y z : E
hx : x ∈ s
hy : y ∈ s
hz : z ∈ openSegment 𝕜 x y
hyz : f y ≤ f z
⊢ f z ≤ f x
state_after: case intro.intro.intro.intro.intro
𝕜 : Type u_1
E : Type u_2
F : Type u_3
α : Type u_4
β : Type u_5
ι : Type u_6
inst✝⁶ : OrderedSemiring 𝕜
inst✝⁵ : AddCommMonoid E
inst✝⁴ : AddCommMonoid F
inst✝³ : LinearOrderedCancelAddCommMonoid β
inst✝² : SMul 𝕜 E
inst✝¹ : Module 𝕜 β
inst✝ : OrderedSMul 𝕜 β
s : Set E
f g : E → β
hf : ConvexOn 𝕜 s f
x y : E
hx : x ∈ s
hy : y ∈ s
a b : 𝕜
ha : 0 < a
hb : 0 < b
hab : a + b = 1
hyz : f y ≤ f (a • x + b • y)
⊢ f (a • x + b • y) ≤ f x
tactic: obtain ⟨a, b, ha, hb, hab, rfl⟩ := hz
state_before: case intro.intro.intro.intro.intro
𝕜 : Type u_1
E : Type u_2
F : Type u_3
α : Type u_4
β : Type u_5
ι : Type u_6
inst✝⁶ : OrderedSemiring 𝕜
inst✝⁵ : AddCommMonoid E
inst✝⁴ : AddCommMonoid F
inst✝³ : LinearOrderedCancelAddCommMonoid β
inst✝² : SMul 𝕜 E
inst✝¹ : Module 𝕜 β
inst✝ : OrderedSMul 𝕜 β
s : Set E
f g : E → β
hf : ConvexOn 𝕜 s f
x y : E
hx : x ∈ s
hy : y ∈ s
a b : 𝕜
ha : 0 < a
hb : 0 < b
hab : a + b = 1
hyz : f y ≤ f (a • x + b • y)
⊢ f (a • x + b • y) ≤ f x
state_after: no goals
tactic: exact hf.le_left_of_right_le' hx hy ha hb.le hab hyz
Theorem: Asymptotics.SuperpolynomialDecay.param_pow_mul
File: Mathlib/Analysis/Asymptotics/SuperpolynomialDecay.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
l : Filter α
k f g g' : α → β
inst✝¹ : TopologicalSpace β
inst✝ : CommSemiring β
hf : SuperpolynomialDecay l k f
n : ℕ
⊢ SuperpolynomialDecay l k (k ^ n * f)
state_after: case zero
α : Type u_1
β : Type u_2
l : Filter α
k f g g' : α → β
inst✝¹ : TopologicalSpace β
inst✝ : CommSemiring β
hf : SuperpolynomialDecay l k f
⊢ SuperpolynomialDecay l k (k ^ 0 * f)

case succ
α : Type u_1
β : Type u_2
l : Filter α
k f g g' : α → β
inst✝¹ : TopologicalSpace β
inst✝ : CommSemiring β
hf : SuperpolynomialDecay l k f
n : ℕ
hn : SuperpolynomialDecay l k (k ^ n * f)
⊢ SuperpolynomialDecay l k (k ^ (n + 1) * f)
tactic: induction' n with n hn
Theorem: LieModuleHom.range_eq_top
File: Mathlib/Algebra/Lie/Submodule.lean

Proof steps:
state_before: R : Type u
L : Type v
M : Type w
N : Type w₁
inst✝¹⁰ : CommRing R
inst✝⁹ : LieRing L
inst✝⁸ : LieAlgebra R L
inst✝⁷ : AddCommGroup M
inst✝⁶ : Module R M
inst✝⁵ : LieRingModule L M
inst✝⁴ : LieModule R L M
inst✝³ : AddCommGroup N
inst✝² : Module R N
inst✝¹ : LieRingModule L N
inst✝ : LieModule R L N
f : M →ₗ⁅R,L⁆ N
⊢ f.range = ⊤ ↔ Function.Surjective ⇑f
state_after: no goals
tactic: rw [SetLike.ext'_iff, coe_range, LieSubmodule.top_coe, Set.range_iff_surjective]
Theorem: List.orderedInsert_length
File: Mathlib/Data/List/Sort.lean

Proof steps:
state_before: α : Type u
r : α → α → Prop
inst✝ : DecidableRel r
hd : α
tl : List α
a : α
⊢ (orderedInsert r a (hd :: tl)).length = (hd :: tl).length + 1
state_after: α : Type u
r : α → α → Prop
inst✝ : DecidableRel r
hd : α
tl : List α
a : α
⊢ (if r a hd then a :: hd :: tl else hd :: orderedInsert r a tl).length = tl.length + 1 + 1
tactic: dsimp [orderedInsert]
state_before: α : Type u
r : α → α → Prop
inst✝ : DecidableRel r
hd : α
tl : List α
a : α
⊢ (if r a hd then a :: hd :: tl else hd :: orderedInsert r a tl).length = tl.length + 1 + 1
state_after: no goals
tactic: split_ifs <;> simp [orderedInsert_length tl]
Theorem: Polynomial.eval₂_gcd_eq_zero
File: Mathlib/Algebra/Polynomial/FieldDivision.lean

Proof steps:
state_before: R : Type u
S : Type v
k : Type y
A : Type z
a b : R
n : ℕ
inst✝² : Field R
p q : R[X]
inst✝¹ : CommSemiring k
inst✝ : DecidableEq R
ϕ : R →+* k
f g : R[X]
α : k
hf : eval₂ ϕ α f = 0
hg : eval₂ ϕ α g = 0
⊢ eval₂ ϕ α (EuclideanDomain.gcd f g) = 0
state_after: no goals
tactic: rw [EuclideanDomain.gcd_eq_gcd_ab f g, Polynomial.eval₂_add, Polynomial.eval₂_mul,
    Polynomial.eval₂_mul, hf, hg, zero_mul, zero_mul, zero_add]
Theorem: cfc_nonneg
File: Mathlib/Analysis/CstarAlgebra/ContinuousFunctionalCalculus/Unital.lean

Proof steps:
state_before: R : Type u_1
A : Type u_2
p : A → Prop
inst✝¹⁵ : OrderedCommSemiring R
inst✝¹⁴ : StarRing R
inst✝¹³ : StarOrderedRing R
inst✝¹² : MetricSpace R
inst✝¹¹ : TopologicalSemiring R
inst✝¹⁰ : ContinuousStar R
inst✝⁹ : ∀ (α : Type ?u.740550) [inst : TopologicalSpace α], StarOrderedRing C(α, R)
inst✝⁸ : TopologicalSpace A
inst✝⁷ : Ring A
inst✝⁶ : StarRing A
inst✝⁵ : PartialOrder A
inst✝⁴ : StarOrderedRing A
inst✝³ : Algebra R A
inst✝² : StarModule R A
inst✝¹ : ContinuousFunctionalCalculus R p
inst✝ : NonnegSpectrumClass R A
f : R → R
a : A
h : ∀ x ∈ spectrum R a, 0 ≤ f x
⊢ 0 ≤ cfc f a
state_after: case pos
R : Type u_1
A : Type u_2
p : A → Prop
inst✝¹⁵ : OrderedCommSemiring R
inst✝¹⁴ : StarRing R
inst✝¹³ : StarOrderedRing R
inst✝¹² : MetricSpace R
inst✝¹¹ : TopologicalSemiring R
inst✝¹⁰ : ContinuousStar R
inst✝⁹ : ∀ (α : Type ?u.740550) [inst : TopologicalSpace α], StarOrderedRing C(α, R)
inst✝⁸ : TopologicalSpace A
inst✝⁷ : Ring A
inst✝⁶ : StarRing A
inst✝⁵ : PartialOrder A
inst✝⁴ : StarOrderedRing A
inst✝³ : Algebra R A
inst✝² : StarModule R A
inst✝¹ : ContinuousFunctionalCalculus R p
inst✝ : NonnegSpectrumClass R A
f : R → R
a : A
h : ∀ x ∈ spectrum R a, 0 ≤ f x
hf : ContinuousOn f (spectrum R a)
⊢ 0 ≤ cfc f a

case neg
R : Type u_1
A : Type u_2
p : A → Prop
inst✝¹⁵ : OrderedCommSemiring R
inst✝¹⁴ : StarRing R
inst✝¹³ : StarOrderedRing R
inst✝¹² : MetricSpace R
inst✝¹¹ : TopologicalSemiring R
inst✝¹⁰ : ContinuousStar R
inst✝⁹ : ∀ (α : Type ?u.740550) [inst : TopologicalSpace α], StarOrderedRing C(α, R)
inst✝⁸ : TopologicalSpace A
inst✝⁷ : Ring A
inst✝⁶ : StarRing A
inst✝⁵ : PartialOrder A
inst✝⁴ : StarOrderedRing A
inst✝³ : Algebra R A
inst✝² : StarModule R A
inst✝¹ : ContinuousFunctionalCalculus R p
inst✝ : NonnegSpectrumClass R A
f : R → R
a : A
h : ∀ x ∈ spectrum R a, 0 ≤ f x
hf : ¬ContinuousOn f (spectrum R a)
⊢ 0 ≤ cfc f a
tactic: by_cases hf : ContinuousOn f (spectrum R a)
Theorem: mem_ball_iff_norm''
File: Mathlib/Analysis/Normed/Group/Basic.lean

Proof steps:
state_before: 𝓕 : Type u_1
𝕜 : Type u_2
α : Type u_3
ι : Type u_4
κ : Type u_5
E : Type u_6
F : Type u_7
G : Type u_8
inst✝² : SeminormedGroup E
inst✝¹ : SeminormedGroup F
inst✝ : SeminormedGroup G
s : Set E
a a₁ a₂ b b₁ b₂ : E
r r₁ r₂ : ℝ
⊢ b ∈ ball a r ↔ ‖b / a‖ < r
state_after: no goals
tactic: rw [mem_ball, dist_eq_norm_div]
Theorem: AlgebraicGeometry.Scheme.OpenCover.pullbackCover_J
File: Mathlib/AlgebraicGeometry/Cover/Open.lean

Proof steps:
state_before: X✝ Y Z : Scheme
𝒰✝ : X✝.OpenCover
f✝ : X✝ ⟶ Z
g : Y ⟶ Z
inst✝ : ∀ (x : 𝒰✝.J), HasPullback (𝒰✝.map x ≫ f✝) g
X W : Scheme
𝒰 : X.OpenCover
f : W ⟶ X
x : ↑↑W.toPresheafedSpace
⊢ x ∈ Set.range ⇑((fun x => pullback.fst f (𝒰.map x)) ((fun x => 𝒰.f (f.val.base x)) x)).val.base
state_after: X✝ Y Z : Scheme
𝒰✝ : X✝.OpenCover
f✝ : X✝ ⟶ Z
g : Y ⟶ Z
inst✝ : ∀ (x : 𝒰✝.J), HasPullback (𝒰✝.map x ≫ f✝) g
X W : Scheme
𝒰 : X.OpenCover
f : W ⟶ X
x : ↑↑W.toPresheafedSpace
⊢ x ∈
    Set.range
      ⇑((PreservesPullback.iso forgetToTop f (𝒰.map (𝒰.f (f.val.base x)))).hom ≫
          pullback.fst (forgetToTop.map f) (forgetToTop.map (𝒰.map (𝒰.f (f.val.base x)))))
tactic: rw [←
      show _ = (pullback.fst _ _ : pullback f (𝒰.map (𝒰.f (f.1.base x))) ⟶ _).1.base from
        PreservesPullback.iso_hom_fst Scheme.forgetToTop f (𝒰.map (𝒰.f (f.1.base x)))]
state_before: X✝ Y Z : Scheme
𝒰✝ : X✝.OpenCover
f✝ : X✝ ⟶ Z
g : Y ⟶ Z
inst✝ : ∀ (x : 𝒰✝.J), HasPullback (𝒰✝.map x ≫ f✝) g
X W : Scheme
𝒰 : X.OpenCover
f : W ⟶ X
x : ↑↑W.toPresheafedSpace
⊢ x ∈
    Set.range
      ⇑((PreservesPullback.iso forgetToTop f (𝒰.map (𝒰.f (f.val.base x)))).hom ≫
          pullback.fst (forgetToTop.map f) (forgetToTop.map (𝒰.map (𝒰.f (f.val.base x)))))
state_after: X✝ Y Z : Scheme
𝒰✝ : X✝.OpenCover
f✝ : X✝ ⟶ Z
g : Y ⟶ Z
inst✝ : ∀ (x : 𝒰✝.J), HasPullback (𝒰✝.map x ≫ f✝) g
X W : Scheme
𝒰 : X.OpenCover
f : W ⟶ X
x : ↑↑W.toPresheafedSpace
⊢ x ∈ {x_1 | ∃ y, (forgetToTop.map f) x_1 = (forgetToTop.map (𝒰.map (𝒰.f (f.val.base x)))) y}

X✝ Y Z : Scheme
𝒰✝ : X✝.OpenCover
f✝ : X✝ ⟶ Z
g : Y ⟶ Z
inst✝ : ∀ (x : 𝒰✝.J), HasPullback (𝒰✝.map x ≫ f✝) g
X W : Scheme
𝒰 : X.OpenCover
f : W ⟶ X
x : ↑↑W.toPresheafedSpace
⊢ Function.Surjective ⇑(PreservesPullback.iso forgetToTop f (𝒰.map (𝒰.f (f.val.base x)))).hom
tactic: rw [TopCat.coe_comp, Set.range_comp, Set.range_iff_surjective.mpr, Set.image_univ,
      TopCat.pullback_fst_range]
Theorem: OreLocalization.mul_inv
File: Mathlib/RingTheory/OreLocalization/Basic.lean

Proof steps:
state_before: R : Type u_1
inst✝² : Monoid R
S : Submonoid R
inst✝¹ : OreSet S
X : Type ?u.97943
inst✝ : MulAction R X
s s' : ↥S
⊢ ↑s /ₒ s' * (↑s' /ₒ s) = 1
state_after: no goals
tactic: simp [oreDiv_mul_char (s : R) s' s' s 1 1 (by simp)]
Theorem: RingHom.cancel_left
File: Mathlib/Algebra/Ring/Hom/Defs.lean

Proof steps:
state_before: F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
x✝² : NonAssocSemiring α
x✝¹ : NonAssocSemiring β
x✝ : NonAssocSemiring γ
g : β →+* γ
f₁ f₂ : α →+* β
hg : Injective ⇑g
h : g.comp f₁ = g.comp f₂
x : α
⊢ g (f₁ x) = g (f₂ x)
state_after: no goals
tactic: rw [← comp_apply, h, comp_apply]
Theorem: Finset.ruzsa_triangle_inequality_mul_div_div
File: Mathlib/Combinatorics/Additive/PluenneckeRuzsa.lean

Proof steps:
state_before: α : Type u_1
inst✝¹ : CommGroup α
inst✝ : DecidableEq α
A✝ B✝ C✝ A B C : Finset α
⊢ (A * C).card * B.card ≤ (A / B).card * (B / C).card
state_after: α : Type u_1
inst✝¹ : CommGroup α
inst✝ : DecidableEq α
A✝ B✝ C✝ A B C : Finset α
⊢ (A * C).card * B⁻¹.card ≤ (A * B⁻¹).card * (B⁻¹ * C).card
tactic: rw [div_eq_mul_inv, ← card_inv B, ← card_inv (B / C), inv_div', div_inv_eq_mul]
state_before: α : Type u_1
inst✝¹ : CommGroup α
inst✝ : DecidableEq α
A✝ B✝ C✝ A B C : Finset α
⊢ (A * C).card * B⁻¹.card ≤ (A * B⁻¹).card * (B⁻¹ * C).card
state_after: no goals
tactic: exact ruzsa_triangle_inequality_mul_mul_mul _ _ _
Theorem: Cardinal.mk_preimage_of_injective_of_subset_range
File: Mathlib/SetTheory/Cardinal/Basic.lean

Proof steps:
state_before: α β : Type u
c : Cardinal.{?u.228574}
f : α → β
s : Set β
h : Injective f
h2 : s ⊆ range f
⊢ #↑(f ⁻¹' s) = #↑s
state_after: no goals
tactic: convert mk_preimage_of_injective_of_subset_range_lift.{u, u} f s h h2 using 1 <;> rw [lift_id]
Theorem: UniqueFactorizationMonoid.normalizedFactors_eq_of_dvd
File: Mathlib/RingTheory/UniqueFactorizationDomain.lean

Proof steps:
state_before: α : Type u_1
inst✝² : CancelCommMonoidWithZero α
inst✝¹ : NormalizationMonoid α
inst✝ : UniqueFactorizationMonoid α
a : α
⊢ ∀ p ∈ normalizedFactors a, ∀ q ∈ normalizedFactors a, p ∣ q → p = q
state_after: α : Type u_1
inst✝² : CancelCommMonoidWithZero α
inst✝¹ : NormalizationMonoid α
inst✝ : UniqueFactorizationMonoid α
a p : α
hp : p ∈ normalizedFactors a
q : α
hq : q ∈ normalizedFactors a
hdvd : p ∣ q
⊢ p = q
tactic: intro p hp q hq hdvd
state_before: α : Type u_1
inst✝² : CancelCommMonoidWithZero α
inst✝¹ : NormalizationMonoid α
inst✝ : UniqueFactorizationMonoid α
a p : α
hp : p ∈ normalizedFactors a
q : α
hq : q ∈ normalizedFactors a
hdvd : p ∣ q
⊢ p = q
state_after: no goals
tactic: convert normalize_eq_normalize hdvd
          ((prime_of_normalized_factor _ hp).irreducible.dvd_symm
            (prime_of_normalized_factor _ hq).irreducible hdvd) <;>
    apply (normalize_normalized_factor _ ‹_›).symm
Theorem: List.untrop_prod
File: Mathlib/Algebra/Tropical/BigOperators.lean

Proof steps:
state_before: R : Type u_1
S : Type u_2
inst✝ : AddMonoid R
l : List (Tropical R)
⊢ untrop l.prod = (map untrop l).sum
state_after: case nil
R : Type u_1
S : Type u_2
inst✝ : AddMonoid R
⊢ untrop [].prod = (map untrop []).sum

case cons
R : Type u_1
S : Type u_2
inst✝ : AddMonoid R
hd : Tropical R
tl : List (Tropical R)
IH : untrop tl.prod = (map untrop tl).sum
⊢ untrop (hd :: tl).prod = (map untrop (hd :: tl)).sum
tactic: induction' l with hd tl IH
Theorem: Nat.Coprime.dvd_of_dvd_mul_left
File: .lake/packages/batteries/Batteries/Data/Nat/Gcd.lean

Proof steps:
state_before: k m n : Nat
H1 : k.Coprime m
H2 : k ∣ m * n
⊢ k ∣ n * m
state_after: no goals
tactic: rwa [Nat.mul_comm]
Theorem: MeasureTheory.Content.sup_disjoint
File: Mathlib/MeasureTheory/Measure/Content.lean

Proof steps:
state_before: G : Type w
inst✝ : TopologicalSpace G
μ : Content G
K₁ K₂ : Compacts G
h : Disjoint ↑K₁ ↑K₂
h₁ : IsClosed ↑K₁
h₂ : IsClosed ↑K₂
⊢ (fun s => ↑(μ.toFun s)) (K₁ ⊔ K₂) = (fun s => ↑(μ.toFun s)) K₁ + (fun s => ↑(μ.toFun s)) K₂
state_after: no goals
tactic: simp [apply_eq_coe_toFun, μ.sup_disjoint' _ _ h]
Theorem: Finset.coe_ssubset
File: Mathlib/Data/Finset/Basic.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
s t s₁ s₂ : Finset α
⊢ ↑s₁ ⊂ ↑s₂ ↔ s₁ ⊆ s₂ ∧ ¬s₂ ⊆ s₁
state_after: no goals
tactic: simp only [Set.ssubset_def, Finset.coe_subset]
Theorem: NumberField.InfinitePlace.even_card_aut_of_not_isUnramifiedIn
File: Mathlib/NumberTheory/NumberField/Embeddings.lean

Proof steps:
state_before: k : Type u_1
inst✝⁹ : Field k
K : Type u_2
inst✝⁸ : Field K
F : Type u_3
inst✝⁷ : Field F
inst✝⁶ : NumberField K
inst✝⁵ : Algebra k K
inst✝⁴ : Algebra k F
inst✝³ : Algebra K F
inst✝² : IsScalarTower k K F
σ : K ≃ₐ[k] K
w✝ : InfinitePlace K
inst✝¹ : IsGalois k K
inst✝ : FiniteDimensional k K
w : InfinitePlace k
hw : ¬IsUnramifiedIn K w
⊢ Even (card (K ≃ₐ[k] K))
state_after: case intro
k : Type u_1
inst✝⁹ : Field k
K : Type u_2
inst✝⁸ : Field K
F : Type u_3
inst✝⁷ : Field F
inst✝⁶ : NumberField K
inst✝⁵ : Algebra k K
inst✝⁴ : Algebra k F
inst✝³ : Algebra K F
inst✝² : IsScalarTower k K F
σ : K ≃ₐ[k] K
w : InfinitePlace K
inst✝¹ : IsGalois k K
inst✝ : FiniteDimensional k K
v : InfinitePlace K
hw : ¬IsUnramifiedIn K ((fun x => x.comap (algebraMap k K)) v)
⊢ Even (card (K ≃ₐ[k] K))
tactic: obtain ⟨v, rfl⟩ := comap_surjective (K := K) w
state_before: case intro
k : Type u_1
inst✝⁹ : Field k
K : Type u_2
inst✝⁸ : Field K
F : Type u_3
inst✝⁷ : Field F
inst✝⁶ : NumberField K
inst✝⁵ : Algebra k K
inst✝⁴ : Algebra k F
inst✝³ : Algebra K F
inst✝² : IsScalarTower k K F
σ : K ≃ₐ[k] K
w : InfinitePlace K
inst✝¹ : IsGalois k K
inst✝ : FiniteDimensional k K
v : InfinitePlace K
hw : ¬IsUnramifiedIn K ((fun x => x.comap (algebraMap k K)) v)
⊢ Even (card (K ≃ₐ[k] K))
state_after: case intro
k : Type u_1
inst✝⁹ : Field k
K : Type u_2
inst✝⁸ : Field K
F : Type u_3
inst✝⁷ : Field F
inst✝⁶ : NumberField K
inst✝⁵ : Algebra k K
inst✝⁴ : Algebra k F
inst✝³ : Algebra K F
inst✝² : IsScalarTower k K F
σ : K ≃ₐ[k] K
w : InfinitePlace K
inst✝¹ : IsGalois k K
inst✝ : FiniteDimensional k K
v : InfinitePlace K
hw : ¬IsUnramified k v
⊢ Even (card (K ≃ₐ[k] K))
tactic: rw [isUnramifiedIn_comap] at hw
state_before: case intro
k : Type u_1
inst✝⁹ : Field k
K : Type u_2
inst✝⁸ : Field K
F : Type u_3
inst✝⁷ : Field F
inst✝⁶ : NumberField K
inst✝⁵ : Algebra k K
inst✝⁴ : Algebra k F
inst✝³ : Algebra K F
inst✝² : IsScalarTower k K F
σ : K ≃ₐ[k] K
w : InfinitePlace K
inst✝¹ : IsGalois k K
inst✝ : FiniteDimensional k K
v : InfinitePlace K
hw : ¬IsUnramified k v
⊢ Even (card (K ≃ₐ[k] K))
state_after: no goals
tactic: exact even_card_aut_of_not_isUnramified hw