Up until now, the integrand of the innermost integral has always been 1, so we really could have done all the double integrals as single integrals. The following example is one in which you really need to do iterated integrals.
Example 4[Moments of inertia] The moment of inertia is a measure of how difficult it is to start an object rotating (or stop it). For example, tightrope walkers carry long poles because they want something with a big moment of inertia. The moment of inertia is defined by I=\int R2 dm, where dm is the mass of an infinitesimally small portion of the object, and R is the distance from the axis of rotation.
To start with, let's do an example that doesn't require iterated integrals. Let's calculate the moment of inertia of a thin rod of mass M and length L about a line perpendicular to the rod and passing through its center.
Now let's do one that requires iterated integrals: the moment of inertia of a cube of side b, for rotation about an axis that passes through its center and is parallel to four of its faces.
Let the origin be at the center of the cube, and let x be the rotation axis.
The fact that the last step is a trivial integral results from the symmetry of the problem. The integrand of the remaining double integral breaks down into two terms, each of which depends on only one of the variables, so we break it into two integrals,
which we know have identical results. We therefore only need to evaluate one of them and double the result: