← all study views

science viewlive 3D · minted from a sentence

Atmospheric Scattering

Why the sky is blue, why sunsets are red, and why astronauts see a thin blue limb — one scattering integral, computed per pixel around a planet you can orbit.

the worlddrag to orbit · scroll to zoom

the real artifact, live — not a videoopen it full-page →

the study

The idea

Air molecules are far smaller than a wavelength of light, and scattering off such small particles is fiercely colour-dependent: intensity goes as 1/λ⁴, so 450 nm blue light scatters roughly five times more strongly than 650 nm red. Look anywhere in the daytime sky except at the sun and what reaches your eye is sunlight that has been scattered toward you — overwhelmingly the blue end. That is the whole secret of the blue sky, and this render computes it honestly, integrating scattering along every view ray rather than painting a gradient.

Sunsets are the same physics run in reverse. At the horizon, sunlight travels a path through air tens of times longer than at noon, and by the end of that slant the blue has been scattered out and away — what survives the trip is the red. Add the aerosol layer: particles comparable to or larger than a wavelength scatter by a different rule (Mie scattering), nearly colour-blind and strongly forward-throwing, which is what builds the white glare halo around the sun's disk.

What to look for

  • The day side is a blue disk not because oceans are blue but because you are looking at kilometres of scattering air. The atmosphere is most of the "blue marble".
  • At the terminator — the day/night line — the limb grades from blue through amber to red as the tangent path through air lengthens. Every point on that line is somewhere sunset is happening.
  • In the 'limb' look, the planet backlights its own atmosphere: a thin glowing shell, blue above, warm below. This is the "sunrise from the ISS" view, and its thinness is the point — the breathable layer is a coat of paint on the planet.
  • Around the sun itself, the halo is white, not blue: that is forward Mie scattering off aerosols, indifferent to wavelength.

Getting it right

  • The sky does not reflect the ocean. The causality mostly runs the other way — deep water is blue in large part because it is lit by, and scatters, the same blue-weighted light.
  • Sunsets are not primarily "dust". The base reddening is pure path length through clean air; aerosols and ash deepen and dramatize it, which is why volcanic sunsets are spectacular, but a dust-free atmosphere still sets red.
  • Why is the sky not violet, since 1/λ⁴ favours it even over blue? Because the sun emits less violet than blue, and your eye's colour receptors are much less sensitive to it. The sky's colour is physics filtered through a detector — yours.

Turn the knobs

  • scenario walks the sun around the planet: 'day' (sun behind you — the full blue marble), 'sunset' (sun to the side — the terminator and its reddened limb), 'limb' (sun behind the planet — the backlit airglow ring).
  • brightness is the sun's intensity — in the sunset look, pushing it up bleeds more forward-scattered glare around the limb.
  • Orbit continuously instead of switching scenarios: drag the camera from the day side around to the night side and you pass through every sky colour the atmosphere can make, in order.

the knobs

The world above is one recipe — every knob below is a parameter of it. In a mojulo workshop you rarely touch them directly: you ask your agent in a sentence, and the agent sets the knobs.

parameter manual
  • scenario (string) — The lighting look (default 'day'): 'day' (full lit blue marble), 'sunset' (the day/night terminator, reddened limb), 'limb' (backlit night-side airglow ring).
  • brightness (number) — Sun intensity (4–60). Higher = brighter, more saturated scattering. Overrides the scenario default.

more study views