Skip to content

Commit 942e977

Browse files
committed
feat: convergence in distribution and continuous mapping theorem (#30540)
- Define convergence in distribution of random variables: this is the weak convergence of their laws. - Prove the continuous mapping theorem for convergence in distribution and continuous functions. Co-authored-by: Remy Degenne <remydegenne@gmail.com>
1 parent 0f1f2fc commit 942e977

File tree

3 files changed

+88
-0
lines changed

3 files changed

+88
-0
lines changed

Mathlib.lean

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4625,6 +4625,7 @@ import Mathlib.MeasureTheory.Function.ConditionalExpectation.Indicator
46254625
import Mathlib.MeasureTheory.Function.ConditionalExpectation.Real
46264626
import Mathlib.MeasureTheory.Function.ConditionalExpectation.Unique
46274627
import Mathlib.MeasureTheory.Function.ContinuousMapDense
4628+
import Mathlib.MeasureTheory.Function.ConvergenceInDistribution
46284629
import Mathlib.MeasureTheory.Function.ConvergenceInMeasure
46294630
import Mathlib.MeasureTheory.Function.Egorov
46304631
import Mathlib.MeasureTheory.Function.EssSup
Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
/-
2+
Copyright (c) 2025 Rémy Degenne. All rights reserved.
3+
Released under Apache 2.0 license as described in the file LICENSE.
4+
Authors: Rémy Degenne
5+
-/
6+
import Mathlib.MeasureTheory.Measure.ProbabilityMeasure
7+
8+
/-!
9+
# Convergence in distribution
10+
11+
We introduce a definition of convergence in distribution of random variables: this is the
12+
weak convergence of the laws of the random variables. In Mathlib terms this is a `Tendsto` in the
13+
`ProbabilityMeasure` type.
14+
15+
The definition assumes that the random variables are defined on the same probability space, which
16+
is the most common setting in applications. Convergence in distribution for random variables
17+
on different probability spaces can be talked about using the `ProbabilityMeasure` type directly.
18+
19+
## Main definitions
20+
21+
* `TendstoInDistribution X l Z μ`: the sequence of random variables `X n` converges in
22+
distribution to the random variable `Z` along the filter `l` with respect to the probability
23+
measure `μ`.
24+
25+
## Main statements
26+
27+
* `TendstoInDistribution.continuous_comp`: **Continuous mapping theorem**.
28+
If `X n` tends to `Z` in distribution and `g` is continuous, then `g ∘ X n` tends to `g ∘ Z`
29+
in distribution.
30+
-/
31+
32+
open Filter
33+
open scoped Topology
34+
35+
namespace MeasureTheory
36+
37+
variable {Ω ι E : Type*} {m : MeasurableSpace Ω} {μ : Measure Ω} [IsProbabilityMeasure μ]
38+
[TopologicalSpace E] {mE : MeasurableSpace E} {X Y : ι → Ω → E} {Z : Ω → E} {l : Filter ι}
39+
40+
section TendstoInDistribution
41+
42+
/-- Convergence in distribution of random variables.
43+
This is the weak convergence of the laws of the random variables: `Tendsto` in the
44+
`ProbabilityMeasure` type. -/
45+
structure TendstoInDistribution [OpensMeasurableSpace E] (X : ι → Ω → E) (l : Filter ι) (Z : Ω → E)
46+
(μ : Measure Ω := by volume_tac) [IsProbabilityMeasure μ] : Prop where
47+
forall_aemeasurable : ∀ i, AEMeasurable (X i) μ
48+
aemeasurable_limit : AEMeasurable Z μ := by fun_prop
49+
tendsto : Tendsto (β := ProbabilityMeasure E)
50+
(fun n ↦ ⟨μ.map (X n), Measure.isProbabilityMeasure_map (forall_aemeasurable n)⟩) l
51+
(𝓝 ⟨μ.map Z, Measure.isProbabilityMeasure_map aemeasurable_limit⟩)
52+
53+
lemma tendstoInDistribution_const [OpensMeasurableSpace E] (hZ : AEMeasurable Z μ) :
54+
TendstoInDistribution (fun _ ↦ Z) l Z μ where
55+
forall_aemeasurable := fun _ ↦ by fun_prop
56+
tendsto := tendsto_const_nhds
57+
58+
lemma tendstoInDistribution_unique [HasOuterApproxClosed E] [BorelSpace E]
59+
(X : ι → Ω → E) {Z W : Ω → E} [l.NeBot]
60+
(h1 : TendstoInDistribution X l Z μ) (h2 : TendstoInDistribution X l W μ) :
61+
μ.map Z = μ.map W := by
62+
have h_eq := tendsto_nhds_unique h1.tendsto h2.tendsto
63+
rw [Subtype.ext_iff] at h_eq
64+
simpa using h_eq
65+
66+
/-- **Continuous mapping theorem**: if `X n` tends to `Z` in distribution and `g` is continuous,
67+
then `g ∘ X n` tends to `g ∘ Z` in distribution. -/
68+
theorem TendstoInDistribution.continuous_comp {F : Type*} [OpensMeasurableSpace E]
69+
[TopologicalSpace F] [MeasurableSpace F] [BorelSpace F] {g : E → F} (hg : Continuous g)
70+
(h : TendstoInDistribution X l Z μ) :
71+
TendstoInDistribution (fun n ↦ g ∘ X n) l (g ∘ Z) μ where
72+
forall_aemeasurable := fun n ↦ hg.measurable.comp_aemeasurable (h.forall_aemeasurable n)
73+
aemeasurable_limit := hg.measurable.comp_aemeasurable h.aemeasurable_limit
74+
tendsto := by
75+
convert ProbabilityMeasure.tendsto_map_of_tendsto_of_continuous _ _ h.tendsto hg
76+
· simp only [ProbabilityMeasure.map, ProbabilityMeasure.coe_mk, Subtype.mk.injEq]
77+
rw [AEMeasurable.map_map_of_aemeasurable hg.aemeasurable (h.forall_aemeasurable _)]
78+
· simp only [ProbabilityMeasure.map, ProbabilityMeasure.coe_mk]
79+
congr
80+
rw [AEMeasurable.map_map_of_aemeasurable hg.aemeasurable h.aemeasurable_limit]
81+
82+
end TendstoInDistribution
83+
84+
end MeasureTheory

docs/1000.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2963,6 +2963,9 @@ Q5163116:
29632963

29642964
Q5165492:
29652965
title: Continuous mapping theorem
2966+
decl: MeasureTheory.TendstoInDistribution.continuous_comp
2967+
authors: Rémy Degenne
2968+
date: 2025
29662969

29672970
Q5166389:
29682971
title: Van Vleck's theorem

0 commit comments

Comments
 (0)