how do you solve this?:
$\displaystyle
\int \frac {x^3-6}{x^4+6x^2+8} dx
$
The first step you'll need to do is to factorise the denominator. Judging by that polynomial, you will end up with two irreducible quadratic factors. I'll give you a hint on a quick way of factorising: there is a 'hidden quadratic'. Substitute a for $\displaystyle x^2$ and get two factors in terms of a, then convert back to factors in terms of x
Since $\displaystyle x^4+6x^2+8=(x^2+2)(x^2+4)$, that fraction decomposes to:
$\displaystyle \frac{x^3-6}{x^4+6x^2+8}=\frac{Ax+B}{x^2+4}+\frac{Cx+D}{x^2+ 2}$
Solve for $\displaystyle A,B,C,D$ and then integrate the two pieces separately. To do this, break up $\displaystyle \int\frac{Ax+B}{x^2+4}\,dx$ (for whatever values of $\displaystyle A$ and $\displaystyle B$ you get) into $\displaystyle \frac{A}{2}\int\frac{2x}{x^2+4}\,dx+\int\frac{B}{x ^2+4}\,dx=$ $\displaystyle \frac{A}{2}\ln(x^2+4)+\frac{1}{4}\int\frac{B}{(x/2)^2+1}\,dx$
The latter integral will integrate to something involving $\displaystyle \arctan$, but I leave the actual calculations to you.
Looking at this again, the first thing you should do is some substitution to get that cubic out of the numerator.
Let $\displaystyle a = x^4 + 6x^2 + 8$ then $\displaystyle \frac{da}{dx} = 4x^3 + 12x$ so $\displaystyle dx = \frac{da}{4(x^3 + 3x)}$
Now you can make the integral be $\displaystyle \int \frac{x^3 + 3x}{4(x^3 + 3x)a} da + \int \frac{-3x - 6}{x^4 + 6x^2 + 8}dx$
Remember that the integral of a sum is the sum of the integrals. So
$\displaystyle \int\frac{Ax+B}{x^2+4}\,dx=\int\frac{Ax}{x^2+4}\,d x+\int\frac{B}{x^2+4}\,dx$
$\displaystyle \int\frac{Ax}{x^2+4}\,dx=\int\frac{\frac{A}{2}\cdo t2x}{x^2+4}\,dx=\frac{A}{2}\int\frac{2x}{x^2+4}\,d x$
because you can pull constants out in front of integrals.
@ Fausst: I had typo in my original post, which I have fixed.
Also, the general rule for $\displaystyle \arctan$ integration is $\displaystyle \int\frac{c}{x^2+a}\,dx=\frac{c\sqrt{a}}{a}\tan^{-1}\left(\frac{x}{\sqrt{a}}\right)$, where $\displaystyle a$ and $\displaystyle c$ are arbitrary constants.