MathemagiciansLibraryExplorationsDeep Dives
← Physics · Pre-University
PhysicsPre-University

The lens equation and magnification

PP3 — Waves and Optics › PP3.2 — Geometric and Physical OpticsLecture 3 of 4~2580 words

Two careful students, two different answers

An object stands 30 cm in front of a converging lens of focal length 10 cm. Two students, Rohan and Ama, use the same lens equation to find the image.

Rohan reasons like this: "The object is on the side the light comes from, so its distance is negative. I put cm." He gets cm.

Ama puts cm into the same equation. She gets cm.

The last lecture drew this exact situation as a ray diagram. The rays met 15 cm behind the lens. So Ama is right. But Rohan's arithmetic is correct, and his reason sounds sensible. So where did he go wrong?

The answer is the hard part of this lecture, and it is not the algebra. An optics equation has two parts: the equation itself, and a rule that says what a plus or minus sign means. Use the equation with the wrong rule, and it gives a wrong answer with complete confidence. This lecture builds both parts from the ray diagram, so you can see why they belong together.

From the ray diagram to an equation

The last lecture promised to turn the ray diagram into an equation. Here it is. Use two of the three special rays, from the top of an object of height . The object is a distance from the lens, and the image is a distance behind it, with height .

F F h h′ u v f object image
Ray 3 (through the centre) makes the two blue triangles. Ray 1 (parallel, then through F) makes the two grey triangles, which meet at F. The image height h′ is below the axis, so it is negative. Heights are drawn larger than distances.

Ray 3 gives the size. The ray through the centre goes straight on. It makes two triangles with the axis, one on each side of the lens, with the same angle at the centre. So they are similar. The object triangle has sides and . The image triangle has sides and , and the image is upside down. So

The minus sign records that the image is on the other side of the axis.

Ray 1 gives the position. This ray leaves the lens at height and passes through . It makes two more similar triangles, which meet at . The first has height and base . The second has height and base . So

Put the two together. Both lines describe the same ratio . So . Now divide every term by :

That is it. That is the whole idea. Two pairs of similar triangles, and every image position for every object is in one line.

The thin lens equation (real-is-positive)

and magnification

: positive for a real object. : positive for a real image, on the far side of the lens; negative for a virtual image, on the same side as the object. : positive for a converging lens, negative for a diverging lens. A negative means an inverted image.

Valid for a thin lens and rays close to the axis.

Why the signs are part of the equation

The derivation above used a real image. Now redo it for a magnifying glass, with the object inside . The rays leave the lens spreading out, and the image is found by tracing them back. The same two pairs of similar triangles appear, but the image now lies in front of the lens. Its distance is measured the other way.

If you carry that through with plain distances, you get a second equation: . A diverging lens gives a third one. Three equations for three cases would be easy to mix up.

The sign rule removes them. Count a distance measured "the other way" as negative. Then all three equations become the same equation. This is exactly what "real-is-positive" means. Real distances (where light really goes) are positive. Virtual distances (where light only seems to come from) are negative. The minus signs are not decoration. They are how one equation holds three diagrams.

Now Rohan's mistake is clear. He used a different rule. Many textbooks use the Cartesian convention, which measures every distance like a coordinate: left of the lens is negative. There a real object has cm, but the equation is also different: , with . With that equation, cm gives cm too. Each convention is a package. Its sign rule and its equation were built together. Rohan took the sign rule from one package and the equation from the other.

This library uses real-is-positive. If your textbook uses Cartesian signs, the physics is the same. Use one package from start to finish.

Spot the error — Rohan's working

Here is Rohan's working, line by line. He uses the real-is-positive equation. Tap the line where the mistake happens.

Rohan's working for an object 30 cm from a converging lens with f = 10 cm. The mistake is in line 2.

  1. The lens is converging, so f = +10 cm. (Correct.)
  2. The object is on the side the light comes from, so u = −30 cm. (The mistake: in real-is-positive, a real object has u = +30 cm.)
  3. 1/u + 1/v = 1/f, so 1/v = 1/f − 1/u. (Correct rearrangement.)
  4. 1/v = 1/10 − 1/(−30) = 1/10 + 1/30 = 4/30. (Correct arithmetic from the wrong u.)
  5. v = 30/4 = 7.5 cm. (Follows from line 4.)
  6. m = −v/u = −7.5/(−30) = +0.25, so the image is upright. (Follows, and it is a warning sign: a real image is always inverted.)

Notice the last line. An upright real image is impossible for one lens, as the last lecture showed with ray 3. So a quick look at the answer would have caught the error. Always ask: does the sign of and the sign of match the picture I expect?

Reading the answer

Once the signs are agreed, the answer describes the image completely.

Look at with positive. A positive always gives a negative . So every real image is inverted. A negative always gives a positive , so every virtual image is upright. You do not need to learn these as separate facts. The equation carries them.

The explorer below shows the whole story at once. It plots against for a lens with cm.

Graph builder — every object position at once

Move the object distance u, or use − and +. The point moves along the graph of v against u for a lens with f = 10 cm. Then switch to the second graph, which plots 1/v against 1/u.


The image distance v against the object distance u for a converging lens with f = 10 cm, with a table of values.

−40 −20 20 40 60 20 30 40 50 (30, 15) (15, 30) (5, −10) u = f v = f u in cm v in cm real image above the axis · virtual image below
For u > f the image is real (v > 0); it comes in from very far away towards F as the object moves out. For u < f the image is virtual (v < 0). Neither branch ever crosses the dashed lines u = f and v = f.
u (cm)v (cm)mImage1/u, 1/v (cm⁻¹)
5012.5−0.25real, inverted, smaller0.020, 0.080
3015−0.5real, inverted, smaller0.033, 0.067
2020−1real, inverted, same size0.050, 0.050
1530−2real, inverted, larger0.067, 0.033
10no image—rays leave parallel0.100, 0
5−10+2virtual, upright, larger0.200, −0.100

In the last column, every row has 1/u + 1/v = 0.1 cm⁻¹. Plotted as 1/v against 1/u, the points lie on one straight line that meets both axes at 1/f = 0.1 cm⁻¹.

The first graph has two separate branches. As the object comes in from far away towards , the image moves out from and runs off to infinity. At there is no image. Inside , the image is virtual and appears on the other branch. The ray diagrams of the last lecture are all points on this one curve.

The second graph is a straight line. The equation says , which is a line with gradient . It meets both axes at . This is how a laboratory measures a focal length well. Measure and for six or seven object positions. Plot against . Draw the best straight line, and read from where it crosses the axes. One reading can be wrong. A line through seven readings averages out the errors.

Stop and think

An object 20 cm from a lens with cm gives a real image 20 cm away. Now swap them: put the object where the image was. Where is the new image? What about an object at 30 cm, whose image is at 15 cm?

Show the answer

The equation does not change when and are swapped, because is the same either way. So an object at 15 cm gives an image at 30 cm, and an object at 30 cm gives an image at 15 cm. This is the reversibility of light from the last lecture, now inside the equation. Only the magnification changes: it becomes instead of .

Power, and the lens in your eye

Opticians do not use focal length. They use the power of a lens, , with in metres. The unit is the dioptre (D). A lens with m has power D. A diverging lens with m has power D. A shorter focal length bends light more strongly, so it has more power.

Your eye is a lens system with a fixed distance to the retina. So cannot change. Look at the equation in power form, with and in metres:

For a very distant object, is almost zero. For an object 0.25 m away, D. So to focus on the near object, the eye must add 4 D of power. It does this by accommodation: the ciliary muscle lets the lens inside the eye become more curved. The extra power an eye can add is its amplitude of accommodation, and the nearest point it can focus on is its near point.

This amplitude falls with age, because the lens slowly stiffens. One widely used estimate (Hofstetter, 1950) puts the average at about dioptres. That is about 14 D at age 15, so the near point is about 7 cm. At age 50 it is about 3.5 D, so the near point is about 29 cm. This is why many people need reading glasses in their forties and fifties. Physics problems use 25 cm as the standard near point of an adult eye.

The equation also explains the two common faults.

Worked examples

Worked Example 1 — The object beyond 2F, by equation

An object 2.0 cm tall is 30 cm from a converging lens with cm. Find the image.

Real-is-positive: cm, cm.

, so cm.

Do not stop at . Turn the fraction over to get .

, so cm.

Answer: a real image 15 cm behind the lens, inverted, 1.0 cm tall. This is exactly the last lecture's ray diagram. ✓

Worked Example 2 — The magnifying glass

The same object is 5.0 cm from the same lens. Find the image.

, so cm.

The negative sign is not a mistake. It says that the image is virtual, 10 cm in front of the lens, on the object's side.

. The image is upright and twice as tall: 4.0 cm. This matches the last lecture's ray diagram. ✓

Worked Example 3 — A diverging lens

An object is 30 cm from a diverging lens with cm. Find the image.

, so cm.

. The image is virtual, upright and smaller, 12 cm in front of the lens.

Check: it lies between the lens and , as every diverging-lens image does. The last lecture's diverging example ( cm, cm) gives , so cm, the value found there by drawing. ✓

Worked Example 4 — Designing a projector

A lens must project a picture of a small slide onto a screen 1.2 m away, 4 times larger. Find where the slide goes and the focal length needed.

The image on a screen is real, so it is inverted: . Then , so m.

D, so m = 24 cm.

Check: the slide at 30 cm is between (24 cm) and (48 cm), which is the projector position in the last lecture's table. ✓

Worked Example 5 — Glasses for short sight

A short-sighted student has a far point of 2.0 m. What lens lets her see distant objects clearly? Ignore the small gap between the glasses and the eye.

The lens must take an object at a very large distance () and make a virtual image at 2.0 m: m.

D, so m. A diverging lens of power D.

Check: a diverging lens makes distant objects look as if they are at its focus, 2.0 m away, which is just where her eye can focus. ✓

Three traps

Trap 1 — Mixing two conventions

A negative for a real object belongs to the Cartesian equation . Put it into and the answer is wrong, as Rohan found. Choose one convention and use its sign rule with its own equation.

Trap 2 — "A negative answer means I made a mistake"

A negative is a virtual image. It is the right answer whenever the lens is diverging or the object is inside . Read the sign; do not remove it.

Trap 3 — Power with focal length in centimetres

gives dioptres only when is in metres. A lens with cm has D, not D.

Try it yourself

Work each one on paper first. Open a hint only when you are stuck. Use real-is-positive throughout.

  1. An object is 20 cm from a converging lens with cm. Find the image position and magnification, and describe the image.

    Hint 1

    cm and cm. Rearrange to .

    Hint 2

    Use 60 as the common denominator.

    Full answer

    , so cm. .

    The image is real, 60 cm behind the lens, inverted and 3 times larger.

    Check: the object is between (15 cm) and (30 cm), so the image should be beyond and larger. It is. ✓

  2. A magnifying glass has cm. A stamp is held 12 cm from it. Where is the image, and how many times larger is it?

    Hint 1

    The stamp is inside , so expect a negative .

    Hint 2

    . Use 60 as the common denominator.

    Full answer

    , so cm. .

    The image is virtual, 30 cm from the lens on the stamp's side, upright and 2.5 times larger.

    Check: . ✓

  3. A long-sighted man has a near point of 1.0 m. He wants to read a book held 25 cm away. Find the power and focal length of the reading glasses he needs. Ignore the gap between the glasses and the eye.

    Hint 1

    The glasses must take the book (a real object at 0.25 m) and make an image where his eye can focus. Is that image real or virtual?

    Hint 2

    The image is on the book's side, so it is virtual: m. Then .

    Full answer

    m and m. So D, and m ≈ 33 cm. He needs converging lenses of power +3 D.

    Check: . The print appears upright and 4 times taller, but 4 times further away, so it looks the same size to him. It is now at a distance his eye can focus on. ✓

  4. A lamp and a screen are fixed 45 cm apart. A lens with cm is moved between them. Show that there are two positions where a sharp image forms, and find the magnification at each. Then show that no sharp image is possible if the lamp and screen are less than 40 cm apart.

    Hint 1

    You have two equations: and .

    Hint 2

    The second equation is , so . So and are the roots of . For a general separation , the equation is .

    Full answer

    From and , we get . So and are the roots of , which factorises as .

    Position 1: cm, cm, . Position 2: cm, cm, . These are the two swapped positions from the Stop-and-think. Notice that the two magnifications multiply to 1.

    For a separation , the quadratic is . It has real roots only if its discriminant , which means cm. With the lamp and screen closer than 40 cm, no lens position works. At exactly 40 cm there is one position, cm (), with .

    Check: . ✓

The bigger idea

The lens equation came from two pairs of similar triangles. It was not memorised and it was not guessed. The sign rule then let one equation do the work of three. This is a pattern you will meet across physics. In mechanics, a single rule for the direction of positive displacement lets one set of motion equations cover a ball going up and coming down. In circuits, a chosen direction for current lets one set of equations handle currents that turn out to flow the other way. In each case, the convention is a choice, but it must be made once and kept.

The next lecture shows that a curved mirror forms images by the same geometry. Its equation has the same form, and the same care with signs makes it work.

Key concepts in this lesson