¡@

Triple Integrals in Spherical Coordinates

Download Maple Worksheet

Recall that the spherical coordinates  (rho, theta, phi) of a point P in space are shown below, where rho is the distance from the origin O to P, theta  is the same angle as in cylindrical coordinates, and phiis the angle between the positive z -axis and the line segment joining the origin and P.

The relationship between rectangular and spherical coordinates is given by the equations :

x = rho*sin(phi)*cos(theta)      y = rho*sin(phi)*sin(theta)       z = rho*cos(phi)

and  

rho^2 = x^2+y^2+z^2

[Maple Plot]

In spherical coordinates system the counterpart of a rectangular boxes is a spherical wedge  

[Maple OLE 2.0 Object]

as shown below :

[Maple Plot]
3DVIEW

It is sometimes difficult to evaluate the triple integral [Maple OLE 2.0 Object] using Cartesian coordinates. For example, f(x,y,z) = exp((x^2+y^2+z^2)^(3/2)) , where E is the unit ball:

E  = { ( x, y, z ) | x^2+y^2+z^2 <= 1 }

¡@

Note that in  the spherical coordinates

[Maple OLE 2.0 Object]

Although we defined the triple integrals by dividing solids into small rectangular boxes, it can be shown that dividing a solid into small spherical wedges always gives the same result.

[Maple Plot]
3DVIEW

We can see from the figure above that the length of the navy line segment is Delta*rho, the length of the green circular segment is rho*Delta*phi, and the length of the gold circular segment is r*Delta*theta , where r = rho*sin(phi) .

If   Delta*rho , Delta*theta , and Delta*phi  are small enough then the spherical wedge is approximately a rectangular box with dimension Delta*rho, rho*sin(phi)*Delta*theta , rho*Delta*phi . Hence an approximation of the volume of spherical wedge above is given by rho^2*sin(phi)*Delta*rho*Delta*theta*Delta*phi .

¡@

So if we divide E  into smaller spherical wedges E[i*j*k]  by means of equally spaced spheres rho = rho[i] , half planes theta = theta[j]   , and half-cones phi = phi[k] , then an approximation of the volume of E[i*j*k]  is

Delta*V[i*j*k] = rho[i]^2*sin(phi[k])*Delta*rho*Delta*theta*Delta*phi

and so [Maple OLE 2.0 Object]  is approximately equal to

sum(sum(sum(f(x[i*j*k],y[i*j*k],z[i*j*k])*Delta*V[i*j*k],i),j),k) = sum(sum(sum(f(x[i*j*k],y[i*j*k],z[i*j*k])*rho[i]^2*sin(phi[k])*Delta*rho*Delta*theta*Delta*phi,i),j),k)

¡@

Therefore, we have

[Maple OLE 2.0 Object] = int(int(int(f(rho*cos(theta)*sin(phi),rho*sin(theta)*sin(phi),rho*cos(phi))*rho^2*sin(phi),rho = a .. b),theta = alpha .. beta),phi = c .. d)

where [Maple OLE 2.0 Object] .

¡@

¡@

¡@

Now let's evaluate the integral

[Maple OLE 2.0 Object] ,

where f(x,y,z) = exp((x^2+y^2+z^2)^(3/2))   and E  = { ( x, y, z ) | x^2+y^2+z^2 <= 1 }.

¡@

[Maple OLE 2.0 Object] = int(int(int(exp((rho^2)^(3/2))*rho^2*sin(phi),rho = 0 .. 1),theta = 0 .. 2*Pi),phi = 0 .. Pi)  

                   = int(sin(phi),phi = 0 .. Pi)*int(1,theta = 0 .. 2*Pi)*int(rho^2*exp(rho^3),rho = 0 .. 1)

                                              = 4*Pi/3*(exp(1)-1)

¡@

Note that it would have bee extremely difficult to evaluate the integral above without spherical coordinates. The iterated integral in rectangular coordinates would have been

int(int(int(exp((x^2+y^2+z^2)^(3/2)),z = -sqrt(1-x^2-y^2) .. sqrt(1-x^2-y^2)),y = -sqrt(1-x^2) .. sqrt(1-x^2)),x = -1 .. 1)

Now consider the solid that lies above the cone z = sqrt(x^2+y^2)  and below the sphere x^2+y^2+z^2 = z , as shown below. What is the volume of the solid ?

[Maple Plot]
3DVIEW

¡@

Notice that the sphere passes through the origin and has center ( 0, 0, 1 ) with radius 1/2  . And equation of the sphere in spherical coordinates is given by

rho^2 = rho*cos(phi)        or      rho = cos(phi)

¡@

The cone can be written as

rho*cos(phi)   =   sqrt(rho^2*sin(phi)^2*cos(theta)^2+rho^2*sin(phi)^2*sin(theta)^2)   =   rho*sin(phi)

This gives   sin(phi) = cos(phi) , or   phi = Pi/4  . Therefore, the description of the solid in spherical coordinates is

   [Maple OLE 2.0 Object]

[Maple Plot]

    3DVIEW

[Maple Plot]

    3DVIEW

¡@

From the animations above, we see that the volume of the solid is

int(int(int(rho^2*sin(phi),rho = 0 .. cos(phi)),phi = 0 .. Pi/4),theta = 0 .. 2*Pi) = Pi/8


Download Maple Worksheet