# 有点小意思的定积分问题

$\displaystyle \int_{0}^{a}\int_{0}^{b}\cfrac{x}{x^2+y^2}dy dx$

$\displaystyle =\int_ 0^a\int_0^b \cfrac {d(\cfrac{y}{x})}{1+(\cfrac y x)^2}dx$
$\displaystyle =\int_ 0^a\arctan (\cfrac b x) dx$
$\displaystyle =x\arctan(\cfrac b x)|_{x=0}^{x=a}-\int_0^a \cfrac{x(-\cfrac{b}{x^2})}{1+(\cfrac b x)^2}dx$
$\displaystyle =a\arctan(\cfrac b a)+\cfrac b 2 \int_ 0^a \cfrac {dx^2}{x^2+b^2}$
$\displaystyle =a\arctan(\cfrac b a)+\cfrac b 2 \ln (x^2+b^2)|_0^a$
$\displaystyle =a\arctan(\cfrac b a)+b \ln\sqrt{a^2+b^2}-b\ln b$

$\displaystyle V=\int_0^b \int_0^a \cfrac x{x^2+y^2}dxdy$
$\displaystyle =\int_ 0^b \cfrac 12 \ln (a^2+y^2) dy-\int_ 0^b \ln ydy$
($y=a\tan t$, hence $t=\arctan(\cfrac ya)$)
$\displaystyle =a\int_ 0^{\arctan \cfrac ba}\ln (a\sec t) d\tan t -y\ln y|_0^b+y|_0^b$
$\displaystyle =a(\tan t\ln (a\sec t)-\tan t+t )|_ 0^{\arctan \cfrac ba} -b\ln b+b$
$\displaystyle =b\ln\sqrt{a^2+b^2}-b+a\arctan \cfrac ba -b\ln b+b$
$\displaystyle =b\ln\sqrt{a^2+b^2}+a\arctan \cfrac ba -b\ln b$

aarctan（b/a）+（1/2）bln（a²+b²）-blnb