🌅 Rayleigh Scattering

| | |
Rayleigh: I ∝ 1/λ⁴  |  Sun elevation: 45°  |  Path length: 1.0×  |  Sky: Blue

🌅 Why Is The Sky Blue — Rayleigh Scattering

Explore Rayleigh scattering interactively: see why the sky is blue at noon and turns orange-red at sunset. The inverse fourth-power law I ∝ 1/λ⁴ drives the colour of daylight.

🔬 What It Demonstrates

Rayleigh scattering occurs when light interacts with particles much smaller than its wavelength (air molecules). The scattering intensity follows 1/λ⁴: blue light (450 nm) scatters ~5.5× more than red (700 nm). At sunset, longer path lengths scatter all blue light away, leaving red.

🎮 How to Use

Move the sun position from noon to sunset. Watch the sky gradient change from blue through orange to deep red. The wavelength bar chart shows scattering intensity for each colour.

💡 Did You Know?

Lord Rayleigh published his scattering theory in 1871. The same physics explains why Mars has a butterscotch sky, why blue eyes appear blue (structural colour, not pigment), and why distant mountains look blue.

About this simulation

This interactive model visualises Rayleigh scattering, the process by which sunlight is redirected by air molecules far smaller than its wavelength. Because scatter intensity follows the inverse fourth-power law I ∝ 1/λ⁴, short blue wavelengths (~450 nm) scatter far more strongly than long red ones (~700 nm), painting the daytime sky blue. As you lower the sun towards the horizon the simulation lengthens the atmospheric path length, scattering blue away and leaving the warm orange-reds of sunset.

🔬 What it shows

A 2D canvas sky that recolours in real time. It computes scatter for seven wavelengths (400–700 nm) using a 550 nm reference, weights them by an approximate Chapman air-mass path length, and builds a zenith-to-horizon gradient plus a live bar chart of scatter intensity per colour.

🎮 How to use

Drag the "Sun elevation" slider (0–90°) to move the sun from horizon to zenith, or tap the Noon, Sunset and Twilight presets. The "Show rays" checkbox toggles the animated sunbeams. The readout reports elevation, path-length multiplier and the current sky label.

💡 Did you know?

Lord Rayleigh formalised this scattering law in 1871. The same 1/λ⁴ physics explains why distant mountains look hazy blue, why a sunset path through the atmosphere can be roughly 38 times longer than at noon, and why the sky is not violet despite violet scattering even more.

Frequently asked questions

What is Rayleigh scattering?

Rayleigh scattering is the scattering of light by particles much smaller than its wavelength, such as the nitrogen and oxygen molecules in air. It is wavelength-dependent: shorter wavelengths are deflected far more than longer ones, which is why a clear daytime sky appears blue.

Why does the sky turn red at sunset?

When the sun is low, its light travels through much more atmosphere before reaching you. This long path scatters nearly all the blue and green light away, so mainly the longer red and orange wavelengths survive to reach your eye. The simulation models this with its path-length term that grows sharply as elevation falls.

What does the 1/λ⁴ law mean?

It means scattering intensity is inversely proportional to the fourth power of wavelength. Blue light near 450 nm scatters roughly five and a half times more strongly than red light near 700 nm. The bar chart in the simulation visualises this ratio across seven wavelengths from 400 to 700 nm.

What do the controls do?

The sun-elevation slider sets the sun's angle from 0 to 90 degrees, which drives both the sky colour and the path-length multiplier shown in the readout. The Noon, Sunset and Twilight buttons jump to preset elevations, and the "Show rays" checkbox toggles the animated beams emanating from the sun.

Is this simulation physically accurate?

It captures the correct qualitative physics: the 1/λ⁴ wavelength dependence and an approximate Chapman air-mass function for path length. The colours are stylised for clarity rather than spectrally calibrated, so it is an excellent teaching tool but not a precise radiative-transfer model.