1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: matrixEquivTensor_apply_std_basis
File: Mathlib/RingTheory/MatrixAlgebra.lean

tactic: have t : ∀ p : n × n, i = p.1 ∧ j = p.2 ↔ p = (i, j) := by aesop
state_before: R : Type u
inst✝⁴ : CommSemiring R
A : Type v
inst✝³ : Semiring A
inst✝² : Algebra R A
n : Type w
inst✝¹ : Fintype n
inst✝ : DecidableEq n
i j : n
x : A
⊢ (matrixEquivTensor R A n) (stdBasisMatrix i j x) = x ⊗ₜ[R] stdBasisMatrix i j 1
state_after: R : Type u
inst✝⁴ : CommSemiring R
A : Type v
inst✝³ : Semiring A
inst✝² : Algebra R A
n : Type w
inst✝¹ : Fintype n
inst✝ : DecidableEq n
i j : n
x : A
t : ∀ (p : n × n), i = p.1 ∧ j = p.2 ↔ p = (i, j)
⊢ (matrixEquivTensor R A n) (stdBasisMatrix i j x) = x ⊗ₜ[R] stdBasisMatrix i j 1

tactic: simp [ite_tmul, t, stdBasisMatrix]
state_before: R : Type u
inst✝⁴ : CommSemiring R
A : Type v
inst✝³ : Semiring A
inst✝² : Algebra R A
n : Type w
inst✝¹ : Fintype n
inst✝ : DecidableEq n
i j : n
x : A
t : ∀ (p : n × n), i = p.1 ∧ j = p.2 ↔ p = (i, j)
⊢ (matrixEquivTensor R A n) (stdBasisMatrix i j x) = x ⊗ₜ[R] stdBasisMatrix i j 1
state_after: no goals

tactic: aesop
state_before: R : Type u
inst✝⁴ : CommSemiring R
A : Type v
inst✝³ : Semiring A
inst✝² : Algebra R A
n : Type w
inst✝¹ : Fintype n
inst✝ : DecidableEq n
i j : n
x : A
⊢ ∀ (p : n × n), i = p.1 ∧ j = p.2 ↔ p = (i, j)
state_after: no goals
Theorem: tendsto_indicator_const_iff_tendsto_pi_pure
File: Mathlib/Topology/IndicatorConstPointwise.lean

tactic: rw [tendsto_indicator_const_iff_forall_eventually _ b, tendsto_pi]
state_before: α : Type u_1
A : Set α
β : Type u_2
inst✝³ : Zero β
inst✝² : TopologicalSpace β
ι : Type u_3
L : Filter ι
As : ι → Set α
inst✝¹ : T1Space β
b : β
inst✝ : NeZero b
⊢ Tendsto (fun i => (As i).indicator fun x => b) L (𝓝 (A.indicator fun x => b)) ↔
    Tendsto As L (pi fun x => pure (x ∈ A))
state_after: α : Type u_1
A : Set α
β : Type u_2
inst✝³ : Zero β
inst✝² : TopologicalSpace β
ι : Type u_3
L : Filter ι
As : ι → Set α
inst✝¹ : T1Space β
b : β
inst✝ : NeZero b
⊢ (∀ (x : α), ∀ᶠ (i : ι) in L, x ∈ As i ↔ x ∈ A) ↔ ∀ (i : α), Tendsto (fun x => As x i) L (pure (i ∈ A))

tactic: simp_rw [tendsto_pure]
state_before: α : Type u_1
A : Set α
β : Type u_2
inst✝³ : Zero β
inst✝² : TopologicalSpace β
ι : Type u_3
L : Filter ι
As : ι → Set α
inst✝¹ : T1Space β
b : β
inst✝ : NeZero b
⊢ (∀ (x : α), ∀ᶠ (i : ι) in L, x ∈ As i ↔ x ∈ A) ↔ ∀ (i : α), Tendsto (fun x => As x i) L (pure (i ∈ A))
state_after: α : Type u_1
A : Set α
β : Type u_2
inst✝³ : Zero β
inst✝² : TopologicalSpace β
ι : Type u_3
L : Filter ι
As : ι → Set α
inst✝¹ : T1Space β
b : β
inst✝ : NeZero b
⊢ (∀ (x : α), ∀ᶠ (i : ι) in L, x ∈ As i ↔ x ∈ A) ↔ ∀ (i : α), ∀ᶠ (x : ι) in L, As x i = (i ∈ A)

tactic: aesop
state_before: α : Type u_1
A : Set α
β : Type u_2
inst✝³ : Zero β
inst✝² : TopologicalSpace β
ι : Type u_3
L : Filter ι
As : ι → Set α
inst✝¹ : T1Space β
b : β
inst✝ : NeZero b
⊢ (∀ (x : α), ∀ᶠ (i : ι) in L, x ∈ As i ↔ x ∈ A) ↔ ∀ (i : α), ∀ᶠ (x : ι) in L, As x i = (i ∈ A)
state_after: no goals
Theorem: List.all_iff_forall_prop
File: Mathlib/Data/Bool/AllAny.lean

tactic: simp only [all_iff_forall, decide_eq_true_iff]
state_before: α : Type u_1
p : α → Prop
inst✝ : DecidablePred p
l : List α
a : α
⊢ (l.all fun a => decide (p a)) = true ↔ ∀ (a : α), a ∈ l → p a
state_after: no goals
Theorem: Asymptotics.isBigO_atTop_iff_eventually_exists
File: Mathlib/Analysis/Asymptotics/Asymptotics.lean

tactic: rw [isBigO_iff, exists_eventually_atTop]
state_before: α✝ : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
G : Type u_5
E' : Type u_6
F' : Type u_7
G' : Type u_8
E'' : Type u_9
F'' : Type u_10
G'' : Type u_11
E''' : Type u_12
R : Type u_13
R' : Type u_14
𝕜 : Type u_15
𝕜' : Type u_16
inst✝¹⁵ : Norm E
inst✝¹⁴ : Norm F
inst✝¹³ : Norm G
inst✝¹² : SeminormedAddCommGroup E'
inst✝¹¹ : SeminormedAddCommGroup F'
inst✝¹⁰ : SeminormedAddCommGroup G'
inst✝⁹ : NormedAddCommGroup E''
inst✝⁸ : NormedAddCommGroup F''
inst✝⁷ : NormedAddCommGroup G''
inst✝⁶ : SeminormedRing R
inst✝⁵ : SeminormedAddGroup E'''
inst✝⁴ : SeminormedRing R'
inst✝³ : NormedDivisionRing 𝕜
inst✝² : NormedDivisionRing 𝕜'
c c' c₁ c₂ : ℝ
f✝ : α✝ → E
g✝ : α✝ → F
k : α✝ → G
f' : α✝ → E'
g' : α✝ → F'
k' : α✝ → G'
f'' : α✝ → E''
g'' : α✝ → F''
k'' : α✝ → G''
l l' : Filter α✝
α : Type u_17
inst✝¹ : SemilatticeSup α
inst✝ : Nonempty α
f : α → E
g : α → F
⊢ f =O[atTop] g ↔ ∀ᶠ (n₀ : α) in atTop, ∃ c, ∀ n ≥ n₀, ‖f n‖ ≤ c * ‖g n‖
state_after: no goals
Theorem: ENNReal.exists_le_of_sum_le
File: Mathlib/Data/ENNReal/Operations.lean

tactic: contrapose! Hle
state_before: a b c d : ℝ≥0∞
r p q : ℝ≥0
α : Type u_1
s : Finset α
hs : s.Nonempty
f g : α → ℝ≥0∞
Hle : ∑ i ∈ s, f i ≤ ∑ i ∈ s, g i
⊢ ∃ i ∈ s, f i ≤ g i
state_after: a b c d : ℝ≥0∞
r p q : ℝ≥0
α : Type u_1
s : Finset α
hs : s.Nonempty
f g : α → ℝ≥0∞
Hle : ∀ i ∈ s, g i < f i
⊢ ∑ i ∈ s, g i < ∑ i ∈ s, f i

tactic: apply ENNReal.sum_lt_sum_of_nonempty hs Hle
state_before: a b c d : ℝ≥0∞
r p q : ℝ≥0
α : Type u_1
s : Finset α
hs : s.Nonempty
f g : α → ℝ≥0∞
Hle : ∀ i ∈ s, g i < f i
⊢ ∑ i ∈ s, g i < ∑ i ∈ s, f i
state_after: no goals
Theorem: Submonoid.LocalizationMap.eq_mk'_iff_mul_eq
File: Mathlib/GroupTheory/MonoidLocalization.lean

tactic: rw [H, mk'_spec]
state_before: M : Type u_1
inst✝² : CommMonoid M
S : Submonoid M
N : Type u_2
inst✝¹ : CommMonoid N
P : Type u_3
inst✝ : CommMonoid P
f : S.LocalizationMap N
x : M
y : ↥S
z : N
H : z = f.mk' x y
⊢ z * f.toMap ↑y = f.toMap x
state_after: no goals

tactic: erw [mul_inv_right, H]
state_before: M : Type u_1
inst✝² : CommMonoid M
S : Submonoid M
N : Type u_2
inst✝¹ : CommMonoid N
P : Type u_3
inst✝ : CommMonoid P
f : S.LocalizationMap N
x : M
y : ↥S
z : N
H : z * f.toMap ↑y = f.toMap x
⊢ z = f.mk' x y
state_after: no goals
Theorem: Orientation.cos_oangle_sub_right_mul_norm_of_oangle_eq_pi_div_two
File: Mathlib/Geometry/Euclidean/Angle/Oriented/RightAngle.lean

tactic: have hs : (o.oangle y (y - x)).sign = 1 := by
  rw [oangle_sign_sub_right_swap, h, Real.Angle.sign_coe_pi_div_two]
state_before: V : Type u_1
inst✝¹ : NormedAddCommGroup V
inst✝ : InnerProductSpace ℝ V
hd2 : Fact (finrank ℝ V = 2)
o : Orientation ℝ V (Fin 2)
x y : V
h : o.oangle x y = ↑(π / 2)
⊢ (o.oangle y (y - x)).cos * ‖y - x‖ = ‖y‖
state_after: V : Type u_1
inst✝¹ : NormedAddCommGroup V
inst✝ : InnerProductSpace ℝ V
hd2 : Fact (finrank ℝ V = 2)
o : Orientation ℝ V (Fin 2)
x y : V
h : o.oangle x y = ↑(π / 2)
hs : (o.oangle y (y - x)).sign = 1
⊢ (o.oangle y (y - x)).cos * ‖y - x‖ = ‖y‖

tactic: rw [o.oangle_eq_angle_of_sign_eq_one hs, Real.Angle.cos_coe,
  InnerProductGeometry.cos_angle_sub_mul_norm_of_inner_eq_zero
    (o.inner_rev_eq_zero_of_oangle_eq_pi_div_two h)]
state_before: V : Type u_1
inst✝¹ : NormedAddCommGroup V
inst✝ : InnerProductSpace ℝ V
hd2 : Fact (finrank ℝ V = 2)
o : Orientation ℝ V (Fin 2)
x y : V
h : o.oangle x y = ↑(π / 2)
hs : (o.oangle y (y - x)).sign = 1
⊢ (o.oangle y (y - x)).cos * ‖y - x‖ = ‖y‖
state_after: no goals

tactic: rw [oangle_sign_sub_right_swap, h, Real.Angle.sign_coe_pi_div_two]
state_before: V : Type u_1
inst✝¹ : NormedAddCommGroup V
inst✝ : InnerProductSpace ℝ V
hd2 : Fact (finrank ℝ V = 2)
o : Orientation ℝ V (Fin 2)
x y : V
h : o.oangle x y = ↑(π / 2)
⊢ (o.oangle y (y - x)).sign = 1
state_after: no goals
Theorem: Finset.mem_diag
File: Mathlib/Data/Finset/Prod.lean

tactic: simp (config := { contextual := true }) [diag]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : DecidableEq α
s t : Finset α
x : α × α
⊢ x ∈ s.diag ↔ x.1 ∈ s ∧ x.1 = x.2
state_after: no goals
Theorem: MeasureTheory.setIntegral_ge_of_const_le
File: Mathlib/MeasureTheory/Integral/SetIntegral.lean

tactic: rw [mul_comm, ← smul_eq_mul, ← setIntegral_const c]
state_before: X : Type u_1
Y : Type u_2
E : Type u_3
F : Type u_4
inst✝ : MeasurableSpace X
μ : Measure X
f g : X → ℝ
s t : Set X
hf✝ : IntegrableOn f s μ
hg : IntegrableOn g s μ
c : ℝ
hs : MeasurableSet s
hμs : μ s ≠ ⊤
hf : ∀ x ∈ s, c ≤ f x
hfint : IntegrableOn (fun x => f x) s μ
⊢ c * (μ s).toReal ≤ ∫ (x : X) in s, f x ∂μ
state_after: X : Type u_1
Y : Type u_2
E : Type u_3
F : Type u_4
inst✝ : MeasurableSpace X
μ : Measure X
f g : X → ℝ
s t : Set X
hf✝ : IntegrableOn f s μ
hg : IntegrableOn g s μ
c : ℝ
hs : MeasurableSet s
hμs : μ s ≠ ⊤
hf : ∀ x ∈ s, c ≤ f x
hfint : IntegrableOn (fun x => f x) s μ
⊢ ∫ (x : X) in s, c ∂μ ≤ ∫ (x : X) in s, f x ∂μ

tactic: exact setIntegral_mono_on (integrableOn_const.2 (Or.inr hμs.lt_top)) hfint hs hf
state_before: X : Type u_1
Y : Type u_2
E : Type u_3
F : Type u_4
inst✝ : MeasurableSpace X
μ : Measure X
f g : X → ℝ
s t : Set X
hf✝ : IntegrableOn f s μ
hg : IntegrableOn g s μ
c : ℝ
hs : MeasurableSet s
hμs : μ s ≠ ⊤
hf : ∀ x ∈ s, c ≤ f x
hfint : IntegrableOn (fun x => f x) s μ
⊢ ∫ (x : X) in s, c ∂μ ≤ ∫ (x : X) in s, f x ∂μ
state_after: no goals
Theorem: Finset.inter_singleton_of_mem
File: Mathlib/Data/Finset/Basic.lean

tactic: rw [inter_comm, singleton_inter_of_mem h]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : DecidableEq α
s✝ s₁ s₂ t t₁ t₂ u v : Finset α
a✝ b a : α
s : Finset α
h : a ∈ s
⊢ s ∩ {a} = {a}
state_after: no goals
Theorem: Complex.ofReal_nnqsmul
File: Mathlib/Data/Complex/Basic.lean

tactic: simp [NNRat.smul_def]
state_before: q : ℚ≥0
r : ℝ
⊢ ↑(q • r) = q • ↑r
state_after: no goals
Theorem: CategoryTheory.ShortComplex.LeftHomologyMapData.leftHomologyMap_comm
File: Mathlib/Algebra/Homology/ShortComplex/LeftHomology.lean

tactic: simp only [γ.leftHomologyMap_eq, assoc, Iso.inv_hom_id, comp_id]
state_before: C : Type u_1
inst✝³ : Category.{u_2, u_1} C
inst✝² : HasZeroMorphisms C
S S₁ S₂ S₃ : ShortComplex C
φ : S₁ ⟶ S₂
h₁ : S₁.LeftHomologyData
h₂ : S₂.LeftHomologyData
γ : LeftHomologyMapData φ h₁ h₂
inst✝¹ : S₁.HasLeftHomology
inst✝ : S₂.HasLeftHomology
⊢ leftHomologyMap φ ≫ h₂.leftHomologyIso.hom = h₁.leftHomologyIso.hom ≫ γ.φH
state_after: no goals
Theorem: LSeries_zero
File: Mathlib/NumberTheory/LSeries/Basic.lean

tactic: ext
state_before: ⊢ LSeries 0 = 0
state_after: case h
x✝ : ℂ
⊢ LSeries 0 x✝ = 0 x✝

tactic: simp only [LSeries, LSeries.term, Pi.zero_apply, zero_div, ite_self, tsum_zero]
state_before: case h
x✝ : ℂ
⊢ LSeries 0 x✝ = 0 x✝
state_after: no goals
Theorem: CategoryTheory.ShortComplex.LeftHomologyData.homologyπ_comp_homologyIso_hom
File: Mathlib/Algebra/Homology/ShortComplex/Homology.lean

tactic: dsimp only [homologyπ, homologyIso]
state_before: C : Type u
inst✝³ : Category.{v, u} C
inst✝² : HasZeroMorphisms C
S S₁ S₂ S₃ S₄ : ShortComplex C
φ : S₁ ⟶ S₂
h₁ : S₁.HomologyData
h₂ : S₂.HomologyData
A : C
inst✝¹ : S.HasHomology
h : S.LeftHomologyData
inst✝ : S.HasHomology
⊢ S.homologyπ ≫ h.homologyIso.hom = h.cyclesIso.hom ≫ h.π
state_after: C : Type u
inst✝³ : Category.{v, u} C
inst✝² : HasZeroMorphisms C
S S₁ S₂ S₃ S₄ : ShortComplex C
φ : S₁ ⟶ S₂
h₁ : S₁.HomologyData
h₂ : S₂.HomologyData
A : C
inst✝¹ : S.HasHomology
h : S.LeftHomologyData
inst✝ : S.HasHomology
⊢ (S.leftHomologyπ ≫ S.leftHomologyIso.hom) ≫ (S.leftHomologyIso.symm ≪≫ h.leftHomologyIso).hom = h.cyclesIso.hom ≫ h.π

tactic: simp only [Iso.trans_hom, Iso.symm_hom, assoc, Iso.hom_inv_id_assoc,
  leftHomologyπ_comp_leftHomologyIso_hom]
state_before: C : Type u
inst✝³ : Category.{v, u} C
inst✝² : HasZeroMorphisms C
S S₁ S₂ S₃ S₄ : ShortComplex C
φ : S₁ ⟶ S₂
h₁ : S₁.HomologyData
h₂ : S₂.HomologyData
A : C
inst✝¹ : S.HasHomology
h : S.LeftHomologyData
inst✝ : S.HasHomology
⊢ (S.leftHomologyπ ≫ S.leftHomologyIso.hom) ≫ (S.leftHomologyIso.symm ≪≫ h.leftHomologyIso).hom = h.cyclesIso.hom ≫ h.π
state_after: no goals
Theorem: Nat.div_div_self
File: Mathlib/Data/Nat/Defs.lean

tactic: rcases h with ⟨_, rfl⟩
state_before: a b c d m n k : ℕ
p q : ℕ → Prop
h : n ∣ m
hm : m ≠ 0
⊢ m / (m / n) = n
state_after: case intro
a b c d n k : ℕ
p q : ℕ → Prop
w✝ : ℕ
hm : n * w✝ ≠ 0
⊢ n * w✝ / (n * w✝ / n) = n

tactic: rw [Nat.mul_ne_zero_iff] at hm
state_before: case intro
a b c d n k : ℕ
p q : ℕ → Prop
w✝ : ℕ
hm : n * w✝ ≠ 0
⊢ n * w✝ / (n * w✝ / n) = n
state_after: case intro
a b c d n k : ℕ
p q : ℕ → Prop
w✝ : ℕ
hm : n ≠ 0 ∧ w✝ ≠ 0
⊢ n * w✝ / (n * w✝ / n) = n

tactic: rw [mul_div_right _ (Nat.pos_of_ne_zero hm.1), mul_div_left _ (Nat.pos_of_ne_zero hm.2)]
state_before: case intro
a b c d n k : ℕ
p q : ℕ → Prop
w✝ : ℕ
hm : n ≠ 0 ∧ w✝ ≠ 0
⊢ n * w✝ / (n * w✝ / n) = n
state_after: no goals
Theorem: Nat.exists_lt_card_nth_eq
File: Mathlib/Data/Nat/Nth.lean

tactic: refine (setOf p).finite_or_infinite.elim (fun hf => ?_) fun hf => ?_
state_before: p : ℕ → Prop
x : ℕ
h : p x
⊢ ∃ n, (∀ (hf : (setOf p).Finite), n < hf.toFinset.card) ∧ nth p n = x
state_after: case refine_1
p : ℕ → Prop
x : ℕ
h : p x
hf : (setOf p).Finite
⊢ ∃ n, (∀ (hf : (setOf p).Finite), n < hf.toFinset.card) ∧ nth p n = x

case refine_2
p : ℕ → Prop
x : ℕ
h : p x
hf : (setOf p).Infinite
⊢ ∃ n, (∀ (hf : (setOf p).Finite), n < hf.toFinset.card) ∧ nth p n = x

tactic: rcases exists_lt_card_finite_nth_eq hf h with ⟨n, hn, hx⟩
state_before: case refine_1
p : ℕ → Prop
x : ℕ
h : p x
hf : (setOf p).Finite
⊢ ∃ n, (∀ (hf : (setOf p).Finite), n < hf.toFinset.card) ∧ nth p n = x
state_after: case refine_1.intro.intro
p : ℕ → Prop
x : ℕ
h : p x
hf : (setOf p).Finite
n : ℕ
hn : n < hf.toFinset.card
hx : nth p n = x
⊢ ∃ n, (∀ (hf : (setOf p).Finite), n < hf.toFinset.card) ∧ nth p n = x

tactic: exact ⟨n, fun _ => hn, hx⟩
state_before: case refine_1.intro.intro
p : ℕ → Prop
x : ℕ
h : p x
hf : (setOf p).Finite
n : ℕ
hn : n < hf.toFinset.card
hx : nth p n = x
⊢ ∃ n, (∀ (hf : (setOf p).Finite), n < hf.toFinset.card) ∧ nth p n = x
state_after: no goals

tactic: rw [← @Set.mem_setOf_eq _ _ p, ← range_nth_of_infinite hf] at h
state_before: case refine_2
p : ℕ → Prop
x : ℕ
h : p x
hf : (setOf p).Infinite
⊢ ∃ n, (∀ (hf : (setOf p).Finite), n < hf.toFinset.card) ∧ nth p n = x
state_after: case refine_2
p : ℕ → Prop
x : ℕ
h : x ∈ Set.range (nth p)
hf : (setOf p).Infinite
⊢ ∃ n, (∀ (hf : (setOf p).Finite), n < hf.toFinset.card) ∧ nth p n = x

tactic: rcases h with ⟨n, hx⟩
state_before: case refine_2
p : ℕ → Prop
x : ℕ
h : x ∈ Set.range (nth p)
hf : (setOf p).Infinite
⊢ ∃ n, (∀ (hf : (setOf p).Finite), n < hf.toFinset.card) ∧ nth p n = x
state_after: case refine_2.intro
p : ℕ → Prop
x : ℕ
hf : (setOf p).Infinite
n : ℕ
hx : nth p n = x
⊢ ∃ n, (∀ (hf : (setOf p).Finite), n < hf.toFinset.card) ∧ nth p n = x

tactic: exact ⟨n, fun hf' => absurd hf' hf, hx⟩
state_before: case refine_2.intro
p : ℕ → Prop
x : ℕ
hf : (setOf p).Infinite
n : ℕ
hx : nth p n = x
⊢ ∃ n, (∀ (hf : (setOf p).Finite), n < hf.toFinset.card) ∧ nth p n = x
state_after: no goals
Theorem: ProbabilityTheory.integral_condKernel
File: Mathlib/Probability/Kernel/Disintegration/Integral.lean

tactic: conv_rhs => rw [← kernel.compProd_fst_condKernel κ]
state_before: α : Type u_1
β : Type u_2
Ω : Type u_3
mα : MeasurableSpace α
mβ : MeasurableSpace β
inst✝⁶ : MeasurableSpace Ω
inst✝⁵ : StandardBorelSpace Ω
inst✝⁴ : Nonempty Ω
inst✝³ : CountableOrCountablyGenerated α β
κ : ↥(kernel α (β × Ω))
inst✝² : IsFiniteKernel κ
E : Type u_4
f : β × Ω → E
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace ℝ E
a : α
hf : Integrable f (κ a)
⊢ ∫ (b : β), ∫ (ω : Ω), f (b, ω) ∂(kernel.condKernel κ) (a, b) ∂(kernel.fst κ) a = ∫ (x : β × Ω), f x ∂κ a
state_after: α : Type u_1
β : Type u_2
Ω : Type u_3
mα : MeasurableSpace α
mβ : MeasurableSpace β
inst✝⁶ : MeasurableSpace Ω
inst✝⁵ : StandardBorelSpace Ω
inst✝⁴ : Nonempty Ω
inst✝³ : CountableOrCountablyGenerated α β
κ : ↥(kernel α (β × Ω))
inst✝² : IsFiniteKernel κ
E : Type u_4
f : β × Ω → E
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace ℝ E
a : α
hf : Integrable f (κ a)
⊢ ∫ (b : β), ∫ (ω : Ω), f (b, ω) ∂(kernel.condKernel κ) (a, b) ∂(kernel.fst κ) a =
    ∫ (x : β × Ω), f x ∂(kernel.fst κ ⊗ₖ kernel.condKernel κ) a

tactic: rw [← kernel.compProd_fst_condKernel κ] at hf
state_before: α : Type u_1
β : Type u_2
Ω : Type u_3
mα : MeasurableSpace α
mβ : MeasurableSpace β
inst✝⁶ : MeasurableSpace Ω
inst✝⁵ : StandardBorelSpace Ω
inst✝⁴ : Nonempty Ω
inst✝³ : CountableOrCountablyGenerated α β
κ : ↥(kernel α (β × Ω))
inst✝² : IsFiniteKernel κ
E : Type u_4
f : β × Ω → E
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace ℝ E
a : α
hf : Integrable f (κ a)
⊢ ∫ (b : β), ∫ (ω : Ω), f (b, ω) ∂(kernel.condKernel κ) (a, b) ∂(kernel.fst κ) a =
    ∫ (x : β × Ω), f x ∂(kernel.fst κ ⊗ₖ kernel.condKernel κ) a
state_after: α : Type u_1
β : Type u_2
Ω : Type u_3
mα : MeasurableSpace α
mβ : MeasurableSpace β
inst✝⁶ : MeasurableSpace Ω
inst✝⁵ : StandardBorelSpace Ω
inst✝⁴ : Nonempty Ω
inst✝³ : CountableOrCountablyGenerated α β
κ : ↥(kernel α (β × Ω))
inst✝² : IsFiniteKernel κ
E : Type u_4
f : β × Ω → E
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace ℝ E
a : α
hf : Integrable f ((kernel.fst κ ⊗ₖ kernel.condKernel κ) a)
⊢ ∫ (b : β), ∫ (ω : Ω), f (b, ω) ∂(kernel.condKernel κ) (a, b) ∂(kernel.fst κ) a =
    ∫ (x : β × Ω), f x ∂(kernel.fst κ ⊗ₖ kernel.condKernel κ) a

tactic: rw [integral_compProd hf]
state_before: α : Type u_1
β : Type u_2
Ω : Type u_3
mα : MeasurableSpace α
mβ : MeasurableSpace β
inst✝⁶ : MeasurableSpace Ω
inst✝⁵ : StandardBorelSpace Ω
inst✝⁴ : Nonempty Ω
inst✝³ : CountableOrCountablyGenerated α β
κ : ↥(kernel α (β × Ω))
inst✝² : IsFiniteKernel κ
E : Type u_4
f : β × Ω → E
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace ℝ E
a : α
hf : Integrable f ((kernel.fst κ ⊗ₖ kernel.condKernel κ) a)
⊢ ∫ (b : β), ∫ (ω : Ω), f (b, ω) ∂(kernel.condKernel κ) (a, b) ∂(kernel.fst κ) a =
    ∫ (x : β × Ω), f x ∂(kernel.fst κ ⊗ₖ kernel.condKernel κ) a
state_after: no goals
Theorem: List.rdrop_concat_succ
File: Mathlib/Data/List/DropRight.lean

tactic: simp [rdrop_eq_reverse_drop_reverse]
state_before: α : Type u_1
p : α → Bool
l : List α
n : ℕ
x : α
⊢ (l ++ [x]).rdrop (n + 1) = l.rdrop n
state_after: no goals
Theorem: MeasureTheory.Measure.sum_add_sum
File: Mathlib/MeasureTheory/Measure/MeasureSpace.lean

tactic: ext1 s hs
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
ι✝ : Type u_5
R : Type u_6
R' : Type u_7
m0 : MeasurableSpace α
inst✝¹ : MeasurableSpace β
inst✝ : MeasurableSpace γ
μ✝ μ₁ μ₂ μ₃ ν✝ ν' ν₁ ν₂ : Measure α
s s' t : Set α
f : α → β
ι : Type u_8
μ ν : ι → Measure α
⊢ sum μ + sum ν = sum fun n => μ n + ν n
state_after: case h
α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
ι✝ : Type u_5
R : Type u_6
R' : Type u_7
m0 : MeasurableSpace α
inst✝¹ : MeasurableSpace β
inst✝ : MeasurableSpace γ
μ✝ μ₁ μ₂ μ₃ ν✝ ν' ν₁ ν₂ : Measure α
s✝ s' t : Set α
f : α → β
ι : Type u_8
μ ν : ι → Measure α
s : Set α
hs : MeasurableSet s
⊢ (sum μ + sum ν) s = (sum fun n => μ n + ν n) s

tactic: simp only [add_apply, sum_apply _ hs, Pi.add_apply, coe_add,
  tsum_add ENNReal.summable ENNReal.summable]
state_before: case h
α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
ι✝ : Type u_5
R : Type u_6
R' : Type u_7
m0 : MeasurableSpace α
inst✝¹ : MeasurableSpace β
inst✝ : MeasurableSpace γ
μ✝ μ₁ μ₂ μ₃ ν✝ ν' ν₁ ν₂ : Measure α
s✝ s' t : Set α
f : α → β
ι : Type u_8
μ ν : ι → Measure α
s : Set α
hs : MeasurableSet s
⊢ (sum μ + sum ν) s = (sum fun n => μ n + ν n) s
state_after: no goals
Theorem: Finsupp.prod_of_support_subset
File: Mathlib/Algebra/BigOperators/Finsupp.lean

tactic: refine Finset.prod_subset hs fun x hxs hx => h x hxs ▸ (congr_arg (g x) ?_)
state_before: α : Type u_1
ι : Type u_2
γ : Type u_3
A : Type u_4
B : Type u_5
C : Type u_6
inst✝⁵ : AddCommMonoid A
inst✝⁴ : AddCommMonoid B
inst✝³ : AddCommMonoid C
t : ι → A → C
h0 : ∀ (i : ι), t i 0 = 0
h1 : ∀ (i : ι) (x y : A), t i (x + y) = t i x + t i y
s✝ : Finset α
f✝ : α → ι →₀ A
i : ι
g✝ : ι →₀ A
k : ι → A → γ → B
x : γ
β : Type u_7
M : Type u_8
M' : Type u_9
N : Type u_10
P : Type u_11
G : Type u_12
H : Type u_13
R : Type u_14
S : Type u_15
inst✝² : Zero M
inst✝¹ : Zero M'
inst✝ : CommMonoid N
f : α →₀ M
s : Finset α
hs : f.support ⊆ s
g : α → M → N
h : ∀ i ∈ s, g i 0 = 1
⊢ f.prod g = ∏ x ∈ s, g x (f x)
state_after: α : Type u_1
ι : Type u_2
γ : Type u_3
A : Type u_4
B : Type u_5
C : Type u_6
inst✝⁵ : AddCommMonoid A
inst✝⁴ : AddCommMonoid B
inst✝³ : AddCommMonoid C
t : ι → A → C
h0 : ∀ (i : ι), t i 0 = 0
h1 : ∀ (i : ι) (x y : A), t i (x + y) = t i x + t i y
s✝ : Finset α
f✝ : α → ι →₀ A
i : ι
g✝ : ι →₀ A
k : ι → A → γ → B
x✝ : γ
β : Type u_7
M : Type u_8
M' : Type u_9
N : Type u_10
P : Type u_11
G : Type u_12
H : Type u_13
R : Type u_14
S : Type u_15
inst✝² : Zero M
inst✝¹ : Zero M'
inst✝ : CommMonoid N
f : α →₀ M
s : Finset α
hs : f.support ⊆ s
g : α → M → N
h : ∀ i ∈ s, g i 0 = 1
x : α
hxs : x ∈ s
hx : x ∉ f.support
⊢ f x = 0

tactic: exact not_mem_support_iff.1 hx
state_before: α : Type u_1
ι : Type u_2
γ : Type u_3
A : Type u_4
B : Type u_5
C : Type u_6
inst✝⁵ : AddCommMonoid A
inst✝⁴ : AddCommMonoid B
inst✝³ : AddCommMonoid C
t : ι → A → C
h0 : ∀ (i : ι), t i 0 = 0
h1 : ∀ (i : ι) (x y : A), t i (x + y) = t i x + t i y
s✝ : Finset α
f✝ : α → ι →₀ A
i : ι
g✝ : ι →₀ A
k : ι → A → γ → B
x✝ : γ
β : Type u_7
M : Type u_8
M' : Type u_9
N : Type u_10
P : Type u_11
G : Type u_12
H : Type u_13
R : Type u_14
S : Type u_15
inst✝² : Zero M
inst✝¹ : Zero M'
inst✝ : CommMonoid N
f : α →₀ M
s : Finset α
hs : f.support ⊆ s
g : α → M → N
h : ∀ i ∈ s, g i 0 = 1
x : α
hxs : x ∈ s
hx : x ∉ f.support
⊢ f x = 0
state_after: no goals
Theorem: add_pow_expChar_pow_of_commute
File: Mathlib/Algebra/CharP/ExpChar.lean

tactic: cases' hR with _ _ hprime _
state_before: R : Type u
inst✝ : Semiring R
q : ℕ
hR : ExpChar R q
n : ℕ
x y : R
h : Commute x y
⊢ (x + y) ^ q ^ n = x ^ q ^ n + y ^ q ^ n
state_after: case zero
R : Type u
inst✝¹ : Semiring R
n : ℕ
x y : R
h : Commute x y
inst✝ : CharZero R
⊢ (x + y) ^ 1 ^ n = x ^ 1 ^ n + y ^ 1 ^ n

case prime
R : Type u
inst✝ : Semiring R
q n : ℕ
x y : R
h : Commute x y
hprime : Nat.Prime q
hchar✝ : CharP R q
⊢ (x + y) ^ q ^ n = x ^ q ^ n + y ^ q ^ n

tactic: haveI := Fact.mk hprime
state_before: case prime
R : Type u
inst✝ : Semiring R
q n : ℕ
x y : R
h : Commute x y
hprime : Nat.Prime q
hchar✝ : CharP R q
⊢ (x + y) ^ q ^ n = x ^ q ^ n + y ^ q ^ n
state_after: case prime
R : Type u
inst✝ : Semiring R
q n : ℕ
x y : R
h : Commute x y
hprime : Nat.Prime q
hchar✝ : CharP R q
this : Fact (Nat.Prime q)
⊢ (x + y) ^ q ^ n = x ^ q ^ n + y ^ q ^ n

tactic: exact add_pow_char_pow_of_commute R x y h
state_before: case prime
R : Type u
inst✝ : Semiring R
q n : ℕ
x y : R
h : Commute x y
hprime : Nat.Prime q
hchar✝ : CharP R q
this : Fact (Nat.Prime q)
⊢ (x + y) ^ q ^ n = x ^ q ^ n + y ^ q ^ n
state_after: no goals

tactic: simp only [one_pow, pow_one]
state_before: case zero
R : Type u
inst✝¹ : Semiring R
n : ℕ
x y : R
h : Commute x y
inst✝ : CharZero R
⊢ (x + y) ^ 1 ^ n = x ^ 1 ^ n + y ^ 1 ^ n
state_after: no goals
Theorem: SSet.standardSimplex.map_apply
File: Mathlib/AlgebraicTopology/SimplicialSet.lean

tactic: rfl
state_before: m₁ m₂ : SimplexCategoryᵒᵖ
f : m₁ ⟶ m₂
n : SimplexCategory
x : (standardSimplex.obj n).obj m₁
⊢ (standardSimplex.obj n).map f x = (objEquiv n m₂).symm (f.unop ≫ (objEquiv n m₁) x)
state_after: no goals
Theorem: Rat.inv_natCast_den
File: Mathlib/Data/Rat/Lemmas.lean

tactic: simpa [-inv_intCast_den, ofInt_eq_cast] using inv_intCast_den a
state_before: a : ℕ
⊢ (↑a)⁻¹.den = if a = 0 then 1 else a
state_after: no goals
Theorem: NNRat.toNNRat_sum_of_nonneg
File: Mathlib/Data/NNRat/BigOperators.lean

tactic: rw [← coe_inj, coe_sum, Rat.coe_toNNRat _ (Finset.sum_nonneg hf)]
state_before: ι : Type u_1
α : Type u_2
s : Finset α
f : α → ℚ
hf : ∀ a ∈ s, 0 ≤ f a
⊢ (∑ a ∈ s, f a).toNNRat = ∑ a ∈ s, (f a).toNNRat
state_after: ι : Type u_1
α : Type u_2
s : Finset α
f : α → ℚ
hf : ∀ a ∈ s, 0 ≤ f a
⊢ ∑ i ∈ s, f i = ∑ a ∈ s, ↑(f a).toNNRat

tactic: exact Finset.sum_congr rfl fun x hxs ↦ by rw [Rat.coe_toNNRat _ (hf x hxs)]
state_before: ι : Type u_1
α : Type u_2
s : Finset α
f : α → ℚ
hf : ∀ a ∈ s, 0 ≤ f a
⊢ ∑ i ∈ s, f i = ∑ a ∈ s, ↑(f a).toNNRat
state_after: no goals

tactic: rw [Rat.coe_toNNRat _ (hf x hxs)]
state_before: ι : Type u_1
α : Type u_2
s : Finset α
f : α → ℚ
hf : ∀ a ∈ s, 0 ≤ f a
x : α
hxs : x ∈ s
⊢ f x = ↑(f x).toNNRat
state_after: no goals