In optics, a beam of light is said to be coherent if its phase (the phase of the oscillating electric and magnetic fields) varies smoothly along the beam rather than going through discontinuous changes. More precisely, the beam has a "coherence length" which is the average length over which the phase oscillates smoothly. For light from an ordinary lightbulb, this is only about one wavelength, because the light is made up of photons which are not in phase with each other. For a laser beam, the photons are in phase with each other, and the coherence length is about 50cm. Coherent light will produce interference patterns when passed through a diffraction grating.