Diffraction Grating

Set the grating's lines per millimetre, the wavelength of the light, how many lines the beam covers and how far away the screen is. The page finds every order, where it lands, how sharp it is, and, if you add a second wavelength, which order separates the two.

Loading interactive simulation...

Lesson

The theory — Diffraction Grating

A diffraction grating is a surface ruled with many parallel lines a distance d apart, which either transmit or reflect light. Light leaving neighbouring lines at an angle θ has travelled paths that differ by d sin θ, so the waves from all the lines arrive in step, and the light is bright, only where d sin θ = mλ, for a whole number m called the order. Everywhere else the contributions of N lines cancel almost completely; the first dark angle beside each bright one is only about λ/(N d cos θ) away. Two wavelengths come out as separate lines when the resolving power R = mN is at least λ/Δλ.

What each symbol means

d
the distance between neighbouring lines, 1 mm divided by the number of lines per millimetre
λ
the wavelength of the light, in the air after the grating
m
the order, a whole number; m = 0 is the straight-through beam, and only orders with mλ < d exist
N
the number of lines the beam actually covers, not the number ruled on the grating
R
resolving power, mN: the smallest wavelength difference the order separates is λ/R
Assumes
Light of a single wavelength arriving head-on, from a source far enough away and a screen far enough away that every line sends out waves at the same angle. Lines narrow enough that each spreads its light over the whole half-space, so every order is equally bright. All N lit lines equally lit. A reflection grating, like a disc, follows the same formula at normal incidence as a transmission grating does.
Breaks when
Real lines have a width a, and the light from one line is itself a single-slit pattern that dims the higher orders and wipes out any order that lands on one of its zeros: with a = d/2, every even order is missing. Light arriving at an angle θᵢ obeys d(sin θᵢ + sin θ) = mλ instead, which lets wavelengths up to 2d diffract when the light arrives at a grazing angle; that is why a Blu-ray disc tilted to the light does show some colour. And a beam of finite width lights its central lines more strongly than its edges, which softens the side lobes without moving the orders.

Two slits or six hundred, the first order is at 9.18° 🖖

Press Two slits, green and then 300 lines/mm, 600 lit. The spacing has not changed, and neither has any angle: the first order is at 9.18° both times and the sixth at 73.26°. What changes is the width. With two slits a bright band runs 4.607° from its peak to the first dark gap; with 600 it runs 0.01544°, 298.4 times less. The angles come from d sin θ = mλ alone, the condition that light from neighbouring lines arrives a whole number of wavelengths apart, and N does not appear in it. N decides how quickly the waves fall out of step once you move off that angle: with 600 sources, a step of about λ/(Nd cos θ) is enough for them to cancel completely. So a school grating is a double slit whose bright bands have been sharpened into lines, and “more lines per millimetre” and “more lines lit” are two different instructions. The first moves the orders; the second only makes them thinner and brighter.

Red light gives two orders on a CD, one on a DVD, none on a Blu-ray disc 🖖

An order exists only while mλ is less than d, so a finer grating has fewer of them. Red 650 nm light on a CD's 1.6 µm tracks makes two, at 23.97° and 54.34°. The second is not at twice the first, which would be 47.94°: it is the sines that go up in equal steps, 0.4063 and 0.8125, not the angles. On a DVD, 0.740 µm, there is room for one order, at 61.45°. A Blu-ray disc's tracks are 0.32 µm apart, closer than any visible wavelength and closer even than the 405 nm violet laser that reads them, so light arriving head-on has no order at all to go into, and the table below prints none. The same arithmetic breaks the formula most students learn first. On a double slit, y = mλL/d is fine because the angles are tiny; on the CD it puts the first order at 406.3 mm on a screen 1 m away, and the page measures 444.6 mm. At grating angles you need y = L tan θ.

The sodium doublet splits in the second order and not the first 🖖

The two yellow lines of sodium are 588.9950 and 589.5924 nm, 0.5974 nm apart. Lord Rayleigh's criterion counts two lines as separate when the peak of one falls at or beyond the first zero of the other, and for a grating that works out as a resolving power R = mN. The doublet needs 986.4. Press Sodium doublet: 600 lines/mm, 500 of them lit. In the first order R is 500, the two peaks are 0.02196° apart while each is 0.04328° wide to its first zero, and you see one blurred line. In the second order of the same grating, R is 1,000; the peaks are 0.05809° apart and each is 0.05722° wide, and there are two lines, only just. The line spacing is not in R at all. A finer grating with the same 500 lines lit spreads the pair further apart in any given order and widens each peak in the same proportion, so it resolves nothing more. To split the doublet in the first order you need 987 lines under the beam, whatever grating they are on.

Problem solved in full

  1. Which orders of white light overlap? 5 steps

    White light, 400 to 700 nm, falls head-on on a grating of 300 lines per millimetre. Where does each order's spectrum begin and end, which of them overlap, and would a finer grating keep them apart? Press 300 lines/mm, 600 lit to check the first step.

    Open this problem in the tool

    1. The line spacing is 1 mm over 300, which the page prints:

    2. The first-order spectrum runs from the angle where violet satisfies d sin θ = λ to the angle where red does:

    3. The second order runs from 13.89° to 24.83°, so there is a clear gap between it and the first:

    4. The third order begins at 21.10°, before the second has ended. Where its violet lands, the second order is showing 600 nm orange light, because 3 × 400 = 2 × 600:

    5. Orders m and m + 1 overlap when m times the red end is longer than m + 1 times the violet end. The spacing d cancels:

    Answer

    The first order runs from 6.89° to 12.12° and stands alone. From the second order on, every spectrum runs into the one after it: the second's red end is at 24.83° and the third begins at 21.10°. No grating separates them, because the condition m·700 > (m + 1)·400 has no d in it. A finer grating spreads the orders further and leaves fewer of them, and the second order escapes only when the grating is so fine that no third order is left to meet it. The first order is clear only because visible light spans less than an octave, 700/400 = 1.75. A spectrometer that works in a higher order puts a filter in front of the grating to cut off the light from the neighbouring orders, an order-sorting filter.

References (3)