Zulip Chat Archive
Stream: mathlib4
Topic: Advice on proving theorem on sum of random variables
David Ledvinka (Mar 17 2025 at 03:26):
I would like to contribute to Mathlib by proving that if and are two independent random variables with pdfs and then the pdf of is the convolution (In particular I would like to prove the identity for the sum of independent Gaussians). The most general and natural way I would think of doing this would be to prove:
For a monoid "":
- If and are independent random variables taking values in then the distribution of is given by the convolution of with .
For a group "":
- If is a (left/right) invariant measure on and are measures on with densities w.r.t respectively, then the convolution of with has density given by the convolution of and with respect to (appropriately defined).
Trying to come up with a statement for 2 I ran into some issues and figured I should ask for advice. Two of the main issues arise from the definition of convolution of functions in mathlib which do not allow for the group to be non-commutative and do not allow for the domain to be the extended reals (or extended non-negative reals). I could still use this definition by dropping some level of generality but even then I find a statement of 2 quite unwieldy because for example you need to take in , convert them to so they can be turned into densities, convert them to so that you can take a convolution, and then convert the output back to so it can again be converted into a density. Perhaps this could be all resolved by defining a convolution on functions but perhaps this would lead to too much confusion / proof duplication from the other notion of convolution and I am not sure if this is a good idea? Perhaps there is a better way to resolve this issue?
David Ledvinka (Mar 17 2025 at 10:58):
I wrote up this proof of "Step 1". Would love some feedback on the proof structure since I read all of MIL but noticed that many of the proofs in Mathlib look nothing like the proofs in MIL (featuring heavy use of simp etc...)
/- Imports -/
import Mathlib.MeasureTheory.Group.Convolution
import Mathlib.Probability.Independence.Basic
open MeasureTheory ProbabilityTheory Measure AEMeasurable
--open scoped ENNReal
section indepFun
@[to_additive]
theorem IndepFun.map_mul_eq_conv_map_map {M : Type*} [Monoid M] [MeasurableSpace M]
[MeasurableMul₂ M] {Ω : Type*} [MeasurableSpace Ω] {μ : Measure Ω} [IsFiniteMeasure μ]
{f : Ω → M} {g : Ω → M} (hf : AEMeasurable f μ) (hg : AEMeasurable g μ) (hfg : IndepFun f g μ):
μ.map (f * g) = (μ.map f) ∗ (μ.map g) := by
have : f * g = (fun (x,y) ↦ x * y) ∘ (fun ω ↦ (f ω, g ω)) := by rfl
rw[this, ← map_map_of_aemeasurable measurable_mul.aemeasurable (AEMeasurable.prodMk hf hg),
(indepFun_iff_map_prod_eq_prod_map_map hf hg).mp hfg]
rfl
end indepFun
Etienne Marion (Mar 17 2025 at 11:26):
Because we have docs#MeasureTheory.lintegral for ENNReal
-valued functions and docs#MeasureTheory.integral for NormedAddCommGroup
-valued functions, I think it would make sense to define MeasureTheory.lconvolution
.
Last updated: May 02 2025 at 03:31 UTC