$$\int\frac{1}{x^6+1}\,dx$$
How to do this kind of integral, when one has a high degree polynomial in the denominator?
There is an idea in the book to add and subtract $x^2$ in the numerator, so one gets two integrals, but they are easy to do.
$$\int\frac{1}{x^6+1}\,dx = \int\frac{x^2+1}{x^6+1} \,dx - \int\frac{x^2}{x^6+1}\,dx$$
But how would I know that $x^6+1$ is divisible by $x^2+1$? Is there a method that doesn't rely on that division quirk?
Since $x^3+1=(x+1)(x^2-x+1)$, $x^6+1=(x^2+1)(x^4-x^2+1)$. Therefore, your final sum is equal to$$\int\frac1{x^4-x^2+1}\,\mathrm dx-\int\frac{x^2}{x^6+1}\,\mathrm dx$$