Integrating $\arctan^2(x)$ has been a mystery to me since I first learned to compute indefinite integrals. When I plug it into integral calculator or WolframAlpha, I get a primitive written in terms of complex numbers and polylogarythms; but $\arctan^2(x)$ is continuous and defined $\forall\space x\in\mathbb{R}$, the area under the curve $(x,\arctan^2(x))$ is well-defined and obvioulsy real. In fact, I can integrate that function numerically and get the area without using Barrow's Rule at all.
I thought maybe the complex part of that expression is constant, therefore applying Barrow's Rule always yields a real number anyway, but then I could subtract a constant equal to its imaginary part times $i$ and get a real and still valid antiderivative. Anyway, I have no idea of how to compute that antiderivative in the first place, so I can't check for myself.
Can a real, continuous function have a complex primitive but not a real primitive? And, can anyone give me a hint to help me compute its antiderivative by myself?
You are totally correct.
Using the result, compute it for $x=0$ and you will get $\frac{i \pi ^2}{12}$; do it for any arbitrary value of $x$ and you will get the decimal representation of this number.
What you could also do is to perform a Taylor expansion of the result around $0$ and get $$\frac{i \pi ^2}{12}+\frac{x^3}{3}-\frac{2 x^5}{15}+\frac{23 x^7}{315}-\frac{44 x^9}{945}+O\left(x^{11}\right)$$
Compute its derivative to get $$x^2-\frac{2 x^4}{3}+\frac{23 x^6}{45}-\frac{44 x^8}{105}+O\left(x^{10}\right)$$ while $$\tan^{-1}(x)=x-\frac{x^3}{3}+\frac{x^5}{5}-\frac{x^7}{7}+\frac{x^9}{9}+O\left(x^{10}\right)$$ from which $$\left[\tan ^{-1}(x)\right]^2=x^2-\frac{2 x^4}{3}+\frac{23 x^6}{45}-\frac{44 x^8}{105}+O\left(x^{10}\right)$$