Theorem: ProbabilityTheory.IndepFun.integral_mul
File: Mathlib/Probability/Integration.lean

tactic: by_cases h'X : X =ᵐ[μ] 0
state_before: Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
⊢ integral μ (X * Y) = integral μ X * integral μ Y
state_after: case pos
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : X =ᶠ[ae μ] 0
⊢ integral μ (X * Y) = integral μ X * integral μ Y

case neg
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
⊢ integral μ (X * Y) = integral μ X * integral μ Y

tactic: by_cases h'Y : Y =ᵐ[μ] 0
state_before: case neg
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
⊢ integral μ (X * Y) = integral μ X * integral μ Y
state_after: case pos
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : Y =ᶠ[ae μ] 0
⊢ integral μ (X * Y) = integral μ X * integral μ Y

case neg
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : ¬Y =ᶠ[ae μ] 0
⊢ integral μ (X * Y) = integral μ X * integral μ Y

tactic: by_cases h : Integrable (X * Y) μ
state_before: case neg
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : ¬Y =ᶠ[ae μ] 0
⊢ integral μ (X * Y) = integral μ X * integral μ Y
state_after: case pos
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : ¬Y =ᶠ[ae μ] 0
h : Integrable (X * Y) μ
⊢ integral μ (X * Y) = integral μ X * integral μ Y

case neg
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : ¬Y =ᶠ[ae μ] 0
h : ¬Integrable (X * Y) μ
⊢ integral μ (X * Y) = integral μ X * integral μ Y

tactic: have h' : X * Y =ᵐ[μ] 0 := by
  filter_upwards [h'X] with ω hω
  simp [hω]
state_before: case pos
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : X =ᶠ[ae μ] 0
⊢ integral μ (X * Y) = integral μ X * integral μ Y
state_after: case pos
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : X =ᶠ[ae μ] 0
h' : X * Y =ᶠ[ae μ] 0
⊢ integral μ (X * Y) = integral μ X * integral μ Y

tactic: simp only [integral_congr_ae h'X, integral_congr_ae h', Pi.zero_apply, integral_const,
  Algebra.id.smul_eq_mul, mul_zero, zero_mul]
state_before: case pos
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : X =ᶠ[ae μ] 0
h' : X * Y =ᶠ[ae μ] 0
⊢ integral μ (X * Y) = integral μ X * integral μ Y
state_after: no goals

tactic: filter_upwards [h'X] with ω hω
state_before: Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : X =ᶠ[ae μ] 0
⊢ X * Y =ᶠ[ae μ] 0
state_after: case h
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : X =ᶠ[ae μ] 0
ω : Ω
hω : X ω = 0 ω
⊢ (X * Y) ω = 0 ω

tactic: simp [hω]
state_before: case h
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : X =ᶠ[ae μ] 0
ω : Ω
hω : X ω = 0 ω
⊢ (X * Y) ω = 0 ω
state_after: no goals

tactic: have h' : X * Y =ᵐ[μ] 0 := by
  filter_upwards [h'Y] with ω hω
  simp [hω]
state_before: case pos
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : Y =ᶠ[ae μ] 0
⊢ integral μ (X * Y) = integral μ X * integral μ Y
state_after: case pos
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : Y =ᶠ[ae μ] 0
h' : X * Y =ᶠ[ae μ] 0
⊢ integral μ (X * Y) = integral μ X * integral μ Y

tactic: simp only [integral_congr_ae h'Y, integral_congr_ae h', Pi.zero_apply, integral_const,
  Algebra.id.smul_eq_mul, mul_zero, zero_mul]
state_before: case pos
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : Y =ᶠ[ae μ] 0
h' : X * Y =ᶠ[ae μ] 0
⊢ integral μ (X * Y) = integral μ X * integral μ Y
state_after: no goals

tactic: filter_upwards [h'Y] with ω hω
state_before: Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : Y =ᶠ[ae μ] 0
⊢ X * Y =ᶠ[ae μ] 0
state_after: case h
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : Y =ᶠ[ae μ] 0
ω : Ω
hω : Y ω = 0 ω
⊢ (X * Y) ω = 0 ω

tactic: simp [hω]
state_before: case h
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : Y =ᶠ[ae μ] 0
ω : Ω
hω : Y ω = 0 ω
⊢ (X * Y) ω = 0 ω
state_after: no goals

tactic: have HX : Integrable X μ := hXY.integrable_left_of_integrable_mul h hX hY h'Y
state_before: case pos
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : ¬Y =ᶠ[ae μ] 0
h : Integrable (X * Y) μ
⊢ integral μ (X * Y) = integral μ X * integral μ Y
state_after: case pos
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : ¬Y =ᶠ[ae μ] 0
h : Integrable (X * Y) μ
HX : Integrable X μ
⊢ integral μ (X * Y) = integral μ X * integral μ Y

tactic: have HY : Integrable Y μ := hXY.integrable_right_of_integrable_mul h hX hY h'X
state_before: case pos
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : ¬Y =ᶠ[ae μ] 0
h : Integrable (X * Y) μ
HX : Integrable X μ
⊢ integral μ (X * Y) = integral μ X * integral μ Y
state_after: case pos
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : ¬Y =ᶠ[ae μ] 0
h : Integrable (X * Y) μ
HX : Integrable X μ
HY : Integrable Y μ
⊢ integral μ (X * Y) = integral μ X * integral μ Y

tactic: exact hXY.integral_mul_of_integrable HX HY
state_before: case pos
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : ¬Y =ᶠ[ae μ] 0
h : Integrable (X * Y) μ
HX : Integrable X μ
HY : Integrable Y μ
⊢ integral μ (X * Y) = integral μ X * integral μ Y
state_after: no goals

tactic: rw [integral_undef h]
state_before: case neg
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : ¬Y =ᶠ[ae μ] 0
h : ¬Integrable (X * Y) μ
⊢ integral μ (X * Y) = integral μ X * integral μ Y
state_after: case neg
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : ¬Y =ᶠ[ae μ] 0
h : ¬Integrable (X * Y) μ
⊢ 0 = integral μ X * integral μ Y

tactic: have I : ¬(Integrable X μ ∧ Integrable Y μ) := by
  rintro ⟨HX, HY⟩
  exact h (hXY.integrable_mul HX HY)
state_before: case neg
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : ¬Y =ᶠ[ae μ] 0
h : ¬Integrable (X * Y) μ
⊢ 0 = integral μ X * integral μ Y
state_after: case neg
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : ¬Y =ᶠ[ae μ] 0
h : ¬Integrable (X * Y) μ
I : ¬(Integrable X μ ∧ Integrable Y μ)
⊢ 0 = integral μ X * integral μ Y

tactic: rw [not_and_or] at I
state_before: case neg
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : ¬Y =ᶠ[ae μ] 0
h : ¬Integrable (X * Y) μ
I : ¬(Integrable X μ ∧ Integrable Y μ)
⊢ 0 = integral μ X * integral μ Y
state_after: case neg
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : ¬Y =ᶠ[ae μ] 0
h : ¬Integrable (X * Y) μ
I : ¬Integrable X μ ∨ ¬Integrable Y μ
⊢ 0 = integral μ X * integral μ Y

tactic: cases' I with I I <;> simp [integral_undef I]
state_before: case neg
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : ¬Y =ᶠ[ae μ] 0
h : ¬Integrable (X * Y) μ
I : ¬Integrable X μ ∨ ¬Integrable Y μ
⊢ 0 = integral μ X * integral μ Y
state_after: no goals

tactic: rintro ⟨HX, HY⟩
state_before: Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : ¬Y =ᶠ[ae μ] 0
h : ¬Integrable (X * Y) μ
⊢ ¬(Integrable X μ ∧ Integrable Y μ)
state_after: case intro
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : ¬Y =ᶠ[ae μ] 0
h : ¬Integrable (X * Y) μ
HX : Integrable X μ
HY : Integrable Y μ
⊢ False

tactic: exact h (hXY.integrable_mul HX HY)
state_before: case intro
Ω : Type u_1
mΩ : MeasurableSpace Ω
μ : Measure Ω
f g : Ω → ℝ≥0∞
X Y : Ω → ℝ
hXY : IndepFun X Y μ
hX : AEStronglyMeasurable X μ
hY : AEStronglyMeasurable Y μ
h'X : ¬X =ᶠ[ae μ] 0
h'Y : ¬Y =ᶠ[ae μ] 0
h : ¬Integrable (X * Y) μ
HX : Integrable X μ
HY : Integrable Y μ
⊢ False
state_after: no goals