1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: SimplicialObject.Splitting.IndexSet.eqId_iff_len_le
File: Mathlib/AlgebraicTopology/SplitSimplicialObject.lean

tactic: rw [eqId_iff_len_eq]
state_before: C : Type u_1
inst✝ : Category.{?u.3929, u_1} C
Δ : SimplexCategoryᵒᵖ
A : IndexSet Δ
⊢ A.EqId ↔ Δ.unop.len ≤ A.fst.unop.len
state_after: C : Type u_1
inst✝ : Category.{?u.3929, u_1} C
Δ : SimplexCategoryᵒᵖ
A : IndexSet Δ
⊢ A.fst.unop.len = Δ.unop.len ↔ Δ.unop.len ≤ A.fst.unop.len

tactic: constructor
state_before: C : Type u_1
inst✝ : Category.{?u.3929, u_1} C
Δ : SimplexCategoryᵒᵖ
A : IndexSet Δ
⊢ A.fst.unop.len = Δ.unop.len ↔ Δ.unop.len ≤ A.fst.unop.len
state_after: case mp
C : Type u_1
inst✝ : Category.{?u.3929, u_1} C
Δ : SimplexCategoryᵒᵖ
A : IndexSet Δ
⊢ A.fst.unop.len = Δ.unop.len → Δ.unop.len ≤ A.fst.unop.len

case mpr
C : Type u_1
inst✝ : Category.{?u.3929, u_1} C
Δ : SimplexCategoryᵒᵖ
A : IndexSet Δ
⊢ Δ.unop.len ≤ A.fst.unop.len → A.fst.unop.len = Δ.unop.len

tactic: intro h
state_before: case mp
C : Type u_1
inst✝ : Category.{?u.3929, u_1} C
Δ : SimplexCategoryᵒᵖ
A : IndexSet Δ
⊢ A.fst.unop.len = Δ.unop.len → Δ.unop.len ≤ A.fst.unop.len
state_after: case mp
C : Type u_1
inst✝ : Category.{?u.3929, u_1} C
Δ : SimplexCategoryᵒᵖ
A : IndexSet Δ
h : A.fst.unop.len = Δ.unop.len
⊢ Δ.unop.len ≤ A.fst.unop.len

tactic: rw [h]
state_before: case mp
C : Type u_1
inst✝ : Category.{?u.3929, u_1} C
Δ : SimplexCategoryᵒᵖ
A : IndexSet Δ
h : A.fst.unop.len = Δ.unop.len
⊢ Δ.unop.len ≤ A.fst.unop.len
state_after: no goals

tactic: exact le_antisymm (len_le_of_epi (inferInstance : Epi A.e))
state_before: case mpr
C : Type u_1
inst✝ : Category.{?u.3929, u_1} C
Δ : SimplexCategoryᵒᵖ
A : IndexSet Δ
⊢ Δ.unop.len ≤ A.fst.unop.len → A.fst.unop.len = Δ.unop.len
state_after: no goals
Theorem: Int.lcm_comm
File: Mathlib/Data/Int/GCD.lean

tactic: rw [Int.lcm, Int.lcm]
state_before: i j : ℤ
⊢ i.lcm j = j.lcm i
state_after: i j : ℤ
⊢ i.natAbs.lcm j.natAbs = j.natAbs.lcm i.natAbs

tactic: exact Nat.lcm_comm _ _
state_before: i j : ℤ
⊢ i.natAbs.lcm j.natAbs = j.natAbs.lcm i.natAbs
state_after: no goals
Theorem: ZFSet.mem_prod
File: Mathlib/SetTheory/ZFC/Basic.lean

tactic: simp [prod]
state_before: x y z : ZFSet
⊢ z ∈ x.prod y ↔ ∃ a ∈ x, ∃ b ∈ y, z = a.pair b
state_after: no goals
Theorem: IntermediateField.splits_of_splits
File: Mathlib/FieldTheory/SplittingField/IsSplittingField.lean

tactic: simp_rw [← F.fieldRange_val, rootSet_def, Finset.mem_coe, Multiset.mem_toFinset] at hF
state_before: F✝ : Type u
K : Type v
L : Type w
inst✝² : Field K
inst✝¹ : Field L
inst✝ : Algebra K L
p : K[X]
F : IntermediateField K L
h : Splits (algebraMap K L) p
hF : ∀ x ∈ p.rootSet L, x ∈ F
⊢ Splits (algebraMap K ↥F) p
state_after: F✝ : Type u
K : Type v
L : Type w
inst✝² : Field K
inst✝¹ : Field L
inst✝ : Algebra K L
p : K[X]
F : IntermediateField K L
h : Splits (algebraMap K L) p
hF : ∀ x ∈ p.aroots L, x ∈ F.val.fieldRange
⊢ Splits (algebraMap K ↥F) p

tactic: exact splits_of_comp _ F.val.toRingHom h hF
state_before: F✝ : Type u
K : Type v
L : Type w
inst✝² : Field K
inst✝¹ : Field L
inst✝ : Algebra K L
p : K[X]
F : IntermediateField K L
h : Splits (algebraMap K L) p
hF : ∀ x ∈ p.aroots L, x ∈ F.val.fieldRange
⊢ Splits (algebraMap K ↥F) p
state_after: no goals
Theorem: Set.image_iterate_eq
File: Mathlib/Data/Set/Image.lean

tactic: induction n with
| zero => simp
| succ n ih => rw [iterate_succ', iterate_succ', ← ih, image_comp_eq]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
ι : Sort u_4
ι' : Sort u_5
f✝ : α → β
s t : Set α
f : α → α
n : ℕ
⊢ image f^[n] = (image f)^[n]
state_after: no goals

tactic: simp
state_before: case zero
α : Type u_1
β : Type u_2
γ : Type u_3
ι : Sort u_4
ι' : Sort u_5
f✝ : α → β
s t : Set α
f : α → α
⊢ image f^[0] = (image f)^[0]
state_after: no goals

tactic: rw [iterate_succ', iterate_succ', ← ih, image_comp_eq]
state_before: case succ
α : Type u_1
β : Type u_2
γ : Type u_3
ι : Sort u_4
ι' : Sort u_5
f✝ : α → β
s t : Set α
f : α → α
n : ℕ
ih : image f^[n] = (image f)^[n]
⊢ image f^[n + 1] = (image f)^[n + 1]
state_after: no goals
Theorem: NormedAddGroupHom.NormNoninc.neg_iff
File: Mathlib/Analysis/Normed/Group/Hom.lean

tactic: simpa using h x
state_before: V : Type u_1
W : Type u_2
V₁ : Type u_3
V₂ : Type u_4
V₃ : Type u_5
inst✝⁴ : SeminormedAddCommGroup V
inst✝³ : SeminormedAddCommGroup W
inst✝² : SeminormedAddCommGroup V₁
inst✝¹ : SeminormedAddCommGroup V₂
inst✝ : SeminormedAddCommGroup V₃
f✝ : NormedAddGroupHom V W
f : NormedAddGroupHom V₁ V₂
h : (-f).NormNoninc
x : V₁
⊢ ‖f x‖ ≤ ‖x‖
state_after: no goals
Theorem: Continuous.div_const
File: Mathlib/Topology/Algebra/GroupWithZero.lean

tactic: simpa only [div_eq_mul_inv] using hf.mul continuous_const
state_before: α : Type u_1
β : Type u_2
G₀ : Type u_3
inst✝³ : DivInvMonoid G₀
inst✝² : TopologicalSpace G₀
inst✝¹ : ContinuousMul G₀
f : α → G₀
s : Set α
l : Filter α
inst✝ : TopologicalSpace α
hf : Continuous f
y : G₀
⊢ Continuous fun x => f x / y
state_after: no goals
Theorem: PNat.factorMultiset_le_iff
File: Mathlib/Data/PNat/Factors.lean

tactic: constructor
state_before: m n : ℕ+
⊢ m.factorMultiset ≤ n.factorMultiset ↔ m ∣ n
state_after: case mp
m n : ℕ+
⊢ m.factorMultiset ≤ n.factorMultiset → m ∣ n

case mpr
m n : ℕ+
⊢ m ∣ n → m.factorMultiset ≤ n.factorMultiset

tactic: intro h
state_before: case mp
m n : ℕ+
⊢ m.factorMultiset ≤ n.factorMultiset → m ∣ n
state_after: case mp
m n : ℕ+
h : m.factorMultiset ≤ n.factorMultiset
⊢ m ∣ n

tactic: rw [← prod_factorMultiset m, ← prod_factorMultiset m]
state_before: case mp
m n : ℕ+
h : m.factorMultiset ≤ n.factorMultiset
⊢ m ∣ n
state_after: case mp
m n : ℕ+
h : m.factorMultiset ≤ n.factorMultiset
⊢ m.factorMultiset.prod.factorMultiset.prod ∣ n

tactic: apply Dvd.intro (n.factorMultiset - m.factorMultiset).prod
state_before: case mp
m n : ℕ+
h : m.factorMultiset ≤ n.factorMultiset
⊢ m.factorMultiset.prod.factorMultiset.prod ∣ n
state_after: case mp
m n : ℕ+
h : m.factorMultiset ≤ n.factorMultiset
⊢ m.factorMultiset.prod.factorMultiset.prod * (n.factorMultiset - m.factorMultiset).prod = n

tactic: rw [← PrimeMultiset.prod_add, PrimeMultiset.factorMultiset_prod, add_tsub_cancel_of_le h,
  prod_factorMultiset]
state_before: case mp
m n : ℕ+
h : m.factorMultiset ≤ n.factorMultiset
⊢ m.factorMultiset.prod.factorMultiset.prod * (n.factorMultiset - m.factorMultiset).prod = n
state_after: no goals

tactic: intro h
state_before: case mpr
m n : ℕ+
⊢ m ∣ n → m.factorMultiset ≤ n.factorMultiset
state_after: case mpr
m n : ℕ+
h : m ∣ n
⊢ m.factorMultiset ≤ n.factorMultiset

tactic: rw [← mul_div_exact h, factorMultiset_mul]
state_before: case mpr
m n : ℕ+
h : m ∣ n
⊢ m.factorMultiset ≤ n.factorMultiset
state_after: case mpr
m n : ℕ+
h : m ∣ n
⊢ m.factorMultiset ≤ m.factorMultiset + (n.divExact m).factorMultiset

tactic: exact le_self_add
state_before: case mpr
m n : ℕ+
h : m ∣ n
⊢ m.factorMultiset ≤ m.factorMultiset + (n.divExact m).factorMultiset
state_after: no goals
Theorem: Submodule.supIndep_torsionBy
File: Mathlib/Algebra/Module/Torsion.lean

tactic: convert supIndep_torsionBySet_ideal (M := M) fun i hi j hj ij =>
    (Ideal.sup_eq_top_iff_isCoprime (q i) _).mpr <| hq hi hj ij
state_before: R : Type u_1
M : Type u_2
inst✝² : CommSemiring R
inst✝¹ : AddCommMonoid M
inst✝ : Module R M
s : Set R
a : R
ι : Type u_3
p : ι → Ideal R
S : Finset ι
hp : (↑S).Pairwise fun i j => p i ⊔ p j = ⊤
q : ι → R
hq : (↑S).Pairwise (IsCoprime on q)
⊢ S.SupIndep fun i => torsionBy R M (q i)
state_after: case h.e'_6.h
R : Type u_1
M : Type u_2
inst✝² : CommSemiring R
inst✝¹ : AddCommMonoid M
inst✝ : Module R M
s : Set R
a : R
ι : Type u_3
p : ι → Ideal R
S : Finset ι
hp : (↑S).Pairwise fun i j => p i ⊔ p j = ⊤
q : ι → R
hq : (↑S).Pairwise (IsCoprime on q)
x✝ : ι
⊢ torsionBy R M (q x✝) = torsionBySet R M ↑(Ideal.span {q x✝})

tactic: exact (torsionBySet_span_singleton_eq (R := R) (M := M) _).symm
state_before: case h.e'_6.h
R : Type u_1
M : Type u_2
inst✝² : CommSemiring R
inst✝¹ : AddCommMonoid M
inst✝ : Module R M
s : Set R
a : R
ι : Type u_3
p : ι → Ideal R
S : Finset ι
hp : (↑S).Pairwise fun i j => p i ⊔ p j = ⊤
q : ι → R
hq : (↑S).Pairwise (IsCoprime on q)
x✝ : ι
⊢ torsionBy R M (q x✝) = torsionBySet R M ↑(Ideal.span {q x✝})
state_after: no goals
Theorem: MeasureTheory.inter_ae_eq_empty_of_ae_eq_empty_right
File: Mathlib/MeasureTheory/OuterMeasure/AE.lean

tactic: convert ae_eq_set_inter (ae_eq_refl s) h
state_before: α : Type u_1
β : Type u_2
F : Type u_3
inst✝¹ : FunLike F (Set α) ℝ≥0∞
inst✝ : OuterMeasureClass F α
μ : F
s t : Set α
h : t =ᶠ[ae μ] ∅
⊢ s ∩ t =ᶠ[ae μ] ∅
state_after: case h.e'_5
α : Type u_1
β : Type u_2
F : Type u_3
inst✝¹ : FunLike F (Set α) ℝ≥0∞
inst✝ : OuterMeasureClass F α
μ : F
s t : Set α
h : t =ᶠ[ae μ] ∅
⊢ ∅ = s ∩ ∅

tactic: rw [inter_empty]
state_before: case h.e'_5
α : Type u_1
β : Type u_2
F : Type u_3
inst✝¹ : FunLike F (Set α) ℝ≥0∞
inst✝ : OuterMeasureClass F α
μ : F
s t : Set α
h : t =ᶠ[ae μ] ∅
⊢ ∅ = s ∩ ∅
state_after: no goals
Theorem: Set.InjOn.image_ssubset_image_iff
File: Mathlib/Data/Set/Function.lean

tactic: simp_rw [ssubset_def, h.image_subset_image_iff h₁ h₂, h.image_subset_image_iff h₂ h₁]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
ι : Sort u_4
π : α → Type u_5
s s₁ s₂ : Set α
t t₁ t₂ : Set β
p : Set γ
f f₁ f₂ f₃ : α → β
g g₁ g₂ : β → γ
f' f₁' f₂' : β → α
g' : γ → β
a : α
b : β
h : InjOn f s
h₁ : s₁ ⊆ s
h₂ : s₂ ⊆ s
⊢ f '' s₁ ⊂ f '' s₂ ↔ s₁ ⊂ s₂
state_after: no goals
Theorem: CategoryTheory.StructuredArrow.homMk'_comp
File: Mathlib/CategoryTheory/Comma/StructuredArrow.lean

tactic: simp
state_before: C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
D : Type u₂
inst✝ : Category.{v₂, u₂} D
S S' S'' : D
Y Y' Y'' : C
T T' : C ⥤ D
f : StructuredArrow S T
g : f.right ⟶ Y'
g' : Y' ⟶ Y''
⊢ mk ((mk (f.hom ≫ T.map g)).hom ≫ T.map g') = mk (f.hom ≫ T.map (g ≫ g'))
state_after: no goals

tactic: ext
state_before: C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
D : Type u₂
inst✝ : Category.{v₂, u₂} D
S S' S'' : D
Y Y' Y'' : C
T T' : C ⥤ D
f : StructuredArrow S T
g : f.right ⟶ Y'
g' : Y' ⟶ Y''
⊢ f.homMk' (g ≫ g') = f.homMk' g ≫ (mk (f.hom ≫ T.map g)).homMk' g' ≫ eqToHom ⋯
state_after: case h
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
D : Type u₂
inst✝ : Category.{v₂, u₂} D
S S' S'' : D
Y Y' Y'' : C
T T' : C ⥤ D
f : StructuredArrow S T
g : f.right ⟶ Y'
g' : Y' ⟶ Y''
⊢ (f.homMk' (g ≫ g')).right = (f.homMk' g ≫ (mk (f.hom ≫ T.map g)).homMk' g' ≫ eqToHom ⋯).right

tactic: simp [eqToHom_right]
state_before: case h
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
D : Type u₂
inst✝ : Category.{v₂, u₂} D
S S' S'' : D
Y Y' Y'' : C
T T' : C ⥤ D
f : StructuredArrow S T
g : f.right ⟶ Y'
g' : Y' ⟶ Y''
⊢ (f.homMk' (g ≫ g')).right = (f.homMk' g ≫ (mk (f.hom ≫ T.map g)).homMk' g' ≫ eqToHom ⋯).right
state_after: no goals
Theorem: smoothManifoldWithCorners_of_contDiffOn
File: Mathlib/Geometry/Manifold/SmoothManifoldWithCorners.lean

tactic: haveI : HasGroupoid M (contDiffGroupoid ∞ I) := hasGroupoid_of_pregroupoid _ (h _ _)
state_before: 𝕜 : Type u_1
inst✝⁵ : NontriviallyNormedField 𝕜
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace 𝕜 E
H : Type u_3
inst✝² : TopologicalSpace H
I : ModelWithCorners 𝕜 E H
M : Type u_4
inst✝¹ : TopologicalSpace M
inst✝ : ChartedSpace H M
h :
  ∀ (e e' : PartialHomeomorph M H),
    e ∈ atlas H M →
      e' ∈ atlas H M → ContDiffOn 𝕜 ⊤ (↑I ∘ ↑(e.symm ≫ₕ e') ∘ ↑I.symm) (↑I.symm ⁻¹' (e.symm ≫ₕ e').source ∩ range ↑I)
⊢ ∀ {e e' : PartialHomeomorph M H}, e ∈ atlas H M → e' ∈ atlas H M → e.symm ≫ₕ e' ∈ contDiffGroupoid ⊤ I
state_after: 𝕜 : Type u_1
inst✝⁵ : NontriviallyNormedField 𝕜
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace 𝕜 E
H : Type u_3
inst✝² : TopologicalSpace H
I : ModelWithCorners 𝕜 E H
M : Type u_4
inst✝¹ : TopologicalSpace M
inst✝ : ChartedSpace H M
h :
  ∀ (e e' : PartialHomeomorph M H),
    e ∈ atlas H M →
      e' ∈ atlas H M → ContDiffOn 𝕜 ⊤ (↑I ∘ ↑(e.symm ≫ₕ e') ∘ ↑I.symm) (↑I.symm ⁻¹' (e.symm ≫ₕ e').source ∩ range ↑I)
this : HasGroupoid M (contDiffGroupoid ⊤ I)
⊢ ∀ {e e' : PartialHomeomorph M H}, e ∈ atlas H M → e' ∈ atlas H M → e.symm ≫ₕ e' ∈ contDiffGroupoid ⊤ I

tactic: apply StructureGroupoid.compatible
state_before: 𝕜 : Type u_1
inst✝⁵ : NontriviallyNormedField 𝕜
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace 𝕜 E
H : Type u_3
inst✝² : TopologicalSpace H
I : ModelWithCorners 𝕜 E H
M : Type u_4
inst✝¹ : TopologicalSpace M
inst✝ : ChartedSpace H M
h :
  ∀ (e e' : PartialHomeomorph M H),
    e ∈ atlas H M →
      e' ∈ atlas H M → ContDiffOn 𝕜 ⊤ (↑I ∘ ↑(e.symm ≫ₕ e') ∘ ↑I.symm) (↑I.symm ⁻¹' (e.symm ≫ₕ e').source ∩ range ↑I)
this : HasGroupoid M (contDiffGroupoid ⊤ I)
⊢ ∀ {e e' : PartialHomeomorph M H}, e ∈ atlas H M → e' ∈ atlas H M → e.symm ≫ₕ e' ∈ contDiffGroupoid ⊤ I
state_after: no goals
Theorem: mem_nhds_discrete
File: Mathlib/Topology/Order.lean

tactic: rw [nhds_discrete, mem_pure]
state_before: α : Type u_1
t t₁ t₂ : TopologicalSpace α
s✝ : Set α
inst✝¹ : TopologicalSpace α
inst✝ : DiscreteTopology α
β : Type u_2
x : α
s : Set α
⊢ s ∈ 𝓝 x ↔ x ∈ s
state_after: no goals
Theorem: AlgebraicTopology.DoldKan.N₁Γ₀_hom_app_f_f
File: Mathlib/AlgebraicTopology/DoldKan/GammaCompN.lean

tactic: rw [N₁Γ₀_hom_app]
state_before: C : Type u_1
inst✝² : Category.{u_2, u_1} C
inst✝¹ : Preadditive C
inst✝ : HasFiniteCoproducts C
K : ChainComplex C ℕ
n : ℕ
⊢ (N₁Γ₀.hom.app K).f.f n = (Γ₀.splitting K).toKaroubiNondegComplexIsoN₁.inv.f.f n
state_after: C : Type u_1
inst✝² : Category.{u_2, u_1} C
inst✝¹ : Preadditive C
inst✝ : HasFiniteCoproducts C
K : ChainComplex C ℕ
n : ℕ
⊢ ((Γ₀.splitting K).toKaroubiNondegComplexIsoN₁.inv ≫ (toKaroubi (ChainComplex C ℕ)).map (Γ₀NondegComplexIso K).hom).f.f
      n =
    (Γ₀.splitting K).toKaroubiNondegComplexIsoN₁.inv.f.f n

tactic: apply comp_id
state_before: C : Type u_1
inst✝² : Category.{u_2, u_1} C
inst✝¹ : Preadditive C
inst✝ : HasFiniteCoproducts C
K : ChainComplex C ℕ
n : ℕ
⊢ ((Γ₀.splitting K).toKaroubiNondegComplexIsoN₁.inv ≫ (toKaroubi (ChainComplex C ℕ)).map (Γ₀NondegComplexIso K).hom).f.f
      n =
    (Γ₀.splitting K).toKaroubiNondegComplexIsoN₁.inv.f.f n
state_after: no goals
Theorem: iteratedFDeriv_const_of_ne
File: Mathlib/Analysis/Calculus/ContDiff/Basic.lean

tactic: simpa [← iteratedFDerivWithin_univ] using
iteratedFDerivWithin_const_of_ne hn c uniqueDiffOn_univ (mem_univ x)
state_before: 𝕜 : Type u_1
inst✝¹⁰ : NontriviallyNormedField 𝕜
D : Type uD
inst✝⁹ : NormedAddCommGroup D
inst✝⁸ : NormedSpace 𝕜 D
E : Type uE
inst✝⁷ : NormedAddCommGroup E
inst✝⁶ : NormedSpace 𝕜 E
F : Type uF
inst✝⁵ : NormedAddCommGroup F
inst✝⁴ : NormedSpace 𝕜 F
G : Type uG
inst✝³ : NormedAddCommGroup G
inst✝² : NormedSpace 𝕜 G
X : Type u_2
inst✝¹ : NormedAddCommGroup X
inst✝ : NormedSpace 𝕜 X
s s₁ t u : Set E
f f₁ : E → F
g : F → G
x✝ x₀ : E
c✝ : F
b : E × F → G
m n✝ : ℕ∞
p : E → FormalMultilinearSeries 𝕜 E F
n : ℕ
hn : n ≠ 0
c : F
x : E
⊢ iteratedFDeriv 𝕜 n (fun x => c) x = 0 x
state_after: no goals
Theorem: StarAlgebra.adjoin_eq_span
File: Mathlib/Algebra/Star/Subalgebra.lean

tactic: rw [adjoin_toSubalgebra, Algebra.adjoin_eq_span]
state_before: F : Type u_1
R : Type u_2
A : Type u_3
B : Type u_4
inst✝⁹ : CommSemiring R
inst✝⁸ : StarRing R
inst✝⁷ : Semiring A
inst✝⁶ : Algebra R A
inst✝⁵ : StarRing A
inst✝⁴ : StarModule R A
inst✝³ : Semiring B
inst✝² : Algebra R B
inst✝¹ : StarRing B
inst✝ : StarModule R B
s : Set A
⊢ Subalgebra.toSubmodule (adjoin R s).toSubalgebra = span R ↑(Submonoid.closure (s ∪ star s))
state_after: no goals
Theorem: List.length_merge
File: .lake/packages/batteries/Batteries/Data/List/Lemmas.lean

tactic: simp
state_before: α : Type u_1
s : α → α → Bool
l r✝ r : List α
⊢ (merge s [] r).length = [].length + r.length
state_after: no goals

tactic: simp
state_before: α : Type u_1
s : α → α → Bool
l✝ r l : List α
⊢ (merge s l []).length = l.length + [].length
state_after: no goals

tactic: rw [cons_merge_cons]
state_before: α : Type u_1
s : α → α → Bool
l✝ r✝ : List α
a : α
l : List α
b : α
r : List α
⊢ (merge s (a :: l) (b :: r)).length = (a :: l).length + (b :: r).length
state_after: α : Type u_1
s : α → α → Bool
l✝ r✝ : List α
a : α
l : List α
b : α
r : List α
⊢ (if s a b = true then a :: merge s l (b :: r) else b :: merge s (a :: l) r).length = (a :: l).length + (b :: r).length

tactic: split
state_before: α : Type u_1
s : α → α → Bool
l✝ r✝ : List α
a : α
l : List α
b : α
r : List α
⊢ (if s a b = true then a :: merge s l (b :: r) else b :: merge s (a :: l) r).length = (a :: l).length + (b :: r).length
state_after: case isTrue
α : Type u_1
s : α → α → Bool
l✝ r✝ : List α
a : α
l : List α
b : α
r : List α
h✝ : s a b = true
⊢ (a :: merge s l (b :: r)).length = (a :: l).length + (b :: r).length

case isFalse
α : Type u_1
s : α → α → Bool
l✝ r✝ : List α
a : α
l : List α
b : α
r : List α
h✝ : ¬s a b = true
⊢ (b :: merge s (a :: l) r).length = (a :: l).length + (b :: r).length

tactic: simp_arith [length_merge s l (b::r)]
state_before: case isTrue
α : Type u_1
s : α → α → Bool
l✝ r✝ : List α
a : α
l : List α
b : α
r : List α
h✝ : s a b = true
⊢ (a :: merge s l (b :: r)).length = (a :: l).length + (b :: r).length
state_after: no goals

tactic: simp_arith [length_merge s (a::l) r]
state_before: case isFalse
α : Type u_1
s : α → α → Bool
l✝ r✝ : List α
a : α
l : List α
b : α
r : List α
h✝ : ¬s a b = true
⊢ (b :: merge s (a :: l) r).length = (a :: l).length + (b :: r).length
state_after: no goals
Theorem: HNNExtension.toSubgroupEquiv_neg_apply
File: Mathlib/GroupTheory/HNNExtension.lean

tactic: rcases Int.units_eq_one_or u with rfl | rfl
state_before: G : Type u_1
inst✝² : Group G
A B : Subgroup G
φ : ↥A ≃* ↥B
H : Type u_2
inst✝¹ : Group H
M : Type u_3
inst✝ : Monoid M
u : ℤˣ
a : ↥(toSubgroup A B u)
⊢ ↑((toSubgroupEquiv φ (-u)) ((toSubgroupEquiv φ u) a)) = ↑a
state_after: case inl
G : Type u_1
inst✝² : Group G
A B : Subgroup G
φ : ↥A ≃* ↥B
H : Type u_2
inst✝¹ : Group H
M : Type u_3
inst✝ : Monoid M
a : ↥(toSubgroup A B 1)
⊢ ↑((toSubgroupEquiv φ (-1)) ((toSubgroupEquiv φ 1) a)) = ↑a

case inr
G : Type u_1
inst✝² : Group G
A B : Subgroup G
φ : ↥A ≃* ↥B
H : Type u_2
inst✝¹ : Group H
M : Type u_3
inst✝ : Monoid M
a : ↥(toSubgroup A B (-1))
⊢ ↑((toSubgroupEquiv φ (- -1)) ((toSubgroupEquiv φ (-1)) a)) = ↑a

tactic: simp
state_before: case inl
G : Type u_1
inst✝² : Group G
A B : Subgroup G
φ : ↥A ≃* ↥B
H : Type u_2
inst✝¹ : Group H
M : Type u_3
inst✝ : Monoid M
a : ↥(toSubgroup A B 1)
⊢ ↑((toSubgroupEquiv φ (-1)) ((toSubgroupEquiv φ 1) a)) = ↑a
state_after: case inl
G : Type u_1
inst✝² : Group G
A B : Subgroup G
φ : ↥A ≃* ↥B
H : Type u_2
inst✝¹ : Group H
M : Type u_3
inst✝ : Monoid M
a : ↥(toSubgroup A B 1)
⊢ φ.symm (φ a) = a

tactic: erw [MulEquiv.symm_apply_apply]
state_before: case inl
G : Type u_1
inst✝² : Group G
A B : Subgroup G
φ : ↥A ≃* ↥B
H : Type u_2
inst✝¹ : Group H
M : Type u_3
inst✝ : Monoid M
a : ↥(toSubgroup A B 1)
⊢ φ.symm (φ a) = a
state_after: no goals

tactic: simp only [toSubgroup_neg_one, toSubgroupEquiv_neg_one, SetLike.coe_eq_coe]
state_before: case inr
G : Type u_1
inst✝² : Group G
A B : Subgroup G
φ : ↥A ≃* ↥B
H : Type u_2
inst✝¹ : Group H
M : Type u_3
inst✝ : Monoid M
a : ↥(toSubgroup A B (-1))
⊢ ↑((toSubgroupEquiv φ (- -1)) ((toSubgroupEquiv φ (-1)) a)) = ↑a
state_after: case inr
G : Type u_1
inst✝² : Group G
A B : Subgroup G
φ : ↥A ≃* ↥B
H : Type u_2
inst✝¹ : Group H
M : Type u_3
inst✝ : Monoid M
a : ↥(toSubgroup A B (-1))
⊢ (toSubgroupEquiv φ (- -1)) (φ.symm a) = a

tactic: exact φ.apply_symm_apply a
state_before: case inr
G : Type u_1
inst✝² : Group G
A B : Subgroup G
φ : ↥A ≃* ↥B
H : Type u_2
inst✝¹ : Group H
M : Type u_3
inst✝ : Monoid M
a : ↥(toSubgroup A B (-1))
⊢ (toSubgroupEquiv φ (- -1)) (φ.symm a) = a
state_after: no goals
Theorem: ProbabilityTheory.condDistrib_apply_of_ne_zero
File: Mathlib/Probability/Kernel/CondDistrib.lean

tactic: rw [condDistrib, Measure.condKernel_apply_of_ne_zero _ s]
state_before: α : Type u_1
β : Type u_2
Ω : Type u_3
F : Type u_4
inst✝⁵ : MeasurableSpace Ω
inst✝⁴ : StandardBorelSpace Ω
inst✝³ : Nonempty Ω
inst✝² : NormedAddCommGroup F
mα : MeasurableSpace α
μ : Measure α
inst✝¹ : IsFiniteMeasure μ
X : α → β
Y : α → Ω
mβ : MeasurableSpace β
s✝ : Set Ω
t : Set β
f : β × Ω → F
inst✝ : MeasurableSingletonClass β
hY : Measurable Y
x : β
hX : (Measure.map X μ) {x} ≠ 0
s : Set Ω
⊢ ((condDistrib Y X μ) x) s = ((Measure.map X μ) {x})⁻¹ * (Measure.map (fun a => (X a, Y a)) μ) ({x} ×ˢ s)
state_after: α : Type u_1
β : Type u_2
Ω : Type u_3
F : Type u_4
inst✝⁵ : MeasurableSpace Ω
inst✝⁴ : StandardBorelSpace Ω
inst✝³ : Nonempty Ω
inst✝² : NormedAddCommGroup F
mα : MeasurableSpace α
μ : Measure α
inst✝¹ : IsFiniteMeasure μ
X : α → β
Y : α → Ω
mβ : MeasurableSpace β
s✝ : Set Ω
t : Set β
f : β × Ω → F
inst✝ : MeasurableSingletonClass β
hY : Measurable Y
x : β
hX : (Measure.map X μ) {x} ≠ 0
s : Set Ω
⊢ ((Measure.map (fun a => (X a, Y a)) μ).fst {x})⁻¹ * (Measure.map (fun a => (X a, Y a)) μ) ({x} ×ˢ s) =
    ((Measure.map X μ) {x})⁻¹ * (Measure.map (fun a => (X a, Y a)) μ) ({x} ×ˢ s)

α : Type u_1
β : Type u_2
Ω : Type u_3
F : Type u_4
inst✝⁵ : MeasurableSpace Ω
inst✝⁴ : StandardBorelSpace Ω
inst✝³ : Nonempty Ω
inst✝² : NormedAddCommGroup F
mα : MeasurableSpace α
μ : Measure α
inst✝¹ : IsFiniteMeasure μ
X : α → β
Y : α → Ω
mβ : MeasurableSpace β
s✝ : Set Ω
t : Set β
f : β × Ω → F
inst✝ : MeasurableSingletonClass β
hY : Measurable Y
x : β
hX : (Measure.map X μ) {x} ≠ 0
s : Set Ω
⊢ (Measure.map (fun a => (X a, Y a)) μ).fst {x} ≠ 0

tactic: rw [Measure.fst_map_prod_mk hY]
state_before: α : Type u_1
β : Type u_2
Ω : Type u_3
F : Type u_4
inst✝⁵ : MeasurableSpace Ω
inst✝⁴ : StandardBorelSpace Ω
inst✝³ : Nonempty Ω
inst✝² : NormedAddCommGroup F
mα : MeasurableSpace α
μ : Measure α
inst✝¹ : IsFiniteMeasure μ
X : α → β
Y : α → Ω
mβ : MeasurableSpace β
s✝ : Set Ω
t : Set β
f : β × Ω → F
inst✝ : MeasurableSingletonClass β
hY : Measurable Y
x : β
hX : (Measure.map X μ) {x} ≠ 0
s : Set Ω
⊢ ((Measure.map (fun a => (X a, Y a)) μ).fst {x})⁻¹ * (Measure.map (fun a => (X a, Y a)) μ) ({x} ×ˢ s) =
    ((Measure.map X μ) {x})⁻¹ * (Measure.map (fun a => (X a, Y a)) μ) ({x} ×ˢ s)
state_after: no goals

tactic: rwa [Measure.fst_map_prod_mk hY]
state_before: α : Type u_1
β : Type u_2
Ω : Type u_3
F : Type u_4
inst✝⁵ : MeasurableSpace Ω
inst✝⁴ : StandardBorelSpace Ω
inst✝³ : Nonempty Ω
inst✝² : NormedAddCommGroup F
mα : MeasurableSpace α
μ : Measure α
inst✝¹ : IsFiniteMeasure μ
X : α → β
Y : α → Ω
mβ : MeasurableSpace β
s✝ : Set Ω
t : Set β
f : β × Ω → F
inst✝ : MeasurableSingletonClass β
hY : Measurable Y
x : β
hX : (Measure.map X μ) {x} ≠ 0
s : Set Ω
⊢ (Measure.map (fun a => (X a, Y a)) μ).fst {x} ≠ 0
state_after: no goals