Surface integrals and the divergence theorem: dS, flux and Stokes
Ten problems on surface integrals: the area of a sphere from |r_φ × r_θ|, the area of a paraboloid as a graph, the mass of a hemispherical shell, the upward flux through a paraboloid cap with the normal (−g_x, −g_y, 1), the outward flux through a sphere, the divergence theorem on a box and on a ball, the flux through a hemisphere found by closing it with a disk, Stokes' theorem on a hemisphere and its boundary circle, and Gauss's law for the field r/|r|³ with the origin inside and outside, with worked solutions and the mistakes of dropping |r_u × r_v|, the normal (g_x, g_y, 1), forgetting the disk that closes the surface, a boundary traced the wrong way for Stokes and the divergence theorem across a singularity.
Before you start
A surface integral adds something up over a curved surface the way a line integral adds it up along a curve. With respect to area it totals a density over a shell; with a vector field it totals the flux, the rate at which the field flows through the surface. Each one is computed the same way: parametrize the surface by two variables, find the area element dS=∥ru×rv∥dudv from a cross product, and do an ordinary double integral. Two theorems save most of the work. The divergence theorem trades the flux out of a closed surface for a triple integral of the divergence over the solid inside:
∬SF⋅ndS=∭E∇⋅FdV,
and Stokes' theorem trades the flux of a curl for a line integral around the boundary. They are Green's theorem in three dimensions, and they are where Gauss's law of electrostatics comes from. These ten problems compute areas, masses and fluxes directly, then with each theorem, and end with the point charge whose field the divergence theorem gets wrong if you let it.
A surface S is given by r(u,v)=(x,y,z) over a region D of the uv-plane. The vectors ru and rv are tangent to it, ru×rv is normal to it, and its area element is .dS=∥ru×rv∥dudv.
Graphs. For z=g(x,y) over ,D, take :r=(x,y,g): then ,rx×ry=(−gx,−gy,1), which points up, and .dS=1+gx2+gy2dA.
Spheres. On the sphere of radius ,a,r=(asinϕcosθ,asinϕsinθ,acosϕ) with ,0≤ϕ≤π,.0≤θ≤2π. The outward unit normal is n=r/a and .dS=a2sinϕdϕdθ.
Scalar surface integral..∬SgdS=∬Dg(r(u,v))∥ru×rv∥dudv. It does not depend on which way the normal points.
Flux.,∬SF⋅ndS=∬DF(r(u,v))⋅(ru×rv)dudv, with n the chosen unit normal; if ru×rv points the other way, flip its sign. For a closed surface the convention is the outward normal.
Divergence and curl. For :F=(P,Q,R):,∇⋅F=Px+Qy+Rz, and .∇×F=(Ry−Qz,Pz−Rx,Qx−Py).
Divergence theorem. If S is the whole boundary of the solid ,E, with the outward normal, and F has continuous partial derivatives on all of :E:.∬SF⋅ndS=∭E∇⋅FdV.
Stokes' theorem. If S has boundary curve :C:,∬S(∇×F)⋅ndS=∮CF⋅dr, with C traced so that the surface is on your left when you walk along it with your head pointing along n (the right-hand rule).
Parametrize the sphere of radius 2 by ϕ and ,θ, compute rϕ×rθ and its length, and use it to find the area of the sphere.
·
Find the area of the part of the paraboloid z=x2+y2 below the plane .z=2.
··
A thin shell has the shape of the upper hemisphere ,x2+y2+z2=4,,z≥0, and its density is .ρ=z. Find its mass, and the average height of a point on the shell.
··
Find the upward flux of F=(x,y,z) through the cap ,z=1−x2−y2,.z≥0.
··
Find the outward flux of F=(0,0,z) through the sphere of radius 2 about the origin, directly from the parametrization.
·
Use the divergence theorem to find the outward flux of F=(x2,y2,z2) out of the box ,0≤x≤1,,0≤y≤2,.0≤z≤3. Check it face by face.
··
Find the outward flux of F=(x3,y3,z3) through the unit sphere with the divergence theorem, and check it with the surface integral.
···
Let F=(x+y2,y+z2,z+x2) and let S be the upper hemisphere ,x2+y2+z2=1,,z≥0, with the upward normal. Find the flux of F through S by closing the surface with a disk.
···
Let F=(z−y,x+z2,xy) and let S be the upper unit hemisphere with the upward normal. Verify Stokes' theorem: compute ∬S(∇×F)⋅ndS and the line integral around the boundary circle.
···
A point charge at the origin has electric field proportional to
F=(x2+y2+z2)3/2(x,y,z).
Show that ∇⋅F=0 away from the origin. Find the outward flux of F through the sphere of radius a about the origin, through the surface of the cube ,−1≤x,y,z≤1, and through the unit sphere centered at .(3,0,0).
Answers
Area =∫02π∫0π4sinϕdϕdθ=4⋅2⋅2π=16π
Area =2π⋅613=313π≈13.61
Mass ;8π; the average height is 8π/8π=1
Flux =23π≈4.71
Flux =8⋅32⋅2π=332π≈33.51
Flux ;=36; the faces give 6+12+18=36
Flux =512π≈7.54 both ways
Flux through S=2π−(−4π)=49π≈7.07
Both sides equal 2π
Flux 4π through every sphere about the origin, 4π through the cube, and 0 through the sphere centered at (3,0,0)
Worked solutions
Problem 1
Parametrize the sphere of radius 2 by ϕ and ,θ, compute rϕ×rθ and its length, and use it to find the area of the sphere.
r=(2sinϕcosθ,2sinϕsinθ,2cosϕ)ϕ is measured down from the positive z-axis, θ around it.
,rϕ=(2cosϕcosθ,2cosϕsinθ,−2sinϕ),rθ=(−2sinϕsinθ,2sinϕcosθ,0)Differentiate each coordinate.
rϕ×rθ=4sinϕ(sinϕcosθ,sinϕsinθ,cosϕ)The components are ,4sin2ϕcosθ,4sin2ϕsinθ and .4sinϕcosϕ. The vector in parentheses is ,r/2, so the cross product points outward.
∥rϕ×rθ∥=4sinϕThe vector in parentheses is a unit vector, and sinϕ≥0 on .[0,π].
Area =∫02π∫0π4sinϕdϕdθ=4⋅2⋅2π=16πIt agrees with .4πa2. Integrating dϕdθ with no factor gives 2π2≈19.74 instead of :16π≈50.27: the rectangle of angles is not the sphere (Mistake 1).
Problem 2
Find the area of the part of the paraboloid z=x2+y2 below the plane .z=2.
,gx=2x,,gy=2y, so dS=1+4x2+4y2dAThe graph formula.
The shadow is the disk x2+y2≤2The paraboloid meets z=2 where .r2=2.
Area =∫02π∫021+4r2rdrdθPolar coordinates, keeping the r of .dA=rdrdθ.
Area =2π⋅613=313π≈13.61More than twice the area 2π≈6.28 of the disk underneath, because the surface is steep near the rim. Leaving out the square root gives exactly the disk's area (Mistake 1).
Problem 3
A thin shell has the shape of the upper hemisphere ,x2+y2+z2=4,,z≥0, and its density is .ρ=z. Find its mass, and the average height of a point on the shell.
z=2cosϕ and ,dS=4sinϕdϕdθ, with 0≤ϕ≤2πProblem 1 with the upper half only.
Mass =∫02π∫0π/22cosϕ⋅4sinϕdϕdθA scalar surface integral; the direction of the normal plays no part.
∫0π/2cosϕsinϕdϕ=21It is 21sin2ϕ from 0 to .2π.
Mass =8⋅21⋅2π=8π≈25.13The θ-integral gives .2π.
Mass ;8π; the average height is 8π/8π=1The area of the hemisphere is .2πa2=8π. The average height of the shell is ,2a, higher than the 83a of the solid half-ball, whose volume crowds near the flat base.
Problem 4
Find the upward flux of F=(x,y,z) through the cap ,z=1−x2−y2,.z≥0.
,g=1−x2−y2, so (−gx,−gy,1)=(2x,2y,1)It points up, as required: the z-component is .1.
F⋅(2x,2y,1)=2x2+2y2+(1−x2−y2)=1+r2On the surface, .z=1−r2.
The shadow is the unit diskThe cap meets z=0 where .r=1.
Flux =∫02π∫01(1+r2)rdrdθ=2π(21+41)The ∥rx×ry∥ cancels against the 1/∥rx×ry∥ in the unit normal, so no square root appears.
Flux =23π≈4.71A check with the divergence theorem: ∇⋅F=3 and the solid under the cap has volume ,2π, giving 23π out of the closed surface; on the flat bottom ,F⋅(0,0,−1)=−z=0, so all of it leaves through the cap. With (gx,gy,1) as the normal the answer is −2π (Mistake 2).
Problem 5
Find the outward flux of F=(0,0,z) through the sphere of radius 2 about the origin, directly from the parametrization.
,n=21(x,y,z), so F⋅n=2z2The outward unit normal of a sphere is the position vector divided by the radius.
F⋅n=2cos2ϕ and dS=4sinϕdϕdθ.z=2cosϕ.
Flux =∫02π∫0π8cos2ϕsinϕdϕdθBoth hemispheres add: below the equator z<0 and the field points down, which is still outward.
∫0πcos2ϕsinϕdϕ=32It is −31cos3ϕ from 0 to .π.
Flux =8⋅32⋅2π=332π≈33.51This is the volume of the ball, ,34π⋅23, as the divergence theorem predicts: .∇⋅F=1.
Problem 6
Use the divergence theorem to find the outward flux of F=(x2,y2,z2) out of the box ,0≤x≤1,,0≤y≤2,.0≤z≤3. Check it face by face.
∇⋅F=2x+2y+2zSum of ,Px,,Qy,.Rz.
,∭2xdV=2⋅21⋅6=6,,∭2ydV=2⋅1⋅6=12,∭2zdV=2⋅23⋅6=18The box has volume ,6, and the average of ,x,,y,z over it is the center .(21,1,23).
Total =6+12+18=36The divergence theorem's answer.
On :x=1:F⋅n=1 over area ;6; on :y=2:4 over area ;3; on :z=3:9 over area 2The faces ,x=0,,y=0,z=0 contribute ,0, because there the normal component of F is ,−x2=0,,−y2=0,.−z2=0.
Flux ;=36; the faces give 6+12+18=36Each face's flux matches one term of the triple integral.
Problem 7
Find the outward flux of F=(x3,y3,z3) through the unit sphere with the divergence theorem, and check it with the surface integral.
=3⋅51⋅2⋅2π=512πThe limits are numbers, so the integral splits.
On the sphere ,n=(x,y,z), so ,F⋅n=x4+y4+z4, and ∬x4dS=54πWith :z=cosϕ:.∬z4dS=2π∫0πcos4ϕsinϕdϕ=2π⋅52. By symmetry x4 and y4 give the same.
Flux =512π≈7.54 both ways3⋅54π from the surface.
Problem 8
Let F=(x+y2,y+z2,z+x2) and let S be the upper hemisphere ,x2+y2+z2=1,,z≥0, with the upward normal. Find the flux of F through S by closing the surface with a disk.
S and the unit disk D in the plane z=0 together bound the half-ball EThe divergence theorem needs a closed surface; S alone is not one.
,∇⋅F=1+1+1=3, so ∭E3dV=3⋅32π=2πThe half-ball has volume .32π.
On D the outward normal is (0,0,−1) and F⋅n=−(z+x2)=−x2Outward from E is down on the base.
∬D−x2dA=−∫02π∫01r3cos2θdrdθ=−4π.41⋅π.
Flux through S=2π−(−4π)=49π≈7.07The total out of E is ,2π, and the base takes −4π of it, so the dome carries the rest. Stopping at 2π forgets the base (Mistake 3).
Problem 9
Let F=(z−y,x+z2,xy) and let S be the upper unit hemisphere with the upward normal. Verify Stokes' theorem: compute ∬S(∇×F)⋅ndS and the line integral around the boundary circle.
With :n=(x,y,z):(∇×F)⋅n=x2−2xz+y−y2+2zThe upward normal of the upper hemisphere is outward.
,∬Sx2dS=∬Sy2dS=32π,,∬SxzdS=∬SydS=0,∬SzdS=πHalf of 34π for each square; the odd terms cancel between θ and ;θ+π; and ∬zdS is Problem 3 with radius .1.
∬S(∇×F)⋅ndS=32π−32π+2π=2πAdd the pieces.
Both sides equal 2πCounterclockwise seen from above, ,r=(cost,sint,0), so F=(−sint,cost,sintcost) and ,F⋅r′=sin2t+cos2t=1, giving .2π. The flat unit disk has the same boundary and gives ∬2dA=2π too. Clockwise gives −2π (Mistake 4).
Problem 10
A point charge at the origin has electric field proportional to
F=(x2+y2+z2)3/2(x,y,z).
Show that ∇⋅F=0 away from the origin. Find the outward flux of F through the sphere of radius a about the origin, through the surface of the cube ,−1≤x,y,z≤1, and through the unit sphere centered at .(3,0,0).
,Px=ρ31−ρ53x2, and similarly for Qy and RzHere ,ρ=x2+y2+z2, and .∂ρ/∂x=x/ρ.
∇⋅F=ρ33−ρ53ρ2=0 for ρ=0The three ,x2,,y2,z2 terms add up to .ρ2.
On the sphere of radius :a:,F⋅n=a21, so the flux is a21⋅4πa2=4πF points straight out and has length .a21. The radius cancels.
Cube: apply the divergence theorem to the region between the cube and a small sphere inside it, where F is smooth: the flux out of the cube equals the flux out of the small sphere, 4πThe origin is not in that region, and ∇⋅F=0 there. Each face of the cube carries 64π=32π by symmetry.
Flux 4π through every sphere about the origin, 4π through the cube, and 0 through the sphere centered at (3,0,0)That sphere does not contain the origin, so the divergence theorem applies on its ball and gives .∭0dV=0. This is Gauss's law: the flux counts the charge inside, whatever the surface. Using ∇⋅F=0 on a ball that contains the origin gives 0 instead of 4π (Mistake 5).
Where this goes wrong
1. Dropping |r_u × r_v| from dS
The surface integral is written as if dS were dA of the shadow, or dudv of the parameters.
z=x2+y2 below z=2 has shadow x2+y2≤2Right so far: Problem 2.
“Area .=∬D1dA.”The step that causes the mistake: ,dS=1+gx2+gy2dA, and the tilt of the surface is what the square root measures.
Area =2π≈6.28That is the area of the flat disk, not of the bowl above it; the true area is .313π≈13.61. The same slip on the sphere of Problem 1, integrating dϕdθ with no ,4sinϕ, gives 2π2≈19.74 for an area of .16π≈50.27.
2. The normal (g_x, g_y, 1) instead of (−g_x, −g_y, 1)
The normal of a graph is remembered as the gradient of g with a 1 appended.
g=1−x2−y2 and F=(x,y,z)Right so far: Problem 4.
“The upward normal is .(gx,gy,1)=(−2x,−2y,1).”The surface is the level set ,z−g=0, whose gradient is .(−gx,−gy,1). The vector (gx,gy,1) is not normal to the surface at all.
,F⋅ndS=(1−3r2)dA, so the flux is 2π(21−43)=−2πThe field points out of the cap everywhere, so the upward flux must be positive. With (2x,2y,1) it is ,23π, which the divergence theorem confirms.
3. Forgetting the disk that closes the surface
The divergence theorem is applied to a hemisphere as if it were a closed surface.
∇⋅F=3 for F=(x+y2,y+z2,z+x2)Right so far: Problem 8.
“Flux through the hemisphere .=∭E3dV.”The triple integral is the flux out of the whole boundary of ,E, which includes the flat disk at the bottom.
Flux through S=2πThe disk carries −4π of that total, so the dome carries .2π+4π=49π≈7.07. The disk's flux is 0 only when Fz=0 on the plane ,z=0, as in Problem 4.
4. A boundary traced the wrong way for Stokes
The boundary circle is traced in whichever direction comes first.
∬S(∇×F)⋅ndS=2π with the upward normalRight so far: Problem 9.
“,r=(cost,−sint,0),.0≤t≤2π.”This runs clockwise seen from above. With the normal pointing up, the right-hand rule needs counterclockwise.
,∮CF⋅dr=−2π, so Stokes' theorem seems to failClockwise, F=(sint,cost,−sintcost) and ,r′=(−sint,−cost,0), so F⋅r′=−1 at every point. Reversing the curve flips the sign; counterclockwise gives ,2π, as the surface does.
5. The divergence theorem across a singularity
The divergence of the point-charge field is zero, so every closed flux is assumed to be zero.
∇⋅F=0 for ρ=0Right so far: Problem 10.
“By the divergence theorem the flux out of the unit sphere is .∭ρ≤10dV.”The theorem needs F smooth on the whole solid, and F is undefined at the origin, which is inside the ball.
Flux =0The direct computation gives F⋅n=1 at every point of the unit sphere and a flux of .4π≈12.57. All of the divergence sits at the one point where F blows up; the theorem gives 0 only for surfaces that leave the origin outside, like the sphere centered at .(3,0,0).