ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
Theorem: CategoryTheory.MonoidalCategory.tensor_id_comp_id_tensor
File: Mathlib/CategoryTheory/Monoidal/Category.lean

Proof steps:
state_before: C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
f : W ⟶ X
g : Y ⟶ Z
⊢ (g ⊗ 𝟙 W) ≫ (𝟙 Z ⊗ f) = g ⊗ f
state_after: C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
f : W ⟶ X
g : Y ⟶ Z
⊢ g ≫ 𝟙 Z ⊗ 𝟙 W ≫ f = g ⊗ f
tactic: rw [← tensor_comp]
state_before: C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
f : W ⟶ X
g : Y ⟶ Z
⊢ g ≫ 𝟙 Z ⊗ 𝟙 W ≫ f = g ⊗ f
state_after: no goals
tactic: simp
Theorem: lt_or_lt_of_sub_lt_sub
File: Mathlib/Algebra/Order/Group/Unbundled/Basic.lean

Proof steps:
state_before: α : Type u
inst✝² : CommGroup α
inst✝¹ : LinearOrder α
inst✝ : CovariantClass α α (fun x x_1 => x * x_1) fun x x_1 => x ≤ x_1
a b c d : α
⊢ a / d < b / c → a < b ∨ c < d
state_after: α : Type u
inst✝² : CommGroup α
inst✝¹ : LinearOrder α
inst✝ : CovariantClass α α (fun x x_1 => x * x_1) fun x x_1 => x ≤ x_1
a b c d : α
⊢ b ≤ a ∧ d ≤ c → b / c ≤ a / d
tactic: contrapose!
state_before: α : Type u
inst✝² : CommGroup α
inst✝¹ : LinearOrder α
inst✝ : CovariantClass α α (fun x x_1 => x * x_1) fun x x_1 => x ≤ x_1
a b c d : α
⊢ b ≤ a ∧ d ≤ c → b / c ≤ a / d
state_after: no goals
tactic: exact fun h ↦ div_le_div'' h.1 h.2
Theorem: ProbabilityTheory.IndepFun.mgf_add'
File: Mathlib/Probability/Moments.lean

Proof steps:
state_before: Ω : Type u_1
ι : Type u_2
m : MeasurableSpace Ω
X✝ : Ω → ℝ
p : ℕ
μ : Measure Ω
t : ℝ
X Y : Ω → ℝ
h_indep : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
⊢ mgf (X + Y) μ t = mgf X μ t * mgf Y μ t
state_after: Ω : Type u_1
ι : Type u_2
m : MeasurableSpace Ω
X✝ : Ω → ℝ
p : ℕ
μ : Measure Ω
t : ℝ
X Y : Ω → ℝ
h_indep : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
A : Continuous fun x => rexp (t * x)
⊢ mgf (X + Y) μ t = mgf X μ t * mgf Y μ t
tactic: have A : Continuous fun x : ℝ => exp (t * x) := by fun_prop
state_before: Ω : Type u_1
ι : Type u_2
m : MeasurableSpace Ω
X✝ : Ω → ℝ
p : ℕ
μ : Measure Ω
t : ℝ
X Y : Ω → ℝ
h_indep : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
A : Continuous fun x => rexp (t * x)
⊢ mgf (X + Y) μ t = mgf X μ t * mgf Y μ t
state_after: Ω : Type u_1
ι : Type u_2
m : MeasurableSpace Ω
X✝ : Ω → ℝ
p : ℕ
μ : Measure Ω
t : ℝ
X Y : Ω → ℝ
h_indep : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
A : Continuous fun x => rexp (t * x)
h'X : AEStronglyMeasurable (fun ω => rexp (t * X ω)) μ
⊢ mgf (X + Y) μ t = mgf X μ t * mgf Y μ t
tactic: have h'X : AEStronglyMeasurable (fun ω => exp (t * X ω)) μ :=
    A.aestronglyMeasurable.comp_aemeasurable hX.aemeasurable
state_before: Ω : Type u_1
ι : Type u_2
m : MeasurableSpace Ω
X✝ : Ω → ℝ
p : ℕ
μ : Measure Ω
t : ℝ
X Y : Ω → ℝ
h_indep : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
A : Continuous fun x => rexp (t * x)
h'X : AEStronglyMeasurable (fun ω => rexp (t * X ω)) μ
⊢ mgf (X + Y) μ t = mgf X μ t * mgf Y μ t
state_after: Ω : Type u_1
ι : Type u_2
m : MeasurableSpace Ω
X✝ : Ω → ℝ
p : ℕ
μ : Measure Ω
t : ℝ
X Y : Ω → ℝ
h_indep : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
A : Continuous fun x => rexp (t * x)
h'X : AEStronglyMeasurable (fun ω => rexp (t * X ω)) μ
h'Y : AEStronglyMeasurable (fun ω => rexp (t * Y ω)) μ
⊢ mgf (X + Y) μ t = mgf X μ t * mgf Y μ t
tactic: have h'Y : AEStronglyMeasurable (fun ω => exp (t * Y ω)) μ :=
    A.aestronglyMeasurable.comp_aemeasurable hY.aemeasurable
state_before: Ω : Type u_1
ι : Type u_2
m : MeasurableSpace Ω
X✝ : Ω → ℝ
p : ℕ
μ : Measure Ω
t : ℝ
X Y : Ω → ℝ
h_indep : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
A : Continuous fun x => rexp (t * x)
h'X : AEStronglyMeasurable (fun ω => rexp (t * X ω)) μ
h'Y : AEStronglyMeasurable (fun ω => rexp (t * Y ω)) μ
⊢ mgf (X + Y) μ t = mgf X μ t * mgf Y μ t
state_after: no goals
tactic: exact h_indep.mgf_add h'X h'Y
Theorem: Finset.Colex.isInitSeg_iff_exists_initSeg
File: Mathlib/Combinatorics/Colex.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
inst✝² : LinearOrder α
inst✝¹ : LinearOrder β
f : α → β
𝒜 𝒜₁ 𝒜₂ : Finset (Finset α)
s t u : Finset α
a b : α
r : ℕ
inst✝ : Fintype α
⊢ IsInitSeg 𝒜 r ∧ 𝒜.Nonempty ↔ ∃ s, s.card = r ∧ 𝒜 = initSeg s
state_after: α : Type u_1
β : Type u_2
inst✝² : LinearOrder α
inst✝¹ : LinearOrder β
f : α → β
𝒜 𝒜₁ 𝒜₂ : Finset (Finset α)
s t u : Finset α
a b : α
r : ℕ
inst✝ : Fintype α
⊢ (∃ s, s.card = r ∧ 𝒜 = initSeg s) → IsInitSeg 𝒜 r ∧ 𝒜.Nonempty
tactic: refine ⟨fun h𝒜 ↦ h𝒜.1.exists_initSeg h𝒜.2, ?_⟩
state_before: α : Type u_1
β : Type u_2
inst✝² : LinearOrder α
inst✝¹ : LinearOrder β
f : α → β
𝒜 𝒜₁ 𝒜₂ : Finset (Finset α)
s t u : Finset α
a b : α
r : ℕ
inst✝ : Fintype α
⊢ (∃ s, s.card = r ∧ 𝒜 = initSeg s) → IsInitSeg 𝒜 r ∧ 𝒜.Nonempty
state_after: case intro.intro
α : Type u_1
β : Type u_2
inst✝² : LinearOrder α
inst✝¹ : LinearOrder β
f : α → β
𝒜₁ 𝒜₂ : Finset (Finset α)
s✝ t u : Finset α
a b : α
inst✝ : Fintype α
s : Finset α
⊢ IsInitSeg (initSeg s) s.card ∧ (initSeg s).Nonempty
tactic: rintro ⟨s, rfl, rfl⟩
state_before: case intro.intro
α : Type u_1
β : Type u_2
inst✝² : LinearOrder α
inst✝¹ : LinearOrder β
f : α → β
𝒜₁ 𝒜₂ : Finset (Finset α)
s✝ t u : Finset α
a b : α
inst✝ : Fintype α
s : Finset α
⊢ IsInitSeg (initSeg s) s.card ∧ (initSeg s).Nonempty
state_after: no goals
tactic: exact ⟨isInitSeg_initSeg, initSeg_nonempty⟩
Theorem: isClosedMap_swap
File: Mathlib/Topology/Constructions.lean

Proof steps:
state_before: X : Type u
Y : Type v
Z : Type u_1
W : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝⁵ : TopologicalSpace X
inst✝⁴ : TopologicalSpace Y
inst✝³ : TopologicalSpace Z
inst✝² : TopologicalSpace W
inst✝¹ : TopologicalSpace ε
inst✝ : TopologicalSpace ζ
s : Set (X × Y)
hs : IsClosed s
⊢ IsClosed (Prod.swap '' s)
state_after: X : Type u
Y : Type v
Z : Type u_1
W : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝⁵ : TopologicalSpace X
inst✝⁴ : TopologicalSpace Y
inst✝³ : TopologicalSpace Z
inst✝² : TopologicalSpace W
inst✝¹ : TopologicalSpace ε
inst✝ : TopologicalSpace ζ
s : Set (X × Y)
hs : IsClosed s
⊢ IsClosed (Prod.swap ⁻¹' s)
tactic: rw [image_swap_eq_preimage_swap]
state_before: X : Type u
Y : Type v
Z : Type u_1
W : Type u_2
ε : Type u_3
ζ : Type u_4
inst✝⁵ : TopologicalSpace X
inst✝⁴ : TopologicalSpace Y
inst✝³ : TopologicalSpace Z
inst✝² : TopologicalSpace W
inst✝¹ : TopologicalSpace ε
inst✝ : TopologicalSpace ζ
s : Set (X × Y)
hs : IsClosed s
⊢ IsClosed (Prod.swap ⁻¹' s)
state_after: no goals
tactic: exact hs.preimage continuous_swap
Theorem: Ordinal.enumOrd_surjective
File: Mathlib/SetTheory/Ordinal/Arithmetic.lean

Proof steps:
state_before: S : Set Ordinal.{u}
hS : Unbounded (fun x x_1 => x < x_1) S
s : Ordinal.{u}
hs : s ∈ S
⊢ enumOrd S (sSup {a | enumOrd S a ≤ s}) = s
state_after: case a
S : Set Ordinal.{u}
hS : Unbounded (fun x x_1 => x < x_1) S
s : Ordinal.{u}
hs : s ∈ S
⊢ enumOrd S (sSup {a | enumOrd S a ≤ s}) ≤ s

case a
S : Set Ordinal.{u}
hS : Unbounded (fun x x_1 => x < x_1) S
s : Ordinal.{u}
hs : s ∈ S
⊢ s ≤ enumOrd S (sSup {a | enumOrd S a ≤ s})
tactic: apply le_antisymm
Theorem: Real.Gamma_one
File: Mathlib/Analysis/SpecialFunctions/Gamma/Basic.lean

Proof steps:
state_before: ⊢ Gamma 1 = 1
state_after: no goals
tactic: rw [Gamma, Complex.ofReal_one, Complex.Gamma_one, Complex.one_re]
Theorem: Ordnode.any_iff_exists
File: Mathlib/Data/Ordmap/Ordset.lean

Proof steps:
state_before: α : Type u_1
P : α → Prop
⊢ Any P nil → ∃ x, Emem x nil ∧ P x
state_after: no goals
tactic: rintro ⟨⟩
state_before: α : Type u_1
P : α → Prop
⊢ (∃ x, Emem x nil ∧ P x) → Any P nil
state_after: no goals
tactic: rintro ⟨_, ⟨⟩, _⟩
state_before: α : Type u_1
P : α → Prop
size✝ : ℕ
l : Ordnode α
x : α
r : Ordnode α
⊢ Any P (node size✝ l x r) ↔ ∃ x_1, Emem x_1 (node size✝ l x r) ∧ P x_1
state_after: α : Type u_1
P : α → Prop
size✝ : ℕ
l : Ordnode α
x : α
r : Ordnode α
⊢ Any P (node size✝ l x r) ↔ ∃ x_1, Any (Eq x_1) (node size✝ l x r) ∧ P x_1
tactic: simp only [Emem]
state_before: α : Type u_1
P : α → Prop
size✝ : ℕ
l : Ordnode α
x : α
r : Ordnode α
⊢ Any P (node size✝ l x r) ↔ ∃ x_1, Any (Eq x_1) (node size✝ l x r) ∧ P x_1
state_after: no goals
tactic: simp [Any, any_iff_exists, or_and_right, exists_or]
Theorem: Real.hasDerivAt_Gamma_one
File: Mathlib/NumberTheory/Harmonic/GammaDeriv.lean

Proof steps:
state_before: ⊢ HasDerivAt Gamma (-γ) 1
state_after: no goals
tactic: simpa only [factorial_zero, cast_one, harmonic_zero, Rat.cast_zero, add_zero, mul_neg, one_mul,
    cast_zero, zero_add] using hasDerivAt_Gamma_nat 0
Theorem: MeasureTheory.integrable_map_equiv
File: Mathlib/MeasureTheory/Function/L1Space.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
m : MeasurableSpace α
μ ν : Measure α
inst✝² : MeasurableSpace δ
inst✝¹ : NormedAddCommGroup β
inst✝ : NormedAddCommGroup γ
f : α ≃ᵐ δ
g : δ → β
⊢ Integrable g (Measure.map (⇑f) μ) ↔ Integrable (g ∘ ⇑f) μ
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
m : MeasurableSpace α
μ ν : Measure α
inst✝² : MeasurableSpace δ
inst✝¹ : NormedAddCommGroup β
inst✝ : NormedAddCommGroup γ
f : α ≃ᵐ δ
g : δ → β
⊢ Memℒp g 1 (Measure.map (⇑f) μ) ↔ Memℒp (g ∘ ⇑f) 1 μ
tactic: simp_rw [← memℒp_one_iff_integrable]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
m : MeasurableSpace α
μ ν : Measure α
inst✝² : MeasurableSpace δ
inst✝¹ : NormedAddCommGroup β
inst✝ : NormedAddCommGroup γ
f : α ≃ᵐ δ
g : δ → β
⊢ Memℒp g 1 (Measure.map (⇑f) μ) ↔ Memℒp (g ∘ ⇑f) 1 μ
state_after: no goals
tactic: exact f.memℒp_map_measure_iff
Theorem: MeasureTheory.Integrable.comp_snd_map_prod_id
File: Mathlib/Probability/Kernel/Condexp.lean

Proof steps:
state_before: Ω : Type u_1
F : Type u_2
m mΩ : MeasurableSpace Ω
μ : Measure Ω
f : Ω → F
inst✝ : NormedAddCommGroup F
hm : m ≤ mΩ
hf : Integrable f μ
⊢ Integrable (fun x => f x.2) (Measure.map (fun ω => (id ω, id ω)) μ)
state_after: Ω : Type u_1
F : Type u_2
m mΩ : MeasurableSpace Ω
μ : Measure Ω
f : Ω → F
inst✝ : NormedAddCommGroup F
hm : m ≤ mΩ
hf : Integrable (fun x => f x.2) (Measure.map (fun ω => (id ω, ω)) μ)
⊢ Integrable (fun x => f x.2) (Measure.map (fun ω => (id ω, id ω)) μ)
tactic: rw [← integrable_comp_snd_map_prod_mk_iff (measurable_id'' hm)] at hf
state_before: Ω : Type u_1
F : Type u_2
m mΩ : MeasurableSpace Ω
μ : Measure Ω
f : Ω → F
inst✝ : NormedAddCommGroup F
hm : m ≤ mΩ
hf : Integrable (fun x => f x.2) (Measure.map (fun ω => (id ω, ω)) μ)
⊢ Integrable (fun x => f x.2) (Measure.map (fun ω => (id ω, id ω)) μ)
state_after: Ω : Type u_1
F : Type u_2
m mΩ : MeasurableSpace Ω
μ : Measure Ω
f : Ω → F
inst✝ : NormedAddCommGroup F
hm : m ≤ mΩ
hf : Integrable (fun x => f x.2) (Measure.map (fun ω => (ω, ω)) μ)
⊢ Integrable (fun x => f x.2) (Measure.map (fun ω => (ω, ω)) μ)
tactic: simp_rw [id] at hf ⊢
state_before: Ω : Type u_1
F : Type u_2
m mΩ : MeasurableSpace Ω
μ : Measure Ω
f : Ω → F
inst✝ : NormedAddCommGroup F
hm : m ≤ mΩ
hf : Integrable (fun x => f x.2) (Measure.map (fun ω => (ω, ω)) μ)
⊢ Integrable (fun x => f x.2) (Measure.map (fun ω => (ω, ω)) μ)
state_after: no goals
tactic: exact hf
Theorem: Finset.disjUnion_singleton
File: Mathlib/Data/Finset/Basic.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
s : Finset α
a : α
h : _root_.Disjoint s {a}
⊢ s.disjUnion {a} h = cons a s ⋯
state_after: no goals
tactic: rw [disjUnion_comm, singleton_disjUnion]
Theorem: Int.Prime.dvd_mul'
File: Mathlib/RingTheory/Int/Basic.lean

Proof steps:
state_before: m n : ℤ
p : ℕ
hp : Nat.Prime p
h : ↑p ∣ m * n
⊢ ↑p ∣ m ∨ ↑p ∣ n
state_after: m n : ℤ
p : ℕ
hp : Nat.Prime p
h : ↑p ∣ m * n
⊢ p ∣ m.natAbs ∨ p ∣ n.natAbs
tactic: rw [Int.natCast_dvd, Int.natCast_dvd]
state_before: m n : ℤ
p : ℕ
hp : Nat.Prime p
h : ↑p ∣ m * n
⊢ p ∣ m.natAbs ∨ p ∣ n.natAbs
state_after: no goals
tactic: exact Int.Prime.dvd_mul hp h
Theorem: TopCat.Presheaf.pushforwardEq_hom_app
File: Mathlib/Topology/Sheaves/Presheaf.lean

Proof steps:
state_before: C : Type u
inst✝ : Category.{v, u} C
X Y : TopCat
f g : X ⟶ Y
h : f = g
ℱ : Presheaf C X
U : (Opens ↑Y)ᵒᵖ
⊢ (Opens.map f).op.obj U = (Opens.map g).op.obj U
state_after: no goals
tactic: aesop_cat
state_before: C : Type u
inst✝ : Category.{v, u} C
X Y : TopCat
f g : X ⟶ Y
h : f = g
ℱ : Presheaf C X
U : (Opens ↑Y)ᵒᵖ
⊢ (pushforwardEq h ℱ).hom.app U = ℱ.map (eqToHom ⋯)
state_after: no goals
tactic: simp [pushforwardEq]
Theorem: Int.Ico_filter_modEq_card
File: Mathlib/Data/Int/CardIntervalMod.lean

Proof steps:
state_before: a b r : ℤ
hr : 0 < r
v : ℤ
⊢ ↑(filter (fun x => x ≡ v [ZMOD r]) (Ico a b)).card = max (⌈(↑b - ↑v) / ↑r⌉ - ⌈(↑a - ↑v) / ↑r⌉) 0
state_after: no goals
tactic: simp [Ico_filter_modEq_eq, Ico_filter_dvd_eq, toNat_eq_max, hr]
Theorem: upperCentralSeriesStep_eq_comap_center
File: Mathlib/GroupTheory/Nilpotent.lean

Proof steps:
state_before: G : Type u_1
inst✝¹ : Group G
H : Subgroup G
inst✝ : H.Normal
⊢ upperCentralSeriesStep H = comap (mk' H) (center (G ⧸ H))
state_after: case h
G : Type u_1
inst✝¹ : Group G
H : Subgroup G
inst✝ : H.Normal
x✝ : G
⊢ x✝ ∈ upperCentralSeriesStep H ↔ x✝ ∈ comap (mk' H) (center (G ⧸ H))
tactic: ext
state_before: case h
G : Type u_1
inst✝¹ : Group G
H : Subgroup G
inst✝ : H.Normal
x✝ : G
⊢ x✝ ∈ upperCentralSeriesStep H ↔ x✝ ∈ comap (mk' H) (center (G ⧸ H))
state_after: case h
G : Type u_1
inst✝¹ : Group G
H : Subgroup G
inst✝ : H.Normal
x✝ : G
⊢ x✝ ∈ upperCentralSeriesStep H ↔ ∀ (x : G), ↑x * (mk' H) x✝ = (mk' H) x✝ * ↑x
tactic: rw [mem_comap, mem_center_iff, forall_mk]
state_before: case h
G : Type u_1
inst✝¹ : Group G
H : Subgroup G
inst✝ : H.Normal
x✝ : G
⊢ x✝ ∈ upperCentralSeriesStep H ↔ ∀ (x : G), ↑x * (mk' H) x✝ = (mk' H) x✝ * ↑x
state_after: case h.h
G : Type u_1
inst✝¹ : Group G
H : Subgroup G
inst✝ : H.Normal
x✝ : G
⊢ ∀ (a : G), x✝ * a * x✝⁻¹ * a⁻¹ ∈ H ↔ ↑a * (mk' H) x✝ = (mk' H) x✝ * ↑a
tactic: apply forall_congr'
state_before: case h.h
G : Type u_1
inst✝¹ : Group G
H : Subgroup G
inst✝ : H.Normal
x✝ : G
⊢ ∀ (a : G), x✝ * a * x✝⁻¹ * a⁻¹ ∈ H ↔ ↑a * (mk' H) x✝ = (mk' H) x✝ * ↑a
state_after: case h.h
G : Type u_1
inst✝¹ : Group G
H : Subgroup G
inst✝ : H.Normal
x✝ y : G
⊢ x✝ * y * x✝⁻¹ * y⁻¹ ∈ H ↔ ↑y * (mk' H) x✝ = (mk' H) x✝ * ↑y
tactic: intro y
state_before: case h.h
G : Type u_1
inst✝¹ : Group G
H : Subgroup G
inst✝ : H.Normal
x✝ y : G
⊢ x✝ * y * x✝⁻¹ * y⁻¹ ∈ H ↔ ↑y * (mk' H) x✝ = (mk' H) x✝ * ↑y
state_after: no goals
tactic: rw [coe_mk', ← QuotientGroup.mk_mul, ← QuotientGroup.mk_mul, eq_comm, eq_iff_div_mem,
    div_eq_mul_inv, mul_inv_rev, mul_assoc]
Theorem: Substring.Valid.all
File: .lake/packages/batteries/Batteries/Data/String/Lemmas.lean

Proof steps:
state_before: f : Char → Bool
x✝ : Substring
h✝ : x✝.Valid
w✝² w✝¹ w✝ : List Char
h : ValidFor w✝² w✝¹ w✝ x✝
⊢ x✝.all f = x✝.toString.data.all f
state_after: no goals
tactic: simp [h.all, h.toString]
Theorem: bernoulli'_spec'
File: Mathlib/NumberTheory/Bernoulli.lean

Proof steps:
state_before: A : Type u_1
inst✝¹ : CommRing A
inst✝ : Algebra ℚ A
n : ℕ
⊢ ∑ k ∈ antidiagonal n, ↑((k.1 + k.2).choose k.2) / (↑k.2 + 1) * bernoulli' k.1 = 1
state_after: A : Type u_1
inst✝¹ : CommRing A
inst✝ : Algebra ℚ A
n : ℕ
⊢ ∑ k ∈ range n.succ,
      ↑(((k, n - k).1 + (k, n - k).2).choose (k, n - k).2) / (↑(k, n - k).2 + 1) * bernoulli' (k, n - k).1 =
    ∑ k ∈ range n.succ, ↑(n.choose (n - k)) / (↑n - ↑k + 1) * bernoulli' k
tactic: refine ((sum_antidiagonal_eq_sum_range_succ_mk _ n).trans ?_).trans (bernoulli'_spec n)
state_before: A : Type u_1
inst✝¹ : CommRing A
inst✝ : Algebra ℚ A
n : ℕ
⊢ ∑ k ∈ range n.succ,
      ↑(((k, n - k).1 + (k, n - k).2).choose (k, n - k).2) / (↑(k, n - k).2 + 1) * bernoulli' (k, n - k).1 =
    ∑ k ∈ range n.succ, ↑(n.choose (n - k)) / (↑n - ↑k + 1) * bernoulli' k
state_after: A : Type u_1
inst✝¹ : CommRing A
inst✝ : Algebra ℚ A
n x : ℕ
hx : x ∈ range n.succ
⊢ ↑(((x, n - x).1 + (x, n - x).2).choose (x, n - x).2) / (↑(x, n - x).2 + 1) * bernoulli' (x, n - x).1 =
    ↑(n.choose (n - x)) / (↑n - ↑x + 1) * bernoulli' x
tactic: refine sum_congr rfl fun x hx => ?_
state_before: A : Type u_1
inst✝¹ : CommRing A
inst✝ : Algebra ℚ A
n x : ℕ
hx : x ∈ range n.succ
⊢ ↑(((x, n - x).1 + (x, n - x).2).choose (x, n - x).2) / (↑(x, n - x).2 + 1) * bernoulli' (x, n - x).1 =
    ↑(n.choose (n - x)) / (↑n - ↑x + 1) * bernoulli' x
state_after: no goals
tactic: simp only [add_tsub_cancel_of_le, mem_range_succ_iff.mp hx, cast_sub]
Theorem: ContDiffBump.integral_le_measure_closedBall
File: Mathlib/Analysis/Calculus/BumpFunction/Normed.lean

Proof steps:
state_before: E : Type u_1
inst✝⁷ : NormedAddCommGroup E
inst✝⁶ : NormedSpace ℝ E
inst✝⁵ : HasContDiffBump E
inst✝⁴ : MeasurableSpace E
c : E
f : ContDiffBump c
x : E
n : ℕ∞
μ : Measure E
inst✝³ : BorelSpace E
inst✝² : FiniteDimensional ℝ E
inst✝¹ : IsLocallyFiniteMeasure μ
inst✝ : μ.IsOpenPosMeasure
⊢ ∫ (x : E), ↑f x ∂μ ≤ (μ (closedBall c f.rOut)).toReal
state_after: no goals
tactic: calc
  ∫ x, f x ∂μ = ∫ x in closedBall c f.rOut, f x ∂μ := by
    apply (setIntegral_eq_integral_of_forall_compl_eq_zero (fun x hx ↦ ?_)).symm
    apply f.zero_of_le_dist (le_of_lt _)
    simpa using hx
  _ ≤ ∫ x in closedBall c f.rOut, 1 ∂μ := by
    apply setIntegral_mono f.integrable.integrableOn _ (fun x ↦ f.le_one)
    simp [measure_closedBall_lt_top]
  _ = (μ (closedBall c f.rOut)).toReal := by simp
Theorem: Sum.Lex.mono
File: .lake/packages/batteries/Batteries/Data/Sum/Lemmas.lean

Proof steps:
state_before: α✝ : Type u_1
r₁ r₂ : α✝ → α✝ → Prop
β✝ : Type u_2
s₁ s₂ : β✝ → β✝ → Prop
x y : α✝ ⊕ β✝
hr : ∀ (a b : α✝), r₁ a b → r₂ a b
hs : ∀ (a b : β✝), s₁ a b → s₂ a b
h : Lex r₁ s₁ x y
⊢ Lex r₂ s₂ x y
state_after: case inl
α✝ : Type u_1
r₁ r₂ : α✝ → α✝ → Prop
β✝ : Type u_2
s₁ s₂ : β✝ → β✝ → Prop
hr : ∀ (a b : α✝), r₁ a b → r₂ a b
hs : ∀ (a b : β✝), s₁ a b → s₂ a b
a₁✝ a₂✝ : α✝
h✝ : r₁ a₁✝ a₂✝
⊢ Lex r₂ s₂ (inl a₁✝) (inl a₂✝)

case inr
α✝ : Type u_1
r₁ r₂ : α✝ → α✝ → Prop
β✝ : Type u_2
s₁ s₂ : β✝ → β✝ → Prop
hr : ∀ (a b : α✝), r₁ a b → r₂ a b
hs : ∀ (a b : β✝), s₁ a b → s₂ a b
b₁✝ b₂✝ : β✝
h✝ : s₁ b₁✝ b₂✝
⊢ Lex r₂ s₂ (inr b₁✝) (inr b₂✝)

case sep
α✝ : Type u_1
r₁ r₂ : α✝ → α✝ → Prop
β✝ : Type u_2
s₁ s₂ : β✝ → β✝ → Prop
hr : ∀ (a b : α✝), r₁ a b → r₂ a b
hs : ∀ (a b : β✝), s₁ a b → s₂ a b
a✝ : α✝
b✝ : β✝
⊢ Lex r₂ s₂ (inl a✝) (inr b✝)
tactic: cases h
Theorem: Computation.bind_pure'
File: Mathlib/Data/Seq/Computation.lean

Proof steps:
state_before: α : Type u
β : Type v
γ : Type w
s : Computation α
⊢ s.bind pure = s
state_after: case bisim
α : Type u
β : Type v
γ : Type w
s : Computation α
⊢ IsBisimulation fun c₁ c₂ => c₁ = c₂ ∨ ∃ s, c₁ = s.bind pure ∧ c₂ = s

case r
α : Type u
β : Type v
γ : Type w
s : Computation α
⊢ s.bind pure = s ∨ ∃ s_1, s.bind pure = s_1.bind pure ∧ s = s_1
tactic: apply eq_of_bisim fun c₁ c₂ => c₁ = c₂ ∨ ∃ s, c₁ = bind s pure ∧ c₂ = s
Theorem: collapse_of_mem
File: Mathlib/Combinatorics/SetFamily/FourFunctions.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
inst✝² : DecidableEq α
inst✝¹ : LinearOrderedCommSemiring β
inst✝ : ExistsAddOfLE β
𝒜 ℬ : Finset (Finset α)
a : α
f f₁ f₂ f₃ f₄ g μ : Finset α → β
s t u : Finset α
ha : a ∉ s
ht : t ∈ 𝒜
hu : u ∈ 𝒜
hts : t = s
hus : u = insert a s
⊢ collapse 𝒜 a f s = f t + f u
state_after: α : Type u_1
β : Type u_2
inst✝² : DecidableEq α
inst✝¹ : LinearOrderedCommSemiring β
inst✝ : ExistsAddOfLE β
𝒜 ℬ : Finset (Finset α)
a : α
f f₁ f₂ f₃ f₄ g μ : Finset α → β
t u : Finset α
ht : t ∈ 𝒜
hu : u ∈ 𝒜
ha : a ∉ t
hus : u = insert a t
⊢ collapse 𝒜 a f t = f t + f u
tactic: subst hts
state_before: α : Type u_1
β : Type u_2
inst✝² : DecidableEq α
inst✝¹ : LinearOrderedCommSemiring β
inst✝ : ExistsAddOfLE β
𝒜 ℬ : Finset (Finset α)
a : α
f f₁ f₂ f₃ f₄ g μ : Finset α → β
t u : Finset α
ht : t ∈ 𝒜
hu : u ∈ 𝒜
ha : a ∉ t
hus : u = insert a t
⊢ collapse 𝒜 a f t = f t + f u
state_after: α : Type u_1
β : Type u_2
inst✝² : DecidableEq α
inst✝¹ : LinearOrderedCommSemiring β
inst✝ : ExistsAddOfLE β
𝒜 ℬ : Finset (Finset α)
a : α
f f₁ f₂ f₃ f₄ g μ : Finset α → β
t : Finset α
ht : t ∈ 𝒜
ha : a ∉ t
hu : insert a t ∈ 𝒜
⊢ collapse 𝒜 a f t = f t + f (insert a t)
tactic: subst hus
state_before: α : Type u_1
β : Type u_2
inst✝² : DecidableEq α
inst✝¹ : LinearOrderedCommSemiring β
inst✝ : ExistsAddOfLE β
𝒜 ℬ : Finset (Finset α)
a : α
f f₁ f₂ f₃ f₄ g μ : Finset α → β
t : Finset α
ht : t ∈ 𝒜
ha : a ∉ t
hu : insert a t ∈ 𝒜
⊢ collapse 𝒜 a f t = f t + f (insert a t)
state_after: no goals
tactic: simp_rw [collapse_eq ha, if_pos ht, if_pos hu]
Theorem: CategoryTheory.Sieve.le_pullback_bind
File: Mathlib/CategoryTheory/Sites/Sieves.lean

Proof steps:
state_before: C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
D : Type u₂
inst✝ : Category.{v₂, u₂} D
F : C ⥤ D
X Y Z : C
f✝ : Y ⟶ X
S✝ R✝ : Sieve X
S : Presieve X
R : ⦃Y : C⦄ → ⦃f : Y ⟶ X⦄ → S f → Sieve Y
f : Y ⟶ X
h : S f
⊢ R h ≤ pullback f (bind S R)
state_after: C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
D : Type u₂
inst✝ : Category.{v₂, u₂} D
F : C ⥤ D
X Y Z : C
f✝ : Y ⟶ X
S✝ R✝ : Sieve X
S : Presieve X
R : ⦃Y : C⦄ → ⦃f : Y ⟶ X⦄ → S f → Sieve Y
f : Y ⟶ X
h : S f
⊢ pushforward f (R h) ≤ bind S R
tactic: rw [← galoisConnection f]
state_before: C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
D : Type u₂
inst✝ : Category.{v₂, u₂} D
F : C ⥤ D
X Y Z : C
f✝ : Y ⟶ X
S✝ R✝ : Sieve X
S : Presieve X
R : ⦃Y : C⦄ → ⦃f : Y ⟶ X⦄ → S f → Sieve Y
f : Y ⟶ X
h : S f
⊢ pushforward f (R h) ≤ bind S R
state_after: no goals
tactic: apply pushforward_le_bind_of_mem
Theorem: AddMonoid.exists_list_of_mem_closure
File: Mathlib/Deprecated/Submonoid.lean

Proof steps:
state_before: M : Type u_1
inst✝¹ : Monoid M
s✝ : Set M
A : Type u_2
inst✝ : AddMonoid A
t : Set A
s : Set M
a : M
h : a ∈ Closure s
⊢ ∃ l, (∀ x ∈ l, x ∈ s) ∧ l.prod = a
state_after: no goals
tactic: induction h with
  | @basic a ha => exists [a]; simp [ha]
  | one => exists []; simp
  | mul _ _ ha hb =>
    rcases ha with ⟨la, ha, eqa⟩
    rcases hb with ⟨lb, hb, eqb⟩
    exists la ++ lb
    simp only [List.mem_append, or_imp, List.prod_append, eqa.symm, eqb.symm, and_true]
    exact fun a => ⟨ha a, hb a⟩
Theorem: CategoryTheory.Limits.limitIsoLimitCurryCompLim_hom_π_π
File: Mathlib/CategoryTheory/Limits/Fubini.lean

Proof steps:
state_before: J K : Type v
inst✝⁵ : SmallCategory J
inst✝⁴ : SmallCategory K
C : Type u
inst✝³ : Category.{v, u} C
F : J ⥤ K ⥤ C
G : J × K ⥤ C
inst✝² : HasLimitsOfShape K C
inst✝¹ : HasLimit G
inst✝ : HasLimit (curry.obj G ⋙ lim)
j : J
k : K
⊢ (limitIsoLimitCurryCompLim G).hom ≫ limit.π (curry.obj G ⋙ lim) j ≫ limit.π ((curry.obj G).obj j) k = limit.π G (j, k)
state_after: no goals
tactic: set_option tactic.skipAssignedInstances false in
  simp [limitIsoLimitCurryCompLim, Trans.simple, HasLimit.isoOfNatIso, limitUncurryIsoLimitCompLim]
Theorem: Set.prod_image_seq_comm
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
s : Set α
t : Set β
⊢ (Prod.mk '' s).seq t = ((fun b a => (a, b)) '' t).seq s
state_after: α : 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
s : Set α
t : Set β
⊢ ((fun x => Prod.swap ∘ x) ∘ Prod.mk '' t).seq s = ((fun b a => (a, b)) '' t).seq s
tactic: rw [← prod_eq_seq, ← image_swap_prod, prod_eq_seq, image_seq, ← image_comp]
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
s : Set α
t : Set β
⊢ ((fun x => Prod.swap ∘ x) ∘ Prod.mk '' t).seq s = ((fun b a => (a, b)) '' t).seq s
state_after: no goals
tactic: rfl
Theorem: Ordinal.mul_pos
File: Mathlib/SetTheory/Ordinal/Arithmetic.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
r : α → α → Prop
s : β → β → Prop
t : γ → γ → Prop
a b : Ordinal.{u_4}
h₁ : 0 < a
h₂ : 0 < b
⊢ 0 < a * b
state_after: no goals
tactic: simpa only [mul_zero] using mul_lt_mul_of_pos_left h₂ h₁