Long division, explain the result! I have this: $$ \frac{x^2}{x^2+1} $$ Wolfram Alpha suggests that I should do long division to get this: $$ 1- \frac{1}{x^2+1} $$ But I don't understand how it can be that, please explain.

This is the calculation taking place:
$$\frac{x^2}{x^2 + 1} = \overbrace{\frac{x^2 + 1 -1}{x^2 + 1}}^{Adding\,+1-1} = \underbrace{\frac{x^2 + 1}{x^2 + 1}}_{=1} - \frac{1}{x^2 + 1} = 1 - \frac{1}{x^2 + 1}$$
