Express $\int_0^{\pi/2}\{ \operatorname{gd}^{-1}(x)\}dx$ as series of special functions, with $\operatorname{gd}^{-1}(z)$ the inverse Gudermannian

The integral is twice Catalan's constant $$ G = L(1,\chi_4) = 1 - \frac1{3^2} + \frac1{5^2} - \frac1{7^2} + \frac1{9^2} - + \cdots. $$ This constant can be computed efficiently to high precision, even though no further "closed form" is known or expected.

I guessed this as follows. Since ${\rm gd}^{-1}(x) = \int_0^x \sec t \, dt$, your integral is $\int_0^{\pi/2} (\frac\pi2 - t) \sec t \, dt$. Ask gp to compute this numerically with

intnum(x=0,Pi/2,1/cos(x)*(Pi/2-x))

and get

1.8319311883544380301092070298647682217    

; then ask the inverse symbolic calculator for a "simple lookup" of the first 1+24 digits, and the ISC recognizes the number as $2G$. The constant $G$ is known to gp as Catalan(), and indeed

2 * Catalan()

exactly matches the numerically computed integral.

This answer is simple enough that one expects it to be "well-known", and indeed this definite integral is given by Gradshteyn and Ryzhik as 3.747 #2, citing the Nouvelles tables d'intégrales définies of Bierens de Haan (1867).


$$I=\int_0^{\pi/2}\{ \operatorname{gd}^{-1}(x)\}dx=\int_0^{\frac{\pi}{2}} \frac{\frac{\pi} {2} - x}{\cos x} dx\overset{\frac{\pi} {2} - x=t} =\int_{0}^\frac{\pi}{2}\frac{t}{\sin t}dt$$ $$\overset{IBP}=-\int_0^\frac{\pi}{2}\ln\left(\tan\frac{t}{2}\right)dt\overset{\tan \frac{t}{2}=x}=-2\int_0^1 \frac{\ln x}{1+x^2}dx$$ $$=-2\sum_{n=0}^\infty \int_0^1 x^{2n}\ln x dx=2\sum_{n=0}^\infty \frac{(-1)^n}{(2n+1)^2}=2G$$