The point mass P(S_n = k) = C(n,k) / 2ⁿ for a Binomial(n, 1/2) random variable S_n.
Instances For
The Gaussian (local CLT) approximation to binomProbHalf n k,
√(2/(π n)) · exp(-(k - n/2)² / (n/2)).
Instances For
The integer index k = ⌊n/2 + x·√n/2⌋ corresponding to the parameter x in the local
DeMoivre–Laplace statement: it picks the lattice point near n/2 + x √n / 2, so that
(2k - n)/√n ≈ x.
Instances For
The index localDMLIndex x n tends to infinity as n → ∞, for any fixed x : ℝ.
The complementary index n - localDMLIndex x n also tends to infinity, so both k and
n - k are eventually arbitrarily large.
The ratio localDMLIndex x n / n tends to 1/2 as n → ∞, because the correction
x √n / 2 is o(n).
Rewriting of m! in terms of Mathlib's Stirling.stirlingSeq:
m! = stirlingSeq(m) · √(2m) · (m/e)^m.
Algebraic rewriting of the ratio binomProbHalf n k / gaussianApproxHalf n k using
Stirling's formula, separating it into a Stirling-sequence factor, a square-root factor,
a power-of-n factor, and an exponential correction.
Third-order Taylor bound for the symmetric entropy expansion:
|(1+u) log(1+u) + (1-u) log(1-u) - u²| ≤ 6 |u|³ whenever |u| < 1/2. Used to control the
deviation of the binomial coefficient from its Gaussian approximation.
Eventually, the deviation |2k - n| for k = localDMLIndex x n is at most |x| √n + 2,
since k = ⌊n/2 + x √n / 2⌋.
Identity rewriting the logarithm of the power factor nⁿ / (kᵏ (n-k)^{n-k} 2ⁿ) plus the
Gaussian exponent (k - n/2)² / (n/2) as -(n/2) · ((1+u) log(1+u) + (1-u) log(1-u) - u²),
where u = (2k - n)/n. This combines the log-binomial expansion with the Gaussian correction.
The product of the power factor nⁿ / (kᵏ (n-k)^{n-k} 2ⁿ) with the Gaussian correction
exp((k - n/2)² / (n/2)), evaluated at k = localDMLIndex x n, tends to 1 as n → ∞.
This is the key analytic estimate behind the local DeMoivre–Laplace limit theorem.
Companion to localDMLIndex_ratio_half: the ratio (n - k) / n for k = localDMLIndex x n
also tends to 1/2.
The binomial point mass and its Gaussian approximation are asymptotically equivalent along
the sequence k = localDMLIndex x n:
binomProbHalf n k ~ gaussianApproxHalf n k as n → ∞. Combines Stirling's formula with the
power-factor and entropy estimates.
Local DeMoivre–Laplace limit theorem (p = 1/2 case).
If 2k/√(2n) → x, then P(S_{2n} = 2k) ∼ (π n)^{-1/2} e^{-x²/2} for a fair-coin random walk
S_n. Equivalently, for any x ∈ ℝ, the ratio
binomProbHalf n (localDMLIndex x n) / gaussianApproxHalf n (localDMLIndex x n) → 1.