I am working on a tumor model and need to calculate the volume enclosed between the sphere given by
$$(x-d)^2+y^2+z^2=r^2$$ and the cylinder given by $$x^2+y^2=R^2.$$
I have worked it out by using surfaces of revolution but this is tedious and required numerous cases. When I try to use cylindrical coordinates I end up the integral $$\int^{2\pi}_0 \int^R_0 \int^{\sqrt{r^2-R^2+d^2-2dR\cos (\theta )}}_{-\sqrt{r^2-R^2+d^2-2dR\cos (\theta )}} R~dz~dR~d\theta$$ which won't compute. I suspect either I am making an error in my transformation to cylindrical coordinates or a different method is needed.
