Evaluation of $\displaystyle \int_{0}^{1}\left(1-x^3+x^5-x^8+x^{10}-x^{13}+\ldots\right)dx$ 
Evaluation of $\displaystyle \int_{0}^{1}\left(1-x^3+x^5-x^8+x^{10}-x^{13}+\ldots\right)dx$

$\bf{My\; try::}$ We can write  $\displaystyle 1-x^3+x^5-x^8+x^{10}-x^{13}+\ldots$ as 
$$\displaystyle (1-x^3)\cdot (1+x^5+x^{10}+\ldots ) = \frac{(1-x^3)(1)}{1-x^5}$$
So we can write it as $\displaystyle \frac{(1-x)(x^2+x+1)}{(1-x)(x^4+x^3+x^2+x+1)}$
So our Integral Convert into $\displaystyle \int_{0}^{1}\frac{x^2+x+1}{x^4+x^3+x^2+x+1}dx$ 
Now How can I solve it, Help me
Thanks 
 A: Hint:
$$
\begin{align}\displaystyle \int_{0}^{1}\left(1-x^3+x^5-x^8+x^{10}-x^{13}+\ldots\right)dx&=
1-{1\over4}+{1\over6}-{1\over9}+{1\over11}-{1\over14}+\ldots\\&=
\sum_{k=0}^\infty{3\over(5k+1)(5k+4)}\end{align}
$$
A: To expand the answer posted by @Arentino, we have
$$\begin{align}
S&=3\sum_{k=0}^\infty\frac{1}{(5k+1)(5k+4)}\\\\
&=\frac34+\frac15\sum_{k=1}^\infty\left(\frac{1}{k+1/5}-\frac{1}{k+4/5}\right)\\\\
&=\frac34+\frac15\sum_{k=1}^\infty\left(\frac{1}{k+1/5}-\frac{1}{k}\right)+\frac15\sum_{k=1}^\infty\left(\frac{1}{k}-\frac{1}{k+4/5}\right)\\\\
&=\frac34+\frac15(\psi(9/5)-\psi(6/5)) \tag 1
\end{align}$$
Using the reflection and recurrence formulae of the digamma function in $(1)$ reveals that 
$$\begin{align}
S&=\frac34+\frac15(\psi(9/5)-\psi(6/5))\\\\
&=\frac34+\frac15\left(\psi(4/5)+\frac54\right)-\frac15\left(\psi(1/5)+5\right)\\\\
&=\frac34+\frac15\left(\psi(4/5)-\psi(1/5)\right)+\left(\frac14-1\right)\\\\
&=\frac15 \pi \cot(\pi/5)\\\\\
&=\frac{\pi}{5}\sqrt{1+\frac{2}{\sqrt{5}}}
\end{align}$$
as expected!!
A: Here is a sketch of a way that does not use the digamma function.
If we start with your own favourite(?) change of variable,
$$
u=\frac{1}{x}-x,
$$
then, we end up with
$$
\int_0^{+\infty}\frac{2+u^2}{5+5u^2+u^4}\,du-\int_0^{+\infty}\frac{1}{\sqrt{4+u^2}(5+5u^2+u^4)}\,du
$$
In the first integral, it is easier (than in the original one) to do partial fraction decomposition. In the second integral, we let
$$
t=\frac{u}{\sqrt{4+u^2}},
$$
which will give us the integral
$$
\int_0^1\frac{1-t^2}{5+10t^2+t^4}\,dt,
$$
which also can be done using partial fraction decomposition (don't forget that it should come with a minus). I leave the funny calculations to you...
The final result (as already mentioned in several places before) turns out to be
$$
\frac{\pi}{5}\sqrt{1+\frac{2}{\sqrt{5}}}.
$$
Probably there are smarter substitutions, leading to an even simpler expression to integrate.
A: $$\begin{eqnarray*}\sum_{k=0}^{+\infty}\left(\frac{1}{5k+1}-\frac{1}{5k+4}\right)&=&\int_{0}^{1}\frac{1-x^3}{1-x^5}\,dx\\&=&\int_{0}^{1}\frac{1+\frac{1}{\sqrt{5}}}{2+(1-\sqrt{5})x+2x^2}\,dx+\int_{0}^{1}\frac{1-\frac{1}{\sqrt{5}}}{2+(1+\sqrt{5})x+2x^2}\,dx\end{eqnarray*} $$
where the last identity comes from the residue theorem.
By using the reflection formula for the $\psi$ function, we have that the original series equals:
$$ \frac{1}{5}\left(\psi\left(\frac{4}{5}\right)-\psi\left(\frac{1}{5}\right)\right) =\frac{\pi}{5}\cot\frac{\pi}{5}.$$
