Simulations

Instructions
A simulation will only respond to keyboard control when it is "in focus". If not you can click on the simulation area once to bring it to focus.

Double Slit and Diffraction Grating of Arbitrary Number of Slits with Phasor Diagram

The first part represents the slits. The second is the light it produces on the screen. The third is the plot of the intensity. The last is the phasor diagram, adding up the phases produced by the (red) light.

You can change the number of slits by pressing 1 and 2. You can see that the peaks becomes sharper as the number of slits go up, while their positions stay the same. By using a large number of slits, it becomes easier to resolve different wavelengths. Press h to focus on only one light source. To see the very dim secondary peaks, press b repeatedly to increase the brightness.

Single Slit and the Rayleigh criterion with Two Light Sources

Drag your mouse on the light left and right. How close can you place the two peaks while still be able to see them as separate? This is the basis of the Rayleigh criterion. You can also drag on the edge of the slit to change its width or adjust the wavelength to see the effect on the diffraction pattern. Press h to focus on only one light source. To see the very dim secondary peaks, press b repeatedly to increase the brightness.

Single Slit with a Single Source and Phasor Diagram

Drag your mouse on the light left and right. To see how the phasors combined to give the intensity, drag on the red triangle to adjust the position. You can see why the first minimum occurs when k*a*sin(theta)=2*pi.

Diffraction Grating with Adjustable Slit Width

When the width of slits is taken into account, the brightness of the fringes will attenuate as one moves away from the center. Overall the pattern is the combination of the intensity of the diffraction grating (with infinitesimal slit width) and that of a finite-size single slit.