Maxwell Distribution

The Maxwell distribution, also known as the Maxwell-Boltzmann distribution, describes the distribution of speeds of molecules in a gas in thermal equilibrium.

Definition

The Maxwell distribution is defined by its Probability Density Function (PDF):

f(x)=2πx2a3exp(x22a2)

where x0 and a>0 is the scale parameter. The scale parameter a is proportional to the square root of the temperature and inversely proportional to the mass of the particles.

The Cumulative Distribution Function (CDF) is:

F(x)=erf(x2a)2πxaexp(x22a2)

where erf is the error function.

Applications

  • Statistical mechanics uses the distribution to model molecular speeds in ideal gases.

  • Plasma physics employs it to describe particle velocities in plasmas.

  • Astronomy applications include modeling stellar velocities in globular clusters.

  • Materials science uses it for analyzing particle size distributions.

Properties

Statistical Properties
PropertyValue
Mean2a2π
Variancea2(3π8)/π
Skewness22(165π)(3π8)3/2
Excess Kurtosis4(3π296π96)(3π8)2
Modea2
MedianNo closed form
Entropyln(a2π)+γ12

Notable properties include:

  • The distribution is always right-skewed.

  • The most probable speed (mode) differs from the mean speed.

  • The distribution has zero probability density at x = 0.

Relationships to Other Distributions

  • If X, Y, and Z are independent normal variables with mean 0 and variance a2, then X2+Y2+Z2 follows a Maxwell distribution with parameter a.

  • The Maxwell distribution is related to the chi distribution with 3 degrees of freedom.

    E
  • The square of a Maxwell-distributed variable follows a gamma distribution.

The MaxwellDistribution class

The Maxwell distribution is implemented by the MaxwellDistribution class. It has one constructor that takes the value of the scale parameter. The code below creates a Maxwell distribution with scale parameter equal to 3:

C#
var maxwell = new MaxwellDistribution(3.0);

MaxwellDistribution has one static (Shared in Visual Basic) method, Sample, which generates a random sample using a user-supplied uniform random number generator. The second parameter is the scale parameter of the distribution that is to be sampled.

C#
var random = new Pcg32();
double sample = MaxwellDistribution.Sample(random, 3.0);

References

  • Maxwell, J. C. (1860, 1927). Illustrations of the dynamical theory of gases, Scientific Papers, 1, 377-410. Paris: Librairies Scientifiques Hermann.

  • Boltzmann, L. (1878). Weitere Bemerkungen iiber einige Probleme der mechanischen Warmetheorie, Wiss. Abh., 2, 250-288.

  • "Statistical Mechanics" by R.K. Pathria and Paul D. Beale

  • "Introduction to Modern Statistical Mechanics" by David Chandler

See Also