# Surface integral of position vector over a sphere

$$\iint_S$$ r.n $$dS$$

Over the surface of the sphere with radius $$a$$ centered at the origin

Now this is obviously trivial and the answer is $$4\pi a^3$$ but I want to do it the hard way because there's something I don't understand

The surface is $$x^2 + y^2 + z^2 = a^2$$ , then the normal vector $$n = \nabla S$$

$$\hat n$$ = $$\frac{\nabla S}{|\nabla S|}$$ = $$\frac{x \hat i + y \hat j + z \hat k}{a}$$

$$dS = \frac{dxdy}{|\hat n . \hat k|} = \frac{dxdy}{a/z}$$

Then $$\iint_S$$ r.n $$dS$$ = $$\iint_S \frac{x^2 + y^2}{\sqrt{a^2 -x^2 -y^2}} + \sqrt{a^2 -y^2 -x^2}$$ $$dxdy$$

Switching to polar coordinates, $$x=\rho cos\phi , y =\rho \sin\phi$$

Then $$\iint_S$$ r.n $$dS$$ = $$\iint_S \frac{\rho^2}{\sqrt{a^2 -\rho^2}} + \sqrt{a^2 - \rho^2}$$ $$\rho d\rho d\phi$$

Integrating $$\rho$$ from $$0$$ to $$a$$ and $$\phi$$ from $$0$$ to $$2\pi$$ , we get:

$$\iint_S$$ r.n $$dS$$ = $$2\pi a^3$$ which is half the required answer $$4\pi a^3$$ , is it because I only took into account that $$dS = \frac{dxdy}{|\hat n . \hat k|} = \frac{dxdy}{a/z}$$ and should have changed this surface element starting from a specific point? If so, how? Thanks

• When you take the square root, aren’t you only giving the correct value of $z$ in upper half space? Dec 25 '18 at 2:10
• Yes, but didn't I integrate from 0 to $2\pi$ anyway? Dec 25 '18 at 2:25
• This seems to be full of errors. Why are you varying $\rho$. It's constant, you're on a sphere. The surface element should be $a^2\sin\theta\operatorname d\theta\operatorname d\varphi$. You need spherical coordinates, not polar. Etc...
– user403337
Dec 25 '18 at 3:07

notice that $$\vec r \cdot \vec n = \frac{x^2+y^2+z^2} a = \frac {a^2} a = a$$
so $$\iint_S \vec r \cdot \vec n \;dS = a \iint_S \;dS$$
You get $$a\int\int\operatorname dS=a\int\int a^2\sin\theta\operatorname d\theta\operatorname d\varphi=a^3\int_0^{2\pi}\int_0^{\pi}\sin\theta\operatorname d\theta\operatorname d\varphi=2\pi a^3[-\cos\theta]_0^{\pi}=4\pi a^3$$.