Integrating modular function $f(x,y)=|xy|$ in the area of the circle $x^2+y^2=a^2$ I need to solve the integral $$\iint_\omega |xy|\,dx\,dy$$ where $\omega:x^2+y^2=a^2$ I created the following integral and I have no idea how can I integrate modular function:
$$\int_{-a}^a dy\int_{-\sqrt{a^2-y^2}}^\sqrt{a^2-y^2} |xy|\,dx$$The only thing that I do know is that $\int |x|\,dx=\frac{x|x|}{2}+C$, but later on I face the next problem: $$\int_{-a}^a|y|\cdot|\sqrt{a^2-y^2}|\cdot \sqrt{a^2-y^2}\,dy$$
Could anyone help me?
 A: Why not convert to polar coordinates?
With $x=r\cos(\theta)$ and $y=r\sin(\theta)$. The area element becomes $rdrd\theta$. Then the integral over the area of the circle becomes
\begin{align}
I &=\int_0^a\int_0^{2\pi}r^2|\cos(\theta)\sin(\theta)|rdrd\theta=\int_0^ar^3dr\int_0^{2\pi}|\cos(\theta)\sin(\theta)|d\theta\\
&=\frac{a^4}{4}\frac{1}{2}\int_0^{2\pi}|\sin(2\theta)|d\theta
=\frac{a^4}{8}\int_0^{2\pi}|\sin(2\theta)|d\theta=\frac{a^4}{4}\int_0^{\pi}|\sin(2\theta)|d\theta\\
&=\frac{a^4}{2}\int_0^{\pi/2}\sin(2\theta)d\theta=\frac{a^4}{2}
\end{align}
A: You can break your integral into four parts (corresponding to four quadrants) and can integrate easily using polar coordinates.
$$\iint_\omega |xy|dxdy = \int_{r=0}^a\int_{\theta = 0}^{2\pi} f(r, \theta) \ r\  dr\  d\theta$$
$$= \int_{r=0}^a\int_{\theta = 0}^{\pi/2 } r^3 cos\theta \ sin \theta \ dr \ d\theta \ + $$
$$ \quad \ \int_{r=0}^a\int_{\theta = \pi/2}^{\pi } r^3(- cos\theta \ sin \theta) \ dr \ d\theta \ + $$
$$ \int_{r=0}^a\int_{\theta = \pi}^{3\pi/2 } r^3 cos\theta \ sin \theta \ dr \ d\theta \ + $$
$$ \int_{r=0}^a\int_{\theta = 3\pi/2}^{2\pi } r^3(- cos\theta \ sin \theta) \ dr \ d\theta \  $$
A: Without using polar coordinates, we can evaluate the integral of interest $I$ given by
$$I=\int_{-a}^a \int_{-\sqrt{a^2-y^2}}^{\sqrt{a^2-y^2}}|xy|\,dx\,dy$$
Exploiting even symmetry reveals
$$\begin{align}
I&=4\int_{0}^a \int_0^{\sqrt{a^2-y^2}}xy\,dx\,dy\\\\
&=4\int_0^a y\int_0^{\sqrt{a^2-y^2}}x\,dx\,dy\\\\
&=4\int_0^a y\left(\frac12 (a^2-y^2)\right)\,dy\\\\
&=\int_0^a (a^2-y^2)\,d(y^2) \\\\
&=a^4-\frac12 a^4\\\\
&=\frac12 a^4
\end{align}$$
as expected!
