The central limit theorem on the cube #
For a uniformly random x : Fin n → Bool, read as signs xᵢ = signVal (x i), the normalized sum
Zₙ = ∑ᵢ xᵢ / √n converges in distribution to a standard Gaussian Z. This is Mathlib's central
limit theorem (ProbabilityTheory.tendstoInDistribution_inv_sqrt_mul_sum) for a sequence of
independent uniform signs under Measure.infinitePi, carried to the cube by
integral_pi_rademacher. It is stated here as convergence of expectations on the cube:
- for bounded continuous
g,E[g(Zₙ)] → E[g(Z)](tendsto_expect_inv_sqrt_mul_sum_signVal); - for the indicator of a measurable set whose frontier is Gaussian-null, by the portmanteau theorem
(
tendsto_expect_indicator_inv_sqrt_mul_sum_signVal); - for continuous
hof at most linear growth,h(z)² ≤ a z² + b, sinceE[Zₙ²] ≤ 1(tendsto_expect_inv_sqrt_mul_sum_signVal_of_sq_le, throughMeasureTheory.ProbabilityMeasure.tendsto_integral_of_integral_sq_le).
In particular E[|Zₙ|] → E[|Z|] = √(2 / π) (tendsto_expect_abs_inv_sqrt_mul_sum_signVal), the
estimate (5.4) of O'Donnell, Section 5.2 behind I[Majₙ] ∼ √(2 / π) √n.
Main results #
Cslib.BitString.tendsto_expect_inv_sqrt_mul_sum_signVal,Cslib.BitString.tendsto_expect_indicator_inv_sqrt_mul_sum_signVal,Cslib.BitString.tendsto_expect_inv_sqrt_mul_sum_signVal_of_sq_le: the central limit theorem on the cube for bounded continuous functions, events and functions of at most linear growth.Cslib.BitString.tendsto_expect_abs_inv_sqrt_mul_sum_signVal:E[|∑ᵢ xᵢ / √n|] → √(2 / π).
Usage #
The statements match an expectation written exactly as
𝔼 x : Fin n → Bool, g ((√n)⁻¹ * ∑ i, signVal (x i)), with n cast to ℝ; for another finite
index type, reindex to Fin n first, for example with Fintype.expect_comp_arrowCongr. The
form for functions of at most linear growth admits unbounded h of either sign; the second
moments it uses are expect_sq_inv_sqrt_card_mul_sum_signVal_le. The checked clients in
CslibFrontierTests/BooleanAnalysisHammingBallWeight.lean
apply it to z - |z|, which is unbounded below, and derive that E[|∑ᵢ xᵢ / √n|] is eventually
below 1.
References #
- R. O'Donnell, Analysis of Boolean Functions, Section 5.2.
The central limit theorem on the cube. For a bounded continuous g, the expectation of
g (∑ᵢ xᵢ / √n) at a uniform x ∈ {-1, 1}ⁿ tends to E[g(Z)] for a standard Gaussian Z.
The central limit theorem on the cube, for events. For a measurable E whose frontier is
null for the standard Gaussian, Pr_x[∑ᵢ xᵢ / √n ∈ E] tends to Pr[Z ∈ E].
The central limit theorem on the cube, for functions of at most linear growth. For a
continuous h with h(z)² ≤ a z² + b, the expectation of h (∑ᵢ xᵢ / √n) at a uniform
x ∈ {-1, 1}ⁿ tends to E[h(Z)] for a standard Gaussian Z. The second moments are at most one,
which makes h uniformly integrable.
The mean absolute value of the normalized sign sum tends to that of a standard Gaussian,
E[|∑ᵢ xᵢ / √n|] → E[|Z|] = √(2 / π) O'Donnell, Section 5.2, equation (5.4).