# Volume calculating using double integral

Here is my task: Calculate the volume under the surface $z=x^{2}-y^{2}$ over the region $(x^{2}+y^{2})^{3}=a^{2}x^{2}y^{2}$.

Before solving this task, let's say that $z=x^{2}+y^{2}$ instead of$z=x^{2}-y^{2}$. After transforming line $(x^{2}+y^{2})^{3}=a^{2}x^{2}y^{2}$ to polar form $(x=\rho\cos \phi,y=\rho\sin \phi)$, we get $\rho=\frac{a}{2}\sin 2\phi$,$z=\rho^{2}\cos ^{2}\phi+\rho^{2}\sin^{2}\phi=\rho^{2}$ (it's not funcion of angle $\theta$). Here is sketch of this line:

http://s30.postimg.org/jmuwp5kxt/graph.png

Volume would be $8\int_{0}^{\pi/4}d\phi\int_{0}^{(a/2)\sin 2\phi}\rho(\rho^{2}\cos ^{2}\phi+\rho^{2}\sin^{2}\phi)d\rho=8\int_{0}^{\pi/4}d\phi\int_{0}^{(a/2)\sin 2\phi}\rho^{3}d\rho$. (Or we can integrate from zero to pi/4, then from pi/4 to pi/2 and so on, up to 2pi, but it's easier to calculate only from zero to pi/4 and then multiply result by 8).

Let's back to original task. It would be incorrect if we apply same principle as before, ie this wouldn't be true:

$V=8\int_{0}^{\pi/4}d\phi\int_{0}^{(a/2)\sin 2\phi}\rho(\rho^{2}\cos ^{2}\phi-\rho^{2}\sin^{2}\phi)d\rho$ $V=8\int_{0}^{\pi/4}d\phi\int_{0}^{(a/2)\sin 2\phi}\rho^{3}(\cos ^{2}\phi-\sin^{2}\phi)d\rho$,

right? Here volume must be calculated "part by part" - from zero to pi/4, then from pi/4 to pi/2 and so on, up to 2pi, and that's because (I think) surface z depends on angle $\phi$.

In cylindrical coordnates, you have, after some simplification $$z=r^{2}(\cos ^{2}\theta -\sin ^{2}\theta )=r^{2}\cos 2\theta$$ and $$r= a\sin \theta \cos \theta =\frac{\vert a\vert }{2} \sin 2\theta$$ where in the latter equation we have taken the positive root since $- \sin 2\theta = \sin 2(-\theta )$ and so the graph is the same.

The graph of the first equation is a saddle and that of the second is a rose.

We want the volume above the rose between the lines $y=x$ and $y=-x$ and the symmetry of the region allows us to take the limits of integration over $\theta$ to be $0<\theta <\pi/4$ and multiply by $4$ at the end.

So for the volume, take $$4\int_{0} ^{\pi /4}\int _{0}^{\frac{\vert a\vert }{2} \sin 2\theta }\int _{0}^{r^{2}\cos 2\theta } rdzdrd\theta$$ Computing, we get $4\int_{0} ^{\pi /4}\int _{0}^{\frac{\vert a\vert }{2} \sin 2\theta }r^{3}\cos 2\theta drd\theta =\frac{a^{4} }{4}\int_{0} ^{\pi /4} \sin ^{4}2\theta \cos 2\theta drd\theta =\frac{a^{4}}{40}$