Help me to calculate $\int_{0}^{\pi/4}\sqrt{1+\tan x}\,\mathrm dx$ How to calculate $$\int_{0}^{\pi/4}\sqrt{1+\tan x}\,\mathrm dx$$
My attempt:
Let
$$I=\int_{0}^{\pi/4}\sqrt{1+\tan x}\,\mathrm dx$$
substitute $\sqrt{1+\tan x}=t$,then
$$I=\int_{1}^{\sqrt{2}}\frac{2t^{2}}{t^{4}-2t^{2}+2}\,\mathrm dt=\int_{1}^{\sqrt{2}}\frac{2}{t^{2}-2+\dfrac{2}{t^{2}}}\,\mathrm dt$$
but I got stuck here for a long time.Any idea?
 A: Hint: Try to use partial fractions
$$\displaystyle\frac{2t^2}{t^4-2t^2+2}=\frac{At+B}{t^2-\sqrt{2+2\sqrt{2}}t+\sqrt{2}}+\frac{Ct+D}{t^2+\sqrt{2+2\sqrt{2}}t+\sqrt{2}}$$
A: Hint:
\begin{align*}
I&=\int_{1}^{\sqrt{2}}\frac{2t^{2}}{t^{4}-2t^{2}+2}\,\mathrm{d}t\\
&=\int_{1}^{\sqrt{2}}\frac{\sqrt{2}+t^{2}+\left ( t^{2}-\sqrt{2} \right )}{t^{4}-2t^{2}+2}\,\mathrm{d}t \\
 &=\int_{1}^{\sqrt{2}}\frac{\displaystyle\frac{\sqrt{2}}{t^{2}}+1}{t^{2}-2+\displaystyle\frac{2}{t^{2}}}\,\mathrm{d}t+\int_{1}^{\sqrt{2}}\frac{1-\displaystyle\frac{\sqrt{2}}{t^{2}}}{t^{2}-2+\displaystyle\frac{2}{t^{2}}}\,\mathrm{d}t \\
 &=\frac{1}{\sqrt{2\sqrt{2}-2}}\int_{1}^{\sqrt{2}}\frac{1}{\left ( \frac{\displaystyle t-\displaystyle\frac{\sqrt{2}}{t}}{\displaystyle\sqrt{2\sqrt{2}-2}} \right )^{2}+1}\,\mathrm{d}\left (\frac{t-\displaystyle\frac{\sqrt{2}}{t}}{\displaystyle\sqrt{2\sqrt{2}-2}}  \right ) \\
 &~~~+\int_{1}^{\sqrt{2}}\frac{1}{\left ( t+\displaystyle\frac{\sqrt{2}}{t}-\sqrt{2\sqrt{2}+2} \right )\left ( t+\displaystyle\frac{\sqrt{2}}{t}+\sqrt{2\sqrt{2}+2} \right )}\,\mathrm{d}\left ( t+\frac{\sqrt{2}}{t} \right )
\end{align*}
then you can take it from here.
