# Integrating $\int_0^2 \int_0^ \sqrt{1-(x-1)^2} \frac{x+y}{x^2+y^2} dy\,dx$ in polar coordinates

I'm having a problem integrating $\displaystyle\int_0^2 \int_0^ \sqrt{1-(x-1)^2} \frac{x+y}{x^2+y^2} \,dy\,dx$. I drew the graph, and it looks like half a circle on top of the $x$ axis.

I tried dividing it into two parts, with Area 1: $0\leq \theta\leq\frac{ \pi }{4}$ with $\csc\theta\leq r\leq 2\cos\theta$ and

Area 2: $\frac{ \pi }{4}\leq \theta\leq\frac{ \pi }{2}$, but I dont know how to set r boundaries with this. Is it just $0\leq r\leq \csc\theta$? no.... this can't be right.... Could someone please help me out?

This is a semicircle of radius $1$ in the upper half plane, centered at $x=1$. Converting to polar coordinates centered at the origin, the limits are $\theta \in [0,\pi/2]$ and $r \in [0,2 \cos{\theta}]$. The integral is thus

$$\int_0^{\pi/2} d\theta \, (\cos{\theta} + \sin{\theta}) \int_0^{2 \cos{\theta}} dr = \frac{\pi}{2}+1$$

• Thank you!! I think i misunderstood something in learning how to set r boundaries. I should go study that now... Thankyou! – user125342 Jul 4 '14 at 4:58

You need to convert the equation of the circle $(x-1)^2+y^2 = 1$ into polar coordinates.

Substitute $x = r\cos \theta$ and $y = r\sin \theta$:

$(r\cos\theta - 1)^2 + (r\sin\theta)^2 = 1$

$r^2\cos^2\theta - 2r\cos\theta + 1 + r^2\sin^2\theta = 1$

$r^2(\cos^2\theta + \sin^2\theta) - 2r\cos\theta + 1 = 1$

$r^2-2r\cos\theta + 1 = 1$

$r^2-2r\cos\theta = 0$

$r(r-2\cos\theta) = 0$

Do you now see what the equation of the circle is in polar coordinates?