Short answer: integration by parts reverses the product rule: ∫u dv = uv − ∫v du. Pick u as the part that gets simpler when differentiated (use the order LIATE: Logs, Inverse trig, Algebraic, Trig, Exponential), let dv be the rest, then apply the formula.
Where the formula comes from
The product rule says (uv)′ = u′v + uv′. Integrate both sides: uv = ∫v du + ∫u dv. Rearranging gives the formula. So integration by parts is just the product rule run backwards — which is why it suits products like x·ex. Not sure if parts is the right method? See when to use integration by parts.
The four-box method
Write four boxes before you start: u, du, dv, v. Filling them in first prevents most errors.
Worked examples
Example 1: ∫x ex dx
u = x, du = dx; dv = exdx, v = ex.
∫x ex dx = x ex − ∫ex dx = x ex − ex + C.
Example 2: ∫x cos x dx
u = x, du = dx; dv = cos x dx, v = sin x.
= x sin x − ∫sin x dx = x sin x + cos x + C.
Example 3: ∫ln x dx (the hidden product)
Write it as ∫ln x · 1 dx. u = ln x, du = (1/x)dx; dv = dx, v = x.
= x ln x − ∫x · (1/x) dx = x ln x − x + C.
Example 4: ∫x² ex dx (parts twice)
u = x², dv = exdx → x²ex − ∫2x ex dx. Apply Example 1 to the remaining integral:
= x²ex − 2(x ex − ex) + C = ex(x² − 2x + 2) + C.
Example 5: ∫ex sin x dx (the loop)
Call the integral I. Parts with u = sin x: I = ex sin x − ∫ex cos x dx. Parts again with u = cos x: ∫excos x dx = ex cos x + I.
So I = ex sin x − ex cos x − I, giving I = ½ex(sin x − cos x) + C.
Example 6: definite integral ∫01 x e2x dx
u = x, v = ½e2x: [½x e2x]01 − ∫01 ½e2x dx = ½e² − [¼e2x]01 = ½e² − ¼e² + ¼ = (e² + 1)/4.
Beginner mistakes
- Choosing u = ex in ∫x ex dx — the new integral gets harder, not easier.
- Sign errors in the minus before ∫v du, especially when v is negative (like −cos x).
- Forgetting to evaluate uv at the limits in definite integrals.
- Dropping + C on indefinite integrals.
Practice section
- ∫x sin x dx
- ∫x e3x dx
- ∫x ln x dx
- ∫arctan x dx
Show answers
- −x cos x + sin x + C
- (x/3)e3x − (1/9)e3x + C
- (x²/2)ln x − x²/4 + C
- x arctan x − ½ln(1 + x²) + C
Now try the 8-question quiz. For the bigger picture see the integrals topic page, and use the free diagnostic to see whether integration is really your weak spot.