Have you ever struggled with the appearance light sources when taking photographs? Sometimes, you want a hazy effect, other times you'd like halos. Or perhaps, you want those lights — be it the sun or a street lamp — to be in sharp focus. For this last situation, by understanding how light interacts with the camera, you can achieve an in-focus look every time.
An article by PhotoShelter's Allen Murabayashi goes into a lot of detail about the "physics behind sunbursts". There's plenty of background detail on light and optics, but here's the relevant section on the interplay with camera lenses:
Most modern lenses use an iris diaphragm to control the size of the aperture. Wide open, the effects of diffraction are unnoticeable because most of the light can pass directly through the diaphragm without being affected by diffraction occurring at the edges. But as the aperture becomes smaller and approaches the wavelength of light, diffraction has a pronounced effect. When diffraction occurs around an edge like an aperture blade, it creates two visible spikes of light 180° apart and perpendicular to the blade edge.
The diagram below demonstrates the effect different irises have on the appearance of light sources:
So, how can we use this information to achieve crisp focus? We need to use something called a "Bahtinov mask":
Like the struts on a reflecting telescope, the Bahtinov Mask uses slots cut at different angles to produce diffraction spikes when pointed at a bright light source like a star. The mask is placed over the lens or telescope, and focus is achieved when the center of each spike pair is aligned.
While you can buy masks ($5-$50, depending on quality and seller), it is possible to make your own using a plastic binder, glue and a Stanley knife.
The Physics Behind Sunbursts and How It Can Help You Focus Your Photos [PhotoShelter, via PetaPixel]