There are really two basic magnification equations: the lens equation and the magnification equation. Both are needed to compute the magnification of an object by a convex lens. The lens equation relates the focal length, determined by lens shape, to the distances between an object, the lens and the projected image. The magnification equation relates the heights and distances of the objects and images and defines M, the magnification. Both equations have several forms.
The Lens Equation
The lens equation says 1/f = 1/Do + 1/Di, where f is the focal length of the lens, Do is the distance from the object to the lens and Di is the distance from the lens to the in-focus projected image. This form of the lens equation gives rise to three computationally more useful forms by the algebraically straightforward solutions for the three variables. These forms are f = (Do * Di)/(Do + Di), Do = (Di * f)/(Di - f) and Di = (Do * f)/(Do - f). These three forms are much simpler to use if you have two of the variables and need to compute the third variable. The lens equation not only tells you how far the image will be from the object and lens, it can tell you what kind of lens to use if you know the distances.
The Magnification Equation
The magnification equation states that M = Hi/Ho = - Di/Do, where M is the magnification, Hi is the height of the image, Ho is the height of the object, Di is the distance from the lens to the image and Do is the distance of the object to the lens. The minus sign signifies the fact that the image will be inverted. The two equal signs means there are three immediate forms (and four more if you ignore M and solve for the four other variables), namely M = Hi/Ho, M = - Di/Do and Hi/Ho = - Di/Do.
Using the Equations
The lens equation can tell you what kind of lens to use if you know the distances involved. For example, if a camera will be shooting from 10 feet and projecting onto a film 6 inches away, the focal length of the lens should be f = (10 * 0.5)/(10 + 0.5) = 5/10.5 = 0.476, rounded to three places to match the accuracy of the input parameters. Using a straightforward rearrangement of one of the magnification equation forms, we can calculate the size of the image of an object on the camera film. Hi = - (Di * Ho)/Do = - (0.5 * Ho)/10 = - (1/20) * Ho. The image on the film will be 1/20 the size of the image it is photographing. The minus sign indicates the image will be inverted.
- lens image by Sergey Pesterev from Fotolia.com