ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
Theorem: Equiv.piSplitAt_symm_apply
File: Mathlib/Logic/Equiv/Basic.lean

Proof steps:
state_before: α : Type u_1
inst✝ : DecidableEq α
i : α
β : α → Type u_2
f : β i × ((j : { j // j ≠ i }) → β ↑j)
⊢ (fun f => (f i, fun j => f ↑j)) ((fun f j => if h : j = i then ⋯ ▸ f.1 else f.2 ⟨j, h⟩) f) = f
state_after: case a
α : Type u_1
inst✝ : DecidableEq α
i : α
β : α → Type u_2
f : β i × ((j : { j // j ≠ i }) → β ↑j)
⊢ ((fun f => (f i, fun j => f ↑j)) ((fun f j => if h : j = i then ⋯ ▸ f.1 else f.2 ⟨j, h⟩) f)).1 = f.1

case a.h
α : Type u_1
inst✝ : DecidableEq α
i : α
β : α → Type u_2
f : β i × ((j : { j // j ≠ i }) → β ↑j)
x : { j // j ≠ i }
⊢ ((fun f => (f i, fun j => f ↑j)) ((fun f j => if h : j = i then ⋯ ▸ f.1 else f.2 ⟨j, h⟩) f)).2 x = f.2 x
tactic: ext x
state_before: case a
α : Type u_1
inst✝ : DecidableEq α
i : α
β : α → Type u_2
f : β i × ((j : { j // j ≠ i }) → β ↑j)
⊢ ((fun f => (f i, fun j => f ↑j)) ((fun f j => if h : j = i then ⋯ ▸ f.1 else f.2 ⟨j, h⟩) f)).1 = f.1

case a.h
α : Type u_1
inst✝ : DecidableEq α
i : α
β : α → Type u_2
f : β i × ((j : { j // j ≠ i }) → β ↑j)
x : { j // j ≠ i }
⊢ ((fun f => (f i, fun j => f ↑j)) ((fun f j => if h : j = i then ⋯ ▸ f.1 else f.2 ⟨j, h⟩) f)).2 x = f.2 x
state_after: no goals
tactic: exacts [dif_pos rfl, (dif_neg x.2).trans (by cases x; rfl)]
state_before: α : Type u_1
inst✝ : DecidableEq α
i : α
β : α → Type u_2
f : (j : α) → β j
⊢ (fun f j => if h : j = i then ⋯ ▸ f.1 else f.2 ⟨j, h⟩) ((fun f => (f i, fun j => f ↑j)) f) = f
state_after: case h
α : Type u_1
inst✝ : DecidableEq α
i : α
β : α → Type u_2
f : (j : α) → β j
x : α
⊢ (fun f j => if h : j = i then ⋯ ▸ f.1 else f.2 ⟨j, h⟩) ((fun f => (f i, fun j => f ↑j)) f) x = f x
tactic: ext x
state_before: case h
α : Type u_1
inst✝ : DecidableEq α
i : α
β : α → Type u_2
f : (j : α) → β j
x : α
⊢ (fun f j => if h : j = i then ⋯ ▸ f.1 else f.2 ⟨j, h⟩) ((fun f => (f i, fun j => f ↑j)) f) x = f x
state_after: case h
α : Type u_1
inst✝ : DecidableEq α
i : α
β : α → Type u_2
f : (j : α) → β j
x : α
⊢ (if h : x = i then ⋯ ▸ f i else f x) = f x
tactic: dsimp only
state_before: case h
α : Type u_1
inst✝ : DecidableEq α
i : α
β : α → Type u_2
f : (j : α) → β j
x : α
⊢ (if h : x = i then ⋯ ▸ f i else f x) = f x
state_after: case pos
α : Type u_1
inst✝ : DecidableEq α
i : α
β : α → Type u_2
f : (j : α) → β j
x : α
h : x = i
⊢ ⋯ ▸ f i = f x

case neg
α : Type u_1
inst✝ : DecidableEq α
i : α
β : α → Type u_2
f : (j : α) → β j
x : α
h : ¬x = i
⊢ f x = f x
tactic: split_ifs with h
Theorem: ProbabilityTheory.gammaPDFReal_nonneg
File: Mathlib/Probability/Distributions/Gamma.lean

Proof steps:
state_before: a r : ℝ
ha : 0 < a
hr : 0 < r
x : ℝ
⊢ 0 ≤ gammaPDFReal a r x
state_after: a r : ℝ
ha : 0 < a
hr : 0 < r
x : ℝ
⊢ 0 ≤ if 0 ≤ x then r ^ a / Gamma a * x ^ (a - 1) * rexp (-(r * x)) else 0
tactic: unfold gammaPDFReal
state_before: a r : ℝ
ha : 0 < a
hr : 0 < r
x : ℝ
⊢ 0 ≤ if 0 ≤ x then r ^ a / Gamma a * x ^ (a - 1) * rexp (-(r * x)) else 0
state_after: no goals
tactic: split_ifs <;> positivity
Theorem: MeasureTheory.quasiMeasurePreserving_add_right
File: Mathlib/MeasureTheory/Group/Prod.lean

Proof steps:
state_before: G : Type u_1
inst✝⁶ : MeasurableSpace G
inst✝⁵ : Group G
inst✝⁴ : MeasurableMul₂ G
μ ν : Measure G
inst✝³ : SFinite ν
inst✝² : SFinite μ
s : Set G
inst✝¹ : MeasurableInv G
inst✝ : μ.IsMulLeftInvariant
g : G
⊢ QuasiMeasurePreserving (fun h => h * g) μ μ
state_after: G : Type u_1
inst✝⁶ : MeasurableSpace G
inst✝⁵ : Group G
inst✝⁴ : MeasurableMul₂ G
μ ν : Measure G
inst✝³ : SFinite ν
inst✝² : SFinite μ
s✝ : Set G
inst✝¹ : MeasurableInv G
inst✝ : μ.IsMulLeftInvariant
g : G
s : Set G
hs : MeasurableSet s
⊢ μ s = 0 → (map (fun h => h * g) μ) s = 0
tactic: refine ⟨measurable_mul_const g, AbsolutelyContinuous.mk fun s hs => ?_⟩
state_before: G : Type u_1
inst✝⁶ : MeasurableSpace G
inst✝⁵ : Group G
inst✝⁴ : MeasurableMul₂ G
μ ν : Measure G
inst✝³ : SFinite ν
inst✝² : SFinite μ
s✝ : Set G
inst✝¹ : MeasurableInv G
inst✝ : μ.IsMulLeftInvariant
g : G
s : Set G
hs : MeasurableSet s
⊢ μ s = 0 → (map (fun h => h * g) μ) s = 0
state_after: G : Type u_1
inst✝⁶ : MeasurableSpace G
inst✝⁵ : Group G
inst✝⁴ : MeasurableMul₂ G
μ ν : Measure G
inst✝³ : SFinite ν
inst✝² : SFinite μ
s✝ : Set G
inst✝¹ : MeasurableInv G
inst✝ : μ.IsMulLeftInvariant
g : G
s : Set G
hs : MeasurableSet s
⊢ μ s = 0 → μ s = 0
tactic: rw [map_apply (measurable_mul_const g) hs, measure_mul_right_null]
state_before: G : Type u_1
inst✝⁶ : MeasurableSpace G
inst✝⁵ : Group G
inst✝⁴ : MeasurableMul₂ G
μ ν : Measure G
inst✝³ : SFinite ν
inst✝² : SFinite μ
s✝ : Set G
inst✝¹ : MeasurableInv G
inst✝ : μ.IsMulLeftInvariant
g : G
s : Set G
hs : MeasurableSet s
⊢ μ s = 0 → μ s = 0
state_after: no goals
tactic: exact id
Theorem: UniqueFactorizationMonoid.factors_zero
File: Mathlib/RingTheory/UniqueFactorizationDomain.lean

Proof steps:
state_before: α : Type u_1
inst✝¹ : CancelCommMonoidWithZero α
inst✝ : UniqueFactorizationMonoid α
⊢ factors 0 = 0
state_after: no goals
tactic: simp [factors]
Theorem: MeasureTheory.LocallyIntegrableOn.integrableOn_of_isBigO_atBot
File: Mathlib/MeasureTheory/Integral/Asymptotics.lean

Proof steps:
state_before: α : Type u_1
E : Type u_2
F : Type u_3
inst✝⁷ : MeasurableSpace α
inst✝⁶ : NormedAddCommGroup E
inst✝⁵ : NormedAddCommGroup F
f : α → E
g : α → F
a b : α
μ : Measure α
l : Filter α
inst✝⁴ : TopologicalSpace α
inst✝³ : SecondCountableTopology α
inst✝² : LinearOrder α
inst✝¹ : CompactIccSpace α
g' : α → F
inst✝ : atBot.IsMeasurablyGenerated
hf : LocallyIntegrableOn f (Iic a) μ
ho : f =O[atBot] g
hg : IntegrableAtFilter g atBot μ
⊢ IntegrableOn f (Iic a) μ
state_after: α : Type u_1
E : Type u_2
F : Type u_3
inst✝⁷ : MeasurableSpace α
inst✝⁶ : NormedAddCommGroup E
inst✝⁵ : NormedAddCommGroup F
f : α → E
g : α → F
a b : α
μ : Measure α
l : Filter α
inst✝⁴ : TopologicalSpace α
inst✝³ : SecondCountableTopology α
inst✝² : LinearOrder α
inst✝¹ : CompactIccSpace α
g' : α → F
inst✝ : atBot.IsMeasurablyGenerated
hf : LocallyIntegrableOn f (Iic a) μ
ho : f =O[atBot] g
hg : IntegrableAtFilter g atBot μ
⊢ StronglyMeasurableAtFilter f atBot μ
tactic: refine integrableOn_Iic_iff_integrableAtFilter_atBot.mpr ⟨ho.integrableAtFilter ?_ hg, hf⟩
state_before: α : Type u_1
E : Type u_2
F : Type u_3
inst✝⁷ : MeasurableSpace α
inst✝⁶ : NormedAddCommGroup E
inst✝⁵ : NormedAddCommGroup F
f : α → E
g : α → F
a b : α
μ : Measure α
l : Filter α
inst✝⁴ : TopologicalSpace α
inst✝³ : SecondCountableTopology α
inst✝² : LinearOrder α
inst✝¹ : CompactIccSpace α
g' : α → F
inst✝ : atBot.IsMeasurablyGenerated
hf : LocallyIntegrableOn f (Iic a) μ
ho : f =O[atBot] g
hg : IntegrableAtFilter g atBot μ
⊢ StronglyMeasurableAtFilter f atBot μ
state_after: no goals
tactic: exact ⟨Iic a, Iic_mem_atBot a, hf.aestronglyMeasurable⟩
Theorem: Finset.offDiag_union
File: Mathlib/Data/Finset/Prod.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : DecidableEq α
s t : Finset α
x : α × α
h : _root_.Disjoint s t
⊢ ↑(s ∪ t).offDiag = ↑(s.offDiag ∪ t.offDiag ∪ s ×ˢ t ∪ t ×ˢ s)
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : DecidableEq α
s t : Finset α
x : α × α
h : _root_.Disjoint s t
⊢ (↑s ∪ ↑t).offDiag = (↑s).offDiag ∪ (↑t).offDiag ∪ ↑s ×ˢ ↑t ∪ ↑t ×ˢ ↑s
tactic: push_cast
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : DecidableEq α
s t : Finset α
x : α × α
h : _root_.Disjoint s t
⊢ (↑s ∪ ↑t).offDiag = (↑s).offDiag ∪ (↑t).offDiag ∪ ↑s ×ˢ ↑t ∪ ↑t ×ˢ ↑s
state_after: no goals
tactic: exact Set.offDiag_union (disjoint_coe.2 h)
Theorem: BoxIntegral.TaggedPrepartition.forall_mem_single
File: Mathlib/Analysis/BoxIntegral/Partition/Tagged.lean

Proof steps:
state_before: ι : Type u_1
I J : Box ι
π π₁ π₂ : TaggedPrepartition I
x : ι → ℝ
r r₁ r₂ : (ι → ℝ) → ↑(Ioi 0)
p : (ι → ℝ) → Box ι → Prop
hJ : J ≤ I
h : x ∈ Box.Icc I
⊢ (∀ J' ∈ single I J hJ x h, p ((single I J hJ x h).tag J') J') ↔ p x J
state_after: no goals
tactic: simp
Theorem: Nat.WithBot.coe_nonneg
File: Mathlib/Data/Nat/WithBot.lean

Proof steps:
state_before: n : ℕ
⊢ 0 ≤ ↑n
state_after: n : ℕ
⊢ 0 ≤ n
tactic: rw [← WithBot.coe_zero, cast_withBot, WithBot.coe_le_coe]
state_before: n : ℕ
⊢ 0 ≤ n
state_after: no goals
tactic: exact n.zero_le
Theorem: GaloisInsertion.l_iInf_of_ul_eq_self
File: Mathlib/Order/GaloisConnection.lean

Proof steps:
state_before: α : Type u
β : Type v
γ : Type w
ι✝ : Sort x
κ : ι✝ → Sort u_1
a a₁ a₂ : α
b b₁ b₂ : β
l : α → β
u : β → α
inst✝¹ : CompleteLattice α
inst✝ : CompleteLattice β
gi : GaloisInsertion l u
ι : Sort x
f : ι → α
hf : ∀ (i : ι), u (l (f i)) = f i
⊢ l (⨅ i, f i) = l (⨅ i, u (l (f i)))
state_after: no goals
tactic: simp [hf]
Theorem: MeasureTheory.Measure.everywherePosSubset_ae_eq
File: Mathlib/MeasureTheory/Measure/EverywherePos.lean

Proof steps:
state_before: α : Type u_1
inst✝³ : TopologicalSpace α
inst✝² : MeasurableSpace α
μ ν : Measure α
s k : Set α
inst✝¹ : OpensMeasurableSpace α
inst✝ : μ.InnerRegular
hs : MeasurableSet s
⊢ μ.everywherePosSubset s =ᶠ[ae μ] s
state_after: α : Type u_1
inst✝³ : TopologicalSpace α
inst✝² : MeasurableSpace α
μ ν : Measure α
s k : Set α
inst✝¹ : OpensMeasurableSpace α
inst✝ : μ.InnerRegular
hs : MeasurableSet s
⊢ ∀ i ⊆ s \ μ.everywherePosSubset s, IsCompact i → μ i = 0
tactic: simp only [ae_eq_set, diff_eq_empty.mpr (everywherePosSubset_subset μ s), measure_empty,
    true_and, (hs.diff hs.everywherePosSubset).measure_eq_iSup_isCompact, ENNReal.iSup_eq_zero]
state_before: α : Type u_1
inst✝³ : TopologicalSpace α
inst✝² : MeasurableSpace α
μ ν : Measure α
s k : Set α
inst✝¹ : OpensMeasurableSpace α
inst✝ : μ.InnerRegular
hs : MeasurableSet s
⊢ ∀ i ⊆ s \ μ.everywherePosSubset s, IsCompact i → μ i = 0
state_after: α : Type u_1
inst✝³ : TopologicalSpace α
inst✝² : MeasurableSpace α
μ ν : Measure α
s k✝ : Set α
inst✝¹ : OpensMeasurableSpace α
inst✝ : μ.InnerRegular
hs : MeasurableSet s
k : Set α
hk : k ⊆ s \ μ.everywherePosSubset s
h'k : IsCompact k
⊢ μ k = 0
tactic: intro k hk h'k
state_before: α : Type u_1
inst✝³ : TopologicalSpace α
inst✝² : MeasurableSpace α
μ ν : Measure α
s k✝ : Set α
inst✝¹ : OpensMeasurableSpace α
inst✝ : μ.InnerRegular
hs : MeasurableSet s
k : Set α
hk : k ⊆ s \ μ.everywherePosSubset s
h'k : IsCompact k
⊢ μ k = 0
state_after: no goals
tactic: exact measure_eq_zero_of_subset_diff_everywherePosSubset h'k hk
Theorem: Polynomial.natSepDegree_one
File: Mathlib/FieldTheory/SeparableDegree.lean

Proof steps:
state_before: F : Type u
E : Type v
inst✝⁴ : Field F
inst✝³ : Field E
inst✝² : Algebra F E
K : Type w
inst✝¹ : Field K
inst✝ : Algebra F K
f : F[X]
⊢ natSepDegree 1 = 0
state_after: no goals
tactic: rw [← C_1, natSepDegree_C]
Theorem: WeierstrassCurve.ΨSq_neg
File: Mathlib/AlgebraicGeometry/EllipticCurve/DivisionPolynomial/Basic.lean

Proof steps:
state_before: R : Type r
S : Type s
inst✝¹ : CommRing R
inst✝ : CommRing S
W : WeierstrassCurve R
n : ℤ
⊢ W.ΨSq (-n) = W.ΨSq n
state_after: no goals
tactic: simp only [ΨSq, preΨ_neg, neg_sq, even_neg]
Theorem: IsSelfAdjoint.mem_spectrum_eq_re
File: Mathlib/Analysis/CstarAlgebra/Spectrum.lean

Proof steps:
state_before: A : Type u_1
inst✝⁵ : NormedRing A
inst✝⁴ : NormedAlgebra ℂ A
inst✝³ : CompleteSpace A
inst✝² : StarRing A
inst✝¹ : CstarRing A
inst✝ : StarModule ℂ A
a : A
ha : IsSelfAdjoint a
z : ℂ
hz : z ∈ spectrum ℂ a
⊢ z = ↑z.re
state_after: A : Type u_1
inst✝⁵ : NormedRing A
inst✝⁴ : NormedAlgebra ℂ A
inst✝³ : CompleteSpace A
inst✝² : StarRing A
inst✝¹ : CstarRing A
inst✝ : StarModule ℂ A
a : A
ha : IsSelfAdjoint a
z : ℂ
hz : z ∈ spectrum ℂ a
hu : NormedSpace.exp ℂ (I • a) ∈ unitary A
⊢ z = ↑z.re
tactic: have hu := exp_mem_unitary_of_mem_skewAdjoint ℂ (ha.smul_mem_skewAdjoint conj_I)
state_before: A : Type u_1
inst✝⁵ : NormedRing A
inst✝⁴ : NormedAlgebra ℂ A
inst✝³ : CompleteSpace A
inst✝² : StarRing A
inst✝¹ : CstarRing A
inst✝ : StarModule ℂ A
a : A
ha : IsSelfAdjoint a
z : ℂ
hz : z ∈ spectrum ℂ a
hu : NormedSpace.exp ℂ (I • a) ∈ unitary A
⊢ z = ↑z.re
state_after: A : Type u_1
inst✝⁵ : NormedRing A
inst✝⁴ : NormedAlgebra ℂ A
inst✝³ : CompleteSpace A
inst✝² : StarRing A
inst✝¹ : CstarRing A
inst✝ : StarModule ℂ A
a : A
ha : IsSelfAdjoint a
z : ℂ
hz : z ∈ spectrum ℂ a
hu : NormedSpace.exp ℂ (I • a) ∈ unitary A
Iu : ℂˣ := Units.mk0 I I_ne_zero
⊢ z = ↑z.re
tactic: let Iu := Units.mk0 I I_ne_zero
state_before: A : Type u_1
inst✝⁵ : NormedRing A
inst✝⁴ : NormedAlgebra ℂ A
inst✝³ : CompleteSpace A
inst✝² : StarRing A
inst✝¹ : CstarRing A
inst✝ : StarModule ℂ A
a : A
ha : IsSelfAdjoint a
z : ℂ
hz : z ∈ spectrum ℂ a
hu : NormedSpace.exp ℂ (I • a) ∈ unitary A
Iu : ℂˣ := Units.mk0 I I_ne_zero
⊢ z = ↑z.re
state_after: A : Type u_1
inst✝⁵ : NormedRing A
inst✝⁴ : NormedAlgebra ℂ A
inst✝³ : CompleteSpace A
inst✝² : StarRing A
inst✝¹ : CstarRing A
inst✝ : StarModule ℂ A
a : A
ha : IsSelfAdjoint a
z : ℂ
hz : z ∈ spectrum ℂ a
hu : NormedSpace.exp ℂ (I • a) ∈ unitary A
Iu : ℂˣ := Units.mk0 I I_ne_zero
this : NormedSpace.exp ℂ (I • z) ∈ spectrum ℂ (NormedSpace.exp ℂ (I • a))
⊢ z = ↑z.re
tactic: have : NormedSpace.exp ℂ (I • z) ∈ spectrum ℂ (NormedSpace.exp ℂ (I • a)) := by
    simpa only [Units.smul_def, Units.val_mk0] using
      spectrum.exp_mem_exp (Iu • a) (smul_mem_smul_iff.mpr hz)
state_before: A : Type u_1
inst✝⁵ : NormedRing A
inst✝⁴ : NormedAlgebra ℂ A
inst✝³ : CompleteSpace A
inst✝² : StarRing A
inst✝¹ : CstarRing A
inst✝ : StarModule ℂ A
a : A
ha : IsSelfAdjoint a
z : ℂ
hz : z ∈ spectrum ℂ a
hu : NormedSpace.exp ℂ (I • a) ∈ unitary A
Iu : ℂˣ := Units.mk0 I I_ne_zero
this : NormedSpace.exp ℂ (I • z) ∈ spectrum ℂ (NormedSpace.exp ℂ (I • a))
⊢ z = ↑z.re
state_after: no goals
tactic: exact Complex.ext (ofReal_re _) <| by
    simpa only [← Complex.exp_eq_exp_ℂ, mem_sphere_zero_iff_norm, norm_eq_abs, abs_exp,
      Real.exp_eq_one_iff, smul_eq_mul, I_mul, neg_eq_zero] using
      spectrum.subset_circle_of_unitary hu this
Theorem: PiNat.apply_eq_of_dist_lt
File: Mathlib/Topology/MetricSpace/PiNat.lean

Proof steps:
state_before: E : ℕ → Type u_1
x y : (n : ℕ) → E n
n : ℕ
h : dist x y < (1 / 2) ^ n
i : ℕ
hi : i ≤ n
⊢ x i = y i
state_after: case inl
E : ℕ → Type u_1
x : (n : ℕ) → E n
n i : ℕ
hi : i ≤ n
h : dist x x < (1 / 2) ^ n
⊢ x i = x i

case inr
E : ℕ → Type u_1
x y : (n : ℕ) → E n
n : ℕ
h : dist x y < (1 / 2) ^ n
i : ℕ
hi : i ≤ n
hne : x ≠ y
⊢ x i = y i
tactic: rcases eq_or_ne x y with (rfl | hne)
state_before: case inr
E : ℕ → Type u_1
x y : (n : ℕ) → E n
n : ℕ
h : dist x y < (1 / 2) ^ n
i : ℕ
hi : i ≤ n
hne : x ≠ y
⊢ x i = y i
state_after: case inr
E : ℕ → Type u_1
x y : (n : ℕ) → E n
n : ℕ
h : dist x y < (1 / 2) ^ n
i : ℕ
hi : i ≤ n
hne : x ≠ y
this : n < firstDiff x y
⊢ x i = y i
tactic: have : n < firstDiff x y := by
    simpa [dist_eq_of_ne hne, inv_lt_inv, pow_lt_pow_iff_right, one_lt_two] using h
state_before: case inr
E : ℕ → Type u_1
x y : (n : ℕ) → E n
n : ℕ
h : dist x y < (1 / 2) ^ n
i : ℕ
hi : i ≤ n
hne : x ≠ y
this : n < firstDiff x y
⊢ x i = y i
state_after: no goals
tactic: exact apply_eq_of_lt_firstDiff (hi.trans_lt this)
Theorem: Multiset.antidiagonal_map_snd
File: Mathlib/Data/Multiset/Antidiagonal.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
s : Multiset α
l : List α
⊢ map Prod.snd (antidiagonal ⟦l⟧) = powerset ⟦l⟧
state_after: no goals
tactic: simp [powersetAux']
Theorem: Mathlib.Meta.NormNum.isNat_ratCast
File: Mathlib/Tactic/NormNum/Inv.lean

Proof steps:
state_before: u : Lean.Level
R : Type u_1
inst✝ : DivisionRing R
n✝ : ℕ
⊢ ↑↑n✝ = ↑n✝
state_after: no goals
tactic: simp
Theorem: Polynomial.revAtFun_invol
File: Mathlib/Algebra/Polynomial/Reverse.lean

Proof steps:
state_before: R : Type u_1
inst✝ : Semiring R
f : R[X]
N i : ℕ
⊢ revAtFun N (revAtFun N i) = i
state_after: R : Type u_1
inst✝ : Semiring R
f : R[X]
N i : ℕ
⊢ (if (if i ≤ N then N - i else i) ≤ N then N - if i ≤ N then N - i else i else if i ≤ N then N - i else i) = i
tactic: unfold revAtFun
state_before: R : Type u_1
inst✝ : Semiring R
f : R[X]
N i : ℕ
⊢ (if (if i ≤ N then N - i else i) ≤ N then N - if i ≤ N then N - i else i else if i ≤ N then N - i else i) = i
state_after: case pos
R : Type u_1
inst✝ : Semiring R
f : R[X]
N i : ℕ
h : i ≤ N
j : N - i ≤ N
⊢ N - (N - i) = i

case neg
R : Type u_1
inst✝ : Semiring R
f : R[X]
N i : ℕ
h : i ≤ N
j : ¬N - i ≤ N
⊢ N - i = i

case neg
R : Type u_1
inst✝ : Semiring R
f : R[X]
N i : ℕ
h : ¬i ≤ N
⊢ i = i
tactic: split_ifs with h j
Theorem: map_comp_mul_inv
File: Mathlib/Algebra/Group/Hom/Defs.lean

Proof steps:
state_before: ι : Type u_1
α : Type u_2
β : Type u_3
M : Type u_4
N : Type u_5
P : Type u_6
G : Type u_7
H : Type u_8
F : Type u_9
inst✝⁶ : MulOneClass M
inst✝⁵ : MulOneClass N
inst✝⁴ : FunLike F M N
inst✝³ : FunLike F G H
inst✝² : Group G
inst✝¹ : DivisionMonoid H
inst✝ : MonoidHomClass F G H
f : F
g h : ι → G
⊢ ⇑f ∘ (g * h⁻¹) = ⇑f ∘ g * (⇑f ∘ h)⁻¹
state_after: no goals
tactic: simp
Theorem: Matroid.Indep.basis_iff_forall_insert_dep
File: Mathlib/Data/Matroid/Basic.lean

Proof steps:
state_before: α : Type u_1
M : Matroid α
B I J X Y : Set α
e : α
hI : M.Indep I
hIX : I ⊆ X
⊢ M.Basis I X ↔ ∀ e ∈ X \ I, M.Dep (insert e I)
state_after: α : Type u_1
M : Matroid α
B I J X Y : Set α
e : α
hI : M.Indep I
hIX : I ⊆ X
⊢ (∀ (J : Set α), M.Indep J → I ⊆ J → J ⊆ X → I = J) ∧ X ⊆ M.E ↔ ∀ e ∈ X \ I, M.Dep (insert e I)
tactic: rw [basis_iff', and_iff_right hIX, and_iff_right hI]
state_before: α : Type u_1
M : Matroid α
B I J X Y : Set α
e : α
hI : M.Indep I
hIX : I ⊆ X
⊢ (∀ (J : Set α), M.Indep J → I ⊆ J → J ⊆ X → I = J) ∧ X ⊆ M.E ↔ ∀ e ∈ X \ I, M.Dep (insert e I)
state_after: case refine_1
α : Type u_1
M : Matroid α
B I J X Y : Set α
e✝ : α
hI : M.Indep I
hIX : I ⊆ X
h : (∀ (J : Set α), M.Indep J → I ⊆ J → J ⊆ X → I = J) ∧ X ⊆ M.E
e : α
he : e ∈ X \ I
hi : M.Indep (insert e I)
⊢ e ∈ I

case refine_2
α : Type u_1
M : Matroid α
B I J✝ X Y : Set α
e✝ : α
hI : M.Indep I
hIX : I ⊆ X
h : ∀ e ∈ X \ I, M.Dep (insert e I)
J : Set α
hJ : M.Indep J
hIJ : I ⊆ J
hJX : J ⊆ X
e : α
heJ : e ∈ J
heI : e ∉ I
⊢ False

case refine_3
α : Type u_1
M : Matroid α
B I J X Y : Set α
e : α
hI : M.Indep I
hIX : I ⊆ X
h : ∀ e ∈ X \ I, M.Dep (insert e I)
⊢ X ⊆ M.E
tactic: refine ⟨fun h e he ↦ ⟨fun hi ↦ he.2 ?_, insert_subset (h.2 he.1) hI.subset_ground⟩,
    fun h ↦ ⟨fun J hJ hIJ hJX ↦ hIJ.antisymm (fun e heJ ↦ by_contra (fun heI ↦ ?_)), ?_⟩⟩
state_before: case refine_3
α : Type u_1
M : Matroid α
B I J X Y : Set α
e : α
hI : M.Indep I
hIX : I ⊆ X
h : ∀ e ∈ X \ I, M.Dep (insert e I)
⊢ X ⊆ M.E
state_after: case refine_3
α : Type u_1
M : Matroid α
B I J X Y : Set α
e : α
hI : M.Indep I
hIX : I ⊆ X
h : ∀ e ∈ X \ I, M.Dep (insert e I)
⊢ X \ I ⊆ M.E
tactic: rw [← diff_union_of_subset hIX, union_subset_iff, and_iff_left hI.subset_ground]
state_before: case refine_3
α : Type u_1
M : Matroid α
B I J X Y : Set α
e : α
hI : M.Indep I
hIX : I ⊆ X
h : ∀ e ∈ X \ I, M.Dep (insert e I)
⊢ X \ I ⊆ M.E
state_after: no goals
tactic: exact fun e he ↦ (h e he).subset_ground (mem_insert _ _)
Theorem: Ideal.prod.ext_iff
File: Mathlib/RingTheory/Ideal/Prod.lean

Proof steps:
state_before: R : Type u
S : Type v
inst✝¹ : Semiring R
inst✝ : Semiring S
I✝ I'✝ : Ideal R
J✝ J'✝ : Ideal S
I I' : Ideal R
J J' : Ideal S
⊢ I.prod J = I'.prod J' ↔ I = I' ∧ J = J'
state_after: no goals
tactic: simp only [← idealProdEquiv_symm_apply, idealProdEquiv.symm.injective.eq_iff, Prod.mk.inj_iff]
Theorem: algebraMap_mono
File: Mathlib/Algebra/Order/Module/Algebra.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
inst✝³ : OrderedCommSemiring α
inst✝² : OrderedSemiring β
inst✝¹ : Algebra α β
inst✝ : SMulPosMono α β
a a₁ a₂ : α
ha : a₁ ≤ a₂
⊢ (algebraMap α β) a₁ ≤ (algebraMap α β) a₂
state_after: no goals
tactic: simpa only [Algebra.algebraMap_eq_smul_one] using smul_le_smul_of_nonneg_right ha zero_le_one
Theorem: IsSMulRegular.mul_iff
File: Mathlib/Algebra/Regular/SMul.lean

Proof steps:
state_before: R : Type u_1
S : Type u_2
M : Type u_3
a b : R
s : S
inst✝² : CommSemigroup R
inst✝¹ : SMul R M
inst✝ : IsScalarTower R R M
⊢ IsSMulRegular M (a * b) ↔ IsSMulRegular M a ∧ IsSMulRegular M b
state_after: R : Type u_1
S : Type u_2
M : Type u_3
a b : R
s : S
inst✝² : CommSemigroup R
inst✝¹ : SMul R M
inst✝ : IsScalarTower R R M
⊢ IsSMulRegular M (a * b) ↔ IsSMulRegular M (a * b) ∧ IsSMulRegular M (b * a)
tactic: rw [← mul_and_mul_iff]
state_before: R : Type u_1
S : Type u_2
M : Type u_3
a b : R
s : S
inst✝² : CommSemigroup R
inst✝¹ : SMul R M
inst✝ : IsScalarTower R R M
⊢ IsSMulRegular M (a * b) ↔ IsSMulRegular M (a * b) ∧ IsSMulRegular M (b * a)
state_after: no goals
tactic: exact ⟨fun ab => ⟨ab, by rwa [mul_comm]⟩, fun rab => rab.1⟩
Theorem: Stream'.Seq1.join_join
File: Mathlib/Data/Seq/Seq.lean

Proof steps:
state_before: α : Type u
β : Type v
γ : Type w
SS : Seq (Seq1 (Seq1 α))
⊢ SS.join.join = (Seq.map join SS).join
state_after: case bisim
α : Type u
β : Type v
γ : Type w
SS : Seq (Seq1 (Seq1 α))
⊢ Seq.IsBisimulation fun s1 s2 => ∃ s SS, s1 = s.append SS.join.join ∧ s2 = s.append (Seq.map join SS).join

case r
α : Type u
β : Type v
γ : Type w
SS : Seq (Seq1 (Seq1 α))
⊢ ∃ s SS_1, SS.join.join = s.append SS_1.join.join ∧ (Seq.map join SS).join = s.append (Seq.map join SS_1).join
tactic: apply
    Seq.eq_of_bisim fun s1 s2 =>
      ∃ s SS,
        s1 = Seq.append s (Seq.join (Seq.join SS)) ∧ s2 = Seq.append s (Seq.join (Seq.map join SS))
Theorem: CategoryTheory.ShortComplex.unop_X₂
File: Mathlib/Algebra/Homology/ShortComplex/Basic.lean

Proof steps:
state_before: C : Type u_1
D : Type u_2
inst✝³ : Category.{?u.60429, u_1} C
inst✝² : Category.{?u.60433, u_2} D
inst✝¹ : HasZeroMorphisms C
S✝ S₁ S₂ S₃ : ShortComplex C
inst✝ : HasZeroMorphisms D
S : ShortComplex Cᵒᵖ
⊢ S.g.unop ≫ S.f.unop = 0
state_after: C : Type u_1
D : Type u_2
inst✝³ : Category.{?u.60429, u_1} C
inst✝² : Category.{?u.60433, u_2} D
inst✝¹ : HasZeroMorphisms C
S✝ S₁ S₂ S₃ : ShortComplex C
inst✝ : HasZeroMorphisms D
S : ShortComplex Cᵒᵖ
⊢ Quiver.Hom.unop 0 = 0
tactic: simp only [← unop_comp, S.zero]
state_before: C : Type u_1
D : Type u_2
inst✝³ : Category.{?u.60429, u_1} C
inst✝² : Category.{?u.60433, u_2} D
inst✝¹ : HasZeroMorphisms C
S✝ S₁ S₂ S₃ : ShortComplex C
inst✝ : HasZeroMorphisms D
S : ShortComplex Cᵒᵖ
⊢ Quiver.Hom.unop 0 = 0
state_after: no goals
tactic: rfl
Theorem: MeasureTheory.Measure.map_snd_prod
File: Mathlib/MeasureTheory/Constructions/Prod/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
inst✝⁶ : MeasurableSpace α
inst✝⁵ : MeasurableSpace α'
inst✝⁴ : MeasurableSpace β
inst✝³ : MeasurableSpace β'
inst✝² : MeasurableSpace γ
μ μ' : Measure α
ν ν' : Measure β
τ : Measure γ
inst✝¹ : NormedAddCommGroup E
inst✝ : SFinite ν
⊢ map Prod.snd (μ.prod ν) = μ univ • ν
state_after: case h
α : Type u_1
α' : Type u_2
β : Type u_3
β' : Type u_4
γ : Type u_5
E : Type u_6
inst✝⁶ : MeasurableSpace α
inst✝⁵ : MeasurableSpace α'
inst✝⁴ : MeasurableSpace β
inst✝³ : MeasurableSpace β'
inst✝² : MeasurableSpace γ
μ μ' : Measure α
ν ν' : Measure β
τ : Measure γ
inst✝¹ : NormedAddCommGroup E
inst✝ : SFinite ν
s : Set β
hs : MeasurableSet s
⊢ (map Prod.snd (μ.prod ν)) s = (μ univ • ν) s
tactic: ext s hs
state_before: case h
α : Type u_1
α' : Type u_2
β : Type u_3
β' : Type u_4
γ : Type u_5
E : Type u_6
inst✝⁶ : MeasurableSpace α
inst✝⁵ : MeasurableSpace α'
inst✝⁴ : MeasurableSpace β
inst✝³ : MeasurableSpace β'
inst✝² : MeasurableSpace γ
μ μ' : Measure α
ν ν' : Measure β
τ : Measure γ
inst✝¹ : NormedAddCommGroup E
inst✝ : SFinite ν
s : Set β
hs : MeasurableSet s
⊢ (map Prod.snd (μ.prod ν)) s = (μ univ • ν) s
state_after: no goals
tactic: simp [Measure.map_apply measurable_snd hs, ← univ_prod]
Theorem: TypeVec.prod_id
File: Mathlib/Data/TypeVec.lean

Proof steps:
state_before: n : ℕ
⊢ ∀ {n : ℕ} {α β : TypeVec.{u} n}, (id ⊗' id) = id
state_after: n n✝ : ℕ
α✝ β✝ : TypeVec.{u} n✝
⊢ (id ⊗' id) = id
tactic: intros
state_before: n n✝ : ℕ
α✝ β✝ : TypeVec.{u} n✝
⊢ (id ⊗' id) = id
state_after: case a.h
n n✝ : ℕ
α✝ β✝ : TypeVec.{u} n✝
i : Fin2 n✝
a : (α✝ ⊗ β✝) i
⊢ (id ⊗' id) i a = id i a
tactic: ext i a
state_before: case a.h
n n✝ : ℕ
α✝ β✝ : TypeVec.{u} n✝
i : Fin2 n✝
a : (α✝ ⊗ β✝) i
⊢ (id ⊗' id) i a = id i a
state_after: case a.h.fz
n n✝¹ n✝ : ℕ
α✝ β✝ : TypeVec.{u} (n✝ + 1)
a : (α✝ ⊗ β✝) Fin2.fz
⊢ (id ⊗' id) Fin2.fz a = id Fin2.fz a

case a.h.fs
n n✝¹ n✝ : ℕ
a✝ : Fin2 n✝
i_ih : ∀ {α β : TypeVec.{u} n✝} (a : (α ⊗ β) a✝), (id ⊗' id) a✝ a = id a✝ a
α✝ β✝ : TypeVec.{u} (n✝ + 1)
a : (α✝ ⊗ β✝) a✝.fs
⊢ (id ⊗' id) a✝.fs a = id a✝.fs a
tactic: induction' i with _ _ _ i_ih