# Calculating double integral by converting to polar coordinates

Question: Evaluate the integral

$$\int_0^1\int_x^1 \arctan\left(\frac{y}{x}\right) \ dy\,dx$$

My attempt:

So I've converted the integral into polar coordinates, getting the integral

$$\int_0^\frac{\pi}{4}\int_0^\frac{1}{\cos(\theta)} \theta r\,dr\,d\theta \ =\int_0^\frac{\pi}{4} \frac{\theta }{2\cos^2(\theta)} \, d\theta \$$

However I have no idea where to go from here? Have I calculated the limits wrong or am I missing something?

Thank you

• Ok, in order to integrate the $\theta$ function, go for integration by parts, choose $f=\theta$ and $g'=csc^2\theta$ Mar 18, 2016 at 23:56
• Wow, I can't believe I didn't see that! Thank you for guiding me! Mar 18, 2016 at 23:58
• Are there any easier ways to achieve this answer? Mar 19, 2016 at 0:00
• hmmm, I thought my approach was kind of easy, in the sense that behind the integral sign you get a $cot\theta$ and that has a standard anti derivative in the form of $ln|sin\theta|$ Mar 19, 2016 at 0:02
• The limits of $y$ should be from $x$ to $1$? Mar 19, 2016 at 0:17

Do you have your limits of integration correct?

In Cartesian, if your limits are set up correctly at the beginning, your region is $x=y, y=1, x=0$ And since $x<1$ you are going to get a negative value when you integrate.

After you have converted, you have $r = \csc \theta$ which is consistent with y=1. If the rest of the set up was right, you should have $\theta$ from $\pi/4$ to $\pi/2$

Alternatively, if your region was $x = 1, y=0, x=y$ your limit become $r$ from $0$ to $\sec\theta, \theta$ from $0$ to $\pi/4$

• Wait why is r cscθ instead of √2 ? Oct 12, 2019 at 0:07
• In x=y, y=1, x=0 and x<=1 , the greatest distance from origin is √2 right? Oct 12, 2019 at 0:08
• You are commenting on a question that is 3 years old. Anyway, when we convert to polar, the line $y=1$ becomes $r\sin\theta = 1 \implies r = \csc\theta$ Oct 12, 2019 at 0:53
• But r is distance from origin and greatest distance in this region is between 0 and (1, 1) ? Our region is a right angle triangle with r as hypotenuse Oct 12, 2019 at 1:18
• The coordinates are (0, 0), (0, 1) and(1, 1) and greatest distance of r is 0 to (1, 1) ie √2 . Oct 12, 2019 at 1:31

You need this: $$\int_0^{\pi/4}\int_0^{1/\cos\theta} \theta r\,dr\,d\theta.$$ Notice that $$x$$ goes from $$0$$ to $$1$$. So you have a right triangle whose "adjacent" side has length $$1$$, and $$r$$ is the length of the hypotenuse. $$\frac{\text{adjacent}}{\text{hypotenuse}} = \cos\theta = \frac 1 r,$$ so $$r$$ goes up to $$1/\cos\theta$$. So you get \begin{align} & \int_0^{\pi/4} \frac \theta {2\cos^2\theta} \,d\theta = \frac 1 2 \int_0^{\pi/4} \theta \Big( \sec^2\theta \,d\theta \Big) \\[12pt] = {} & \overbrace{\frac 1 2 \int \theta\,dv = \frac 1 2 \theta v - \frac 1 2 \int v\,d\theta}^\text{integration by parts} \\[12pt] = {} & \frac 1 2 \left[ \theta\tan\theta \vphantom{\frac 1 1} \right]_0^{\pi/4} - \frac 1 2 \int_0^{\pi/4} \tan\theta\,d\theta = \text{etc.} \end{align} Recall that \begin{align} & \int\tan\theta\,d\theta = \int \frac{\sin\theta}{\cos\theta}\,d\theta \\[6pt] = {} & \int \frac {-1}{\cos\theta} \Big( - \sin\theta\,d\theta\Big) = \int \frac {-1} u\,du = \text{etc.} \end{align}

• ok, You have $\displaystyle \int_x^1$ rather than $\displaystyle \int_0^x$. So $\theta$ would need to go from $\pi/4$ to $\pi/2$. $\qquad$ Mar 19, 2016 at 0:19