I try to calculate the volume inside the ball $\ x^2 + y^2 + z ^2 = 4 $ the outside the cylinder $\ x^2+y^2=2x $ using double integral. Since the shape is symmetric I chose $\ z = 0 $ as bottom limit and the ball is the upper limit. I try to convert to polar form and so I get
$$\ x^2 + y^2 + z ^2 = 4 \Rightarrow z = \sqrt{4-r^2} \\x^2 + y^2 = 2x \Rightarrow r = 2 \cos \theta $$
therefore the integral should be
$$\ 4 \cdot \int_0^{\pi/2} \int_0^{2\cos\theta} (\sqrt{4-r^2}) \ r \ dr \ d \theta$$
but this integral is way to messy for me to calculate. I mean first step of calculating integral for $\ r $ is okay but then the value I get and calculating integral of $\ \theta $ is beyond me and I believe it is beyond the scope of the course. I guess I'm missing something in the process here?
You've correctly set up the integral representing the volume of the inside cylinder. The scalar $4$ on the left represents
\begin{align} & 4 \int_0^{\pi/2} \int_0^{2\cos\theta} (\sqrt{4-r^2}) \ r \ dr \ d \theta \\ =& 2 \int_0^{\pi/2} \int_0^{2\cos\theta} (\sqrt{4-r^2}) \, d(r^2) \ d \theta \\ =& 2 \int_0^{\pi/2} \left[- \frac{(4-r^2)^{3/2}}{3/2} \right]_0^{2\cos\theta} \, d(r^2) \ d \theta \\ =& \frac{32}{3} \int_0^{\pi/2} (1-\sin^3\theta) \, d \theta \\ =& \frac{32}{3} \cdot \frac{\pi}{2} - \frac{32}{3} \cdot \frac{2}{3} \\ =& \frac{16(3\pi - 4)}{9} \end{align}
The second last equality is due to Wallis's integrals.