Sum of normally distributed random variables
In probability theory, calculation of the sum of normally distributed random variables is an instance of the arithmetic of random variables.
This is not to be confused with the sum of normal distributions which forms a mixture distribution.
Independent random variables
Let X and Y be independent random variables that are normally distributed (and therefore also jointly so), then their sum is also normally distributed. i.e., if
- [math]\displaystyle{ X \sim N(\mu_X, \sigma_X^2) }[/math]
- [math]\displaystyle{ Y \sim N(\mu_Y, \sigma_Y^2) }[/math]
- [math]\displaystyle{ Z=X+Y, }[/math]
then
- [math]\displaystyle{ Z \sim N(\mu_X + \mu_Y, \sigma_X^2 + \sigma_Y^2). }[/math]
This means that the sum of two independent normally distributed random variables is normal, with its mean being the sum of the two means, and its variance being the sum of the two variances (i.e., the square of the standard deviation is the sum of the squares of the standard deviations).[1]
In order for this result to hold, the assumption that X and Y are independent cannot be dropped, although it can be weakened to the assumption that X and Y are jointly, rather than separately, normally distributed.[2] (See here for an example.)
The result about the mean holds in all cases, while the result for the variance requires uncorrelatedness, but not independence.
Proofs
Proof using characteristic functions
- [math]\displaystyle{ \varphi_{X+Y}(t) = \operatorname{E}\left(e^{it(X+Y)}\right) }[/math]
of the sum of two independent random variables X and Y is just the product of the two separate characteristic functions:
- [math]\displaystyle{ \varphi_X (t) = \operatorname{E}\left(e^{itX}\right), \qquad \varphi_Y(t) = \operatorname{E}\left(e^{itY}\right) }[/math]
of X and Y.
The characteristic function of the normal distribution with expected value μ and variance σ2 is
- [math]\displaystyle{ \varphi(t) = \exp\left(it\mu - {\sigma^2 t^2 \over 2}\right). }[/math]
So
- [math]\displaystyle{ \begin{align} \varphi_{X+Y}(t)=\varphi_X(t) \varphi_Y(t) & =\exp\left(it\mu_X - {\sigma_X^2 t^2 \over 2}\right) \exp\left(it\mu_Y - {\sigma_Y^2 t^2 \over 2}\right) \\[6pt] & = \exp \left( it (\mu_X +\mu_Y) - {(\sigma_X^2 + \sigma_Y^2) t^2 \over 2}\right). \end{align} }[/math]
This is the characteristic function of the normal distribution with expected value [math]\displaystyle{ \mu_X + \mu_Y }[/math] and variance [math]\displaystyle{ \sigma_X^2+\sigma_Y^2 }[/math]
Finally, recall that no two distinct distributions can both have the same characteristic function, so the distribution of X + Y must be just this normal distribution.
Proof using convolutions
For independent random variables X and Y, the distribution fZ of Z = X + Y equals the convolution of fX and fY:
- [math]\displaystyle{ f_Z(z) = \int_{-\infty}^\infty f_Y(z-x) f_X(x) \, dx }[/math]
Given that fX and fY are normal densities,
- [math]\displaystyle{ \begin{align} f_X(x) = \mathcal{N}(x; \mu_X, \sigma_X^2) = \frac{1}{\sqrt{2\pi}\sigma_X} e^{-(x-\mu_X)^2/(2\sigma_X^2)} \\[5pt] f_Y(y) = \mathcal{N}(y; \mu_Y, \sigma_Y^2) = \frac{1}{\sqrt{2\pi}\sigma_Y} e^{-(y-\mu_Y)^2/(2\sigma_Y^2)} \end{align} }[/math]
Substituting into the convolution:
- [math]\displaystyle{ \begin{align} f_Z(z) &= \int_{-\infty}^\infty \frac{1}{\sqrt{2\pi}\sigma_Y} \exp \left[-{(z-x-\mu_Y)^2 \over 2\sigma_Y^2}\right] \frac{1}{\sqrt{2\pi}\sigma_X} \exp \left[-{(x-\mu_X)^2 \over 2\sigma_X^2}\right] \, dx \\[6pt] &= \int_{-\infty}^\infty \frac{1}{\sqrt{2\pi}\sqrt{2\pi}\sigma_X\sigma_Y} \exp \left[-\frac{\sigma_X^2(z-x-\mu_Y)^2 + \sigma_Y^2(x-\mu_X)^2}{2\sigma_X^2\sigma_Y^2}\right] \, dx \\[6pt] &= \int_{-\infty}^\infty \frac{1}{\sqrt{2\pi}\sqrt{2\pi}\sigma_X\sigma_Y} \exp \left[ -\frac {\sigma_X^2(z^2 + x^2 + \mu_Y^2 - 2xz - 2z\mu_Y + 2x\mu_Y) + \sigma_Y^2(x^2 + \mu_X^2 - 2x\mu_X)} {2\sigma_Y^2\sigma_X^2} \right] \, dx \\[6pt] &= \int_{-\infty}^\infty \frac{1}{\sqrt{2\pi}\sqrt{2\pi}\sigma_X\sigma_Y} \exp \left[ -\frac { x^2(\sigma_X^2 + \sigma_Y^2) - 2x(\sigma_X^2(z - \mu_Y) + \sigma_Y^2\mu_X) + \sigma_X^2(z^2 + \mu_Y^2 - 2z\mu_Y) + \sigma_Y^2\mu_X^2 } {2\sigma_Y^2\sigma_X^2} \right] \, dx \\[6pt] \end{align} }[/math]
Defining [math]\displaystyle{ \sigma_Z = \sqrt{\sigma_X^2 + \sigma_Y^2} }[/math], and completing the square:
- [math]\displaystyle{ \begin{align} f_Z(z) &= \int_{-\infty}^\infty \frac{1}{\sqrt{2\pi}\sigma_Z} \frac{1}{\sqrt{2\pi}\frac{\sigma_X\sigma_Y}{\sigma_Z}} \exp \left[ -\frac { x^2 - 2x\frac{\sigma_X^2(z - \mu_Y) + \sigma_Y^2\mu_X}{\sigma_Z^2} + \frac{\sigma_X^2(z^2 + \mu_Y^2 - 2z\mu_Y) + \sigma_Y^2\mu_X^2}{\sigma_Z^2} } {2\left(\frac{\sigma_X\sigma_Y}{\sigma_Z}\right)^2} \right] \, dx \\[6pt] &= \int_{-\infty}^\infty \frac{1}{\sqrt{2\pi}\sigma_Z} \frac{1}{\sqrt{2\pi}\frac{\sigma_X\sigma_Y}{\sigma_Z}} \exp \left[ -\frac { \left(x - \frac{\sigma_X^2(z - \mu_Y) + \sigma_Y^2\mu_X}{\sigma_Z^2}\right)^2 - \left(\frac{\sigma_X^2(z - \mu_Y) + \sigma_Y^2\mu_X}{\sigma_Z^2}\right)^2 + \frac{\sigma_X^2(z - \mu_Y)^2 + \sigma_Y^2\mu_X^2}{\sigma_Z^2} } {2\left(\frac{\sigma_X\sigma_Y}{\sigma_Z}\right)^2} \right] \, dx \\[6pt] &= \int_{-\infty}^\infty \frac{1}{\sqrt{2\pi}\sigma_Z} \exp \left[ -\frac { \sigma_Z^2\left(\sigma_X^2(z - \mu_Y)^2 + \sigma_Y^2\mu_X^2\right) - \left(\sigma_X^2(z - \mu_Y) + \sigma_Y^2\mu_X\right)^2 } {2\sigma_Z^2\left(\sigma_X\sigma_Y\right)^2} \right] \frac{1}{\sqrt{2\pi}\frac{\sigma_X\sigma_Y}{\sigma_Z}} \exp \left[ -\frac { \left(x - \frac{\sigma_X^2(z - \mu_Y) + \sigma_Y^2\mu_X}{\sigma_Z^2}\right)^2 } {2\left(\frac{\sigma_X\sigma_Y}{\sigma_Z}\right)^2} \right] \, dx \\[6pt] &= \frac{1}{\sqrt{2\pi}\sigma_Z} \exp \left[ - { (z-(\mu_X+\mu_Y))^2 \over 2\sigma_Z^2 } \right] \int_{-\infty}^{\infty} \frac{1}{\sqrt{2\pi}\frac{\sigma_X\sigma_Y}{\sigma_Z}} \exp \left[ - \frac{\left(x-\frac{\sigma_X^2(z-\mu_Y)+\sigma_Y^2\mu_X}{\sigma_Z^2}\right)^2}{2\left(\frac{\sigma_X\sigma_Y}{\sigma_Z}\right)^2} \right] \, dx \end{align} }[/math]
The expression in the integral is a normal density distribution on x, and so the integral evaluates to 1. The desired result follows:
- [math]\displaystyle{ f_Z(z) = \frac{1}{\sqrt{2\pi}\sigma_Z} \exp \left[ - { (z-(\mu_X+\mu_Y))^2 \over 2\sigma_Z^2 } \right] }[/math]
Using the convolution theorem
It can be shown that the Fourier transform of a Gaussian, [math]\displaystyle{ f_X(x) = \mathcal{N}(x; \mu_X, \sigma_X^2) }[/math], is[3]
- [math]\displaystyle{ \mathcal{F}\{f_X\} = F_X(\omega) = \exp \left[ -j \omega \mu_X \right] \exp \left[-\tfrac{\sigma_X^2\omega^2}{2} \right] }[/math]
By the convolution theorem:
- [math]\displaystyle{ \begin{align} f_Z(z) &= (f_X * f_Y)(z) \\[5pt] &= \mathcal{F}^{-1}\big\{\mathcal{F}\{f_X\}\cdot\mathcal{F}\{f_Y\}\big\} \\[5pt] &= \mathcal{F}^{-1}\big\{ \exp \left[ -j \omega \mu_X \right] \exp \left[-\tfrac{\sigma_X^2\omega^2}{2} \right] \exp \left[ -j \omega \mu_Y \right] \exp \left[-\tfrac{\sigma_Y^2\omega^2}{2} \right] \big\} \\[5pt] &= \mathcal{F}^{-1}\big\{ \exp \left[ -j \omega (\mu_X + \mu_Y) \right] \exp \left[-\tfrac{(\sigma_X^2\ + \sigma_Y^2)\omega^2}{2} \right] \big\} \\[5pt] &= \mathcal{N}(z; \mu_X + \mu_Y, \sigma_X^2 + \sigma_Y^2) \end{align} }[/math]
Geometric proof
First consider the normalized case when X, Y ~ N(0, 1), so that their PDFs are
- [math]\displaystyle{ f(x) = \frac 1 {\sqrt{2\pi \,}} e^{-x^2/2} }[/math]
and
- [math]\displaystyle{ g(y) = \frac1 {\sqrt{2\pi\,}} e^{-y^2/2}. }[/math]
Let Z = X + Y. Then the CDF for Z will be
- [math]\displaystyle{ z \mapsto \int_{x+y \leq z} f(x)g(y) \, dx \, dy. }[/math]
This integral is over the half-plane which lies under the line x+y = z.
The key observation is that the function
- [math]\displaystyle{ f(x)g(y) = \frac 1 {2\pi}e^{-(x^2 + y^2)/2}\, }[/math]
is radially symmetric. So we rotate the coordinate plane about the origin, choosing new coordinates [math]\displaystyle{ x',y' }[/math] such that the line x+y = z is described by the equation [math]\displaystyle{ x' = c }[/math] where [math]\displaystyle{ c = c(z) }[/math] is determined geometrically. Because of the radial symmetry, we have [math]\displaystyle{ f(x)g(y) = f(x')g(y') }[/math], and the CDF for Z is
- [math]\displaystyle{ \int_{x'\leq c, y' \in \reals} f(x')g(y') \, dx' \, dy'. }[/math]
This is easy to integrate; we find that the CDF for Z is
- [math]\displaystyle{ \int_{-\infty}^{c(z)} f(x') \, dx' = \Phi(c(z)). }[/math]
To determine the value [math]\displaystyle{ c(z) }[/math], note that we rotated the plane so that the line x+y = z now runs vertically with x-intercept equal to c. So c is just the distance from the origin to the line x+y = z along the perpendicular bisector, which meets the line at its nearest point to the origin, in this case [math]\displaystyle{ (z/2,z/2)\, }[/math]. So the distance is [math]\displaystyle{ c = \sqrt{ (z/2)^2 + (z/2)^2 } = z/\sqrt{2}\, }[/math], and the CDF for Z is [math]\displaystyle{ \Phi(z/\sqrt{2}) }[/math], i.e., [math]\displaystyle{ Z = X+Y \sim N(0, 2). }[/math]
Now, if a, b are any real constants (not both zero) then the probability that [math]\displaystyle{ aX+bY \leq z }[/math] is found by the same integral as above, but with the bounding line [math]\displaystyle{ ax+by =z }[/math]. The same rotation method works, and in this more general case we find that the closest point on the line to the origin is located a (signed) distance
- [math]\displaystyle{ \frac{z}{\sqrt{a^2 + b^2}} }[/math]
away, so that
- [math]\displaystyle{ aX + bY \sim N(0, a^2 + b^2). }[/math]
The same argument in higher dimensions shows that if
- [math]\displaystyle{ X_i \sim N(0,\sigma_i^2), \qquad i=1, \dots, n, }[/math]
then
- [math]\displaystyle{ X_1+ \cdots + X_n \sim N(0, \sigma_1^2 + \cdots + \sigma_n^2). }[/math]
Now we are essentially done, because
- [math]\displaystyle{ X \sim N(\mu,\sigma^2) \Leftrightarrow \frac{1}{\sigma} (X - \mu) \sim N(0,1). }[/math]
So in general, if
- [math]\displaystyle{ X_i \sim N(\mu_i, \sigma_i^2), \qquad i=1, \dots, n, }[/math]
then
- [math]\displaystyle{ \sum_{i=1}^n a_i X_i \sim N\left(\sum_{i=1}^n a_i \mu_i, \sum_{i=1}^n (a_i \sigma_i)^2 \right). }[/math]
In the event that the variables X and Y are jointly normally distributed random variables, then X + Y is still normally distributed (see Multivariate normal distribution) and the mean is the sum of the means. However, the variances are not additive due to the correlation. Indeed,
- [math]\displaystyle{ \sigma_{X+Y} = \sqrt{\sigma_X^2+\sigma_Y^2+2\rho\sigma_X \sigma_Y}, }[/math]
where ρ is the correlation. In particular, whenever ρ < 0, then the variance is less than the sum of the variances of X and Y.
Extensions of this result can be made for more than two random variables, using the covariance matrix.
Proof
In this case (with X and Y having zero means), one needs to consider
- [math]\displaystyle{ \frac{1}{2 \pi \sigma_x \sigma_y \sqrt{1-\rho^2}} \iint_{x\,y} \exp \left[ -\frac{1}{2(1-\rho^2)} \left(\frac{x^2}{\sigma_x^2} + \frac{y^2}{\sigma_y^2} - \frac{2 \rho x y}{\sigma_x\sigma_y}\right)\right] \delta(z - (x+y))\, \mathrm{d}x\,\mathrm{d}y. }[/math]
As above, one makes the substitution [math]\displaystyle{ y\rightarrow z-x }[/math]
This integral is more complicated to simplify analytically, but can be done easily using a symbolic mathematics program. The probability distribution fZ(z) is given in this case by
- [math]\displaystyle{ f_Z(z)=\frac{1}{\sqrt{2 \pi}\sigma_+ }\exp\left(-\frac{z^2}{2\sigma_+^2}\right) }[/math]
where
- [math]\displaystyle{ \sigma_+ = \sqrt{\sigma_x^2+\sigma_y^2+2\rho\sigma_x \sigma_y}. }[/math]
If one considers instead Z = X − Y, then one obtains
- [math]\displaystyle{ f_Z(z)=\frac{1}{\sqrt{2\pi(\sigma_x^2+\sigma_y^2-2\rho\sigma_x \sigma_y)}}\exp\left(-\frac{z^2}{2(\sigma_x^2+\sigma_y^2-2\rho\sigma_x \sigma_y)}\right) }[/math]
which also can be rewritten with
- [math]\displaystyle{ \sigma_{X-Y}=\sqrt{\sigma_x^2+\sigma_y^2-2\rho\sigma_x \sigma_y}. }[/math]
The standard deviations of each distribution are obvious by comparison with the standard normal distribution.
References
- ↑ Lemons, Don S. (2002), An Introduction to Stochastic Processes in Physics, The Johns Hopkins University Press, p. 34, ISBN 0-8018-6866-1
- ↑ Lemons (2002) pp. 35–36
- ↑ Derpanis, Konstantinos G. (October 20, 2005). "Fourier Transform of the Gaussian". http://www.cse.yorku.ca/~kosta/CompVis_Notes/fourier_transform_Gaussian.pdf.
See also
- Propagation of uncertainty
- Algebra of random variables
- Stable distribution
- Standard error (statistics)
- Ratio distribution
- Product distribution
- Slash distribution
- List of convolutions of probability distributions
Original source: https://en.wikipedia.org/wiki/Sum of normally distributed random variables.
Read more |