I have a question here that requires me to find the Maclaurin series expansion of $\arctan^{2}(x)$. Now I know how to find it for $\arctan(x)$, by taking the derivative, expanding it into a series, and integrating back (given x is in the interval of uniform convergence), But applying that here leaves me with $$\frac{df}{dx}=2\arctan(x)\frac{1}{(x^2+1)}$$ I am not sure If I can pick out parts of the product (like $\arctan(x)$) and differentiate, expand , then integrate them. Even if I did, how would I go about multiplying two series? Is there an easier way to do this? Thanks.
4 Answers
Using the Cauchy Product Formula, $$ \begin{align} \frac{\mathrm{d}}{\mathrm{d}x}\arctan^2(x) &=2\frac{\arctan(x)}{1+x^2}\\ &=2\left(x-\frac{x^3}3+\frac{x^5}5-\frac{x^7}7+\cdots\right)\left(1-x^2+x^4-x^6+\cdots\right)\\ &=2\left((1)x-\left(1+\tfrac13\right)x^3+\left(1+\tfrac13+\tfrac15\right)x^5-\left(1+\tfrac13+\tfrac15+\tfrac17\right)x^7+\cdots\right)\\ &=2\sum_{k=1}^\infty(-1)^{k-1}\left(H_{2k}-\tfrac12H_k\right)x^{2k-1} \end{align} $$ Therefore, $$ \arctan^2(x)=\sum_{k=1}^\infty\frac{(-1)^{k-1}}k\left(H_{2k}-\tfrac12H_k\right)x^{2k} $$

- 345,667
-
Thank you. I suspected the series had to be multiplied. It looks like you got it in as closed a form as it can get with the harmonic series inside. – math101 Nov 23 '18 at 18:50
We can try to obtain the series in the following way:
$$f(x)=\arctan^2 x=x^2 \int_0^1 \int_0^1 \frac{du~dv}{(1+x^2u^2)(1+x^2v^2)}$$
It's easier to consider:
$$g(x)=\int_0^1 \int_0^1 \frac{du~dv}{(1+x^2u^2)(1+x^2v^2)}$$
Let's use partial fractions:
$$\frac{1}{(1+x^2u^2)(1+x^2v^2)}=\frac{u^2}{(u^2-v^2)(1+x^2u^2)}-\frac{v^2}{(u^2-v^2)(1+x^2v^2)}$$
We obtain a sum of two singular integrals, which however, can both be formally expanded into a series:
$$g(x)=\int_0^1 \int_0^1 \left(\frac{u^2}{(u^2-v^2)(1+x^2u^2)}-\frac{v^2}{(u^2-v^2)(1+x^2v^2)} \right) du ~dv=$$
$$g(x)=\sum_{n=0}^\infty (-1)^n x^{2n} \int_0^1 \int_0^1 \left(\frac{u^{2n+2}}{u^2-v^2}-\frac{v^{2n+2}}{u^2-v^2} \right) du ~dv$$
Now:
$$g(x)=\sum_{n=0}^\infty (-1)^n x^{2n} \int_0^1 \int_0^1 \frac{u^{2n+2}-v^{2n+2}}{u^2-v^2} du ~dv$$
Obviously, every integral is finite now, and we can write:
$$\int_0^1 \int_0^1 \frac{u^{2n+2}-v^{2n+2}}{u^2-v^2} dv ~du=2 \int_0^1 \int_0^u \frac{u^{2n+2}-v^{2n+2}}{u^2-v^2} dv ~du= \\ = 2 \sum_{k=0}^\infty \int_0^1 \int_0^u u^{2n} \left(1-\frac{v^{2n+2}}{u^{2n+2}} \right) \frac{v^{2k}}{u^{2k}} dv ~du =2 \sum_{k=0}^\infty \int_0^1 \int_0^1 u^{2n+1} \left(1-t^{2n+2} \right) t^{2k} dt ~du= \\ = 2 \sum_{k=0}^\infty \int_0^1 \left(\frac{1}{2k+1}-\frac{1}{2k+2n+3} \right) u^{2n+1}~du= 2\sum_{k=0}^\infty \frac{1}{(2k+1)(2k+2n+3)}$$
So we get:
$$g(x)=\frac{1}{2} \sum_{n=0}^\infty (-1)^n x^{2n} \sum_{k=0}^\infty \frac{1}{(k+\frac{1}{2})(k+n+\frac{3}{2})}$$
The inner series converges for all $n$, and we can formally represent it as a difference of two divergent harmonic series, which, after some manipulations, should give us the same result as robjohn obtained.
I suppose, a kind of closed form for the general term can also be given in terms of digamma function:
$$g(x)=\frac{1}{2} \sum_{n=0}^\infty (-1)^n \frac{\psi \left(n+\frac32 \right)-\psi \left(\frac12 \right)}{n+1} x^{2n}$$
Which makes:
$$\arctan^2 x=\frac{x^2}{2} \sum_{n=0}^\infty (-1)^n \frac{\psi \left(n+\frac32 \right)-\psi \left(\frac12 \right)}{n+1} x^{2n}$$
Which is essentially the same as robjohn's answer.

- 31,474
-
Thank you. I got it now. You went with a bit more advanced path. e.g. I haven't used digamma functions before. But I see the reasoning. – math101 Nov 23 '18 at 18:51
-
@math101, the thing is: the expression with harmonic numbers involves subtraction of two divergent series, so it's numerically unstable. But using digamma function (which has a lot of definitions, see Wikipedia for example) or directly the series for $k$ I have, allows us a stable algorithm for computing the coefficients. Even if it doesn't look as pretty – Yuriy S Nov 26 '18 at 13:05
-
I'm curious: what two divergent series are you claiming cause a problem with my answer? I used the Cauchy Product Formula to compute the coefficients and then noted that harmonic numbers can be used to represent those coefficients. The fact that the harmonic series is divergent has no bearing on this. – robjohn Apr 27 '22 at 07:30
-
@robjohn, you are right, it's been years, I have no idea why I said that. My series involves subtraction as well. For what it's worth, I had your answer upvoted – Yuriy S Apr 27 '22 at 07:39
-
I have shown the equivalence of the sum from your answer and $H_{2n+2}-\frac12H_{n+1}$ here. To view it, you will need to have ChatJax or similar installed. – robjohn Apr 27 '22 at 13:08
For the sake of an alternative method, here's a double series.
For $|x|<1$, we have $$\arctan x=\sum_{k\geq0}\frac{(-1)^kx^{1+2k}}{1+2k}$$ As you noted, $$\arctan^2x=2\int\frac{\arctan x}{x^2+1}\mathrm{d}x$$ So, assuming $|x|<1$, $$\arctan^2x=2\int\frac1{x^2+1}\sum_{k\geq0}\frac{(-1)^kx^{1+2k}}{1+2k}\mathrm{d}x$$ $$\arctan^2x=2\sum_{k\geq0}\frac{(-1)^k}{1+2k}\int\frac{x^{2k}}{1+x^2}x\mathrm{d}x$$ Now we focus on $$I=\int\frac{x^{2k+1}}{1+x^2}\mathrm{d}x$$ We recall that for $|x|<1$, $$\frac1{1+x^2}=\frac12\sum_{n\geq0}i^n\big(1+(-1)^n\big)x^n$$ Hence $$I=\frac12\sum_{n\geq0}i^n\big(1+(-1)^n\big)\int x^{2k+n+1}\mathrm{d}x$$ $$I=\frac12\sum_{n\geq0}\frac{i^n\big(1+(-1)^n\big)}{2k+n+2}x^{2k+n+2}$$ Then we have our (pretty inefficient) result: $$\arctan^2x=\sum_{k\geq0}\frac{(-1)^k}{1+2k}\sum_{n\geq0}\frac{i^n\big(1+(-1)^n\big)}{2k+n+2}x^{2k+n+2}$$ $$\arctan^2x=\sum_{n,k\in\Bbb N}\frac{(-1)^{k+\frac{n}2}\big(1+(-1)^n\big)}{(1+2k)(2+2k+n)}x^{2k+n+2}$$

- 17,161
For $|t|<1$, we have \begin{align*} \arctan t&=\sum_{k=0}^{\infty}(-1)^{k}\frac{t^{2k+1}}{2k+1},\\ \frac{(\arctan t)^2}{2!}&=\sum_{k=0}^{\infty}(-1)^{k}\Biggl(\sum_{\ell=0}^{k}\frac{1}{2\ell+1}\Biggr)\frac{t^{2k+2}}{2k+2}\\ &=\frac{t^2}{2}-\biggl(1+\frac{1}{3}\biggr)\frac{t^4}{4} +\biggl(1+\frac{1}{3}+\frac{1}{5}\biggr)\frac{t^6}{6}-\dotsm,\\ \frac{(\arctan t)^3}{3!}&=\sum_{k=0}^{\infty}(-1)^{k}\Biggl(\sum_{\ell_2=0}^{k}\frac{1}{2\ell_2+2}\sum_{\ell_1=0}^{\ell_2} \frac{1}{2\ell_1+1}\Biggr) \frac{t^{2k+3}}{2k+3}\\ &=\frac{1}{2}\frac{t^3}{3} -\biggl[\frac{1}{2}+\frac{1}{4}\biggl(1+\frac{1}{3}\biggr)\biggr]\frac{t^5}{5} +\biggl[\frac{1}{2}+\frac{1}{4}\biggl(1+\frac{1}{3}\biggr)+\frac{1}{6}\biggl(1+\frac{1}{3}+\frac{1}{5}\biggr)\biggr]\frac{t^7}{7}-\dotsm,\\ \frac{(\arctan t)^4}{4!}&=\sum_{k=0}^{\infty}(-1)^{k}\Biggl(\sum_{\ell_{3}=0}^{k}\frac{1}{2\ell_{3}+3} \sum_{\ell_2=0}^{\ell_3}\frac{1}{2\ell_2+2}\sum_{\ell_1=0}^{\ell_2} \frac{1}{2\ell_1+1}\Biggr)\frac{t^{2k+4}}{2k+4},\\ \frac{(\arctan t)^5}{5!}&=\sum_{k=0}^{\infty}(-1)^{k}\Biggl[\sum_{\ell_{4}=0}^{k}\frac{1}{2\ell_{4}+4} \sum_{\ell_{3}=0}^{\ell_4}\frac{1}{2\ell_{3}+3} \sum_{\ell_2=0}^{\ell_3}\frac{1}{2\ell_2+2}\sum_{\ell_1=0}^{\ell_2} \frac{1}{2\ell_1+1}\Biggr]\frac{t^{2k+5}}{2k+5}, \end{align*} and, generally, \begin{equation} \begin{aligned}\label{arctan-power-series-expansion-gen} \frac{(\arctan t)^n}{n!}&=\sum_{k=0}^{\infty}(-1)^{k} \Biggl(\sum_{\ell_{n-1}=0}^{k}\frac{1}{2\ell_{n-1}+n-1} \sum_{\ell_{n-2}=0}^{\ell_{n-1}}\frac{1}{2\ell_{n-2}+n-2}\dotsm \sum_{\ell_2=0}^{\ell_3}\frac{1}{2\ell_2+2}\sum_{\ell_1=0}^{\ell_2} \frac{1}{2\ell_1+1}\Biggr)\frac{t^{2k+n}}{2k+n}\\ &=\sum_{k=0}^{\infty}(-1)^{k}\Biggl(\prod_{m=1}^{n-1}\sum_{\ell_m=0}^{\ell_{m+1}} \frac{1}{2\ell_{m}+m}\Biggr)\frac{t^{2k+n}}{2k+n} \end{aligned} \end{equation} for all $n\in\mathbb{N}$ with $\ell_n=k$, where the product is understood to be $1$ if the starting index exceeds the finishing index.
References
- B.-N. Guo, D. Lim, and F. Qi, Maclaurin's series expansions for positive integer powers of inverse (hyperbolic) sine and tangent functions, closed-form formula of specific partial Bell polynomials, and series representation of generalized logsine function, Appl. Anal. Discrete Math. 16 (2022), in press; available online at https://doi.org/10.2298/AADM210401017G.
- M. Milgram, A new series expansion for integral powers of arctangent, Integral Transforms Spec. Funct. 17 (2006), no. 7, 531--538; available online at https://doi.org/10.1080/10652460500422486 or https://arxiv.org/abs/math/0406337.

- 1,691