<s>[INST] Indefinite integral $\int \arctan^2 x dx$ in terms of the dilogarithm function I read about the integral
$$\int \arctan^2 x dx$$ in this old post: Evaluation of $\int (\arctan x)^2 dx$
By replacing
$$\arctan x = -\frac{i}{2}\left[\log(1+ix) - \log(i-ix)\right],$$
as suggested there, I ended up with this solution
$$\int\arctan^2 x dx = x\arctan^2x - \frac{1}{2}\log(1+x^2)\arctan x -\log 2 \arctan x  + \mbox{Im}\left\{\mbox{Li}_2\left(\frac{1+ix}{2}\right)\right\} + K, \tag{1}\label{uno}$$
where, as usual, $\mbox{Li}_2(z)$ is the dilogarithm function 
$$\mbox{Li}_2(z) = -\int_0^z \frac{\log(1-u)}{u}du=\sum_{k=1}^{+\infty}\frac{z^k}{k^2}.$$
Is this a correct development? 
In that case, if I determine, using \eqref{uno}, the definite integral $\int_0^1 \arctan^2xdx$ I get the result
$$\int_0^1 \arctan^2xdx=\frac{\pi^2}{16}-\frac{3\pi}{8}\log 2 + \mbox{Im}\left\{\mbox{Li}_2\left(\frac{1+i}{2}\right)\right\}.$$
If I now compare this result with the one given in Definite Integral of $\arctan(x)^2$, i.e.
$$\int_0^1 \arctan^2xdx=\frac{\pi^2}{16}+\frac{\pi}{4}\log 2 - C,$$
where $C$ is the Catalan constant
$$C = \sum_{k=0}^{+\infty} \frac{(-1)^k}{(2k+1)^2},$$
I get the following expression:
$$\mbox{Im}\left\{\mbox{Li}_2\left(\frac{1+i}{2}\right)\right\} = \frac{5\pi}{8}\log 2 - C.$$
Is that reasonable?
 [/INST] Landen's identity states that if $z \notin (1,\infty)$, then
$$
\operatorname{Li}_2(z) = -\operatorname{Li}_2\left(\frac{z}{z-1}\right)-\frac12\ln^2(1-z).
$$
For $z:=(1+i)/2$, we have $z/(z-1) = -i$, thus
$$
\operatorname{Li}_2\left(\frac{i+1}{2}\right) = -\operatorname{Li}_2(-i)-\frac12\ln^2\left(\frac{1-i}{2}\right).
$$
It is well known that
$$
\operatorname{Li}_2(-i) = -iC -\frac{\pi^2}{48},
$$
where $C$ is Catalan's constant. For the logarithmic term we have
\begin{align}
\frac12\ln^2\left(\frac{1-i}{2}\right) &= -\frac{1}{32}\left(\pi - 2\ln(2)\cdot i\right)^2 \\
&= \frac{\ln^2 2}{8} - \frac{\pi^2}{32} + \frac{\pi}{8}\ln(2) \cdot i.
\end{align}
Finally
$$
\operatorname{Li}_2\left(\frac{i+1}{2}\right) = \frac{5\pi^2}{96} - \frac{\ln^2 2}{8} + \left(C - \frac{\pi}{8}\ln 2\right)\cdot i.
$$
You could find a more general approach in this answer, where there is a solution for all $z \in \mathbb{C}$, such that $\left|z/(z-1)\right|=1$.
</s>