Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

The microscopic origin of pressure

The puzzle: violence underneath, calm on top

Press your palm against a table and the force you feel is steady. Now press it against the air — the atmosphere pushes back on every square centimetre of your skin with about ten newtons, and that push is steady too. Steady enough that a barometer built in 1643 still works today.

But the air is not a smooth fluid pressing on you. It is roughly 3×10193 \times 10^{19} molecules per cubic centimetre, each moving at hundreds of metres per second, each striking your skin, rebounding, and flying off. Nothing about a single collision is gentle or regular. A molecule arrives at a random moment, from a random direction, with a random speed.

So here is the puzzle this module exists to resolve:

The answer will turn out to have nothing to do with the collisions becoming gentler. It has to do with how many of them there are, and it will give us our first quantitative law of large numbers: the relative size of the jitter falls off as 1/N1/\sqrt{N}.

Predict before you calculate

Commit to an answer for each of these before running anything. Write them down. The point is not to be right — it is to find out which of your intuitions the simulation will overturn.

  1. A gas of NN particles at temperature TT sits in a box of volume VV. You double NN at fixed TT and VV. What happens to the pressure? What happens to the relative size of its fluctuations?

  2. You double the mass mm of every particle while holding the temperature fixed. Each particle now carries more momentum per collision. Does the pressure go up?

  3. Two boxes hold the same gas at the same temperature. One holds 100 particles, the other 106. Which one’s pressure gauge visibly twitches?

  4. At equilibrium, has the microscopic motion stopped?

Explore the model

The laboratory notebook for this module lets you set NN, TT, the particle mass, and the box size, then watch three things at once: the individual impulses arriving at the wall, the running time-average of the pressure, and the value NkBT/VN k_B T / V predicted by the ideal gas law.

Here is the phenomenon in one picture. On the left, sixty argon atoms at 300 K, going about their business. On the right, the running average of the pressure they exert, converging on the dashed line — the ideal gas law — without anything on the left ever becoming orderly.

Sixty argon atoms bouncing in a square box, beside the running average of the pressure they exert. Left: the microscopic reality — nothing steady anywhere. Right: the same data, accumulated. The animation is generated by the same thermolab.kinetics code you can run and read.

Watch what changes when there are more particles. The three panels below run the identical measurement at N=20N = 20, 200 and 2000, plotted as a fraction of the predicted pressure so the comparison is fair:

Three pressure traces at increasing particle number, each drawn as a fraction of the pressure predicted for it. The jitter does not disappear because the collisions calm down — the collisions are identical in all three panels. It shrinks because there are more of them to average over.

Run the laboratory now, then come back. Three things are worth doing before you read on:

Derive the result

We now do the calculation the simulation is imitating. Everything below is exact for the model above; nothing is approximated except where it says so.

System and boundary. The gas inside the container. The wall is the boundary; we compute the force it feels.

Independent variables. NN, VV, TT, and the particle mass mm.

Sign convention. Momentum transferred to the wall is counted positive.

One particle, one wall

Take a wall perpendicular to the xx axis. A particle with velocity component vxv_x hits it and rebounds elastically, leaving with −vx-v_x. The particle’s momentum changed by −2mvx-2 m v_x, so by momentum conservation the wall received

Δp=2m∣vx∣.\Delta p = 2 m |v_x| .

Between collisions with that same wall the particle must cross the box and come back, a round trip of length 2Lx2L_x, which takes

Δt=2Lx∣vx∣.\Delta t = \frac{2 L_x}{|v_x|} .

So this one particle delivers momentum to that one wall at the average rate

F1=ΔpΔt=2m∣vx∣2Lx/∣vx∣=mvx2Lx.F_1 = \frac{\Delta p}{\Delta t} = \frac{2 m |v_x|}{2L_x / |v_x|} = \frac{m v_x^2}{L_x}.

Note what happened: the awkward ∣vx∣|v_x| became vx2v_x^2. The direction dropped out, and only the energy-like quantity survived. That is the first hint that pressure will turn out to be about energy, not about impacts.

All the particles

Sum over the NN particles and divide by the wall’s area A=V/LxA = V/L_x:

P=1A∑i=1Nmvx,i2Lx=mV∑i=1Nvx,i2=Nm⟨vx2⟩V,P = \frac{1}{A}\sum_{i=1}^{N} \frac{m v_{x,i}^2}{L_x} = \frac{m}{V}\sum_{i=1}^{N} v_{x,i}^2 = \frac{N m \langle v_x^2 \rangle}{V},

where ⟨vx2⟩\langle v_x^2 \rangle is the average over particles. This is exact for the model.

Bringing in temperature

So far no thermodynamics has entered — this is pure mechanics, and it would hold for any distribution of speeds. Temperature enters through one additional statement:

Substituting:

  PV=NkBT  \boxed{\; P V = N k_B T \;}

Notice that the mass cancelled. Doubling mm at fixed TT makes each particle slower — ⟨vx2⟩=kBT/m\langle v_x^2\rangle = k_B T/m — by exactly enough to offset its heavier punch. If you predicted that heavier particles push harder, this is the sentence to reread.

Verify computationally

Deriving a formula and trusting it are different things. The laboratory checks the result four ways, and each check is also a test in the project’s test suite, so the claims on this page cannot silently rot.

1. The equation of state. Measure pressure from the summed wall impulses, P=∑Δp/(t⋅wall)P = \sum \Delta p / (t \cdot \text{wall}), and compare with NkBT/VN k_B T/V. They agree within statistical error, across eight independent random seeds.

2. Energy conservation. Elastic reflection flips a velocity component’s sign, so the total kinetic energy must be conserved to machine precision — not approximately. If it drifts, the simulation is wrong, not the physics.

3. Equipartition. The measured mean kinetic energy per particle must equal d2kBT\tfrac{d}{2} k_B T — in two dimensions, kBTk_B T.

4. Fluctuations. This is the answer to the opening puzzle.

That is the resolution. The collisions never became gentle. There are simply so many of them that the fractional jitter fell below the noise floor of reality.

Transfer the idea

The same reasoning — a steady macroscopic quantity as an average over many random microscopic events, with N−1/2N^{-1/2} fluctuations — reappears throughout the course and beyond it.

Check your understanding

  1. A gas sits at equilibrium in a sealed container, its pressure gauge perfectly steady. What are the molecules doing?

    A. Moving as fast as ever, colliding constantly; only the averages have settled. B. They have come to rest, which is why the pressure no longer changes. C. They move but no longer strike the walls, so no further momentum is transferred. D. They oscillate in place about fixed positions, as in a solid.

    Check your answer

    Correct answer: A — Moving as fast as ever, colliding constantly; only the averages have settled.

    • A. Right. Equilibrium is a statement about macroscopic averages, not about the microscopic motion. At 300 K nitrogen molecules average roughly 500 m/s whether or not the gauge is moving.

    • B. This would require zero kinetic energy, i.e. absolute zero. It also cannot be right on its own terms: motionless molecules exert no pressure at all, so the gauge would read zero rather than a steady value.

    • C. Wall collisions are precisely what the pressure is. They continue at an enormous rate; what is steady is the rate, not its absence.

    • D. That describes a solid, where atoms are bound to lattice sites. In a gas the molecules travel freely between collisions and explore the whole container.

  2. Container A holds 1 mole of helium at 300 K. Container B holds 2 moles of helium at 300 K, in twice the volume. Which statement is correct?

    A. Both have the same pressure and the same mean energy per atom; B has twice the internal energy. B. B has twice the pressure, because it contains twice as many atoms. C. B has twice the temperature, because it has twice the internal energy. D. A has the higher pressure, because its atoms are more crowded.

    Check your answer

    Correct answer: A — Both have the same pressure and the same mean energy per atom; B has twice the internal energy.

    • A. Correct, and this is the distinction worth carrying forward: temperature measures energy per particle, internal energy measures the total. Doubling N and V together leaves P = N k T / V unchanged.

    • B. Particle number alone does not set the pressure — density does. B has twice the particles in twice the volume, so N/V, and hence P, is unchanged.

    • C. This is the most common confusion in the whole subject. Temperature tracks the mean energy per particle; spreading twice the energy over twice the particles leaves the mean, and therefore the temperature, exactly where it was.

    • D. The atoms are not more crowded: both containers have the same number density N/V, which is what “crowded” means here.

  3. You double the mass of every particle while holding the temperature and density fixed. What happens to the pressure?

    A. It is unchanged, because the heavier particles move more slowly by exactly the compensating factor. B. It doubles, because each collision delivers twice the momentum. C. It halves, because the heavier particles move more slowly. D. It is unchanged, because pressure never depends on what the gas is made of.

    Check your answer

    Correct answer: A — It is unchanged, because the heavier particles move more slowly by exactly the compensating factor.

    • A. Exactly. P = N m <v_x^2> / V and equipartition fixes m<v_x^2> = k_B T, so the mass cancels. Heavier particles hit harder but less often, and the two effects cancel identically rather than approximately.

    • B. Each collision does deliver more momentum — but at fixed temperature the heavier particles are slower (<v_x^2> = k_B T / m), so they arrive at the wall less often and carry less speed. Work through P = N m <v_x^2>/V and watch m cancel.

    • C. You have kept the slowing but dropped the heavier punch. Both effects are present and they cancel.

    • D. The conclusion is right but the reason is not. Pressure is independent of mass only for an ideal gas; real gases at high density differ from one another because their particles have different sizes and attractions.

  4. A box holds 10,000 non-interacting particles in thermal equilibrium. Estimate the relative standard deviation of its pressure, sigma_P / , using the N^(-1/2) law. Give your answer as a decimal fraction.

    Check your answer

    Correct answer: 0.01 (± 0.002)

    sigma_P/ = N^(-1/2) = 1/100 = 0.01, i.e. 1%. Note how quickly this becomes unmeasurable: a mole gives about 4e-13.

  5. Which single change would make a gas’s pressure fluctuations easiest to detect?

    A. Measuring a very small sample, so that N is small. B. Raising the temperature, so the collisions are more violent. C. Using heavier molecules, so each impact is larger. D. Compressing the gas, so collisions happen more often.

    Check your answer

    Correct answer: A — Measuring a very small sample, so that N is small.

    • A. Yes. The relative fluctuation depends on N and essentially nothing else — not on temperature, not on the species, not on the pressure itself. Small N is the only lever.

    • B. Hotter collisions are more violent, but there are correspondingly more of them and the mean pressure rises too. The relative fluctuation is N^(-1/2), independent of temperature.

    • C. Mass cancels out of the pressure at fixed temperature, and it cancels out of the relative fluctuation too.

    • D. Compression raises both the mean pressure and the absolute fluctuation, leaving the ratio unchanged at N^(-1/2).

  6. In which situation is the kinetic model used in this module least trustworthy?

    A. Helium at 4 K and high density, close to liquefaction. B. Nitrogen at room temperature and atmospheric pressure. C. Argon in a vacuum chamber at very low density. D. Air in a very large room rather than a small flask.

    Check your answer

    Correct answer: A — Helium at 4 K and high density, close to liquefaction.

    • A. Right on both counts. High density makes interparticle forces and finite particle size matter, and low temperature brings quantum statistics into play — the two failure modes named in the model specification.

    • B. This is the model’s home ground: the molecules occupy about a thousandth of the volume and quantum effects are utterly negligible.

    • C. Low density makes the model better, not worse — that is precisely the dilute limit in which “non-interacting” is an excellent description.

    • D. Container size is irrelevant to the model’s validity; density and temperature are what matter. If anything, larger N makes the macroscopic description sharper.

  7. Before reading the derivation: you double the number of particles at fixed temperature and volume. Predict what happens to (a) the pressure, (b) the relative size of its fluctuations, and (c) the mean kinetic energy per particle.

    Check your answer

    The pressure doubles (P is proportional to N at fixed T and V). The relative fluctuation falls by a factor sqrt(2), since it goes as N^(-1/2). The mean kinetic energy per particle is unchanged — it is fixed by the temperature alone, which is exactly what makes temperature a useful intensive quantity. If you predicted that the mean energy per particle rises with N, you are treating temperature as a measure of total energy; that confusion is worth naming now, because it will otherwise resurface in every later module.

  8. In two or three sentences, explain why the pressure of a gas is steady, in a way that would not also (incorrectly) predict that the pressure of ten molecules is steady.

    Check your answer

    A good answer identifies the mechanism as averaging over a large number of independent events, and makes the size of N do the work: the absolute fluctuation grows as sqrt(N) while the total grows as N, so the ratio falls as N^(-1/2). For ten molecules that ratio is about 30%, which is not steady at all. Answers that say “the collisions average out” without reference to N do not distinguish the two cases and should be pushed further.

Exam-style problems for this module — the ones worth doing with a pen — are collected in the problem set.

Explain it in your own words

Answer in a few sentences each. These are the questions that reveal whether the ideas landed; no number will save you.

  1. A student says: “Pressure is steady because the collisions all average out to a smooth push.” Improve this sentence so that it is actually correct, and say precisely what was wrong with it.

  2. Explain why doubling the particle mass at fixed temperature leaves the pressure unchanged, without writing an equation.

  3. Two containers hold gas at the same temperature. One is twice the volume with twice the particles. Compare their pressures and the relative sizes of their pressure fluctuations.

  4. Your derivation assumed the particles do not collide with one another. Real air molecules collide roughly 109 times per second. Why does the result survive?

Advanced: beyond the simplest picture

Why interparticle collisions do not change the pressure. In the derivation each particle delivers mvx2/Lxm v_x^2 / L_x to the wall. Collisions between particles redistribute velocities but conserve total momentum and energy, so the sum ∑mvx,i2\sum m v_{x,i}^2 is unchanged over times long compared with a collision. The pressure depends only on that sum. This is why the ideal gas law survives in a gas that collides constantly — and it is also why the argument stops working the moment the collisions are not instantaneous or the particles feel each other at a distance, since then there is a potential-energy contribution to the momentum flux.

Pressure as momentum flux. The sharper statement is that pressure is the flux of xx momentum in the xx direction, a component of the stress tensor Πij=∑imvivj/V\Pi_{ij} = \sum_i m v_i v_j / V. Written this way there is no need for a wall at all: pressure exists in the interior of a fluid, where there is nothing to bounce off. Walls are a pedagogical crutch, and the crutch is worth putting down.

The virial correction. For interacting particles the exact result is the virial equation

PV=NkBT+1d⟨∑i<jrij⋅Fij⟩,P V = N k_B T + \frac{1}{d}\left\langle \sum_{i<j} \mathbf{r}_{ij} \cdot \mathbf{F}_{ij} \right\rangle ,

where the second term collects the interparticle forces. Attractive forces make it negative and reduce the pressure below the ideal value — the physical origin of the aa term in the van der Waals equation (module 14).

Fluctuations and the ensemble. The N−1/2N^{-1/2} result above compares independently drawn microstates at fixed TT, which is a canonical statement. If instead the energy is held exactly fixed (microcanonical), the pressure fluctuations differ in detail but still vanish as N−1/2N^{-1/2}. The agreement of ensembles in the thermodynamic limit is a theorem worth meeting properly in module 11 — and it is why we can be casual about which one a real experiment realises.