Reasoning behind integrating f(x)/g(x)? I understand the method to integrate this function would be:
$\int{\frac{x^2+1}{x^4-x^2+1} \thinspace dx}$
Divide all terms by $x^2$:
$= \int{\frac{\frac{x^2}{x^2}+\frac{1}{x^2}}{\frac{x^4}{x^2}-\frac{x^2}{x^2}+\frac{1}{x^2}} \thinspace dx}$
=$ \int{\frac{1+\frac{1}{x^2}}{x^2-1+\frac{1}{x^2}} \thinspace dx}$
Factor the denominator:
=$ \int{\frac{1+\frac{1}{x^2}}{(x-\frac{1}{x})^2 + 1} \thinspace dx}$
Use $u$-substitution:
$ u = x -\frac{1}{x}, du = 1 +\frac{1}{x^2} \thinspace dx$
$ \int{\frac{du}{u^2+1}} $
$= \tan^{-1}{(x-\frac{1}{x})}+C$
I can verify that this is the correct method using the chain rule:
$u = x-\frac{1}{x}, \frac{du}{dx} = 1 +\frac{1}{x^2} $
$y = \tan^{-1}{u}, \frac{dy}{du} = \frac{1}{u^2+1} $
$ \frac{dy}{dx} =  \frac{1}{u^2+1} \times (1 +\frac{1}{x^2})$
$=  \frac{1 +\frac{1}{x^2}}{u^2+1} $
$ =  \frac{1 +\frac{1}{x^2}}{u^2+1} $
$ =  \frac{\frac{x^2 +1}{x^2}}{(x-\frac{1}{x})^2+1} $
$ =  \frac{\frac{x^2 +1}{x^2}}{x^2-2+\frac{1}{x^2}+1} $
$ =  \frac{\frac{x^2 +1}{x^2}}{\frac{x^4-x^2+1}{x^2}} $
$ =  \frac{x^2 +1}{x^4-x^2+1} $
Only after differentiating the resulting integral, does it make sense where the $x^2$ comes from.
As some terms are fractions, distributing the denominator and dividing all terms by the same common denominator simplifies the function.
$$  \frac{\frac{x^2 +1}{x^2}}{\frac{x^4-x^2+1}{x^2}} =  \frac{x^2 +1}{x^4-x^2+1} $$
So it makes sense then that this is the term we will multiply with the original integral in order to make it more useful to work with.
Firstly, is there a name for this technique, that is, multiply all terms by some function of x in order to make it easier to factor into something integratable?
Is there a telltale way to recognise when to use this method, and what the divisor should be (obviously without knowing the answer and working backwards)?
Are there any other ways to solve this integral?
Sometimes I don't feel this method is intuitive enough to remember in exam conditions.
Thanks

Here's another way to do it. I would go for this way if I don't immediately see a trick.
It's a big theorem that all rational functions have elementary antiderivatives. The general way to integrate a rational function is to factor it into quadratics and linears (this is always possible by FTA), and use partial fractions decomposition.
For our specific example, we have to factor $x^4-x^2+1$. The following is a somewhat common trick:
$$x^4-x^2+1 = x^4+2x^2+1 - 3x^2=(x^2+1)^2-(\sqrt3x)^2 = (x^2-\sqrt3x+1)(x^2+\sqrt3x+1)$$
For the partial fraction decomposition, it seems reasonable that the numerators should be constants; fortunately, we can even guess them
$$\dfrac {x^2+1}{(x^2-\sqrt3x+1)(x^2+\sqrt3x+1)}= \dfrac {1/2}{x^2-\sqrt3x+1}+ \dfrac {1/2}{x^2+\sqrt3x+1}$$
And now the way you integrate $\frac {1}{ \text{quadratic}}$ is you complete the square on the bottom.
Completing the Square: From $x^2+bx+c$ we can complete the square to $\left(x+\dfrac {b}{2}\right)^2+ \left( c-\dfrac {b^2}{4} \right)$. This means that 
$$\dfrac {1}{x^2+\sqrt3x+1} = \dfrac {1}{(x+\frac {\sqrt 3}{2})^2+\frac 14}$$
Let me know if you need more help.
