# Integrate $f(x,y,z)=x^2+y^2+z^2$ over the region $0 \leq r \leq 4, \pi/4 \leq \theta \leq3\pi/4, -1\leq z \leq1.$

The question says to evaluate the given triple integral in cylindrical coordinates over the region $$W$$. Here's the integrand and the region:

I'm confused about this question because I keep getting $$0$$. Here's the triple integral in polar coordinates that represents the region given in question $$9$$:

Note that I use $$x=r\cos\theta$$, $$y=r\sin\theta$$, and $$z=z$$ to simplify the integrand $$f(x,y,z)=x^2+y^2+z^2$$.

$$\int_{-1}^1\int_{\pi/4}^{3\pi/4}\int_{0}^4 r(r^2+z^2) \ dr\ d\theta \ dz$$

After integrating the inner intergral we end up with positive powers of $$r$$. As a result, the function evaluated at $$1$$ minus the function evaluated at $$-1$$ ends up being $$0$$, and the integration stops there. The order of integration turns out not to matter: I always get this result.

Yet the text shows a non-zero number as the answer. What am I missing?

The answer is non-zero. I suspect you're calculating the integrals incorrectly, since your setup looks great. We have \begin{align*} \int_{-1}^1\int_{\pi/4}^{3\pi/4}\int_{0}^4 r\big(r^2+z^2\big) \ dr\ d\theta \ dz &=\frac{\pi}{2}\int_{-1}^1\int_0^4\big(r^3+rz^2\big)\,dr\,dz\\ &=\frac{\pi}{2}\int_{-1}^1\left(\frac{r^4}{4}+\frac{r^2z^2}{2}\right)\bigg|_{0\to 0}^4\,dz\\ &=\frac{\pi}{2}\int_{-1}^1\left(64+8z^2\right)dz\\ &=\pi\int_{0}^1\left(64+8z^2\right)dz\quad\text{(even function on symmetric interval)}\\ &=\pi\left(64z+\frac{8z^3}{3}\right)\bigg|_{0}^{1}\\ &=\frac{200\pi}{3}. \end{align*}
Not true... $$\int_{0}^4 r(r^2+z^2)dr=\left[\frac{r^4}{4} + \frac{r^2 z^2}{2}\right]_{0}^4 = \frac{4^4}{4} + \frac{4^2 z^2}{2}=64+8z^2$$
• Sorry, I meant for that $dz$ to be a $dr$; I've fixed it now. So you'd actually be evaluating $r^4 + (r^2z^2)/2$ over $1$ and $-1$ with respect to $r$. The positive powers of $r$ in that integrand make it so that the entire thing has the same value whether you're evaluating for $1$ or $-1$ – James Ronald Oct 7 at 14:07
• @JamesRonald When you exchange the order of integration you must be consistent in the integration limits. If you start with $dr$, the integration limits are $0,4$, not $-1,1$. – PierreCarre Oct 7 at 14:09
• Indeed, I fixed that as well, thank you. Do you know how to solve this now that we're evaluating with respect to $r$ first? – James Ronald Oct 7 at 14:10
• @JamesRoland The result is $\frac{200 \pi}{3}$, regardless of the integration order. – PierreCarre Oct 7 at 14:11