How integration by parts works: formula and example

Integration by parts trades one integral for another that may be easier to evaluate. The formula comes directly from the product rule for derivatives. Let’s derive it, then work through an example to see how the new integral helps us finish the calculation.

Start with the product rule

For differentiable functions u and v, the product rule gives

ddx(uv)=udvdx+vdudx

Integrate both sides with respect to x. Integrating the derivative of uv takes us back to the product uv, up to a constant.

uv=∫udvdxdx+∫vdudxdx

Rearrange to leave the first integral on one side. Using dv for v′(x) dx and du for u′(x) dx gives the integration-by-parts formula:

∫udv=uv-∫vdu

The constant of integration is included when we write the final antiderivative. The formula relates the original integral to a product and a second integral, so we choose u and dv to make that second integral more manageable.

Example: Integrate x e⁻ˣ

∫xe-xdx

Choose u = x because its derivative is the simpler constant 1. The rest of the integrand becomes dv, and we can integrate it directly.

u=xdu=dx
dv=e-xdxv=-e-x

Substitute u, v, and du into the formula.

∫xe-xdx=x(-e-x)-∫(-e-x)dx
∫xe-xdx=-xe-x+∫e-xdx

The new integral contains only the exponential function. Integrating it gives

∫xe-xdx=-xe-x-e-x+C
∫xe-xdx=-e-x(x+1)+C

Why did this choice help?

The original integrand was a product of x and e⁻ˣ. After integration by parts, differentiating x removed the polynomial factor from the remaining integral. We could then finish with an antiderivative we already knew.

We can use LIPET as a guide for choosing u: logarithmic, inverse trigonometric, polynomial, exponential, then trigonometric functions. The purpose is to find a choice that simplifies when differentiated while leaving a dv we can integrate. We still examine the resulting integral to decide whether the choice helps.

Why a product does not always require integration by parts

A product can sometimes be integrated by substitution or simplified first. Integration by parts is useful when the change from u dv to v du makes progress; the formula itself comes from the product rule, but choosing an effective setup depends on the functions in the problem.

It also works for definite integrals, with the product uv evaluated at the original endpoints and the remaining integral carrying those same bounds. The underlying relationship is the same one we derived here.