An interactive demo created by Claude Opus 5.5, based on the lecture notes by Sang Hoon Lee (Chapter 7, Section 7.4, Blackbody Radiation)

Blackbody Radiation

Treat the electromagnetic field inside a hot box as a gas of photons: bosons with zero chemical potential. Their statistics explain the color of glowing objects, Stefan’s \(T^4\) law, the cosmic background radiation, and the temperature of the Earth.

The ultraviolet catastrophe

Classically, the radiation inside a box is a combination of standing-wave patterns, each behaving as a harmonic oscillator with frequency \(f = c/\lambda\). Each oscillator has two quadratic degrees of freedom, so equipartition gives it an average energy \(\bar{E} = k_{\mathrm{B}}T\). But there are infinitely many modes, most of them at very short wavelengths, so the total thermal energy would be infinite. That cannot be physically true.

Planck’s solution: a quantum oscillator has energies \(E_n = 0, hf, 2hf, \ldots\) (dropping the zero-point energy, which only multiplies \(Z\) by a constant). The partition function of a single oscillator is a geometric series,

\( \displaystyle Z = \sum_{n=0}^{\infty} e^{-n\beta hf} = \frac{1}{1 - e^{-\beta hf}}, \)\( \displaystyle \bar{E} = -\frac{\partial \ln Z}{\partial \beta} = \frac{hf}{e^{hf/k_{\mathrm{B}}T} - 1} \)

and the average number of energy units in the oscillator is the Planck distribution:

\( \displaystyle \bar{n}_{\mathrm{Pl}} = \frac{1}{e^{hf/k_{\mathrm{B}}T} - 1} \)

Modes with \(hf \gg k_{\mathrm{B}}T\) are exponentially suppressed, “frozen out,” and the catastrophe disappears. Slide the mode frequency to compare.

Average energy per mode, in units of \(k_{\mathrm{B}}T\).

Energy spectrum: the number of modes grows as \(\varepsilon^2\), so the classical spectrum grows without bound.

Classical (equipartition, Rayleigh–Jeans) Planck
\(\bar{n}_{\mathrm{Pl}}\) for this mode
–
Planck \(\bar{E}/k_{\mathrm{B}}T\)
–
Classical \(\bar{E}/k_{\mathrm{B}}T\)
1

Photons as bosons

Now take the units of field energy seriously as particles called photons. They are bosons and should follow the Bose–Einstein distribution with \(\varepsilon = hf\). Photons can be created or destroyed in any quantity, so their number is not conserved: \(N\) takes whatever value minimizes \(F\), which means \((\partial F/\partial N)_{T,V} = \mu = 0\). Then \(\bar{n}_{\mathrm{BE}}\) is exactly \(\bar{n}_{\mathrm{Pl}}\).

Photons are ultrarelativistic, \(\varepsilon = pc = hcn/2L\) with \(n = |\vec{n}|\), and come in two independent polarizations (playing the role of the electrons’ two spin states). Summing \(\varepsilon\,\bar{n}_{\mathrm{Pl}}\) over all modes in the eighth-sphere of \(n\)-space gives

\( \displaystyle U = 2\sum_{n_x,n_y,n_z} \varepsilon\, \bar{n}_{\mathrm{Pl}}(\varepsilon) \)\( \displaystyle \approx \pi \int_0^\infty n^2\, dn\, \frac{hcn}{2L}\,\frac{1}{e^{hcn/2Lk_{\mathrm{B}}T} - 1} \)\( \displaystyle \Longrightarrow\; \frac{U}{V} = \int_0^\infty \frac{8\pi\varepsilon^3/(hc)^3}{e^{\varepsilon/k_{\mathrm{B}}T} - 1}\, d\varepsilon \)

The integrand is the spectrum: the energy density per unit photon energy,

\( \displaystyle u(\varepsilon) = \frac{8\pi}{(hc)^3}\,\frac{\varepsilon^3}{e^{\varepsilon/k_{\mathrm{B}}T} - 1} \)

With \(x = \varepsilon/k_{\mathrm{B}}T\) its shape is \(x^3/(e^x - 1)\), which peaks at \(x = 2.82\). Higher temperature means higher photon energies, larger frequency, and shorter wavelength: Wien’s law.

The spectrum at any temperature

Choose a temperature. The curve is drawn relative to its own peak on a logarithmic axis, so it slides left as the temperature rises; pin a curve to compare. The colored band marks visible light.

Current temperature Pinned curves Where \(u(\varepsilon)\) peaks, converted to wavelength
–
Peak of \(u(\lambda)\)
–
Peak of \(u(\varepsilon)\)
–
\(hc/\varepsilon_{\max}\)
–

Per wavelength is not per energy

Problem 7.39. Changing variables to \(\lambda = hc/\varepsilon\), with \(d\varepsilon = -hc\,d\lambda/\lambda^2\), gives the energy density per unit wavelength:

\( \displaystyle u(\lambda) = \frac{8\pi hc}{\lambda^5}\,\frac{1}{e^{hc/\lambda k_{\mathrm{B}}T} - 1}, \)\( \displaystyle \lambda_{\max} = 0.2014\,\frac{hc}{k_{\mathrm{B}}T} \)\( \displaystyle \neq \frac{hc}{2.82\,k_{\mathrm{B}}T} = 0.3546\,\frac{hc}{k_{\mathrm{B}}T} \)

The two peaks disagree because \(\lambda \propto 1/\varepsilon\) is nonlinear: equal intervals \(d\varepsilon\) correspond to unequal intervals \(d\lambda \propto d\varepsilon/\varepsilon^2\). Compare the last two rows of the panel. For sunlight, \(u(\varepsilon)\) peaks at 1.41 eV, which corresponds to 880 nm in the near infrared, yet \(u(\lambda)\) peaks near 500 nm.

Totals: energy, photons, entropy, pressure

Integrating the spectrum with \(\int_0^\infty x^3/(e^x-1)\,dx = \pi^4/15\) gives the total energy, and the rest follow:

\( \displaystyle \frac{U}{V} = \frac{8\pi^5 (k_{\mathrm{B}}T)^4}{15 (hc)^3} \propto T^4 \)

Doubling the temperature multiplies the energy by 16. Dimensional analysis already suggests this: each photon carries something of order \(k_{\mathrm{B}}T\), and the only relevant length is the photons’ typical wavelength \(hc/k_{\mathrm{B}}T\). The density of states (Problem 7.40) is \(g(\varepsilon) = 8\pi V\varepsilon^2/(hc)^3\).

\( \displaystyle C_V = 4aT^3, \)\( \displaystyle S = \frac{32\pi^5}{45}\,V\left(\frac{k_{\mathrm{B}}T}{hc}\right)^3 k_{\mathrm{B}}, \)\( \displaystyle N = 16\pi\,\zeta(3)\,V\left(\frac{k_{\mathrm{B}}T}{hc}\right)^3 \)

with \(a = 8\pi^5 k_{\mathrm{B}}^4 V/15(hc)^3\) and \(\int_0^\infty x^2/(e^x-1)\,dx = 2\zeta(3) \approx 2.404\) (Problem 7.44). \(S\) and \(N\) share the same dependence on \(V(k_{\mathrm{B}}T/hc)^3\), so the entropy per photon is a constant, \(S/N \approx 3.6\,k_{\mathrm{B}}\). For the pressure (Problem 7.45) and free energy (Problem 7.46),

\( \displaystyle P = -\left(\frac{\partial U}{\partial V}\right)_{S,N} = \frac13\,\frac{U}{V}, \)\( \displaystyle F = U - TS = -\frac13 U \)

and \(F\) can also be found mode by mode as \(-k_{\mathrm{B}}T\ln Z\), with the same result. Pick a temperature to see the numbers.

Shares nothing with the slider above, so you can compare two temperatures.

Energy density \(U/V\)
–
Photons per m³, \(N/V\)
–
Average photon energy \(U/N\)
–
Entropy per photon \(S/N\)
3.60 \(k_{\mathrm{B}}\)
Radiation pressure \(P\)
–
Air at 1 atm, for scale
1.01 × 105 Pa
Power per area \(\sigma T^4\)
–

Problem 7.45 asks you to compare: radiation inside a 1500 K kiln exerts only about \(1.3 \times 10^{-3}\ \mathrm{Pa}\), a hundred-millionth of atmospheric pressure. At the center of the Sun, at 15 million K, radiation pressure reaches about \(1.3 \times 10^{13}\ \mathrm{Pa}\), yet the ionized hydrogen gas there (density about \(10^5\ \mathrm{kg/m^3}\)) exerts roughly \(2.5 \times 10^{16}\ \mathrm{Pa}\), about 2000 times more.

The cosmic background radiation

The radiation that fills the entire observable universe has an almost perfect thermal spectrum at 2.73 K. Its \(u(f)\) peaks at \(\varepsilon = 2.82\,k_{\mathrm{B}}T = 6.6 \times 10^{-4}\ \mathrm{eV}\), corresponding to a wavelength of about 1 mm, in the far infrared. There are about \(4.1 \times 10^8\) of these photons in every cubic meter of space. Part of the “snow” on an old analog television tuned between channels came from this leftover glow of the Big Bang. Choose Cosmic background in the spectrum above to see it.

Photons escaping through a hole

Open a small hole of area \(A\) in a box of radiation. All photons travel at the same speed \(c\), regardless of wavelength, so the light that escapes has the same spectrum as the light inside. To find how much escapes in a time \(dt\), consider a chunk of the box at distance \(R\) and angle \(\theta\) from the hole, inside a hemispherical shell of thickness \(c\,dt\). Only photons in that shell can reach the hole during \(dt\).

The chunk, volume \(R^2\sin\theta\,d\theta\,d\phi\,c\,dt\) The hole as seen from the chunk, \(A\cos\theta\)
Apparent hole area
–
Chunk volume \(\propto \sin\theta\)
–
Contribution \(\propto \sin\theta\cos\theta\)
–

Photons in the chunk point every which way, so the fraction aimed at the hole is its apparent area over the full sphere, \(A\cos\theta/4\pi R^2\). Head-on chunks see the whole hole but are small rings; grazing chunks are large but see the hole edge-on. The product peaks at 45°.

The chunk holds energy \((U/V)\,R^2\sin\theta\,d\theta\,d\phi\,c\,dt\), and a fraction \(A\cos\theta/4\pi R^2\) of it heads for the hole; \(R\) cancels. Integrating over \(\phi\) from 0 to \(2\pi\) and \(\theta\) from 0 to \(\pi/2\),

\( \displaystyle \text{energy escaping} \)\( \displaystyle = \int_0^{2\pi}\! d\phi \int_0^{\pi/2}\! d\theta\, \frac{A\cos\theta}{4\pi}\,\frac{U}{V}\,c\,dt\,\sin\theta \)\( \displaystyle = \frac{A}{4}\,\frac{U}{V}\,c\,dt \)

The factor of \(\tfrac14\) is easy to check by brute force. Below, 2000 photons fly around a box at speed \(c\), bouncing off the walls; any that hit the hole escape. To keep the radiation inside in equilibrium, each is replaced by a photon entering through the hole, as if the hole opened onto more radiation at the same temperature. Compare the counted escape rate with \(\tfrac14 (N/V)\,c\,A\), and the escape angles with \(\sin\theta\cos\theta\).

Escaped photons, by angle from the hole’s normal Prediction \(\propto \sin\theta\cos\theta\)
Photons \(N\)
2,000
Hole area \(A\)
\((0.3L)^2\)
Escapes
0
Escape rate, measured
–
\(\tfrac14 (N/V)\,c\,A\)
–
Ratio
–

Rates are per unit of simulation time, with \(c = 0.45\) box lengths per unit. The view is from the front, so photons at all depths overlap; only 1 in 5 is drawn.

\( \displaystyle \frac{\text{power}}{\text{area}} = \frac{c}{4}\frac{U}{V} = \frac{2\pi^5}{15}\frac{(k_{\mathrm{B}}T)^4}{h^3c^2} = \sigma T^4, \)\( \displaystyle \sigma = 5.67 \times 10^{-8}\ \mathrm{W\,m^{-2}\,K^{-4}} \)

This is Stefan’s law, discovered empirically in 1879 (remember “5–6–7–8”). Any nonreflecting (“black”) surface at the same temperature must emit the same power, and indeed the same entire spectrum, as the hole; otherwise placing it next to the hole, with a wavelength filter in between, would violate the second law. A surface that reflects some photons emits correspondingly less: power \(= \sigma e A T^4\), where \(e\) is the emissivity.

The Sun and the Earth

The Earth receives 1370 W/m² of sunlight (the solar constant) at a distance of \(1.5 \times 10^{8}\ \mathrm{km}\), so the Sun’s total output is \(4\pi (1.5 \times 10^{11}\ \mathrm{m})^2 \times 1370\ \mathrm{W/m^2} \approx 3.9 \times 10^{26}\ \mathrm{W}\). Its radius is about \(7.0 \times 10^8\ \mathrm{m}\), so with emissivity 1, \(T_\odot = (L/\sigma A)^{1/4} \approx 5800\ \mathrm{K}\).

Sunlight, spreading over a sphere of area \(4\pi d^2\) Infrared radiated by the Earth Not to scale: the Sun and Earth are drawn far larger than life.

The Earth absorbs sunlight across its disk, \(\pi r_E^2\), but radiates from its whole surface, \(4\pi r_E^2\). Balancing the two gives the Earth’s temperature:

\( \displaystyle (1 - \text{albedo})\,(\text{solar constant})\,\pi r_E^2 = 4\pi r_E^2\,\sigma T^4 \)\( \displaystyle \Longrightarrow\; T = \left[\frac{(1-\text{albedo})\times 1370\ \mathrm{W/m^2}}{4\sigma}\right]^{1/4} \)

Model the atmosphere as a single layer, transparent to visible light but opaque to infrared. In equilibrium the surface then receives twice as much energy as from sunlight alone, raising its temperature by \(2^{1/4}\): the greenhouse effect.

Energy flows averaged over the whole surface, in W/m². Sunlight (mostly visible) is drawn in gold, infrared in gray. Arrow widths are proportional to the flows.

–

In astronomical units (1 AU = \(1.5 \times 10^8\) km). Venus is at 0.72, Mars at 1.52.
Solar constant
–
Measured average surface
288 K (15 °C)

The single-layer model overshoots (303 K) because the real atmosphere isn’t one perfectly opaque layer. Most actual greenhouses work mainly by a different mechanism, limiting convective cooling. The default Sun temperature, 5772 K, reproduces the 1370 W/m² solar constant to within about 1%.