The ideal gas and Brownian motion explained

The air around you is a crowd of molecules racing at hundreds of metres a second and colliding billions of times a second. This page explains how such chaos gives the simple laws of gases: where pressure and temperature come from, why the ideal-gas law works and when it fails, how speeds settle into the Maxwell–Boltzmann distribution, what happens when a gas is compressed, how gases mix, and how the jiggling of tiny particles finally convinced scientists that atoms are real.

A box of gas atoms coloured by their energy, with a piston on the right and a large Brownian particle with its random-walk trail
A box of gas atoms coloured by their energy, with a piston on the right and a large Brownian particle with its random-walk trail

Pressure from bouncing atoms

In 1738 Daniel Bernoulli suggested that a gas is made of tiny particles in fast motion and that its pressure is their knocking on the walls. An atom of mass m that hits a wall with the speed v⊥ towards it bounces back and hands the wall an impulse of 2mv⊥. Add up all the bounces on a piece of wall in a second and you get a steady force: in three dimensions a force per area, in pascals; on a two-dimensional surface a force per length, in newtons per metre. Faster atoms hit harder and more often, so the pressure grows with the square of their speed, that is, with their kinetic energy.

Temperature is motion

Temperature measures the energy of this random motion. The equipartition theorem says that in equilibrium every way a particle can store energy in a squared quantity, each degree of freedom, holds ½kT on average, where k = 1.380649 × 10⁻²³ J/K is Boltzmann's constant and T the absolute temperature in kelvin. An atom flying in space has three degrees of freedom and a mean kinetic energy of 3/2 kT; one moving in a plane has two and ⟨½mv²⟩ = kT. At absolute zero, 0 K or −273.15 °C, this motion would stop. At room temperature helium atoms race at more than a kilometre a second, and heavier atoms more slowly.

The ideal-gas law and its limits

Boyle found in 1662 that squeezing a gas to half its volume doubles its pressure, Charles and Gay-Lussac that heating it raises the pressure or the volume in proportion to the absolute temperature, and Avogadro that equal volumes hold equal numbers of molecules. Kinetic theory joins them in one law, PV = NkT, or PA = NkT in two dimensions: the pressure times the volume equals the total kinetic energy of the atoms in two dimensions, and two thirds of it in three. Real gases deviate because their molecules take up room and attract each other; Johannes van der Waals corrected for both in 1873. For hard discs that only repel, Douglas Henderson's equation of state of 1975, PA / NkT = (1 + φ²/8) / (1 − φ)², gives the extra push of discs covering a share φ of the area.

The Maxwell–Boltzmann distribution

In 1860 James Clerk Maxwell asked how the speeds of the molecules are spread and found a bell-shaped curve with a long tail of fast molecules; Ludwig Boltzmann derived it from the energy and proved in 1872 that collisions drive any other distribution towards it, the first statistical view of entropy. In two dimensions the distribution of speeds is f(v) = (mv/kT) e^(−mv²/2kT): it peaks at √(kT/m) and its root-mean-square speed is √(2kT/m). Lighter atoms are faster: at the same temperature a helium atom moves √33 ≈ 5.7 times as fast as a xenon atom, while both carry the same mean energy.

Compressing a gas

A piston moving into the gas hands energy to every atom that bounces off it; one moving out takes energy away. This is the work of the first law of thermodynamics, and the area under a curve on the P–V diagram is the work done. If the walls let heat through and the piston moves slowly, the gas stays at the temperature of its surroundings: the compression is isothermal and PV stays the same. If the walls are insulated, the work stays in the gas: the compression is adiabatic, PV^γ stays the same, with γ = 5/3 for atoms in three dimensions and γ = 2 in two, so in two dimensions halving the area doubles the temperature. A piston pushed fast creates a crowd of atoms in front of it, and the gas heats up more than the adiabat predicts: the process is irreversible and entropy grows.

Diffusion and the mean free path

An atom in a gas does not fly far before it hits another: the average distance, the mean free path, is about 70 nm in air, about 200 times the size of a molecule. Its path is a zigzag, so a smell spreads through a still room slowly, by diffusion, even though the molecules move at hundreds of metres a second. Thomas Graham found in 1833 that light gases diffuse faster, in proportion to one over the square root of their mass, and Adolf Fick wrote the diffusion equation in 1855. When a partition between a gas and an empty space is lifted, the gas fills the space without any change of temperature for an ideal gas, a free expansion that James Joule studied in 1845.

Brownian motion and the reality of atoms

In 1827 Robert Brown watched tiny particles from pollen grains jiggle in water and found the same motion in specks of dust and glass, so it was not life. In 1905 Albert Einstein showed that the jiggling is the result of random kicks from the molecules of the water and that the mean squared displacement grows in proportion to time, ⟨Δr²⟩ = 2dDt in d dimensions, with a diffusion coefficient D = kT / γ set by the friction γ. Paul Langevin added the particle's inertia in 1908: over short times it moves in straight lines, over long times it diffuses. Jean Perrin measured the motion in 1908 and from it Avogadro's number, the last proof that atoms exist, which earned him the Nobel Prize in Physics in 1926.

Frequently asked questions

Why does a gas get hotter when it is compressed?

Because the piston does work on it. Each atom that bounces off a piston moving inward leaves faster than it came, as a tennis ball does from a racket swung towards it. The added kinetic energy is a higher temperature. This is why a bicycle pump gets warm and why diesel engines can ignite their fuel just by compressing the air. In reverse, a gas that expands against a piston cools down, which is how refrigerators work.

Why do light atoms move faster than heavy ones?

At the same temperature every atom has the same mean kinetic energy, ½mv² = kT in two dimensions. A small mass needs a larger speed to carry the same energy: the speed goes as one over the square root of the mass. Hydrogen and helium are so fast that some of them escape from the Earth's atmosphere into space, which is one reason the air holds almost no helium.

What is absolute zero?

The temperature at which the random motion of the atoms would stop: 0 kelvin, or −273.15 °C. Following the ideal-gas law, the pressure of a gas at fixed volume would fall to zero there. In practice every gas liquefies before that, and quantum mechanics leaves a little motion even at absolute zero. Laboratories have cooled atoms to less than a billionth of a kelvin.

How did Brownian motion prove that atoms exist?

Einstein's formula linked something that can be seen, how far a particle wanders under a microscope in a given time, to the size and number of the molecules that kick it. Jean Perrin followed particles of resin a thousandth of a millimetre across and measured their mean squared displacement; from it he got Avogadro's number, about 6 × 10²³ per mole, the same value as from completely different experiments. After that even sceptics such as Wilhelm Ostwald accepted that atoms are real.

Ready to try it?

Open PictorX in your browser — no install, no credit card required to start.

Open the ideal gas simulator