Improper integral containing $\sqrt{\cos x-\frac1{\sqrt 2}}$ in the denominator How do I find the value of this integral--
$$I=\displaystyle\int_{0}^{\pi/4} \frac{\sec^2 x \ dx}{\sqrt {\cos x-\dfrac{1}{\sqrt 2}}}$$
I came across this integral too in physics.

With $t=\cos(x)$, we see it is an elliptic integral,
$$
I = \int_{1/\sqrt{2}}^1 \frac{dt}{t^2\sqrt{(1-t^2)(t-1/\sqrt{2})}}
$$  
added 
Maple gets: if $0<a<1$, then
$$
\int _{a}^{1}\!{\frac {dt}{{t}^{2}\sqrt { \left( 1-t^2 \right) 
 \left( t-a \right) }}}{}
=-{\frac {\sqrt {2}{\bf K} \left( 1
/2\,\sqrt {-2\,a+2} \right) }{a}}
+{\frac {\sqrt {2} \left( a+1
 \right) {\bf E} \left( 1/2\,\sqrt {-2\,a+2} \right) }{a
 \left( 1+a \right) }}
+\frac{1}{\sqrt {2}} \left( a+1 \right) {\bf \Pi} \left({\frac {a-1}{2a}},
\frac{\sqrt {-2\,a+2}}{2} \right) 
{a}^{-2}
$$
and in particular with $a=1/\sqrt{2}$,
$$
I = 2\,{\bf E} \left( 1/2\,\sqrt {2-\sqrt {2}} \right) -2\,{\bf K} \left( 1/2\,\sqrt {2-\sqrt {2}} \right) + \left( 1+\sqrt {2
} \right) {\bf \Pi} \left( 1/4\, \left( -2+\sqrt {2} \right) 
\sqrt {2},1/2\,\sqrt {2-\sqrt {2}} \right) \approx 3.338954
$$
where Maple's notation uses the modulus $k$.
