Calculating divergence between two spheres

73 Views Asked by At

A practice problem I have asks me to calculate the flux of a vector field across the surface of the solid defined by a sphere of radius $1$ and a sphere of radius $\sqrt{2}$.

Calculating the divergence of the field $F$ first, I get $9(x^2+y^2+z^2)$. I then thought it'd be best to parametrize the solid with $0<s<2\pi$, $-\frac{\pi}{2}<t<\frac{\pi}{2}$, $1<r<\sqrt{2}$, and $x=r\cos(s)\cos(t)$, $y=r\sin(s)\cos(t)$, $z=r\sin(t)$. Then taking the triple integral of the divergence over $dr\ dt\ ds$ with the above bounds. I get a result of $6\pi^2$, however that does not match the solution.

What am I doing wrong?

1

There are 1 best solutions below

0
On

You should post your integral, otherwise it is hard to tell what you are doing wrong. A guess is, that may be you took a wrong volume element. Anyway with this integral:

f[x_, y_, z_] = 9 (x^2 + y^2 + z^2);
Integrate[
 f[r Cos[s] Cos[t], r Sin[s] Cos[t], r  Sin[t]] r^2 Cos[t] , {s, 0, 
  2 Pi}, {t, -Pi/2, Pi/2}, {r, 1, Sqrt[2]}] 

I get the result:

36/5 (-1 + 4 Sqrt[2]) \[Pi]