Formula for a thin lens
Using the real is positive - virtual is negative sign convention the formula for a thin lens can be shown to be: 
Lens formula:	
   1/object distance (u) + 1/image distance (v) = 1/focal length 
1/u + 1/v = 1/f
This applies to all 
types of lens as long as the correct sign convention is used when substituting values for the 
distances.
(Reminder: we use the 'real is positive, virtual is negative' sign 
convention.)
For a treatment using waves and the curvature of the lens surface see 
Lenses and waves)
Two proofs of the formula will be given here, one a geometrical proof 
and the other an optical version.
(a) Geometrical proof of the lens formula
 
Consider a plano-convex lens, as shown in Figure 1.
 
If we consider the action of the lens to be like 
that of a small-angle prism, then all rays have the same deviation. Therefore, in Figure 
2,
Deviation (d) = α + β and so for small angles   tan d = tan α 
+ tan β
Therefore:  h/f = h/u + h/v and so 1/f = 1/u + 1/v   
and the formula is proved.
Example problem
An object is placed in front of a converging lens and gives a real image with magnification 5; when the object is moved 6 cm along the axis of the lens a real image of magnification 2 is obtained. 
What is the focal length of the lens?
Let the initial object and image distances be u and v respectively.
 
Therefore v/u = 5, v = 5u, and v’/u + 6 = 2 where v' is the new image distance.
 Also:
1/u + 1/5u = 1/f  	  and 1/[u+6] + 1/[2u + 12]
These equations give:    6f = 5u and 3f = 2u + 12, and so f = 20 cm.
(b) Optical proof of the lens formula
We will 
only consider the case for a biconvex lens here. (see Figure 3). 
 
Consider the two spherical surfaces of the lens. 
For the first surface we have
n
2/v' + n
1/u = [n
2 – 
n
1]/R
1	For the second surface we have
n
2/-v' + 
n
1/v = [n
2 – n
1]/R
2(note the negative sign denoting a 
virtual object for the second surface). 
Combining these two equations gives: 
n1/u   + n1/v + = [n2 – n1][1/R1 + 1/R2 ] =n1/f
If n
1 = 1 (i.e. the 
lens is in air) the formula becomes:
1/u + 1/v = 1/f
This formula could be 
used to calculate the refractive index (n
2) of the glass of the lens.
 
A VERSION IN WORD IS AVAILABLE ON THE SCHOOLPHYSICS USB