Sub topic 8
Work done by a gas as the area under the P-V curve
This chapter assumes you know the ideal gas equation PV = nRT, the definition of work as force times displacement, and basic integration of simple functions such as 1/V.
From force on a piston to PdV
Take a gas in a cylinder closed by a frictionless piston of area A. The gas exerts a force F = PA on the piston. If the piston moves outward by a small distance dx, the work done by the gas is
dW = F dx = P A dx = P dV
where dV = A dx is the small change in volume. Over a whole process from volume V₁ to V₂:
W = ∫ P dV (from V₁ to V₂)
This integral is the area under the curve on a P-V diagram. The expression holds for any gas, provided the process is slow enough that the pressure is defined at each instant.
Sign rules
- Expansion (dV > 0): W is positive. The gas does work on its surroundings.
- Compression (dV < 0): W is negative. The surroundings do work on the gas.
- Constant volume: W = 0, because no area is swept out.
Work for the standard processes
| Process | Condition | Work done by the gas |
|---|---|---|
| Isochoric | V constant | 0 |
| Isobaric | P constant | P(V₂ − V₁) = nR(T₂ − T₁) |
| Isothermal | T constant | nRT ln(V₂/V₁) |
For the isothermal case, P = nRT/V, so W = nRT ∫ dV/V = nRT ln(V₂/V₁). Use P₁/P₂ in place of V₂/V₁ when pressures are given, since P₁V₁ = P₂V₂.
A worked example
One mole of a monatomic ideal gas at 300 K doubles its volume. Compare an isothermal path with an adiabatic one.
import math
R = 8.314
n, T1, f = 1.0, 300.0, 3
Cv = f / 2 * R
gamma = 1 + 2 / f
ratio = 2.0
W_iso = n * R * T1 * math.log(ratio)
T2 = T1 * ratio ** (1 - gamma)
W_adi = n * Cv * (T1 - T2)
print(f"Isothermal work: {W_iso:.0f} J")
print(f"Adiabatic final T: {T2:.1f} K, work: {W_adi:.0f} J")The isothermal work is about 1729 J. The adiabatic work is smaller, about 1405 J, because the gas cools to about 189 K and its pressure falls faster. On the P-V diagram the adiabatic curve lies below the isothermal curve, so it encloses less area.
Common errors
- Path matters. Work is not fixed by the end states alone. Two paths between the same points enclose different areas.
- Using ln with the wrong ratio. Isothermal work uses V₂/V₁ (or P₁/P₂), never P₂/P₁ in the same position.
- Forgetting the sign. A compression in a question usually asks for work done on the gas, so check which one is requested.
- Reading the area on the wrong axis. The area is under the curve down to the V axis, not to the P axis.
Exercise
One mole of an ideal gas is heated at a constant pressure of 2 × 10⁵ Pa, and its volume increases from 10 L to 25 L. How much work does the gas do?
Show answer
W = PΔV = 2 × 10⁵ Pa × (25 − 10) × 10⁻³ m³ = 3000 J. The work is positive because the gas expands.
Exercise
A gas goes from (V₁, P₁) to (V₂, P₂) along a straight line on a P-V diagram, with P₁ = 4 × 10⁵ Pa, P₂ = 2 × 10⁵ Pa, V₁ = 2 × 10⁻³ m³ and V₂ = 6 × 10⁻³ m³. Find the work done by the gas.
Show answer
The area is a trapezoid: W = ½(4 × 10⁵ + 2 × 10⁵)(6 × 10⁻³ − 2 × 10⁻³) = ½ × 6 × 10⁵ × 4 × 10⁻³ = 1200 J.