Let $D$ be the region enclosed by the surface $z = \sqrt{4-x^2-y^2}$ and $z = -\sqrt{x^2+y^2}$
Determine:
$$\iiint zdv$$
using Spherical coordinates.
I'm trying to solve the above but I'm unsure how to go about it.
My attempt has been: $$\int_0^{2\pi}\int_0^{2}\int_{-\sqrt{x^2+y^2}}^{\sqrt{4-x^2-y^2}} zdv$$
which I then integrate the first layer leaving me with: $$\int_0^{2\pi}\int_0^{2} 2-x^2-y^2dv$$
Should I have subbed in the spherical coordinates right at the start and integrated it as: $$\int_0^{2\pi}\int_0^{2}\int_{-\sqrt{x^2+y^2}}^{\sqrt{4-x^2-y^2}}p\cos\phi p^2\sin\phi dp d\theta d\phi$$
Based on a users input, would I have to first rewrite $z = \sqrt{4-x^2-y^2}$ and $z = -\sqrt{x^2+y^2}$
In terms of spherical coordinates?
The given region is that from a cone up to the sphere "capping" the cone. $\rho$ goes from 0 to 2 (the radius of the sphere) and $\theta$ goes from 0 to $2\pi$ (the complete circle). $\phi$ goes from 0 (vertical) down to the cone, $\pi/4$. Since $z=\rho cos(\phi)$ in spherical coordinates, the integral is $\int_0^2\int_0^{2\pi}\int_0^{\pi/4} \rho cos(\phi) (\rho^2 sin(\phi)d\phi d\theta d\rho)$$= \int_0^2\int_0^{2\pi}\int_0^{\pi/4}\rho^3sin(\phi)cos(\phi)d\phi d\theta d\rho$.
That can easily be done as $\left(\int_0^2\rho^3d\rho\right)\left(\int_0^{2\pi} d\theta\right)\left(\int_0^{\pi/4} sin(\phi)cos(\phi) d\phi\right)$