<s>[INST] Partial fractions integral. Compute $\int_{0}^{1} \frac {x^4+1}{x^6+1}dx$ 
Evaluate $\int_{0}^{1} \frac {x^4+1}{x^6+1}dx$.

I directly approached this with partial fractions and rewritten $x^6+1=(x^2)^3+1=(x^2+1)(x^4+x^2+1)$.
Therefore the integral is:
$$\int_{0}^{1} \frac {x^4+1}{(x^2+1)(x^4+x^2+1)}dx=-2\int_{0}^{1} \frac {x}{1+x^2}dx+2\int_{0}^{1}\frac 1{1+x^2}dx-\int_{0}^1\frac {(x-1)^2}{(x^2+1)^2+(\frac {\sqrt{3}}2)^2}dx$$
But I don't know how to solve the last term.
I answered the question... I realized my silly mistake, sorry for bothering...
 [/INST] Note that $x^6+1=(x^2)^3+1=(x^2+1)(x^4-x^2+1)$ and
use the fact that you are integrating over $[0,1]$,
$$\int_0^1 \frac{x^4+1\pm x^2}{x^6+1}dx =\int_0^1 \frac{x^4-x^2+1}{x^6+1}dx+ \frac{1}{3}\int_0^1 \frac{3x^2}{x^6+1}dx\\=\int_0^1 \frac{1}{x^2+1}dx+ \frac{1}{3}\int_0^1 \frac{1}{t^2+1}dt=\left(1+\frac{1}{3}\right)\frac{\pi}{4}=\frac{\pi}{3}$$
where, in the second integral, $t=x^3$.
</s>