All Tools

Lens & Mirror Image Formation Tool

Enter the focal length and object distance to find the image position, magnification, and whether the image is real or virtual. Drag the object on the ray diagram to explore how lenses and mirrors form images. All calculations run in your browser.

Ray Diagram

cm
cm
Image Distance (dᵢ)
20 cm
Magnification (M)
-1×
Image Height
2 cm
RealInvertedSame Size

Reference Guide

The Thin Lens Equation

The thin lens equation relates three quantities: focal length, object distance, and image distance. It applies to any thin lens where the thickness is small compared to the focal length.

1f=1do+1di\frac{1}{f} = \frac{1}{d_o} + \frac{1}{d_i}
Variables
  • ff is the focal length of the lens
  • dod_o is the object distance (from lens to object)
  • did_i is the image distance (from lens to image)

A positive did_i means a real image forms on the opposite side of the lens from the object. A negative did_i means a virtual image forms on the same side as the object.

The Mirror Equation

Mirrors follow the same formula as lenses. The difference is in how the sign conventions work for curved mirrors.

1f=1do+1di\frac{1}{f} = \frac{1}{d_o} + \frac{1}{d_i}
Sign conventions
  • Concave mirror has f>0f > 0 because it converges light
  • Convex mirror has f<0f < 0 because it diverges light

The focal length of a mirror equals half its radius of curvature: f=R/2f = R/2. Concave mirrors can form both real and virtual images depending on the object position, while convex mirrors always produce virtual images.

Magnification

Magnification tells you how the image size compares to the object. It can be expressed as a ratio of distances or heights.

M=dido=hihoM = -\frac{d_i}{d_o} = \frac{h_i}{h_o}
Interpreting magnification
  • M>0M > 0 means the image is upright (same orientation as the object)
  • M<0M < 0 means the image is inverted (flipped upside down)
  • M>1|M| > 1 means the image is enlarged (bigger than the object)
  • M<1|M| < 1 means the image is reduced (smaller than the object)
  • M=1|M| = 1 means the image is the same size as the object

Image Characteristics

You can determine everything about the image from the signs of did_i and MM.

Condition Image type Meaning
di>0d_i > 0 Real Light converges to form the image
di<0d_i < 0 Virtual Light appears to diverge from the image
M>0M > 0 Upright Image has the same orientation as the object
M<0M < 0 Inverted Image is flipped relative to the object

When do=fd_o = f, the denominator in the lens equation goes to zero, so no image forms. The outgoing rays are parallel, and the image is said to be at infinity.