Lens Equation Calculator
Work out where a thin lens forms an image and how large it is from focal length (mm), object distance (mm). 1/f = 1/do + 1/di; magnification = −di/do, and the page prints the substitution so the result can be checked by hand.
Lens Equation Calculator
Work out where a thin lens forms an image and how large it is from focal length (mm), object distance (mm). 1/f = 1/do + 1/di; magnification = −di/do, and the page prints the substitution so the result can be checked by hand.
How this page computes
1/f = 1/do + 1/di; magnification = −di/do
A negative magnification means an inverted, real image. A positive one means a virtual image on the same side as the object, which is what a magnifying glass produces when the object is inside the focal length.
This is the thin-lens equation: it treats the lens as one plane and ignores its thickness and aberrations.
The calculation runs entirely in this browser tab; nothing is uploaded.
Lens Equation Calculator computes where a thin lens forms an image and how large it is. 1/f = 1/do + 1/di; magnification = −di/do. The page prints the rule, the numbers substituted into it and the result, so the arithmetic can be checked by hand.
A negative magnification means an inverted, real image. A positive one means a virtual image on the same side as the object, which is what a magnifying glass produces when the object is inside the focal length. Pressed with focal length 50, object distance 2000, it answers: Image distance = 51.282051 mm
How to use Lens Equation Calculator
Enter focal length 50, object distance 2000, then press Run: the page evaluates where a thin lens forms an image and how large it is and prints every line of the working. Typed input is read exactly as written, and a blank field is refused with its name.
Read the first line as the answer and the lines below it as the substitution. If a value is out of range the page refuses it by field and reason instead of printing a number.
With focal length 50, object distance 2000, the answer is Image distance = 51.282051 mm.
The sign of the magnification
A negative magnification means an inverted, real image. A positive one means a virtual image on the same side as the object, which is what a magnifying glass produces when the object is inside the focal length.
This is the thin-lens equation: it treats the lens as one plane and ignores its thickness and aberrations.
What to Expect
Best for
- Working out where a thin lens forms an image and how large it is without a spreadsheet
- Checking a figure someone else quoted
- Seeing the formula behind an answer
Not ideal for
- An object distance of zero, or exactly the focal length, is refused: the image is at the lens or at infinity, and neither is a finite distance.
- A quantity the page cannot compute, which it refuses instead of estimating
- Rounding an answer that has an exact form
What this tool keeps
- 1/f = 1/do + 1/di; magnification = −di/do
- Every input exactly as typed
What may need cleanup
- Nothing: the printed answer is the final output
- A unit conversion, if the inputs were entered in different units
Common errors
- An object distance of zero, or exactly the focal length, is refused: the image is at the lens or at infinity, and neither is a finite distance.
- An empty field is refused with the field's name
Example use cases
- Work out where a thin lens forms an image and how large it is for one set of inputs
- Check the result against the formula by hand
- See which input the answer is most sensitive to
Sample input
Lens Equation Calculator: focal length 50, object distance 2000
Sample output
Image distance = 51.282051 mm — 1/f = 1/do + 1/di, so di = 1 ÷ (1/50 − 1/2000) = 51.28205128 mm
Who this is for
- Students checking a formula
- Anyone who needs the number and the working
Frequently asked questions
What formula does this page use?
1/f = 1/do + 1/di; magnification = −di/do. The page prints the substitution as well, so the answer can be checked against the rule.
What does Lens Equation Calculator refuse?
An object distance of zero, or exactly the focal length, is refused: the image is at the lens or at infinity, and neither is a finite distance.
What does the default example give?
Focal length 50, object distance 2000 gives Image distance = 51.282051 mm. Every line below that restates the same arithmetic.
Build custom tools for your store
Join the SDK program to create useful ecommerce utilities for your store.