- W = n · R · T · ln(V₂ / V₁)
n is the amount of gas in moles, R the gas constant 8.314 J/(mol·K), T the temperature in kelvins,
V₁ and V₂ the volumes before and after, and W the work done by the gas in joules.
Holds for an ideal gas expanding slowly enough, and with good enough contact for heat, that the temperature
stays constant.
It follows from the ideal gas law: at constant
temperature the pressure falls as the gas expands, p = nRT / V, and adding up p · dV along the way gives the
logarithm.
Worked examples
2 mol at 300 K doubles its volume, 10 L to 20 L: W = 2 · 8.314 · 300 · ln 2 ≈ 3,458 J.
The same gas from 1 L to 2 L: again 3,458 J. Only the ratio V₂ / V₁ enters, so every doubling does
the same work, whatever the size of the container.
Tripling instead, 10 L to 30 L: W = 2 · 8.314 · 300 · ln 3 ≈ 5,480 J. Tripling is not 50% more
work than doubling but 58%, since ln 3 / ln 2 ≈ 1.58.
Compressing from 20 L back to 10 L: ln(1/2) is negative, so W ≈ −3,458 J. The gas does negative
work; someone has to push.
Where the energy comes from
An ideal gas at constant temperature keeps its internal energy, so the
first law says Q = W: all 3,458 J of
work arrive as heat from the surroundings. If the gas cannot take in heat fast enough, the expansion is no
longer isothermal but closer to an adiabatic process,
and the gas cools and does less work.
Common mistakes
- Using litres in R. The volumes appear only as a ratio, so litres are fine there — but T must be in
kelvins and n in moles, or R = 8.314 gives the wrong unit.
- Using log₁₀. The formula needs the natural logarithm. With log₁₀ the answer is 2.3 times too small.
- Using p · ΔV. That is the work at constant pressure. Here the pressure falls throughout, so p · ΔV
with either pressure gives the wrong answer.
Questions people ask
Can it be written with pressures instead?
Yes. At constant temperature p₁V₁ = p₂V₂, so V₂ / V₁ = p₁ / p₂ and W = nRT ln(p₁ / p₂).
Is a real expansion ever isothermal?
Close to it, when it is slow and the container conducts heat well. Gas escaping from a bottle is the
opposite case: fast and nearly adiabatic, which is why the valve gets cold.