When to use: Integrating P(x)/Q(x) where Q(x) factors into linear and quadratic terms.
Step 1: If deg(P) >= deg(Q), divide first to get polynomial + proper fraction.
Step 2: Factor Q(x) completely over the reals.
Step 3: Write the decomposition:
- Each factor (x-a) contributes A/(x-a)
- Each factor (x-a)^k contributes A1/(x-a) + A2/(x-a)^2 + ... + Ak/(x-a)^k
- Each factor (x^2+px+q) contributes (Ax+B)/(x^2+px+q)
- Repeated quadratic factors: similar stacking
Step 4: Find coefficients by:
- Substituting roots of Q (cover-up method for distinct linear factors)
- Comparing coefficients of powers of x
- Using convenient values of x
Step 5: Integrate each term:
- A/(x-a) => A*ln|x-a|
- A/(x-a)^n => A(x-a)^(1-n)/(1-n)
- (Ax+B)/(x^2+px+q) => split into ln and arctan parts