Skip to content
MasterMath

Lens Calculator

The thin lens equation relates focal length, object distance and image distance. It covers cameras, glasses and the eye.

Result

—

How this was worked out

    The formula

    1/f = 1/o + 1/i

    SymbolQuantityUnit
    fFocal lengthcm
    oObject distancecm
    iImage distancecm

    What it means

    The reciprocal of the focal length equals the sum of the reciprocals of the object and image distances. Working in reciprocals looks awkward and is what makes the relationship so simple.

    How to work it out by hand

    1. Take the reciprocal of the focal length
    2. Subtract the reciprocal of the object distance
    3. Take the reciprocal of the result for the image distance

    What is worth knowing

    The sign conventions carry the physics and are where the mistakes live: a positive focal length is a converging lens and a negative one diverges, while a negative image distance means the image is virtual — on the same side as the object, like the one in a magnifying glass. Optometrists work in dioptres, which is simply the reciprocal of the focal length in metres, so a +2 dioptre lens has a 50 cm focal length. That is also why prescriptions add so conveniently: reciprocals of focal lengths sum directly.

    Frequently asked questions

    What is a dioptre?

    The reciprocal of the focal length in metres. A +2 dioptre lens focuses at 50 cm, and prescriptions add directly because reciprocals do.

    What is the difference between a real and a virtual image?

    A real image can be projected onto a screen; a virtual one cannot. A negative image distance means it is virtual.

    What does a negative focal length mean?

    A diverging lens, which spreads light rather than focusing it. It is used to correct short-sightedness.

    Does this work for mirrors?

    The same equation applies to spherical mirrors with their own sign conventions, which is why it is often taught alongside them.