Evaluating triple integral in a different sphere I have been stuck with this problem for a while:
Evaluate $$ \iiint_D\frac{1}{x^2 + y^2 + (z-1)^2}\,dx\,dy\,dz \,,$$
where $D$ is a sphere centered at $(0,0,0)$ with a radius of $1/2$.
I couldn't make any progress without the use of spherical coordinates. Furthermore substituting $D(x, y, z)$ with spherical coordinates centered at $(0,0,0)$ leads to a very complex integral. It is obvious that we need to substitute $x, y, z$ to spherical coordinates centered at $(0, 0, 1)$ so that our denominator simplifies to $r^2$. The problem arises when you try to represent D(the $(0,0,0)$ radius $= 1/2$ sphere) with spherical coordinates, because they need to be centered at $(0,0,1)$. Any help?
 A: How about using cylinder coordinates instead? The integral becomes
$$\int_0^{2\pi}\int_{-1/2}^{1/2}\int_{0}^{\sqrt{1/4-z^2}}\frac{1}{r^2 + (z-1)^2}rdrdzd\theta$$
or
$$\frac{1}{2}\int_0^{2\pi}\int_{-1/2}^{1/2}\Bigl[\ln(r^2+(z-1)^2)\Bigr]_{0}^{\sqrt{1/4-z^2}}dzd\theta$$
which is
$$\frac{1}{2}\int_0^{2\pi}\int_{-1/2}^{1/2}\Bigl(\ln(\frac{5}{4}-2z) - 2\ln(1-z)\Bigr)dzd\theta$$
Can you take it from here?
A: Equivalently what you are suggesting is the integral
$$\iiint_{x^2+y^2+(z+1)^2\leq\frac{1}{4}} \frac{1}{x^2+y^2+z^2}\:dV$$
Take the boundary and expand powers:
$$x^2 + y^2 + z^2 = -\frac{3}{4}-2z \implies \rho^2 + 2\rho\cos\phi + \frac{3}{4} = 0$$
It would be best to put the bounds in terms of $\phi$ and integrate $\phi$ first like so:
$$\int_0^{2\pi} \int_{\frac{1}{2}}^{\frac{3}{2}} \int_{\cos^{-1}\left(-\frac{\rho}{2}-\frac{3}{8\rho}\right)}^{\pi} \sin\phi \:d\phi \:d\rho \:d\theta = 2\pi \int_{\frac{1}{2}}^{\frac{3}{2}}1 - \frac{\rho}{2} - \frac{3}{8\rho} \: d\rho = \pi - \frac{3\pi}{4}\log 3$$
