Theorem: MeasureTheory.rnDeriv_tilted_left
File: Mathlib/MeasureTheory/Measure/Tilted.lean

tactic: let g := fun x ↦ ENNReal.ofReal (exp (f x) / (∫ x, exp (f x) ∂μ))
state_before: α : Type u_1
mα : MeasurableSpace α
μ : Measure α
f : α → ℝ
ν : Measure α
inst✝¹ : SigmaFinite μ
inst✝ : SigmaFinite ν
hfμ : AEMeasurable f μ
hfν : AEMeasurable f ν
⊢ (μ.tilted f).rnDeriv ν =ᶠ[ae ν] fun x => ENNReal.ofReal (rexp (f x) / ∫ (x : α), rexp (f x) ∂μ) * μ.rnDeriv ν x
state_after: α : Type u_1
mα : MeasurableSpace α
μ : Measure α
f : α → ℝ
ν : Measure α
inst✝¹ : SigmaFinite μ
inst✝ : SigmaFinite ν
hfμ : AEMeasurable f μ
hfν : AEMeasurable f ν
g : α → ℝ≥0∞ := fun x => ENNReal.ofReal (rexp (f x) / ∫ (x : α), rexp (f x) ∂μ)
⊢ (μ.tilted f).rnDeriv ν =ᶠ[ae ν] fun x => ENNReal.ofReal (rexp (f x) / ∫ (x : α), rexp (f x) ∂μ) * μ.rnDeriv ν x

tactic: refine Measure.rnDeriv_withDensity_left (μ := μ) (ν := ν) (f := g) ?_ ?_ ?_
state_before: α : Type u_1
mα : MeasurableSpace α
μ : Measure α
f : α → ℝ
ν : Measure α
inst✝¹ : SigmaFinite μ
inst✝ : SigmaFinite ν
hfμ : AEMeasurable f μ
hfν : AEMeasurable f ν
g : α → ℝ≥0∞ := fun x => ENNReal.ofReal (rexp (f x) / ∫ (x : α), rexp (f x) ∂μ)
⊢ (μ.tilted f).rnDeriv ν =ᶠ[ae ν] fun x => ENNReal.ofReal (rexp (f x) / ∫ (x : α), rexp (f x) ∂μ) * μ.rnDeriv ν x
state_after: case refine_1
α : Type u_1
mα : MeasurableSpace α
μ : Measure α
f : α → ℝ
ν : Measure α
inst✝¹ : SigmaFinite μ
inst✝ : SigmaFinite ν
hfμ : AEMeasurable f μ
hfν : AEMeasurable f ν
g : α → ℝ≥0∞ := fun x => ENNReal.ofReal (rexp (f x) / ∫ (x : α), rexp (f x) ∂μ)
⊢ AEMeasurable g μ

case refine_2
α : Type u_1
mα : MeasurableSpace α
μ : Measure α
f : α → ℝ
ν : Measure α
inst✝¹ : SigmaFinite μ
inst✝ : SigmaFinite ν
hfμ : AEMeasurable f μ
hfν : AEMeasurable f ν
g : α → ℝ≥0∞ := fun x => ENNReal.ofReal (rexp (f x) / ∫ (x : α), rexp (f x) ∂μ)
⊢ AEMeasurable g ν

case refine_3
α : Type u_1
mα : MeasurableSpace α
μ : Measure α
f : α → ℝ
ν : Measure α
inst✝¹ : SigmaFinite μ
inst✝ : SigmaFinite ν
hfμ : AEMeasurable f μ
hfν : AEMeasurable f ν
g : α → ℝ≥0∞ := fun x => ENNReal.ofReal (rexp (f x) / ∫ (x : α), rexp (f x) ∂μ)
⊢ ∀ᵐ (x : α) ∂μ, g x ≠ ⊤

tactic: exact ((measurable_exp.comp_aemeasurable hfμ).div_const _).ennreal_ofReal
state_before: case refine_1
α : Type u_1
mα : MeasurableSpace α
μ : Measure α
f : α → ℝ
ν : Measure α
inst✝¹ : SigmaFinite μ
inst✝ : SigmaFinite ν
hfμ : AEMeasurable f μ
hfν : AEMeasurable f ν
g : α → ℝ≥0∞ := fun x => ENNReal.ofReal (rexp (f x) / ∫ (x : α), rexp (f x) ∂μ)
⊢ AEMeasurable g μ
state_after: no goals

tactic: exact ((measurable_exp.comp_aemeasurable hfν).div_const _).ennreal_ofReal
state_before: case refine_2
α : Type u_1
mα : MeasurableSpace α
μ : Measure α
f : α → ℝ
ν : Measure α
inst✝¹ : SigmaFinite μ
inst✝ : SigmaFinite ν
hfμ : AEMeasurable f μ
hfν : AEMeasurable f ν
g : α → ℝ≥0∞ := fun x => ENNReal.ofReal (rexp (f x) / ∫ (x : α), rexp (f x) ∂μ)
⊢ AEMeasurable g ν
state_after: no goals

tactic: exact ae_of_all _ (fun x ↦ by simp [g])
state_before: case refine_3
α : Type u_1
mα : MeasurableSpace α
μ : Measure α
f : α → ℝ
ν : Measure α
inst✝¹ : SigmaFinite μ
inst✝ : SigmaFinite ν
hfμ : AEMeasurable f μ
hfν : AEMeasurable f ν
g : α → ℝ≥0∞ := fun x => ENNReal.ofReal (rexp (f x) / ∫ (x : α), rexp (f x) ∂μ)
⊢ ∀ᵐ (x : α) ∂μ, g x ≠ ⊤
state_after: no goals

tactic: simp [g]
state_before: α : Type u_1
mα : MeasurableSpace α
μ : Measure α
f : α → ℝ
ν : Measure α
inst✝¹ : SigmaFinite μ
inst✝ : SigmaFinite ν
hfμ : AEMeasurable f μ
hfν : AEMeasurable f ν
g : α → ℝ≥0∞ := fun x => ENNReal.ofReal (rexp (f x) / ∫ (x : α), rexp (f x) ∂μ)
x : α
⊢ g x ≠ ⊤
state_after: no goals