DEV Community

Cover image for Wien's Displacement Law: Why Color Tells You Temperature
NovaSolver
NovaSolver

Posted on Originally published at novasolver.jp

Wien's Displacement Law: Why Color Tells You Temperature

Watch a blacksmith heat a bar of iron and you can read its temperature with your eyes alone. It first glows a dull red, then a brighter cherry red, then orange, then a brilliant yellow-white as it gets hotter. The bar is not changing what it is made of — it is changing the color of the light it radiates. That shift from red toward white is not a quirk of iron. Every hot object does it, from a stove element to a star, and the shift follows a precise mathematical law.

This article explains Wien's displacement law: what it says, why the peak of an object's glow moves with temperature, how to calculate that peak with a worked example, and the misunderstandings that catch people out.

Why this calculation matters

Every object above absolute zero radiates thermal energy across a broad spread of wavelengths, but not evenly — there is always one wavelength where the emission is strongest. Wien's displacement law tells you where that peak sits, and crucially, it tells you that the peak depends on temperature and nothing else. That makes the color of a glowing body a remote thermometer.

The consequences reach across science and engineering. Astronomers measure the surface temperatures of stars from the wavelength at which their light peaks, without ever touching them. Infrared thermography — the technology behind thermal cameras — works because objects near room temperature peak in the infrared, and the camera reads that emission as a temperature map. The law also explains why an incandescent bulb wastes most of its energy: its filament is not hot enough to peak in the visible band, so the bulk of its output spills out as invisible heat. Anywhere temperature and radiated light meet, Wien's law is the bridge.

The core formula

Wien's displacement law states that the wavelength of peak emission is inversely proportional to absolute temperature:

lambda_max = b / T
Enter fullscreen mode Exit fullscreen mode

Here lambda_max is the wavelength at which the object radiates most strongly, T is the absolute temperature in kelvin, and b is Wien's displacement constant:

b = 2.898e-3 m.K
Enter fullscreen mode Exit fullscreen mode

The relationship is an inverse one, and that is the whole story. Double the temperature and the peak wavelength halves — the glow shifts to shorter wavelengths, from red toward blue. Cool an object down and its peak slides the other way, toward longer wavelengths and eventually into the infrared, where the eye cannot follow it.

Wien's law is one feature of the full Planck radiation curve, which describes the complete spectrum of a black body — an idealized perfect emitter and absorber. Planck's curve gives the intensity at every wavelength; Wien's law simply locates its summit. The peak is also a single point on the broader picture: the total energy radiated across all wavelengths is governed by a separate result, the Stefan-Boltzmann law, which scales with temperature to the fourth power. Wien tells you the color; Stefan-Boltzmann tells you the brightness.

One detail worth noting: the constant b above is for a spectrum plotted against wavelength. If you instead plot the spectrum against frequency, the peak lands at a different place, because the conversion between the two stretches the axis unevenly. The wavelength form is the one most often used and the one quoted here.

A worked example

Consider the most familiar hot object in the sky: the Sun. Its visible surface, the photosphere, has a temperature of about T = 5778 K. At what wavelength does it shine most strongly?

Step 1 — write the law and gather inputs.

lambda_max = b / T
b = 2.898e-3 m.K
T = 5778 K
Enter fullscreen mode Exit fullscreen mode

Step 2 — substitute and divide.

lambda_max = 2.898e-3 / 5778
lambda_max = 5.02e-7 m
Enter fullscreen mode Exit fullscreen mode

Step 3 — convert to a friendlier unit.

5.02e-7 m = 502 nm
Enter fullscreen mode Exit fullscreen mode

So the Sun's emission peaks at about 502 nanometres — green light, sitting near the middle of the visible band, which runs roughly from 400 nm (violet) to 700 nm (red). That result is quietly remarkable. The Sun's peak output lands right inside the narrow range of wavelengths the human eye evolved to detect, and very close to the eye's own peak sensitivity. The Sun does not look green because it emits strongly across the entire visible spectrum at once, and the eye blends that broad mix into white. But the single strongest wavelength is green, and Wien's law pinpoints it from temperature alone.

Push the temperature higher and the peak marches toward shorter wavelengths. A star at 12,000 K would peak near 240 nm, deep in the ultraviolet, and would look distinctly blue-white. A cool red giant at 3,000 K peaks near 970 nm, in the near-infrared, and glows a deep red. Hotter means bluer — that is the rule the blacksmith was reading all along.

Common mistakes

Forgetting to use absolute temperature. The T in Wien's law must be in kelvin, measured from absolute zero. Plugging in degrees Celsius gives a badly wrong answer — and using a negative Celsius value gives a nonsensical negative wavelength. Always convert: kelvin equals Celsius plus 273.15.

Reading the inverse relationship backward. Hotter objects peak at shorter wavelengths, not longer. It is easy to associate "more energy" with "bigger number" and assume the wavelength grows with temperature. It shrinks. The peak shifts from red toward blue as things heat up.

Confusing the peak with the total output. Wien's law locates the strongest wavelength; it says nothing about how much total power is radiated. Two objects can peak at very different colors yet a small hot object can out-radiate a large cool one. For total radiated energy you need the Stefan-Boltzmann law, not Wien's.

Assuming the object is a perfect black body. Wien's law is derived for an ideal black body. Real materials have emissivity that varies with wavelength, which can shift or distort the apparent peak. For many practical hot objects the law is a very good guide, but treat it as a clean baseline rather than an exact verdict for every surface.

Mixing up the wavelength and frequency forms. The peak wavelength and the peak frequency do not correspond to the same point on the spectrum. If a problem is stated in frequency, do not simply convert the wavelength-form constant — the frequency form uses its own constant.

Try the interactive NovaSolver calculator

Computing one peak by hand is straightforward, but watching the whole spectrum shift as you change temperature is where the law comes alive. The Wien Displacement Law Simulator — Peak Wavelength of Black-Body Radiation on NovaSolver lets you set the temperature, emissivity, surface area, and observation distance, and returns the peak wavelength along with the radiant exitance, total radiated power, and the irradiance at your chosen distance — all plotted on a live Planck curve with the visible band shaded, so you can see exactly where green, red, and blue-white sit.

Related calculators

You can browse the full set in the physics tools hub.

Closing note

Wien's displacement law is a small equation with an outsized reach: it makes color a thermometer. The takeaways are easy to keep — the peak wavelength is inversely proportional to absolute temperature, hotter means bluer, and the constant is about 2.898e-3 m.K. With those in hand you can estimate a star's temperature from its color, understand why thermal cameras see in the infrared, and explain the blacksmith's glowing bar in one sentence. Run a few temperatures yourself, watch the peak slide across the spectrum, and let it anchor the rest of your study of thermal radiation.

Top comments (0)