<s>[INST] Evaluate $ \int_0^1 \sum_{k=0}^\infty (-x^4)^k dx = \int_0^1 \frac{dx}{1+x^4} $ I have read this thread and I found in some comments the above named equality. I couldn't follow the transformation, which are done to get from the left to the right side at that point in particular.
Can someone help me and show how it's done? 
 [/INST] On the left, reverse the order of summation and integration to get
$$\sum_{k=0}^{\infty} (-1)^k \, \int_0^1 dx \, x^{4 k} = \sum_{k=0}^{\infty} \frac{(-1)^k}{4 k+1} = 1 - \frac15 + \frac19 - \frac1{13} + \cdots$$
This sum is equal to 
$$\int_0^1 \frac{dx}{1+x^4}$$
To evaluate this, observe that
$$1+x^4 = (1+\sqrt{2} x + x^2)(1-\sqrt{2} x+x^2)$$
so that we may use partial fractions in the integrand as follows:
$$\frac1{1+x^4} = \frac{A x+B}{x^2-\sqrt{2} x+1} + \frac{C x+D}{x^2+\sqrt{2} x+1}$$
where one may deduce that $A=-1/(2 \sqrt{2})$, $B=1/2$, $C=1/(2 \sqrt{2})$, and $D=1/2$.  We rewrite the resulting expression for ease of integration:
$$\begin{align}\int_0^1 \frac{dx}{1+x^4} &= \frac1{2} \int_0^1 dx \, \left (\frac{-\frac1{\sqrt{2}} \left (x-\frac1{\sqrt{2}} \right )+\frac12}{\left (x-\frac1{\sqrt{2}} \right )^2+\frac12} + \frac{\frac1{\sqrt{2}} \left (x+\frac1{\sqrt{2}} \right )+\frac12}{\left (x+\frac1{\sqrt{2}} \right )^2+\frac12} \right ) \\ &= \frac1{4 \sqrt{2}} \left [\log{\left (\frac{1+\frac1{\sqrt{2}}}{1-\frac1{\sqrt{2}}} \right )} + 2 \arctan{(\sqrt{2}-1)} + 2 \arctan{(\sqrt{2}+1)} \right ] \\ &=  \frac1{4 \sqrt{2}} \left [\log{\left (\frac{1+\frac1{\sqrt{2}}}{1-\frac1{\sqrt{2}}} \right )} + \pi\right ]\end{align}$$
Thus,
$$\begin{align}\sum_{k=0}^{\infty} \frac{(-1)^k}{4 k+1} = 1 - \frac15 + \frac19 - \frac1{13} + \cdots &= \frac1{4 \sqrt{2}} \left [\pi+\log{\left (\frac{1+\frac1{\sqrt{2}}}{1-\frac1{\sqrt{2}}} \right )} \right ]\\ &=\frac1{4 \sqrt{2}} \left [\pi + 2 \log{\left (\sqrt{2}+1\right )} \right ]\end{align}$$
ADDENDUM
I may as well illustrate how to get the sum of another, similar series almost for free from the above series.  Note that
$$\int_1^{\infty} \frac{dx}{1+x^4} = \int_0^1 dx \frac{x^2}{1+x^4} = \sum_{k=0}^{\infty} \frac{(-1)^k}{4 k+3} $$
However,
$$\begin{align}\int_1^{\infty} \frac{dx}{1+x^4} &= \int_0^{\infty} \frac{dx}{1+x^4} -\int_0^{1} \frac{dx}{1+x^4} \end{align} $$
The first integral on the right may be evaluated using a contour integral and the residue theorem.  I prefer to use a quarter-circle in the upper-right quadrant; the only enclosed pole is at $z=e^{i \pi/4}$.  By the residue theorem, we have
$$(1-i) \int_0^{\infty} \frac{dx}{1+x^4} = \frac{i 2 \pi}{4 e^{i 3 \pi/4}} \implies \int_0^{\infty} \frac{dx}{1+x^4} = \frac{\pi}{2 \sqrt{2}}$$
Thus,
$$\sum_{k=0}^{\infty} \frac{(-1)^k}{4 k+3} = \frac13 - \frac17 + \frac1{11} - \frac1{15} + \cdots = \frac1{4 \sqrt{2}} \left [\pi - 2 \log{\left (\sqrt{2}+1\right )} \right ] $$
</s>