We have seen that sometimes double integrals are simplified by doing them in polar coordinates; not surprisingly, triple integrals are sometimes simpler in cylindrical coordinates or spherical coordinates. To set up integrals in polar coordinates, we had to understand the shape and area of a typical small region into which the region of integration was divided. We need to do the same thing here, for three dimensional regions.
The cylindrical coordinate system is the simplest, since it is just the polar coordinate system plus a $z$ coordinate. A typical small unit of volume is the shape shown in figure 17.2.1 "fattened up'' in the $z$ direction, so its volume is $r\Delta r\Delta \theta\Delta z$, or in the limit, $r\,dr\,d\theta\,dz$.
Example 17.6.1 Find the volume under $z=\sqrt{4-r^2}$ above the quarter circle inside $x^2+y^2=4$ in the first quadrant.
We could of course do this with a double integral, but we'll use a triple integral: $$\int_0^{\pi/2}\int_0^2\int_0^{\sqrt{4-r^2}} r\,dz\,dr\,d\theta= \int_0^{\pi/2}\int_0^2 \sqrt{4-r^2}\; r\,dr\,d\theta= {4\pi\over3}.$$ Compare this to example 17.2.1. $\square$
Example 17.6.2 An object occupies the space inside both the cylinder $x^2+y^2=1$ and the sphere $x^2+y^2+z^2=4$, and has density $x^2$ at $(x,y,z)$. Find the total mass.
We set this up in cylindrical coordinates, recalling that $x=r\cos\theta$: $$\eqalign{ \int_0^{2\pi}\int_0^1\int_{-\sqrt{4-r^2}}^{\sqrt{4-r^2}} r^3\cos^2(\theta)\,dz\,dr\,d\theta &=\int_0^{2\pi}\int_0^1 2\sqrt{4-r^2}\;r^3\cos^2(\theta)\,dr\,d\theta\cr &=\int_0^{2\pi} \left({128\over15}-{22\over5}\sqrt3\right)\cos^2(\theta)\,d\theta\cr &=\left({128\over15}-{22\over5}\sqrt3\right)\pi\cr }$$ $\square$
Spherical coordinates are somewhat more difficult to understand. The small volume we want will be defined by $\Delta\rho$, $\Delta\phi$, and $\Delta\theta$, as pictured in figure 17.6.1. The small volume is nearly box shaped, with 4 flat sides and two sides formed from bits of concentric spheres. When $\Delta\rho$, $\Delta\phi$, and $\Delta\theta$ are all very small, the volume of this little region will be nearly the volume we get by treating it as a box. One dimension of the box is simply $\Delta\rho$, the change in distance from the origin. The other two dimensions are the lengths of small circular arcs, so they are $r\Delta\alpha$ for some suitable $r$ and $\alpha$, just as in the polar coordinates case.
The easiest of these to understand is the arc corresponding to a change in $\phi$, which is nearly identical to the derivation for polar coordinates, as shown in the left graph in figure 17.6.2. In that graph we are looking "face on'' at the side of the box we are interested in, so the small angle pictured is precisely $\Delta\phi$, the vertical axis really is the $z$ axis, but the horizontal axis is not a real axis—it is just some line through the origin in the $x$-$y$ plane. Because the other arc is governed by $\theta$, we need to imagine looking straight down the $z$ axis, so that the apparent angle we see is $\Delta\theta$. In this view, the axes really are the $x$ and $y$ axes. In this graph, the apparent distance from the origin is not $\rho$ but $\rho\sin\phi$, as indicated in the left graph.
The upshot is that the volume of the little box is approximately $\Delta\rho(\rho\Delta\phi)(\rho\sin\phi\Delta\theta) =\rho^2\sin\phi\Delta\rho\Delta\phi\Delta\theta$, or in the limit $\rho^2\sin\phi\,d\rho\,d\phi\,d\theta$.
Example 17.6.3 Suppose the temperature at $(x,y,z)$ is $T=1/(1+x^2+y^2+z^2)$. Find the average temperature in the unit sphere centered at the origin.
In two dimensions we add up the temperature at "each'' point and divide by the area; here we add up the temperatures and divide by the volume, $(4/3)\pi$: $${3\over4\pi}\int_{-1}^1\int_{-\sqrt{1-x^2}}^{\sqrt{1-x^2}} \int_{-\sqrt{1-x^2-y^2}}^{\sqrt{1-x^2-y^2}} {1\over1+x^2+y^2+z^2}\,dz\,dy\,dx $$ This looks quite messy; since everything in the problem is closely related to a sphere, we'll convert to spherical coordinates. $${3\over4\pi}\int_0^{2\pi}\int_0^\pi \int_0^1 {1\over1+\rho^2}\,\rho^2\sin\phi\,d\rho\,d\phi\,d\theta ={3\over4\pi}(4\pi -\pi^2)=3-{3\pi\over4}. $$ $\square$
Exercises 17.6
Here is a Sage cell if you'd like to use it.
Ex 17.6.1 Evaluate $\ds\int_{0}^{1}\int_{0}^{x}\int_{0}^{\sqrt{x^2+y^2}} {(x^2+y^2)^{3/2}\over x^2+y^2+z^2}\,dz\,dy\,dx$. (answer)
Ex 17.6.2 Evaluate $\ds\int_{-1}^{1}\int_{0}^{\sqrt{1-x^2}} \int_{\sqrt{x^2+y^2}}^{\sqrt{2-x^2-y^2}}\sqrt{x^2+y^2+z^2}\,dz\,dy\,dx$. (answer)
Ex 17.6.3 Evaluate $\ds\int\int\int x^2\,dV$ over the interior of the cylinder $x^2+y^2=1$ between $z=0$ and $z=5$. (answer)
Ex 17.6.4 Evaluate $\ds\int\int\int xy\,dV$ over the interior of the cylinder $x^2+y^2=1$ between $z=0$ and $z=5$. (answer)
Ex 17.6.5 Evaluate $\ds\int\int\int z\,dV$ over the region above the $x$-$y$ plane, inside $x^2+y^2-2x=0$ and under $x^2+y^2+z^2=4$. (answer)
Ex 17.6.6 Evaluate $\ds\int\int\int yz\,dV$ over the region in the first octant, inside $x^2+y^2-2x=0$ and under $x^2+y^2+z^2=4$. (answer)
Ex 17.6.7 Evaluate $\ds\int\int\int x^2+y^2\,dV$ over the interior of $x^2+y^2+z^2=4$. (answer)
Ex 17.6.8 Evaluate $\ds\int\int\int \sqrt{x^2+y^2}\,dV$ over the interior of $x^2+y^2+z^2=4$. (answer)
Ex 17.6.9 Compute $\ds\int\int\int x+y+z\,dV$ over the region inside $x^2+y^2+z^2 = 1$ in the first octant. (answer)
Ex 17.6.10 Find the mass of a right circular cone of height $h$ and base radius $a$ if the density is proportional to the distance from the base. (answer)
Ex 17.6.11 Find the mass of a right circular cone of height $h$ and base radius $a$ if the density is proportional to the distance from its axis of symmetry. (answer)
Ex 17.6.12 An object occupies the region inside the unit sphere at the origin, and has density equal to the distance from the $x$-axis. Find the mass. (answer)
Ex 17.6.13 An object occupies the region inside the unit sphere at the origin, and has density equal to the square of the distance from the origin. Find the mass. (answer)
Ex 17.6.14 An object occupies the region between the unit sphere at the origin and a sphere of radius 2 with center at the origin, and has density equal to the distance from the origin. Find the mass. (answer)
Ex 17.6.15 An object occupies the region in the first octant bounded by the cones $\phi = \pi/4$ and $\phi = \arctan 2$, and the sphere $\rho = \sqrt{6}$, and has density proportional to the distance from the origin. Find the mass. (answer)