Lens Refraction Calculator

Calculate image formation through lenses with ray diagrams

Ray Diagram

Blue rays show principal ray paths. Green line shows real image.

Positive for converging lens

Results

Enter values and click Calculate to see the result.

Theory & Formula

Lenses refract (bend) light to form images. The thin lens equation relates object distance, image distance, and focal length.

Lens Types:

  • Converging (Convex): Thicker at center, positive focal length, converges parallel rays
  • Diverging (Concave): Thinner at center, negative focal length, diverges parallel rays

Sign Convention (Cartesian):

  • Distances measured from optical center of lens
  • Real images: \(v > 0\) (opposite side from object)
  • Virtual images: \(v < 0\) (same side as object)
  • Inverted images: \(m < 0\)
  • Upright images: \(m > 0\)

Power of Lens: \(P = \frac{1}{f}\) (in meters), measured in diopters (D)

\(\frac{1}{f} = \frac{1}{v} + \frac{1}{u}, \quad m = \frac{v}{u} = \frac{h'}{h}\)

Worked Examples

Converging Lens

\((f > 0)\) Object beyond 2F: Real, inverted, diminished image between F and 2F

Converging Lens

Object between F and 2F: Real, inverted, magnified image beyond 2F

Diverging Lens

\((f < 0)\) Always forms virtual, upright, diminished image on same side
Lens Refraction Calculator - Ray Diagrams | MathCalcLab | MathCalcLab