Depth of Field
Introduction
The depth of field (DOF) is the distance between the nearest and the farthest objects that are in acceptably sharp focus in an image captured with a camera. By definition, a photo that has a shallow DOF has the main subject in focus, while the background and foreground are blurred, and a photo that has a deep DOF has most of the objects in focus.
When the photo captures a scene of a landscape, a deep DOF is usually preferred, because it can show the details of the whole scene. When the photo captures a portrait or a specific object of interest, a shallow DOF is usually preferred, because it can highlight the main subject and blur the background and foreground.
There are a few key factors that affect the DOF of a photo, including the aperture, the focal length, the distance between the camera and the subject. In this blog post, I would like to derive the DOF equation, which is a function of the aperture, the focal length, the distance between the camera and the subject.
Thin Lens Equation
The thin lens equation is the fundamental equation that is used for deriving the DOF equation.
Assuming the thickness of the lens is infinitely small, the thin lens equation
where

Thin Lens Diagram
The proof of the thin lens equation can be found in my previous blog post “How Camera Lens Works”.
Circle of Confusion
In the above diagram, because the focal length
But what if the thin lens equation is not satisfied, each point in the object
The diameter of the circle can be quantified mathematically.
Assuming the lens is set up in a way such that the focal length
Suppose there is another object
It is also straightforward to see that the image distance to lens
Similarly suppose there is another object
It is also straightforward to see that the image distance to lens
Because the image distance to lens
Assuming the aperture
After some simplification, we have
Given the circle of confusion
This means, as long as the object whose image distance to lens is within the range
For camera lens, it is more common to use
Using the
Accordingly, the range of the object distance to lens that the object will look sharp in the image can be computed using the thin lens equation.
Depth of Field Equation
The depth of field (DOF) is the distance between the nearest and the farthest objects that are in acceptably sharp focus in an image captured with a camera. Therefore, based on the setup in the previous section, the DOF can be defined mathematically as
Using the derived equations of
With some additional assumptions, this DOF equation can be simplified further to a form that we commonly see in photography.
Assuming
where
Let’s also examine the feasibility of the assumption
Based on the simplified DOF equation, we can see that the DOF is proportional to the square of the distance between the camera and the object, the
Depth of Field Simulator
The Depth of Field Simulator created by Jack Herrington can be used for photographers to understand how the DOF changes with the distance between the camera and the object, the
FAQs
Why Does Full Frame Camera Usually Have Shallower Depth of Field Than Crop Sensor Camera?
The full frame camera has a larger sensor size than the crop sensor camera. Therefore, the full frame camera usually has a longer focal length lens for the same field of view. According to the DOF equation, the DOF is inversely proportional to the square of the focal length of the lens. Therefore, the full frame camera usually has a shallower DOF than the crop sensor camera.
Why Does Cell Phone Camera Usually Have a Deep Depth of Field?
The cell phone camera usually has a small aperture (large
Conclusions
In photography, because of the depth of field (DOF) equation, we have the following consequences.
- Moving the camera closer to the object can cause blurring in the background and foreground of the picture, producing a shallow DOF. Moving away from your subject has the opposite effect; the entire picture comes into focus, providing a deep DOF.
- Using a larger aperture (smaller
-stop) can cause blurring in the background and foreground of the picture, producing a shallow DOF. Using a smaller aperture (larger -stop) has the opposite effect; the entire picture comes into focus, providing a deep DOF. - Using a lens with a longer focal length can cause blurring in the background and foreground of the picture, producing a shallow DOF. Using a lens with a shorter focal length has the opposite effect; the entire picture comes into focus, providing a deep DOF.
To select lenses, we want to have longer focal length and smaller
References
Depth of Field