Skip to content

Thin Lens Equation Calculator

Solve 1/f = 1/dₒ + 1/dᵢ for the image distance, the focal length or the object distance of a thin lens or a spherical mirror. You also get the magnification, the image height, whether the image is real or virtual, upright or inverted, and a ray diagram with the three principal rays. The sign convention is stated, so the signs always make sense. Free, no sign-up.

Lens or mirror?
What do you want to find?
Try an example

Used for the image height and the drawing.

Type

Converging = convex lens; diverging = concave lens.

Results

16.67 cm

Image distance (dᵢ)

10 cm

Focal length (f)

25 cm

Object distance (dₒ)

-0.6667

Magnification (m)

-3.333 cm

Image height (hᵢ)

10 D

Optical power (1/f)

The image is

real, inverted, reduced

The image forms on the far side of the lens

Ray diagram with the three principal raysAn object arrow, the lens or mirror, and its image, with three principal rays: one parallel to the axis, one through the centre and one through the focal point.FFObjectImage

The working

  1. 1/dᵢ = 1/f − 1/dₒ = 1/10 cm − 1/25 cm → dᵢ = 16.67 cm
  2. m = −dᵢ ÷ dₒ = −(16.67 cm) ÷ 25 cm = -0.6667
  3. hᵢ = m × hₒ = -0.6667 × 5 cm = -3.333 cm

Sign convention (real is positive): f is positive for a converging lens or mirror and negative for a diverging one; dₒ is positive for a real object; dᵢ is positive for a real image and negative for a virtual one; a negative magnification means the image is inverted.

How to Use the Thin Lens Equation Calculator

  1. 1. Choose a lens or a mirror, and what to find. The image distance is the usual unknown; you can instead find the focal length from a measured object and image, or the object distance for a wanted image.
  2. 2. Say whether it is converging or diverging. Converging means a convex lens or concave mirror; diverging means a concave lens or convex mirror. Type the focal length as a plain size and the calculator applies the sign.
  3. 3. Enter the distances and the object height. Use mm, cm or m for each box. The object height only scales the image height and the drawing.
  4. 4. Read the image. You get the distance, magnification, image height, optical power and a plain-language description such as "real, inverted, reduced", together with the working and a ray diagram.

The Equation and Its Sign Convention

For a thin lens or a mirror with small angles, 1/f = 1/dₒ + 1/dᵢ, where f is the focal length, dₒ the distance from the element to the object and dᵢ the distance to the image. The magnification is m = −dᵢ ÷ dₒ, and the image height is hᵢ = m × hₒ. The same equations serve lenses and mirrors; only the side on which a real image forms differs.

QuantityPositive whenNegative when
Focal length fConverging: convex lens, concave mirrorDiverging: concave lens, convex mirror
Object distance dₒReal object in front of the elementVirtual object (not used here)
Image distance dᵢReal image: far side of a lens, front of a mirrorVirtual image: same side as the object for a lens, behind a mirror
Magnification mUpright imageInverted image

Other sign conventions

This is the "real is positive" convention taught in many introductory physics courses. Some textbooks (the New Cartesian convention, common in Indian curricula) instead measure distances from the element along the direction of the light, making dₒ negative and giving a concave mirror a negative f. The physical results — image position, size and nature — are identical; only the signs and the form of the equation change, so check which convention your course uses.

What the Image Will Be Like

ElementObject positionImage
ConvergingBeyond 2fReal, inverted, reduced
ConvergingAt 2fReal, inverted, same size
ConvergingBetween f and 2fReal, inverted, magnified
ConvergingAt fNo image: rays leave parallel
ConvergingInside fVirtual, upright, magnified (a magnifying glass)
DivergingAnywhereVirtual, upright, reduced

Worked Examples

  • A converging lens, f = 10 cm, object at 25 cm (the starting example): 1/dᵢ = 1/10 − 1/25 = 0.06 per cm, so dᵢ = 16.67 cm. The magnification is −16.67 ÷ 25 = −0.6667, so a 5 cm object gives a −3.333 cm image: real, inverted and reduced, on the far side of the lens.
  • A magnifying glass, f = 10 cm, object at 6 cm: dᵢ = −15 cm, so the image is virtual, on the same side as the object, and m = +2.5, upright and magnified.
  • A diverging lens, f = −10 cm, object at 25 cm: dᵢ = −7.143 cm and m = +0.2857, a virtual, upright, reduced image whatever the distance.
  • A 50 mm camera lens focused on a person 2 m away: dᵢ = 51.28 mm and m = −0.02564, so a 1.8 m person makes a 46.15 mm inverted image on the sensor.

Frequently Asked Questions

What is the thin lens equation?
1/f = 1/dₒ + 1/dᵢ, relating the focal length f to the object distance dₒ and image distance dᵢ. Solve for the image distance with dᵢ = f × dₒ ÷ (dₒ − f). It also applies to spherical mirrors for rays close to the axis.
How do I know if the image is real or virtual?
A positive image distance means a real image: the light rays actually meet there, and a screen can show it. A negative image distance means a virtual image: the rays only appear to come from it, so it can be seen by looking into the lens or mirror but not projected.
What does a negative magnification mean?
That the image is inverted (upside down) relative to the object. A positive magnification means upright. The size of the number tells you the scale: m = −2 is twice as large and inverted, m = 0.5 is half the size and upright.
What happens when the object is at the focal point?
The rays leave the lens or mirror parallel to each other, so they never meet and the image is at infinity. In the equation, dₒ − f = 0, which would need a division by zero, and the calculator reports that no image forms.
Is the mirror equation the same as the lens equation?
Yes, 1/f = 1/dₒ + 1/dᵢ for both. For a spherical mirror f is half the radius of curvature, f = R ÷ 2. The difference is geometric: a mirror forms its real image in front of the mirror, a lens on the far side.
What is the unit of lens power?
The dioptre (D), equal to 1 ÷ f with f in metres. A 10 cm focal-length lens has a power of +10 D; a −50 cm diverging lens has −2 D. Eyeglass prescriptions are written in dioptres.

Related Tools

More in Science & Lab Calculators

See all Science & Lab Calculators