ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
Theorem: Set.inj_on_of_surj_on_of_ncard_le
File: Mathlib/Data/Set/Card.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
s t✝ : Set α
f✝ : α → β
t : Set β
f : (a : α) → a ∈ s → β
hf : ∀ (a : α) (ha : a ∈ s), f a ha ∈ t
hsurj : ∀ b ∈ t, ∃ a, ∃ (ha : a ∈ s), f a ha = b
hst : s.ncard ≤ t.ncard
a₁ : α
ha₁ : a₁ ∈ s
a₂ : α
ha₂ : a₂ ∈ s
ha₁a₂ : f a₁ ha₁ = f a₂ ha₂
hs : autoParam s.Finite _auto✝
⊢ a₁ = a₂
state_after: no goals
tactic: classical
  set f' : s → t := fun x ↦ ⟨f x.1 x.2, hf _ _⟩
  have hsurj : f'.Surjective := by
    rintro ⟨y, hy⟩
    obtain ⟨a, ha, rfl⟩ := hsurj y hy
    simp only [Subtype.mk.injEq, Subtype.exists]
    exact ⟨_, ha, rfl⟩
  haveI := hs.fintype
  haveI := Fintype.ofSurjective _ hsurj
  set f'' : ∀ a, a ∈ s.toFinset → β := fun a h ↦ f a (by simpa using h)
  exact
    @Finset.inj_on_of_surj_on_of_card_le _ _ _ t.toFinset f''
      (fun a ha ↦ by { rw [mem_toFinset] at ha ⊢; exact hf a ha }) (by simpa)
      (by { rwa [← ncard_eq_toFinset_card', ← ncard_eq_toFinset_card'] }) a₁
      (by simpa) a₂ (by simpa) (by simpa)
Theorem: preNormEDS_even
File: Mathlib/NumberTheory/EllipticDivisibilitySequence.lean

Proof steps:
state_before: R : Type u
S : Type v
inst✝¹ : CommRing R
inst✝ : CommRing S
W : ℤ → R
f : R →+* S
b c d : R
m : ℕ
⊢ preNormEDS b c d (2 * (↑m + 3)) =
    preNormEDS b c d (↑m + 2) ^ 2 * preNormEDS b c d (↑m + 3) * preNormEDS b c d (↑m + 5) -
      preNormEDS b c d (↑m + 1) * preNormEDS b c d (↑m + 3) * preNormEDS b c d (↑m + 4) ^ 2
state_after: R : Type u
S : Type v
inst✝¹ : CommRing R
inst✝ : CommRing S
W : ℤ → R
f : R →+* S
b c d : R
m : ℕ
⊢ preNormEDS' b c d (2 * (m + 3)) =
    preNormEDS' b c d (m + 2) ^ 2 * preNormEDS' b c d (m + 3) * preNormEDS' b c d (m + 5) -
      preNormEDS' b c d (m + 1) * preNormEDS' b c d (m + 3) * preNormEDS' b c d (m + 4) ^ 2
tactic: repeat erw [preNormEDS_ofNat]
state_before: R : Type u
S : Type v
inst✝¹ : CommRing R
inst✝ : CommRing S
W : ℤ → R
f : R →+* S
b c d : R
m : ℕ
⊢ preNormEDS' b c d (2 * (m + 3)) =
    preNormEDS' b c d (m + 2) ^ 2 * preNormEDS' b c d (m + 3) * preNormEDS' b c d (m + 5) -
      preNormEDS' b c d (m + 1) * preNormEDS' b c d (m + 3) * preNormEDS' b c d (m + 4) ^ 2
state_after: no goals
tactic: exact preNormEDS'_even ..
Theorem: finsum_mem_sub_distrib
File: Mathlib/Algebra/BigOperators/Finprod.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
ι : Type u_3
G : Type u_4
M : Type u_5
N : Type u_6
inst✝² : CommMonoid M
inst✝¹ : CommMonoid N
f✝ g✝ : α → M
a b : α
s t : Set α
inst✝ : DivisionCommMonoid G
f g : α → G
hs : s.Finite
⊢ ∏ᶠ (i : α) (_ : i ∈ s), f i / g i = (∏ᶠ (i : α) (_ : i ∈ s), f i) / ∏ᶠ (i : α) (_ : i ∈ s), g i
state_after: no goals
tactic: simp only [div_eq_mul_inv, finprod_mem_mul_distrib hs, finprod_mem_inv_distrib g hs]
Theorem: nhdsWithin_Iic_basis'
File: Mathlib/Topology/Order/Basic.lean

Proof steps:
state_before: α : Type u
β : Type v
γ : Type w
inst✝² : TopologicalSpace α
inst✝¹ : LinearOrder α
inst✝ : OrderTopology α
a : α
ha : ∃ l, l < a
⊢ (𝓝[≤] a).HasBasis (fun l => l < a) fun l => Ioc l a
state_after: case h.e'_5.h.h
α : Type u
β : Type v
γ : Type w
inst✝² : TopologicalSpace α
inst✝¹ : LinearOrder α
inst✝ : OrderTopology α
a : α
ha : ∃ l, l < a
e_1✝ : α = αᵒᵈ
x✝ : α
⊢ Ioc x✝ a = Ico a x✝
tactic: convert nhdsWithin_Ici_basis' (α := αᵒᵈ) ha using 2
state_before: case h.e'_5.h.h
α : Type u
β : Type v
γ : Type w
inst✝² : TopologicalSpace α
inst✝¹ : LinearOrder α
inst✝ : OrderTopology α
a : α
ha : ∃ l, l < a
e_1✝ : α = αᵒᵈ
x✝ : α
⊢ Ioc x✝ a = Ico a x✝
state_after: no goals
tactic: exact dual_Ico.symm
Theorem: sub_smul_slope
File: Mathlib/LinearAlgebra/AffineSpace/Slope.lean

Proof steps:
state_before: k : Type u_1
E : Type u_2
PE : Type u_3
inst✝³ : Field k
inst✝² : AddCommGroup E
inst✝¹ : Module k E
inst✝ : AddTorsor E PE
f : k → PE
a b : k
⊢ (b - a) • slope f a b = f b -ᵥ f a
state_after: case inl
k : Type u_1
E : Type u_2
PE : Type u_3
inst✝³ : Field k
inst✝² : AddCommGroup E
inst✝¹ : Module k E
inst✝ : AddTorsor E PE
f : k → PE
a : k
⊢ (a - a) • slope f a a = f a -ᵥ f a

case inr
k : Type u_1
E : Type u_2
PE : Type u_3
inst✝³ : Field k
inst✝² : AddCommGroup E
inst✝¹ : Module k E
inst✝ : AddTorsor E PE
f : k → PE
a b : k
hne : a ≠ b
⊢ (b - a) • slope f a b = f b -ᵥ f a
tactic: rcases eq_or_ne a b with (rfl | hne)
Theorem: Dioph.div_dioph
File: Mathlib/NumberTheory/Dioph.lean

Proof steps:
state_before: α β : Type
n : ℕ
f g : (α → ℕ) → ℕ
df : DiophFn f
dg : DiophFn g
this : Dioph fun v => v &2 = 0 ∧ v &0 = 0 ∨ v &0 * v &2 ≤ v &1 ∧ v &1 < (v &0 + 1) * v &2
z x y : ℕ
⊢ y = 0 ∧ z = 0 ∨ z * y ≤ x ∧ x < (z + 1) * y ↔ x / y = z
state_after: α β : Type
n : ℕ
f g : (α → ℕ) → ℕ
df : DiophFn f
dg : DiophFn g
this : Dioph fun v => v &2 = 0 ∧ v &0 = 0 ∨ v &0 * v &2 ≤ v &1 ∧ v &1 < (v &0 + 1) * v &2
z x y : ℕ
⊢ y = 0 ∧ z = 0 ∨ z * y ≤ x ∧ x < (z + 1) * y ↔ z = x / y
tactic: refine Iff.trans ?_ eq_comm
state_before: α β : Type
n : ℕ
f g : (α → ℕ) → ℕ
df : DiophFn f
dg : DiophFn g
this : Dioph fun v => v &2 = 0 ∧ v &0 = 0 ∨ v &0 * v &2 ≤ v &1 ∧ v &1 < (v &0 + 1) * v &2
z x y : ℕ
⊢ y = 0 ∧ z = 0 ∨ z * y ≤ x ∧ x < (z + 1) * y ↔ z = x / y
state_after: no goals
tactic: exact y.eq_zero_or_pos.elim
              (fun y0 => by
                rw [y0, Nat.div_zero]
                exact ⟨fun o => (o.resolve_right fun ⟨_, h2⟩ => Nat.not_lt_zero _ h2).right,
                  fun z0 => Or.inl ⟨rfl, z0⟩⟩)
              fun ypos =>
                Iff.trans ⟨fun o => o.resolve_left fun ⟨h1, _⟩ => Nat.ne_of_gt ypos h1, Or.inr⟩
                  (le_antisymm_iff.trans <| and_congr (Nat.le_div_iff_mul_le ypos) <|
                    Iff.trans ⟨lt_succ_of_le, le_of_lt_succ⟩ (div_lt_iff_lt_mul ypos)).symm
Theorem: groupCohomology.resolution.quasiIso_forget₂_εToSingle₀
File: Mathlib/RepresentationTheory/GroupCohomology/Resolution.lean

Proof steps:
state_before: k G : Type u
inst✝¹ : CommRing k
n : ℕ
inst✝ : Monoid G
⊢ QuasiIso (((forget₂ (Rep k G) (ModuleCat k)).mapHomologicalComplex (ComplexShape.down ℕ)).map (εToSingle₀ k G))
state_after: k G : Type u
inst✝¹ : CommRing k
n : ℕ
inst✝ : Monoid G
h : QuasiIso (forget₂ToModuleCatHomotopyEquiv k G).hom
⊢ QuasiIso (((forget₂ (Rep k G) (ModuleCat k)).mapHomologicalComplex (ComplexShape.down ℕ)).map (εToSingle₀ k G))
tactic: have h : QuasiIso (forget₂ToModuleCatHomotopyEquiv k G).hom := inferInstance
state_before: k G : Type u
inst✝¹ : CommRing k
n : ℕ
inst✝ : Monoid G
h : QuasiIso (forget₂ToModuleCatHomotopyEquiv k G).hom
⊢ QuasiIso (((forget₂ (Rep k G) (ModuleCat k)).mapHomologicalComplex (ComplexShape.down ℕ)).map (εToSingle₀ k G))
state_after: k G : Type u
inst✝¹ : CommRing k
n : ℕ
inst✝ : Monoid G
h :
  QuasiIso
    (((forget₂ (Rep k G) (ModuleCat k)).mapHomologicalComplex (ComplexShape.down ℕ)).map (εToSingle₀ k G) ≫
      (HomologicalComplex.singleMapHomologicalComplex (forget₂ (Rep k G) (ModuleCat k)) (ComplexShape.down ℕ) 0).hom.app
        (Rep.trivial k G k))
⊢ QuasiIso (((forget₂ (Rep k G) (ModuleCat k)).mapHomologicalComplex (ComplexShape.down ℕ)).map (εToSingle₀ k G))
tactic: rw [← εToSingle₀_comp_eq k G] at h
state_before: k G : Type u
inst✝¹ : CommRing k
n : ℕ
inst✝ : Monoid G
h :
  QuasiIso
    (((forget₂ (Rep k G) (ModuleCat k)).mapHomologicalComplex (ComplexShape.down ℕ)).map (εToSingle₀ k G) ≫
      (HomologicalComplex.singleMapHomologicalComplex (forget₂ (Rep k G) (ModuleCat k)) (ComplexShape.down ℕ) 0).hom.app
        (Rep.trivial k G k))
⊢ QuasiIso (((forget₂ (Rep k G) (ModuleCat k)).mapHomologicalComplex (ComplexShape.down ℕ)).map (εToSingle₀ k G))
state_after: no goals
tactic: exact quasiIso_of_comp_right (hφφ' := h)
Theorem: Real.BohrMollerup.tendsto_log_gamma
File: Mathlib/Analysis/SpecialFunctions/Gamma/BohrMollerup.lean

Proof steps:
state_before: f : ℝ → ℝ
x✝ : ℝ
n : ℕ
x : ℝ
hx : 0 < x
⊢ Tendsto (logGammaSeq x) atTop (𝓝 (log (Gamma x)))
state_after: f : ℝ → ℝ
x✝ : ℝ
n : ℕ
x : ℝ
hx : 0 < x
this : log (Gamma x) = (log ∘ Gamma) x - (log ∘ Gamma) 1
⊢ Tendsto (logGammaSeq x) atTop (𝓝 (log (Gamma x)))
tactic: have : log (Gamma x) = (log ∘ Gamma) x - (log ∘ Gamma) 1 := by
    simp_rw [Function.comp_apply, Gamma_one, log_one, sub_zero]
state_before: f : ℝ → ℝ
x✝ : ℝ
n : ℕ
x : ℝ
hx : 0 < x
this : log (Gamma x) = (log ∘ Gamma) x - (log ∘ Gamma) 1
⊢ Tendsto (logGammaSeq x) atTop (𝓝 (log (Gamma x)))
state_after: f : ℝ → ℝ
x✝ : ℝ
n : ℕ
x : ℝ
hx : 0 < x
this : log (Gamma x) = (log ∘ Gamma) x - (log ∘ Gamma) 1
⊢ Tendsto (logGammaSeq x) atTop (𝓝 ((log ∘ Gamma) x - (log ∘ Gamma) 1))
tactic: rw [this]
state_before: f : ℝ → ℝ
x✝ : ℝ
n : ℕ
x : ℝ
hx : 0 < x
this : log (Gamma x) = (log ∘ Gamma) x - (log ∘ Gamma) 1
⊢ Tendsto (logGammaSeq x) atTop (𝓝 ((log ∘ Gamma) x - (log ∘ Gamma) 1))
state_after: f : ℝ → ℝ
x✝ : ℝ
n : ℕ
x : ℝ
hx : 0 < x
this : log (Gamma x) = (log ∘ Gamma) x - (log ∘ Gamma) 1
y : ℝ
hy : 0 < y
⊢ (log ∘ Gamma) (y + 1) = (log ∘ Gamma) y + log y
tactic: refine BohrMollerup.tendsto_logGammaSeq convexOn_log_Gamma (fun {y} hy => ?_) hx
state_before: f : ℝ → ℝ
x✝ : ℝ
n : ℕ
x : ℝ
hx : 0 < x
this : log (Gamma x) = (log ∘ Gamma) x - (log ∘ Gamma) 1
y : ℝ
hy : 0 < y
⊢ (log ∘ Gamma) (y + 1) = (log ∘ Gamma) y + log y
state_after: no goals
tactic: rw [Function.comp_apply, Gamma_add_one hy.ne', log_mul hy.ne' (Gamma_pos_of_pos hy).ne', add_comm,
    Function.comp_apply]
Theorem: leOnePart_le_one'
File: Mathlib/Algebra/Order/Group/PosPart.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
inst✝¹ : Lattice α
inst✝ : Group α
a : α
⊢ a⁻ᵐ ≤ 1 ↔ a⁻¹ ≤ 1
state_after: no goals
tactic: simp [leOnePart]
Theorem: ProbabilityTheory.IsRatCondKernelCDFAux.tendsto_one_of_monotone
File: Mathlib/Probability/Kernel/Disintegration/CdfToKernel.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
mα : MeasurableSpace α
mβ : MeasurableSpace β
κ : Kernel α (β × ℝ)
ν : Kernel α β
f : α × β → ℚ → ℝ
hf : IsRatCondKernelCDFAux f κ ν
inst✝ : IsFiniteKernel ν
a : α
seq : ℕ → ℚ
hseq : Monotone seq
hseq_tendsto : Tendsto seq atTop atTop
⊢ ∀ᵐ (c : β) ∂ν a, Tendsto (fun m => f (a, c) (seq m)) atTop (𝓝 1)
state_after: case refine_1
α : Type u_1
β : Type u_2
mα : MeasurableSpace α
mβ : MeasurableSpace β
κ : Kernel α (β × ℝ)
ν : Kernel α β
f : α × β → ℚ → ℝ
hf : IsRatCondKernelCDFAux f κ ν
inst✝ : IsFiniteKernel ν
a : α
seq : ℕ → ℚ
hseq : Monotone seq
hseq_tendsto : Tendsto seq atTop atTop
⊢ ∀ (n : ℕ), Integrable (fun c => f (a, c) (seq n)) (ν a)

case refine_2
α : Type u_1
β : Type u_2
mα : MeasurableSpace α
mβ : MeasurableSpace β
κ : Kernel α (β × ℝ)
ν : Kernel α β
f : α × β → ℚ → ℝ
hf : IsRatCondKernelCDFAux f κ ν
inst✝ : IsFiniteKernel ν
a : α
seq : ℕ → ℚ
hseq : Monotone seq
hseq_tendsto : Tendsto seq atTop atTop
⊢ Tendsto (fun i => ∫ (a_1 : β), f (a, a_1) (seq i) ∂ν a) atTop (𝓝 (∫ (a : β), 1 ∂ν a))

case refine_3
α : Type u_1
β : Type u_2
mα : MeasurableSpace α
mβ : MeasurableSpace β
κ : Kernel α (β × ℝ)
ν : Kernel α β
f : α × β → ℚ → ℝ
hf : IsRatCondKernelCDFAux f κ ν
inst✝ : IsFiniteKernel ν
a : α
seq : ℕ → ℚ
hseq : Monotone seq
hseq_tendsto : Tendsto seq atTop atTop
⊢ ∀ᵐ (a_1 : β) ∂ν a, Monotone fun i => f (a, a_1) (seq i)

case refine_4
α : Type u_1
β : Type u_2
mα : MeasurableSpace α
mβ : MeasurableSpace β
κ : Kernel α (β × ℝ)
ν : Kernel α β
f : α × β → ℚ → ℝ
hf : IsRatCondKernelCDFAux f κ ν
inst✝ : IsFiniteKernel ν
a : α
seq : ℕ → ℚ
hseq : Monotone seq
hseq_tendsto : Tendsto seq atTop atTop
⊢ ∀ᵐ (a_1 : β) ∂ν a, ∀ (i : ℕ), f (a, a_1) (seq i) ≤ 1
tactic: refine tendsto_of_integral_tendsto_of_monotone ?_ (integrable_const _) ?_ ?_ ?_
Theorem: mulRothNumber_union_le
File: Mathlib/Combinatorics/Additive/AP/Three/Defs.lean

Proof steps:
state_before: F : Type u_1
α : Type u_2
β : Type u_3
𝕜 : Type u_4
E : Type u_5
inst✝³ : DecidableEq α
inst✝² : Monoid α
inst✝¹ : DecidableEq β
inst✝ : Monoid β
s✝ t✝ : Finset α
n : ℕ
s t u : Finset α
hus : u ⊆ s ∪ t
hcard : u.card = mulRothNumber (s ∪ t)
hu : ThreeGPFree ↑u
⊢ u.card = (u ∩ s ∪ u ∩ t).card
state_after: no goals
tactic: rw [← inter_union_distrib_left, inter_eq_left.2 hus]
Theorem: HasLineDerivWithinAt.mono_of_mem
File: Mathlib/Analysis/Calculus/LineDeriv/Basic.lean

Proof steps:
state_before: 𝕜 : Type u_1
inst✝⁴ : NontriviallyNormedField 𝕜
F : Type u_2
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
E : Type u_3
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
f f₀ f₁ : E → F
f' : F
s t : Set E
x v : E
L : E →L[𝕜] F
h : HasLineDerivWithinAt 𝕜 f f' t x v
hst : t ∈ 𝓝[s] x
⊢ HasLineDerivWithinAt 𝕜 f f' s x v
state_after: 𝕜 : Type u_1
inst✝⁴ : NontriviallyNormedField 𝕜
F : Type u_2
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
E : Type u_3
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
f f₀ f₁ : E → F
f' : F
s t : Set E
x v : E
L : E →L[𝕜] F
h : HasLineDerivWithinAt 𝕜 f f' t x v
hst : t ∈ 𝓝[s] x
⊢ (fun t => x + t • v) ⁻¹' t ∈ 𝓝[(fun t => x + t • v) ⁻¹' s] 0
tactic: apply HasDerivWithinAt.mono_of_mem h
state_before: 𝕜 : Type u_1
inst✝⁴ : NontriviallyNormedField 𝕜
F : Type u_2
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
E : Type u_3
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
f f₀ f₁ : E → F
f' : F
s t : Set E
x v : E
L : E →L[𝕜] F
h : HasLineDerivWithinAt 𝕜 f f' t x v
hst : t ∈ 𝓝[s] x
⊢ (fun t => x + t • v) ⁻¹' t ∈ 𝓝[(fun t => x + t • v) ⁻¹' s] 0
state_after: 𝕜 : Type u_1
inst✝⁴ : NontriviallyNormedField 𝕜
F : Type u_2
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
E : Type u_3
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
f f₀ f₁ : E → F
f' : F
s t : Set E
x v : E
L : E →L[𝕜] F
h : HasLineDerivWithinAt 𝕜 f f' t x v
hst : t ∈ 𝓝[s] x
⊢ ContinuousWithinAt (fun t => x + t • v) ((fun t => x + t • v) ⁻¹' s) 0
tactic: apply ContinuousWithinAt.preimage_mem_nhdsWithin'' _ hst (by simp)
state_before: 𝕜 : Type u_1
inst✝⁴ : NontriviallyNormedField 𝕜
F : Type u_2
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
E : Type u_3
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
f f₀ f₁ : E → F
f' : F
s t : Set E
x v : E
L : E →L[𝕜] F
h : HasLineDerivWithinAt 𝕜 f f' t x v
hst : t ∈ 𝓝[s] x
⊢ ContinuousWithinAt (fun t => x + t • v) ((fun t => x + t • v) ⁻¹' s) 0
state_after: case h
𝕜 : Type u_1
inst✝⁴ : NontriviallyNormedField 𝕜
F : Type u_2
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
E : Type u_3
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
f f₀ f₁ : E → F
f' : F
s t : Set E
x v : E
L : E →L[𝕜] F
h : HasLineDerivWithinAt 𝕜 f f' t x v
hst : t ∈ 𝓝[s] x
⊢ Continuous fun t => x + t • v
tactic: apply Continuous.continuousWithinAt
state_before: case h
𝕜 : Type u_1
inst✝⁴ : NontriviallyNormedField 𝕜
F : Type u_2
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
E : Type u_3
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
f f₀ f₁ : E → F
f' : F
s t : Set E
x v : E
L : E →L[𝕜] F
h : HasLineDerivWithinAt 𝕜 f f' t x v
hst : t ∈ 𝓝[s] x
⊢ Continuous fun t => x + t • v
state_after: no goals
tactic: fun_prop
Theorem: MeasureTheory.integral_sub
File: Mathlib/MeasureTheory/Integral/Bochner.lean

Proof steps:
state_before: α : Type u_1
E : Type u_2
F : Type u_3
𝕜 : Type u_4
inst✝⁹ : NormedAddCommGroup E
inst✝⁸ : NormedSpace ℝ E
hE : CompleteSpace E
inst✝⁷ : NontriviallyNormedField 𝕜
inst✝⁶ : NormedSpace 𝕜 E
inst✝⁵ : SMulCommClass ℝ 𝕜 E
inst✝⁴ : NormedAddCommGroup F
inst✝³ : NormedSpace ℝ F
inst✝² : CompleteSpace F
G : Type u_5
inst✝¹ : NormedAddCommGroup G
inst✝ : NormedSpace ℝ G
f✝ g✝ : α → E
m : MeasurableSpace α
μ : Measure α
f g : α → G
hf : Integrable f μ
hg : Integrable g μ
⊢ ∫ (a : α), f a - g a ∂μ = ∫ (a : α), f a ∂μ - ∫ (a : α), g a ∂μ
state_after: case pos
α : Type u_1
E : Type u_2
F : Type u_3
𝕜 : Type u_4
inst✝⁹ : NormedAddCommGroup E
inst✝⁸ : NormedSpace ℝ E
hE : CompleteSpace E
inst✝⁷ : NontriviallyNormedField 𝕜
inst✝⁶ : NormedSpace 𝕜 E
inst✝⁵ : SMulCommClass ℝ 𝕜 E
inst✝⁴ : NormedAddCommGroup F
inst✝³ : NormedSpace ℝ F
inst✝² : CompleteSpace F
G : Type u_5
inst✝¹ : NormedAddCommGroup G
inst✝ : NormedSpace ℝ G
f✝ g✝ : α → E
m : MeasurableSpace α
μ : Measure α
f g : α → G
hf : Integrable f μ
hg : Integrable g μ
hG : CompleteSpace G
⊢ ∫ (a : α), f a - g a ∂μ = ∫ (a : α), f a ∂μ - ∫ (a : α), g a ∂μ

case neg
α : Type u_1
E : Type u_2
F : Type u_3
𝕜 : Type u_4
inst✝⁹ : NormedAddCommGroup E
inst✝⁸ : NormedSpace ℝ E
hE : CompleteSpace E
inst✝⁷ : NontriviallyNormedField 𝕜
inst✝⁶ : NormedSpace 𝕜 E
inst✝⁵ : SMulCommClass ℝ 𝕜 E
inst✝⁴ : NormedAddCommGroup F
inst✝³ : NormedSpace ℝ F
inst✝² : CompleteSpace F
G : Type u_5
inst✝¹ : NormedAddCommGroup G
inst✝ : NormedSpace ℝ G
f✝ g✝ : α → E
m : MeasurableSpace α
μ : Measure α
f g : α → G
hf : Integrable f μ
hg : Integrable g μ
hG : ¬CompleteSpace G
⊢ ∫ (a : α), f a - g a ∂μ = ∫ (a : α), f a ∂μ - ∫ (a : α), g a ∂μ
tactic: by_cases hG : CompleteSpace G
Theorem: Pell.isPell_mul
File: Mathlib/NumberTheory/PellMatiyasevic.lean

Proof steps:
state_before: d : ℤ
b c : ℤ√d
hb : IsPell b
hc : IsPell c
⊢ b * c * star (b * c) = 1
state_after: no goals
tactic: simp [mul_comm, mul_left_comm c, mul_assoc,
    star_mul, isPell_norm.1 hb, isPell_norm.1 hc]
Theorem: Polynomial.eval_geom_sum
File: Mathlib/Algebra/Polynomial/Eval.lean

Proof steps:
state_before: R✝ : Type u
S : Type v
T : Type w
ι : Type y
a b : R✝
m n✝ : ℕ
inst✝² : CommSemiring R✝
p q : R✝[X]
x✝ : R✝
inst✝¹ : CommSemiring S
f : R✝ →+* S
R : Type u_1
inst✝ : CommSemiring R
n : ℕ
x : R
⊢ eval x (∑ i ∈ range n, X ^ i) = ∑ i ∈ range n, x ^ i
state_after: no goals
tactic: simp [eval_finset_sum]
Theorem: DiscreteValuationRing.unit_mul_pow_congr_unit
File: Mathlib/RingTheory/DiscreteValuationRing/Basic.lean

Proof steps:
state_before: R : Type u_1
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : DiscreteValuationRing R
ϖ : R
hirr : Irreducible ϖ
u v : Rˣ
m n : ℕ
h : ↑u * ϖ ^ m = ↑v * ϖ ^ n
⊢ u = v
state_after: R : Type u_1
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : DiscreteValuationRing R
ϖ : R
hirr : Irreducible ϖ
u v : Rˣ
m : ℕ
h : ↑u * ϖ ^ m = ↑v * ϖ ^ m
⊢ u = v
tactic: obtain rfl : m = n := unit_mul_pow_congr_pow hirr hirr u v m n h
state_before: R : Type u_1
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : DiscreteValuationRing R
ϖ : R
hirr : Irreducible ϖ
u v : Rˣ
m : ℕ
h : ↑u * ϖ ^ m = ↑v * ϖ ^ m
⊢ u = v
state_after: R : Type u_1
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : DiscreteValuationRing R
ϖ : R
hirr : Irreducible ϖ
u v : Rˣ
m : ℕ
h : ↑u * ϖ ^ m - ↑v * ϖ ^ m = 0
⊢ u = v
tactic: rw [← sub_eq_zero] at h
state_before: R : Type u_1
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : DiscreteValuationRing R
ϖ : R
hirr : Irreducible ϖ
u v : Rˣ
m : ℕ
h : ↑u * ϖ ^ m - ↑v * ϖ ^ m = 0
⊢ u = v
state_after: R : Type u_1
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : DiscreteValuationRing R
ϖ : R
hirr : Irreducible ϖ
u v : Rˣ
m : ℕ
h : ↑u - ↑v = 0 ∨ ϖ ^ m = 0
⊢ u = v
tactic: rw [← sub_mul, mul_eq_zero] at h
state_before: R : Type u_1
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : DiscreteValuationRing R
ϖ : R
hirr : Irreducible ϖ
u v : Rˣ
m : ℕ
h : ↑u - ↑v = 0 ∨ ϖ ^ m = 0
⊢ u = v
state_after: case inl
R : Type u_1
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : DiscreteValuationRing R
ϖ : R
hirr : Irreducible ϖ
u v : Rˣ
m : ℕ
h : ↑u - ↑v = 0
⊢ u = v

case inr
R : Type u_1
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : DiscreteValuationRing R
ϖ : R
hirr : Irreducible ϖ
u v : Rˣ
m : ℕ
h : ϖ ^ m = 0
⊢ u = v
tactic: cases' h with h h
Theorem: MeasureTheory.integrableOn_Ioi_deriv_of_nonneg'
File: Mathlib/MeasureTheory/Integral/IntegralEqImproper.lean

Proof steps:
state_before: E : Type u_1
f f' : ℝ → E
g g' : ℝ → ℝ
a b l : ℝ
m : E
inst✝² : NormedAddCommGroup E
inst✝¹ : NormedSpace ℝ E
inst✝ : CompleteSpace E
hderiv : ∀ x ∈ Ici a, HasDerivAt g (g' x) x
g'pos : ∀ x ∈ Ioi a, 0 ≤ g' x
hg : Tendsto g atTop (𝓝 l)
⊢ IntegrableOn g' (Ioi a) volume
state_after: E : Type u_1
f f' : ℝ → E
g g' : ℝ → ℝ
a b l : ℝ
m : E
inst✝² : NormedAddCommGroup E
inst✝¹ : NormedSpace ℝ E
inst✝ : CompleteSpace E
hderiv : ∀ x ∈ Ici a, HasDerivAt g (g' x) x
g'pos : ∀ x ∈ Ioi a, 0 ≤ g' x
hg : Tendsto g atTop (𝓝 l)
⊢ ContinuousWithinAt g (Ici a) a
tactic: refine integrableOn_Ioi_deriv_of_nonneg ?_ (fun x hx => hderiv x hx.out.le) g'pos hg
state_before: E : Type u_1
f f' : ℝ → E
g g' : ℝ → ℝ
a b l : ℝ
m : E
inst✝² : NormedAddCommGroup E
inst✝¹ : NormedSpace ℝ E
inst✝ : CompleteSpace E
hderiv : ∀ x ∈ Ici a, HasDerivAt g (g' x) x
g'pos : ∀ x ∈ Ioi a, 0 ≤ g' x
hg : Tendsto g atTop (𝓝 l)
⊢ ContinuousWithinAt g (Ici a) a
state_after: no goals
tactic: exact (hderiv a left_mem_Ici).continuousAt.continuousWithinAt
Theorem: CategoryTheory.Limits.biprod.symmetry'
File: Mathlib/CategoryTheory/Limits/Shapes/Biproducts.lean

Proof steps:
state_before: J : Type w
C : Type u
inst✝⁴ : Category.{v, u} C
inst✝³ : HasZeroMorphisms C
D : Type uD
inst✝² : Category.{uD', uD} D
inst✝¹ : HasZeroMorphisms D
P✝ Q✝ : C
inst✝ : HasBinaryBiproducts C
P Q : C
⊢ lift snd fst ≫ lift snd fst = 𝟙 (P ⊞ Q)
state_after: no goals
tactic: aesop_cat
Theorem: SimpleGraph.dist_self
File: Mathlib/Combinatorics/SimpleGraph/Metric.lean

Proof steps:
state_before: V : Type u_1
G : SimpleGraph V
u v w : V
⊢ G.dist v v = 0
state_after: no goals
tactic: simp
Theorem: Zsqrtd.coprime_of_dvd_coprime
File: Mathlib/NumberTheory/Zsqrtd/Basic.lean

Proof steps:
state_before: d : ℤ
a b : ℤ√d
hcoprime : IsCoprime a.re a.im
hdvd : b ∣ a
⊢ IsCoprime b.re b.im
state_after: case nonzero
d : ℤ
a b : ℤ√d
hcoprime : IsCoprime a.re a.im
hdvd : b ∣ a
⊢ ¬(b.re = 0 ∧ b.im = 0)

case H
d : ℤ
a b : ℤ√d
hcoprime : IsCoprime a.re a.im
hdvd : b ∣ a
⊢ ∀ z ∈ nonunits ℤ, z ≠ 0 → z ∣ b.re → ¬z ∣ b.im
tactic: apply isCoprime_of_dvd
Theorem: preimage_add_ball
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✝¹ : SeminormedCommGroup E
inst✝ : SeminormedCommGroup F
a✝ a₁ a₂ b✝ b₁ b₂ : E
r✝ r₁ r₂ : ℝ
a b : E
r : ℝ
⊢ (fun x => b * x) ⁻¹' ball a r = ball (a / b) r
state_after: case h
𝓕 : 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✝¹ : SeminormedCommGroup E
inst✝ : SeminormedCommGroup F
a✝ a₁ a₂ b✝ b₁ b₂ : E
r✝ r₁ r₂ : ℝ
a b : E
r : ℝ
c : E
⊢ c ∈ (fun x => b * x) ⁻¹' ball a r ↔ c ∈ ball (a / b) r
tactic: ext c
state_before: case h
𝓕 : 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✝¹ : SeminormedCommGroup E
inst✝ : SeminormedCommGroup F
a✝ a₁ a₂ b✝ b₁ b₂ : E
r✝ r₁ r₂ : ℝ
a b : E
r : ℝ
c : E
⊢ c ∈ (fun x => b * x) ⁻¹' ball a r ↔ c ∈ ball (a / b) r
state_after: no goals
tactic: simp only [dist_eq_norm_div, Set.mem_preimage, mem_ball, div_div_eq_mul_div, mul_comm]
Theorem: SimpleGraph.Colorable.of_embedding
File: Mathlib/Combinatorics/SimpleGraph/Coloring.lean

Proof steps:
state_before: V : Type u
G : SimpleGraph V
n✝ : ℕ
α : Type u_1
β : Type u_2
C : G.Coloring α
V' : Type u_3
G' : SimpleGraph V'
f : G ↪g G'
n : ℕ
h : G'.Colorable n
⊢ n ≤ card (Fin n)
state_after: no goals
tactic: simp
Theorem: MvPolynomial.finSuccEquiv_eq
File: Mathlib/Algebra/MvPolynomial/Equiv.lean

Proof steps:
state_before: R : Type u
S₁ : Type v
S₂ : Type w
S₃ : Type x
σ : Type u_1
a a' a₁ a₂ : R
e : ℕ
s : σ →₀ ℕ
inst✝ : CommSemiring R
n : ℕ
⊢ ↑(finSuccEquiv R n) = eval₂Hom (Polynomial.C.comp C) fun i => Fin.cases Polynomial.X (fun k => Polynomial.C (X k)) i
state_after: case hC.a
R : Type u
S₁ : Type v
S₂ : Type w
S₃ : Type x
σ : Type u_1
a a' a₁ a₂ : R
e : ℕ
s : σ →₀ ℕ
inst✝ : CommSemiring R
n : ℕ
i : R
⊢ ((↑(finSuccEquiv R n)).comp C) i =
    ((eval₂Hom (Polynomial.C.comp C) fun i => Fin.cases Polynomial.X (fun k => Polynomial.C (X k)) i).comp C) i

case hX.a
R : Type u
S₁ : Type v
S₂ : Type w
S₃ : Type x
σ : Type u_1
a a' a₁ a₂ : R
e : ℕ
s : σ →₀ ℕ
inst✝ : CommSemiring R
n : ℕ
i : Fin (n + 1)
n✝ : ℕ
⊢ (↑(finSuccEquiv R n) (X i)).coeff n✝ =
    ((eval₂Hom (Polynomial.C.comp C) fun i => Fin.cases Polynomial.X (fun k => Polynomial.C (X k)) i) (X i)).coeff n✝
tactic: ext i : 2