Central limit theorem

The various laws of large numbers say that the empirical mean converges to the true mean when you take more and more trials. The central limit theorem says that the normalized fluctuations about the mean converge to the normal distribution.

Theorem 1 (Central Limit Theorem).

Let $\set{X_n}_{n \in \N}$ be i.i.d. random variables with $\E X_1 = \mu$ and $\var(X_1) = \sigma^2$. Then $$ \frac{1}{\sqrt{N}} \sum_{n = 1}^N (X_n - \mu) \xrightarrow[N \to \infty]{d} \mathcal N(0, \sigma^2) \,. $$

Here the $\xrightarrow{d}$ notation above means convergence in distribution, which will be defined shortly.

Normal distribution

Definition 2. We say $X$ is a standard normal if $X \sim \mathcal N(0, 1)$.

Proposition 3. If $X \sim \mathcal N(\mu, \sigma^2)$, and $a, b \in \R$ with $a \neq 0$, then $$ aX + b \sim \mathcal N(a\mu+b, a^2\sigma^2) \,. $$ In particular, $(X-\mu)/\sigma$ is a standard normal distribution.

Proposition 4. Suppose $X_1, \dots, X_N$ are independent random variables with $X_n \sim \mathcal N(\mu_n, \sigma_n^2)$. Then $$ \sum_{n=1}^N X_n \sim \mathcal N\paren[\Big]{ \sum_{n=1}^N \mu_n,\, \sum_{n=1}^N \sigma_n^2 } \,. $$

Proof sketch. Follows immediately from this problem.

Remark 5. Suppose $X_n$ are i.i.d. $\mathcal N(\mu,\sigma^2)$ random variables. Then for every $N \in \N$, $$ \frac{1}{\sqrt N}\sum_{n=1}^N(X_n-\mu) \sim \mathcal N(0,\sigma^2) \,. $$

Say $\E X = \mu$ and $\var(X) = \sigma^2$. Recall by Chebychev’s inequality, $$ \P( \abs{X - \mu} > \lambda \sigma ) \leq \frac{1}{\lambda^2} \,. $$ For Gaussian random variables, you can do much better.

Proposition 6. If $X \sim \mathcal N(\mu, \sigma^2)$, then $$ \P( \abs{X - \mu} > \lambda \sigma ) \leq \frac{2}{\lambda \sqrt{2\pi}}e^{-\lambda^2 / 2} \,. $$

Remark 7. Say $X \sim \mathcal N(\mu, \sigma^2)$. By computing with the standard normal CDF, one can check the $3\sigma$-rule.

  1. $\P( |X - \mu| < \sigma ) \approx 68.3\%$,
  2. $\P( |X - \mu| < 2 \sigma ) \approx 95.4\%$,
  3. $\P( |X - \mu| < 3 \sigma ) \approx 99.7\%$.

Problem 8. If $X \sim \mathcal N(\mu, \sigma^2)$ find $\E(X - \mu)^n$ for all $n \in \N$.

Answer. $\E (X - \mu)^n = 0$ if $n$ is odd, and $\sigma^n (n-1)!!$ when $n$ is even. (Here $m!!$ is the double factorial of $m$ which is the product of all integers between $1$ and $m$ which have the same parity as $m$.)

Problem 9. Let $Z = (Z_1, \dots, Z_d)$ where $\set{Z_i}$ are i.i.d. $\mathcal N(0, 1)$ random variables. Let $A$ be a $m \times d$ matrix, and $\mu \in \R^m$ and define $X = A Z + \mu$. Show that $$ \E X = \mu \,, \qquad \cov(X_i,X_j) = \Sigma_{ij} \quad\text{where}\quad \Sigma = A A^T \,. $$

Problem 10. Let $X, Y$ be two i.i.d. standard normals, $\theta \in \R$ and define $$ U = X \cos \theta + Y \sin \theta \,,\qquad V = X \sin \theta - Y \cos \theta \,. $$ Show that $U, V$ are also independent standard normals.

Hint. For independence, try making a (two dimensional) change of variables to find the joint distribution of $(U, V)$.

Definition 11. Let $Z_1$, …, $Z_k$ be i.i.d. standard normals, and let $X = \sum_1^k Z_i^2$. The distribution of $X$ is called the $\chi^2$-distribution with $k$-degrees of freedom, and denoted by $X \sim \chi^2_k$.

The $\chi_k^2$ distribution arises often in statistics and hypothesis testing; the CLT says fluctuations around the mean are normal. Measuring errors by squaring leads the $\chi_k^2$ distribution.

Problem 12.

  1. Find the mean and variance of the $\chi_k^2$ distribution.
  2. For $k = 2$, find the density of the $\chi_k^2$ distribution.

Convergence in distribution

Before defining convergence in distribution, let’s first show we need it. Namely, almost sure convergence is not good enough to give the central limit theorem.

Problem 13. Let $\set{X_n}_{n \in \N}$ be i.i.d. standard normals, and let $S_N = \sum_{n = 1}^N X_n / \sqrt{N}$. Show that (almost surely) $\set{S_N}_{N \in \N}$ is not bounded, and so $S_N$ can not converge almost surely.

Hint. Let $T_N = \sqrt{N} S_N$, $Y_k = (T_{2^{k+1}} - T_{2^k}) / 2^{k/2}$. Show that for any $C \in \R$, the events $\set{\abs{Y_k} > C}$ occur infinitely often.

Definition 14. Let $X_n$ be a sequence of random variables, and let $X$ be random variable. We say $X_n$ converges in distribution to $X$ (notation $X_n \xrightarrow{d} X$) if $$ \lim_{n \to \infty} F_{X_n}(x) = F_X(x) $$ at every point $x$ where $F_X$ is continuous.

Remark 15. Convergence in distribution doesn’t require the random variables $X_n$, $X$ to be defined on the same probability space. Convergence almost surely, convergence in probability, and convergence in $L^p$ all require the random variables $X_n$ and the limit $X$ to be defined on a common probability space.

Example 16. Convergence in distribution does not imply convergence in probability, or convergence almost surely. For example, if $\set{X_n}$ are i.i.d. Bernoulli $p$ for some $p \in (0, 1)$, then they converge in distribution, but do not converge in probability, and do not converge almost surely.

Proposition 17. If $X_n \to X$ in probability, then $X_n \xrightarrow{d} X$.

Proof sketch. For any $\epsilon > 0$, $$ F_X(x-\epsilon) - \P(|X_n-X|>\epsilon) \leq F_{X_n}(x) \leq F_X(x+\epsilon) + \P(|X_n-X|>\epsilon) \,. $$ First let $n \to \infty$, then $\epsilon \to 0$, at a continuity point of $F_X$ to conclude.

Proposition 18. Let $c \in \R$ be a constant, and $\set{X_n}_{n \in \N}$ be a sequence of random variables. Then $X_n \to c$ in probability as $n \to \infty$, if and only if $X_n \to c$ in distribution as $n \to \infty$. (That is, if the target random variables is constant, then convergence in distribution and convergence in probability are equivalent.)

There is another useful characterization of convergence in distribution, which is often easier to verify.

Theorem 19. Let $X_n$ and $X$ be random variables. Then $X_n \xrightarrow{d} X$ if and only if $$\label{e:F}\tag{F} \lim_{n \to \infty} \E f(X_n) = \E f(X) $$ for every bounded continuous function $f \colon \R \to \R$.

Non proof. The proof requires some approximation arguments which are beyond the scope of this course.

Remark 20. In Theorem 19, it is important that $f$ is continuous. Convergence in distribution does not imply \eqref{e:F} holds for functions which are not continuous. For example, let $X_n = 1/n$ and $X=0$. Then $X_n \xrightarrow{d} X$, but for $f = \one_{(-\infty, 0]}$, $$ \lim_{n \to \infty} \E f(X_n) = 0 \neq 1 = \E f(X) \,. $$

Problem 21. Suppose $X_n \xrightarrow{d} X$.

  1. Show that $\E X_n^2$ need not converge to $\E X^2$ (even if both are defined and finite).
  2. For any continuous (but not necessarily bounded) function, show that $g(X_n) \xrightarrow{d} g(X)$. (In particular, $X_n^2 \xrightarrow{d} X^2$, but $\E X_n^2$ need not converge to $\E X^2$.)

Theorem 22 (Slutsky). Let $\set{X_n}_{n \in \N}$, $\set{Y_n}_{n \in \N}$ be two (not necessarily independent) sequence of random variable, $X$ be a random variable, and $c \in \R$ be a constant. Suppose as $n \to \infty$ we have $X_n \to X$ in distribution, and $Y_n \to c$ in probability.

  1. As $n \to \infty$ we have $X_n + Y_n \to X + c$ in distribution.
  2. As $n \to \infty$ we have $X_n Y_n \to c X$ in distribution.
  3. As $n \to \infty$ we have $X_n / Y_n \to X / c$, provided $c \neq 0$. (Note, when $Y_n = 0$, you can define $X_n / Y_n$ arbitrarily.)

Proof sketch. In general, show \begin{align} \P(X_n\leq t-c-\epsilon) -\P( \abs{Y_n-c} > \epsilon) &\leq \P(X_n+Y_n\leq t) \\ &\leq \P(X_n\leq t-c+\epsilon) + \P( \abs{Y_n-c} > \epsilon ) \,. \end{align}

Lindeberg’s proof of the central limit theorem

We now prove Theorem 1 using a technique called Lindeberg’s replacement method. The idea is to replace the random variables in the sum, one at a time, by independent normal random variables with the same mean and variance.

Proof sketch of Theorem 1. Let $Y_i = X_i-\mu$. Let $Z_1,\dots,Z_N$ be independent $\mathcal N(0,\sigma^2)$ random variables, also independent of all the $Y_i$. We will only prove \eqref{e:F} for functions $f$ which are $3$-times differentiable with a bounded third derivative, and we will assume the third moments of $\set{X_n}$ are finite. (Both these assumptions aren’t necessary.)

For $k \in \set{1, \dots, N}$ set $$ S_N = \frac{1}{\sqrt N}\sum_{i=1}^N Y_i \,,\qquad T_N = \frac{1}{\sqrt N}\sum_{i=1}^N Z_i \,,\qquad W_k = \frac{1}{\sqrt N} \paren[\Big]{ \sum_{j<k} Z_j + \sum_{j>k} Y_j } \,. $$ Note $T_N \sim \mathcal N(0,\sigma^2)$ for every $N$, and $W_k$ is independent of both $Y_k$ and $Z_k$. Replacing the variables one at a time gives $$ \E f(S_N) - \E f(T_N) = \sum_{i=1}^N \E\paren[\Big]{ f\paren[\Big]{ W_i + \frac{Y_i}{\sqrt N} } - f\paren[\Big]{ W_i + \frac{Z_i}{\sqrt N} } } \,. $$

By Taylor’s theorem, $$ f(x + h) = f(x) + h f’(x) + \frac{h^2}{2} f\dprime(x) + \frac{h^3}{6} f\tprime(\xi)\,, $$ for some $\xi$ between $x$ and $x + h$. Since $f\tprime$ is bounded, let $C = \max \abs{f\tprime}$ (or more correctly, $C = \sup \abs{f \tprime}$), then $$ \abs{\E f(S_N)-\E f(T_N)} \leq \frac{C}{6N^{3/2}} \sum_{i=1}^N \E\paren[\big]{\abs{Y_i}^3+\abs{Z_i}^3} \xrightarrow{N \to \infty} 0 \,, $$ which implies \eqref{e:F} for $C^3$ test functions. A standard approximation argument shows that this implies \eqref{e:F} for all bounded continuous functions.

Corollary 23 (De Moivre–Laplace). If $X_N \sim \Binom(N, p)$, then $$ \frac{X_N - N p}{\sqrt{N}} \xrightarrow[N \to \infty]{d} \mathcal N(0, p( 1 - p)) \,. $$

Proof sketch. Historically this was proved using explicit formulae and Stirling’s approximation. However, now you can deduce this quickly from the CLT.

Problem 24. Let $\set{X_n}_{n \in \N}$ be i.i.d. random variables, with mean $\mu$ and variance $\sigma^2 > 0$. Suppose further all higher moments of $X_1$ are defined and finite (though you only need $\E X_1^8 < \infty$). Define the empirical mean and variance by $$ \hat \mu_N \defeq \frac{1}{N} \sum_{n = 1}^N X_n \,, \quad\text{and}\quad \hat \sigma_N^2 \defeq \frac{1}{N} \sum_{n = 1}^N (X_n - \hat \mu_N)^2 $$

  1. Show that as $N \to \infty$, $\hat \sigma_N^2 \to \sigma^2$ almost surely, and $\sqrt{N} (\hat \sigma_N^2 - \sigma^2)$ converges in distribution to a normally distributed random variable with mean $0$ and variance $\E (X_1 - \mu)^4 - \sigma^4$.
  2. Show that $N (\hat \mu_N - \mu)^2 / \sigma^2$ converges in distribution to $\chi_1^2$.

Remark 25. Using the multiplicative version of Slutsky’s theorem, one can also show $N (\hat \mu - \mu)^2 / \hat \sigma_N^2$ converges in distribution to $\chi_1^2$, and $\sqrt{N} (\hat \mu_N - \mu) / \hat \sigma_N$ converges in distribution to $\mathcal N(0, 1)$. This is called “Studentization” and explains why you can use the empirical standard deviation when computing confidence intervals.

Remark 26. Without assuming the random variables have a finite variance, the central limit theorem is false. A particularly memorable counter example is below.

Proposition 27. If $\set{X_n}_{n \in \N}$ are i.i.d. standard Cauchy random variables, then for every $N \in \N$, the random variables $\frac{1}{N} \sum_{n = 1}^N X_n$ all also follow the standard Cauchy distribution.

Remark 28. The correct generalization of the central limit theorem without assuming finite variance involves a different normalization and gives Lévy stable distributions.