White light from a hot star passes through a cloud of gas. Choose the gases in the nebula, then shine the light to see the absorption and emission spectra. Devised by Aaron Jones.
The hot star on its own: every colour.
Looking through the gas at the star: dark lines.
Looking at the gas from the side: bright lines.
The electrons in an atom can only have certain energies. An electron can absorb a photon only if the photon has exactly the energy needed to jump to a higher level. When the electron drops back down, it gives out a photon with the same energy.
E = hf = hc / λ
Absorption: looking straight through the gas at the star, photons with those exact energies are missing, so there are dark lines on the continuous spectrum.
Emission: the excited atoms give out those photons again in every direction. Looking at the gas from the side, against a dark sky, only those wavelengths reach us, so there are bright lines. Each gas has the same wavelengths in both spectra. This is its fingerprint.
These are Kirchhoff's three laws of spectra: a hot, dense object gives a continuous spectrum, a cool gas in front of it gives an absorption spectrum, and a hot, thin gas gives an emission spectrum.
Hydrogen, helium and sodium use real wavelengths, rounded to the nearest nm. Nitrogen and oxygen are simplified to a few lines to make the game clearer. In a real nebula the glow from oxygen mostly comes from ionised oxygen (the strong green lines near 496 and 501 nm). Lines are not all the same brightness in real spectra.
Interactive devised by Aaron Jones (Scots College). Learn more in the Bohr model lesson and the Stellar spectroscopy lesson.