Thin Film Interference Calculator
Calculate which visible wavelengths are reinforced or cancelled by thin film interference.
Explains soap bubble colors, oil slick iridescence, and AR coatings.
When light reflects off both surfaces of a thin transparent film, the two reflected beams interfere. Whether they reinforce or cancel depends on the film thickness and refractive index.
For a film with n > surrounding medium (e.g., soap in air):
Constructive (bright) interference: 2nt = (m + ½)λ → λ = 2nt/(m + ½) for m = 0, 1, 2…
Destructive (dark) interference: 2nt = mλ → λ = 2nt/m for m = 1, 2, 3…
Where:
- n = refractive index of the film
- t = film thickness (nm)
- λ = wavelength in air (nm)
- m = integer order
The key physics: When light reflects off a surface going from low-n to high-n, it gains a phase shift of 180° (half wavelength). This shifts the interference conditions.
Real-world examples:
- Soap bubbles: As the bubble wall thins near the top, different colors interfere constructively at different thicknesses, creating rainbow swirls
- Oil slicks on water: Oil (n≈1.47) on water (n≈1.33), which gives two phase reversals rather than one
- Camera lens coatings: A thin MgF₂ coating (n=1.38, t≈100 nm) cancels reflections at green wavelengths → lens appears purple (red+blue reflected)
- CD/DVD rainbow colors: Diffraction rather than thin film, but similar visual effect
- Butterfly wings: Nano-scale thin-film structures create iridescent structural colors without pigment
Count the phase reversals before you trust a formula
This is where thin-film problems go wrong, and the lens-coating example above is a good illustration of it. A reflection flips phase by 180° only when light hits a higher index than it came from. Soap in air reverses at the front surface and not at the back, so one reversal, and the equations at the top apply as written.
A coating on glass is different. Air (1.00) to magnesium fluoride (1.38) reverses, and then magnesium fluoride to glass (1.52) reverses again. Two reversals cancel out, so the conditions swap over: 2nt = (m + ½)λ now gives you destructive interference, which is exactly what an anti-reflection coating is for. Run the numbers on that 100 nm coating and 2nt = 276 nm, so the cancelled wavelength is 552 nm, in the green where the eye is most sensitive. What survives is red and blue, which is why good lenses look faintly purple.
So the rule is: one reversal, use the formulas above. Two reversals or none, swap constructive and destructive. This calculator assumes the single-reversal case.
Why the colours move as you tilt
Everything here uses light arriving straight on. Tilt the film and the path inside it lengthens, so the reinforced wavelength shifts toward the blue. That is the whole reason a soap bubble or an oil slick changes colour as you move your head, and it is also why an interference filter has to be specified at a stated angle of incidence.
How we build and check this calculator
This calculator runs entirely in your browser, so the numbers you enter stay on your device. The math behind it is written by hand and tested against worked examples and standard references before the page goes live.
SuperGlobalCalculator is independently built and maintained. See how we build and verify our calculators.