-- File: FoML/FoML/ForMathlib/Probability/Moments.lean
Theorem statement:
theorem extracted_formal_statement_95.{u_1} {Ω : Type u_1} {m : MeasurableSpace Ω} {μ : Measure Ω}
  [inst : IsFiniteMeasure μ] (t : ℝ) (f : ℝ → ℝ) {X : Ω → ℝ} (hX : AEMeasurable X μ)
  (h_original_goal :
    ∫ (ω : Ω), ((∂μ.tilted fun ω => t * X ω/∂μ) ω).toReal • f (X ω) ∂μ =
      ∫ (ω : Ω), (rexp (t * X ω) / ∫ (x : Ω), (fun ω => rexp (t * X ω)) x ∂μ) * f (X ω) ∂μ) :
  (fun a => ((∂μ.tilted fun ω => t * X ω/∂μ) a).toReal • f (X a)) =ᶠ[ae μ] fun a =>
    (rexp (t * X a) / ∫ (x : Ω), (fun ω => rexp (t * X ω)) x ∂μ) * f (X a) := sorry

Tactic state before:
Ω : Type u_1
m : MeasurableSpace Ω
μ : Measure Ω
inst✝ : IsFiniteMeasure μ
t : ℝ
f : ℝ → ℝ
X : Ω → ℝ
hX : AEMeasurable X μ
⊢ ∫ (ω : Ω), ((∂μ.tilted fun ω => t * X ω/∂μ) ω).toReal • f (X ω) ∂μ =
    ∫ (ω : Ω), (rexp (t * X ω) / ∫ (x : Ω), (fun ω => rexp (t * X ω)) x ∂μ) * f (X ω) ∂μ

Tactic: apply integral_congr_ae

Tactic state after:
[case h
 Ω : Type u_1
 m : MeasurableSpace Ω
 μ : Measure Ω
 inst✝ : IsFiniteMeasure μ
 t : ℝ
 f : ℝ → ℝ
 X : Ω → ℝ
 hX : AEMeasurable X μ
 ⊢ (fun a => ((∂μ.tilted fun ω => t * X ω/∂μ) a).toReal • f (X a)) =ᶠ[ae μ] fun a =>
     (rexp (t * X a) / ∫ (x : Ω), (fun ω => rexp (t * X ω)) x ∂μ) * f (X a)]

Premises used:
MeasureTheory.integral_congr_ae : ∀ {α : Type u_1} {G : Type u_5} [inst : NormedAddCommGroup G]
  [inst_1 : NormedSpace ℝ G] {m : MeasurableSpace α} {μ : Measure α} {f g : α → G},
  f =ᶠ[ae μ] g → ∫ (a : α), f a ∂μ = ∫ (a : α), g a ∂μ