Partial Fractions
Partial fractions is a way to integrate functions of the form $\displaystyle\frac{P(x)}{Q(x)}$, where $P(x)$ and $Q(x)$ are polynomials (also called rational functions).
The key is to decompose $\displaystyle\frac{P(x)}{Q(x)}$ into a sum of simpler fractions, which are related to the terms in the factorization of $Q(x)$.
Example: $$\frac{2}{x^21} = \frac{1}{x1}  \frac{1}{x+1} $$

What to look for
 If the degree of $P(x)$ is greater or equal to the degree of $Q(x)$, then we need to use long division.
 For every factor of $(xa)$ in $Q(x)$, we have a term $\displaystyle\frac{A}{xa}$.
 For every repeated linear factor $(xa)^n$, we have $$\displaystyle\frac{A_1}{(xa)} + \frac{A_2}{(xa)^2} + \ldots + \frac{A_n}{(xa)^n}.$$
 For every quadratic factor $x^2 + bx + c$, we have $$\displaystyle\frac{Ax+B}{x^2+bx+c}.$$
 For every repeated quadratic factor $(x^2+bx+c)^n$, we have $$\displaystyle\frac{A_1 x + B_1}{x^2+bx+c} + \frac{A_2x+B_2}{(x^2+bx+c)^2}+\ldots + \frac{A_nx+B_n}{(x^2+bx+c)^n}.$$

Finally, we have to integrate the resulting terms. Linear factors give logs. Quadratic factors give a combination of logs and arctangents, thanks to what you learned about trig substitutions.
Example: $$\int \frac{x^3}{x^2 1}\,dx =
\int \left(x + \frac{x}{x^2 1}\right)\,dx=
\int x\,dx+ \frac{1}{2}\int\left( \frac{1}{x1} + \frac{1}{x+1} \right)\,dx $$
$$\qquad\qquad\qquad= \frac{x^2}{2}+ \frac{1}{2}\Bigl(\ln\lvert x1\rvert +\ln\lvert x+1\rvert \Bigr)+ C$$

