How to evaluate $\iint_A \frac{1}{x^2+y^2}\,\mathrm dx\,\mathrm dy,$ where $A=[\frac{1}{a},a]\times[0,1]$ I want to compute
$$\iint_A \frac{1}{x^2+y^2}\,\mathrm dx\,\mathrm dy$$ where $A:=\left[\frac{1}{a},a\right]\times[0,1]$.
I got that this is equal to $\int_{1/a} ^a \frac{1}{x}\arctan \Big(\frac{1}{x}\Big) \mathrm dx\ $ and I don't know what to do from here. Can somebody help me, please?
 A: Let's catch up with you:
$$\begin{align}
\iint\limits_A \frac{1}{x^2+y^2}dx\,dy &= \int\limits_{\frac{1}{a}}^a\int\limits_0^1\frac{1}{x^2+y^2}dy\,dx\\
&=\int\limits_{\frac{1}{a}}^a\int\limits_0^1\frac{1}{x^2(1 + (y/x)^2)}dy\,dx.
\end{align}$$
Taking $u = y/x, \frac{\partial u}{\partial y} = 1/x$ so the last integral becomes
$$\begin{align}
\int\limits_{\frac{1}{a}}^a\int\limits_0^{\frac{1}{x}}\frac{1}{x(1 + u^2)}du\,dx
&= \int\limits_\frac{1}{a}^a\frac{1}{x}\arctan \left(\frac{1}{x}\right)\,dx \\
&=\int\limits_a^\frac{1}{a} -\frac{1}{u}\arctan u\,du \\
&= \int\limits_\frac{1}{a}^a \frac{1}{u}\arctan u\,du,
\end{align}$$
because $u = 1/x \implies du = -1/x^2\,dx = -u^2 \,dx \implies dx = du/u^2$ and $1/a \mapsto a, a \mapsto 1/a$. Accordingly to WolframAlpha, the indefinite integral for your expression has no closed form (in terms of elementary functions), but Wolfram Mathematica tells us it has a closed form with those integration limits (kudos to Semiclassical)!

So we have to exploit our integration limits. Let $I =\int\limits_\frac{1}{a}^a\frac{1}{x}\arctan \left(\frac{1}{x}\right)\,dx$.  Since $\arctan x = \pi/2 - \arctan 1/x$,
$$\begin{align}
I &= \int\limits_\frac{1}{a}^a \frac{1}{u}\arctan u\,du,\\
&= \int\limits_\frac{1}{a}^a \frac{1}{u}\left(\frac{\pi}{2}-\arctan \frac{1}{u}\right)\,du \\
&= \frac{\pi}{2}\left(\int\limits_\frac{1}{a}^a 1/u\,du\right) - I \\
&= \frac{\pi}{2}(\ln a - \ln(1/a)) - I \\
&= \pi \ln a - I.
\end{align}
$$
Therefore $I = \frac{\pi}{2}\ln a$, as desired.
