This is what i've done so far:

$\displaystyle y=Aarctan(Bx) \Rightarrow \ tan \left( \frac{y}{A} \right)=B$

$\displaystyle \frac{dy}{dx}\frac{1}{cos^2 \left(\frac{y}{A} \right)}=B \Rightarrow \ \frac{dy}{dx}=Bcos^2 \left( \frac{y}{A} \right)$

This was to just get my bearings with what the integral should look like.

In double integral form, the initial integral is:

$\displaystyle \int_0^2 \int_x^{\pi x} cos^2 (y) \ dy \ dx$

Call the region we're integrating over R.

Let $\displaystyle R_1=\{ (x,y):\frac{y}{\pi} \leq x \leq y, \ 0 \leq y \leq 2 \}$ and $\displaystyle R_2=\{(x,y):\frac{y}{\pi} \leq x \leq 2, \ 2 \leq y \leq 2 \pi \}$.

$\displaystyle R= R_1 \cup R_2$.

This gives:

$\displaystyle \int_0^2 \int_{\frac{y}{\pi}}^y cos^2 y \ dx \ dy + \int_2^{2 \pi} \int_{\frac{y}{\pi}}^2 cos^2 y \ dx \ dy$

$\displaystyle \int_0^2 ycos^2 (y)-\frac{y}{\pi} cos^2(y)dy+\int_2^{2 \pi} 2cos^2(y)-\frac{y}{\pi}cos^2(y)dy$

$\displaystyle \int_0^{2 \pi} \left( y+2-\frac{2y}{\pi} \right) cos^2(y) \ dy$

Integrating by parts gives:

$\displaystyle \left[ arctan(y) \left( y+2-\frac{2y}{\pi} \right) \right]_0^{2 \pi}- \left( 1-\frac{2}{\pi} \right) \int_0^{2 \pi} arctan (y)\ dy$

$\displaystyle (2 \pi -2)arctan(2 \pi)- \left(1-\frac{2}{\pi} \right) \left[yarctan(y)-\frac{1}{2}ln (1+y^2) \right]_0^{2 \pi}$

$\displaystyle (2 \pi -2)arctan(2 \pi)-\left( 1-\frac{2}{\pi} \right) \left(2 \pi arctan (2 \pi) -\frac{1}{2}ln(1+4 \pi^2) \right)$

$\displaystyle 2arctan (2 \pi)+\left( \frac{1}{2}-\frac{1}{\pi} \right) ln (1+4 \pi^2)$

Firstly, is this answer correct?

Secondly, is there an easier way to do it than this??