Solution: Bernoulli Sums and the de Moivre-Laplace Approximation
Part 1
For i.i.d. Bernoulli() with :
So , with standard deviation .
Part 2
Without continuity correction:
Part 3
With continuity correction:
Part 4
from scipy.stats import binom
exact = 1 - binom.cdf(59, n=100, p=0.55)
print(f"Exact binomial: {exact:.4f}")
# Exact binomial: 0.1827Comparison: exact , corrected Gaussian (off by ), uncorrected Gaussian (off by ). The continuity correction is dramatically better — an order of magnitude more accurate for the same computational cost.
Takeaways
- The CLT is a continuous approximation to a discrete distribution. Shifting by half a unit to straddle the integer (continuity correction) recovers almost all the accuracy lost to the discretisation.
- At the uncorrected approximation is already off by 15% relative. For smaller the error explodes; use exact binomial, not Gaussian, for .
- Always use the continuity correction on discrete CLT problems. The cost is typing
±0.5; the gain is an order of magnitude in accuracy. - This is the de Moivre-Laplace theorem — historically the first CLT, proved by de Moivre for fair coins () in 1733 and generalised by Laplace to arbitrary in 1810. It predates the general CLT by over a century.