\(\newcommand{\R}{\mathbb{R}}\) \(\newcommand{\N}{\mathbb{N}}\) \(\newcommand{\E}{\mathbb{E}}\) \(\newcommand{\P}{\mathbb{P}}\) \(\newcommand{\var}{\text{var}}\) \(\newcommand{\sd}{\text{sd}}\) \(\newcommand{\cov}{\text{cov}}\) \(\newcommand{\cor}{\text{cor}}\) \(\newcommand{\skw}{\text{skew}}\) \(\newcommand{\kur}{\text{kurt}}\)
  1. Random
  2. 4. Special Distributions
  3. The Maxwell Distribution

The Maxwell Distribution

The Maxwell distribution, named for James Clerk Maxwell, is the distribution of the magnitude of a three-dimensional random vector whose coordinates are independent, identically distributed, mean 0 normal variables. The distribution has a number of applications in settings where magnitudes of normal variables are important, particularly in physics. It is also called the Maxwell-Boltzmann distribution in honor also of Ludwig Boltzmann. The Maxwell distribution is closely related to the Rayleigh distribution, which governs the magnitude of a two-dimensional random vector whose coordinates are independent, identically distributed, mean 0 normal variables.

The Standard Maxwell Distribution

Definition

Suppose that \(Z_1\), \(Z_2\), and \(Z_3\) are independent random variables with standard normal distributions. The magnitude \(R = \sqrt{Z_1^2 + Z_2^2 + Z_3^2}\) of the vector \((Z_1, Z_2, Z_3)\) has the standard Maxwell distribution.

Distribution Functions

\(R\) has distribution function \(G\) given below, where \( \Phi \) is the standard normal distribution function \[G(x) = 2 \Phi(x) - \sqrt{\frac{2}{\pi}} x e^{-x^2/2} - 1, \quad x \in [0, \infty)\]

Proof:

\((Z_1, Z_2, Z_3)\) has joint PDF \((z_1, z_2, z_3) \mapsto \frac{1}{(2 \pi)^{3/2}} e^{-(z_1^2 + z_2^2 + z_3^2)/2}\) on \(\R^3\). Hence \[\P(R \le x) = \int_{B_x} \frac{1}{(2 \pi)^{3/2}} e^{-(z_1^2 + z_2^2 + z_3^2)/2} d(z_1, z_2, z_3)\] where \(B_x = \left\{(z_1, z_2. z_3) \in \R^3: z_1^2 + z_2^2 + z_3^2 \le x^2\right\}\). Convert to spherical coordinates with \(z_1 = \rho \sin(\phi) \cos(\theta)\), \(z_2 = \rho \sin(\phi) \sin(\theta)\), \(z_3 = \rho \cos(\phi)\) to get \[\P(R \le x) = \int_0^\pi \int_0^{2 \pi} \int_0^x \frac{1}{(2 \pi)^{3/2}} e^{-\rho^2/2} \rho^2 \sin(\phi) \, d \rho \, d \theta \, d\phi\] The result now follows by simple integration.

\(R\) has probability density function \(g\) given by \(g(x) = \sqrt{\frac{2}{\pi}} x^2 e^{-x^2 / 2}\) for \(x \in [0, \infty)\).

  1. \(g\) increases and then decreases with mode at \(x = \sqrt{2}\).
  2. \(g\) is concave upward, then downward, then upward again, with inflection points at \(x_1 = \sqrt{(5 - \sqrt{17})/2} \approx 0.6622\) and \(x_2 = \sqrt{(5 + \sqrt{17})/2} \approx 2.1358\)
Proof:

The formula for the PDF follows immediately from the distribution function since \(g(x) = G^\prime(x)\). Part (a) follows from \(g^\prime(x) = \sqrt{2 / \pi} x e^{-x^2 / 2}(2 - x^2)\) and part (b) follows from \(g^{\prime\prime}(x) = \sqrt{2 / \pi} e^{-x^2/2}(x^4 - 5 x^2 + 2)\).

Open the Special Distribution Simulator and select the Maxwell distribution. Keep the default parameter value and note the shape of the probability density function. Run the simulation 1000 times and compare the emprical density function to the probability density function.

The quantile function has no simple closed-form expression.

Open the Special Distribution Calculator and select the Maxwell distribution. Keep the default parameter value. Find approximate values of the median and the first and third quartiles.

Moments

\(R\) has moment generating function \(m\) given below, where \(\Phi\) is the standard normal distribution function: \[ m(t) = \E\left(e^{tR}\right) = \sqrt{\frac{2}{\pi}} t + 2(1 + t^2) e^{t^2/2} \Phi(t), \quad t \in \R \]

Proof:

Completing the square in \(x\) gives \[ m(t) = \int_0^\infty \sqrt{\frac{2}{\pi}} x^2 e^{-x^2/2} e^{tx} dx = \sqrt{\frac{2}{\pi}} e^{t^2/2} \int_0^\infty x^2 e^{-(x - t)^2/2} dx\] The substitution \(z = x - t\) gives \[ m(t) = \sqrt{\frac{2}{\pi}} e^{t^2/2} \int_{-t}^\infty (z + t)^2 e^{-z^2/2} dz = \sqrt{\frac{2}{\pi}} e^{t^2/2} \int_{-t}^\infty (z^2 + 2 t z + t^2) e^{-z^2/2} dz\] Integrating by parts or by simple substitution, using the fact that \(z \mapsto \frac{1}{\sqrt{2 \pi}} e^{-z^2/2} \) is the standard normal PDF, and that \(1 - \Phi(-t) = \Phi(t) \) we have \begin{align} \int_{-t}^\infty z^2 e^{-z^2/2} dz & = -t e^{-t^2/2} + \sqrt{2 \pi} \Phi(t) \\ \int_{-t}^\infty 2 t z e^{-z^2/2} dz & = 2 t e^{-t^2/2} \\ \int_{-t}^\infty t^2 e^{-z^2/2} dz & = t^2 \sqrt{2 \pi} \Phi(t) \end{align} Simplifying gives the result.

The mean, variance, and standard deviation of \(R\) are

  1. \( \E(R) = 2 \sqrt{2 / \pi} \approx 1.5958 \)
  2. \( \var(R) = 3 - 8/\pi \)
  3. \( \sd(R) = \sqrt{3 - 8/\pi} \approx 0.6734 \)
Proof:

The integration methods are by parts and by simple substitution. \[ \E(R) = \int_0^\infty \sqrt{\frac{2}{\pi}} x^3 e^{-x^2/2} dx = 2 \sqrt{\frac{2}{\pi}} \int_0^\infty x e^{-x^2/2} dx = 2 \sqrt{\frac{2}{\pi}} \] \[ \E\left(R^2\right) = \int_0^\infty \sqrt{\frac{2}{\pi}} x^4 e^{-x^2/2} dx = 3 \int_0^\infty \sqrt{\frac{2}{\pi}} x^2 e^{-x^2/2} dx = 3 \]

Open the Special Distribution Simulator and select the Maxwell distribution. Keep the default parameter value. Note the size and location of the mean\(\pm\)standard deviation bar. Run the simulation 1000 times and compare the empirical mean and standard deviation to the true mean and standard deviation.

The moments of \(R\) (about 0) are give below, where \(\Gamma\) is the gamma function: \[ \E(R^n) = \frac{2^{n/2 + 1}}{\sqrt{\pi}} \Gamma\left(\frac{n + 3}{2}\right), \quad n \in \N\]

Proof:

The substitution \(u = x^2/2\) gives \[\E(R^n) = \int_0^\infty \sqrt{\frac{2}{\pi}} x^{n + 1} x e^{-x^2/2} dx = \int_0^\infty \sqrt{\frac{2}{\pi}} (2 u)^{(n+1)/2} e^{-u} du = \frac{2^{n/2 + 1}}{\sqrt{\pi}} \int_0^\infty u^{(n+1)/2} e^{-u} du\] The last integral is \(\Gamma[(n+3)/2]\) by definition.

Of course, the formula for the general moments gives an alternate derivation of parts (a) and (b) in (6), since \(\Gamma(2) = 1\) and \(\Gamma(5/2) = 3 \sqrt{\pi} / 4\). On the other hand, the moment generating function can be also be used to derive the formula for the general moments.

The skewness and kurtosis of \(R\) are

  1. \(\skw(R) = 2 \sqrt{2}(16 - 5 \pi) \big/ (3 \pi - 8)^{3/2} \approx 0.4857\)
  2. \(\kur(R) = (15 \pi^2 +16 \pi -192) \big/ (3 \pi - 8)^2 \approx 3.1082\)
Proof:

These results follow from the standard formulas for the skewness and kurtosis in terms of the moments, since \(\E(R) = 2 \sqrt{2 / \pi}\), \(\E\left(R^2\right) = 3\), \(\E\left(R^3\right) = 8 \sqrt{2/\pi}\), and \(\E\left(R^4\right) = 15\).

Related Distributions

The fundamental connection between the standard Maxwell distribution and the standard normal distribution is given in the very definition of the standard Maxwell, as the distribution of the magnitude of a vector in \(\R^3\) with independent, standard normal coordinates.

Connections to the chi-square distribution.

  1. If \(R\) has the standard Maxwell distribution then \(R^2\) has the chi-square distribution with 3 degrees of freedom.
  2. If \(V\) has the chi-square distribution with 3 degrees of freedom then \(\sqrt{V}\) has the standard Maxwell distribution.
Proof:

This follows directly from the definition of the standard Maxwell variable \(R = \sqrt{Z_1^2 + Z_2^2 + Z_3^2}\), where \(Z_1\), \(Z_2\), and \(Z_3\) are independent standard normal variables.

The General Maxwell Distribution

Definition

The standard Maxwell distribution is generalized by adding a scale parameter.

If \(R\) has the standard Maxwell distribution and \(b \in (0, \infty)\) then \(X = b R\) has the Maxwell distribution with scale parameter \(b\).

Equivalently, the Maxwell distribution is the distribution of the magnitude of a three-dimensional vector whose components have independent, identically distributed, mean 0 normal variables.

If \(U_1\), \( U_2 \) and \(U_3\) are independent normal variables with mean 0 and standard deviation \(\sigma \gt 0\) then \(X = \sqrt{U_1^2 + U_2^2 + U_3^2}\) has the Maxwell distribution with scale parameter \(\sigma\).

Proof:

We can take \(U_i = \sigma Z_i\) for \( i \in \{1, 2, 3\} \) where \(Z_1\), \( Z_2 \), and \(Z_3\) are independent standard normal variables. Then \(X = \sigma \sqrt{Z_1^2 + Z_2^2 + Z_3^2} = \sigma R\) where \(R\) has the standard Maxwell distribution.

Distribution Functions

In this section, we assume that \(X\) has the Maxwell distribution with scale parameter \(b\).

\(X\) has cumulative distribution function \(F\) given below, where \( \Phi \) is the standard normal distribution function: \[F(x) = 2 \Phi\left(\frac{x}{b}\right) - \frac{1}{b}\sqrt{\frac{2}{\pi}} x \exp\left(-\frac{x^2}{2 b^2}\right) - 1, \quad x \in [0, \infty)\]

Proof:

Recall that \(F(x) = G(x / b)\) where \(G\) is the standard Maxwell CDF.

\(X\) has probability density function \(f\) given by \[ f(x) = \frac{1}{b^3}\sqrt{\frac{2}{\pi}} x^2 \exp\left(-\frac{x^2}{2 b^2}\right), \quad x \in [0, \infty) \]

  1. \(f\) increases and then decreases with mode at \(x = b \sqrt{2}\).
  2. \(f\) is concave upward, then downward, then upward again, with inflection points at \(x = b \sqrt{(5 \pm \sqrt{17})/2}\).
Proof:

Recall that \(f(x) = \frac{1}{b} g\left(\frac{x}{b}\right)\) where \(g\) is the standard Maxwell PDF.

Open the Special Distribution Simulator and select the Maxwell distribution. Vary the scale parameter and note the shape and location of the probability density function. For various values of the scale parameter, run the simulation 1000 times and compare the emprical density function to the probability density function.

Again, the quantile function does not hava a simple, closed-form expression.

Open the Special Distribution Calculator and select the Maxwell distribution. For various values of the scale parameter, compute the median and the first and third quartiles.

Moments

Again, we assume that \(X\) has the Maxwell distribution with scale parameter \(b\).

\(X\) has moment generating function \(M\) given below, where \(\Phi\) is the standard normal distribution function: \[ M(t) = \E\left(e^{t X}\right) = \sqrt{\frac{2}{\pi}} b t + 2(1 + b^2 t^2) \exp\left(\frac{b^2 t^2}{2}\right) \Phi(b t), \quad t \in \R \]

Proof:

Recall that \(M(t) = m(b t)\) where \(m\) is the standard Maxwell MGF.

The mean, variance, and standard deviation of \(X\) are

  1. \( \E(X) = b 2 \sqrt{2 / \pi} \)
  2. \( \var(X) = b^2 (3 - 8/\pi) \)
  3. \( \sd(X) = b \sqrt{3 - 8/\pi} \)
Proof:

These result follow from the standard mean and variance and basic properties of expected value and variance.

Open the Special Distribution Simulator and select the Maxwell distribution. Vary the scale parameter and note the size and location of the mean\(\pm\)standard deviation bar. For various values of the scale parameter, run the simulation 1000 times compare the empirical mean and standard deviation to the true mean and standard deviation.

The moments of \(X\) (about 0) are give below, where \(\Gamma\) is the gamma function: \[ \E(X^n) = b^n \frac{2^{n/2 + 1}}{\sqrt{\pi}} \Gamma\left(\frac{n + 3}{2}\right), \quad n \in \N\]

Proof:

This follows from the standard moments and basic properties of expected value.

The skewness and kurtosis of \(X\) are

  1. \(\skw(X) = 2 \sqrt{2}(16 - 5 \pi) \big/ (3 \pi - 8)^{3/2} \approx 0.4857\)
  2. \(\kur(X) = (15 \pi^2 +16 \pi -192) \big/ (3 \pi - 8)^2 \approx 3.1082\)
Proof:

Recall that skewness and kurtosis are defined in terms of the standard score, and hence are unchanged by a scale transformation. Thus the results follow from the standard skewness and kurtosis.

Related Distributions

The fundamental connection between the Maxwell distribution and the normal distribution is given in the definition, and of course, is the primary reason that the Maxwell distribution is special in the first place.

By construction, the Maxwell distribution is a scale family, and so is closed under scale transformations.

If \(X\) has the Maxwell distribution with scale parameter \(b\) and if \(c \in (0, \infty)\) then \(c X\) has the Maxwell distribution with scale parameter \(b c\).

The Maxwell distribution is a generalized exponential distribution.

If \(X\) has the Maxwell distribution with scale parameter \(b\) then \(X\) is a one-parameter exponential family with natural parameter \(-1/b^2\) and natural statistic \(X^2 / 2\).

Proof:

This follows directly from the definition of the general exponential distribution.