Integration by parts is the product rule run backward. It rewrites the integral of udv as uv minus the integral of vdu, trading an integral you cannot do for one you can. It works when the integrand is a product in which one factor gets simpler when differentiated, such as x, and the other is easy to integrate, such as ex or cosx. It even integrates lnx, written as lnxtimes 1.
Find a function whose derivative is xcosx. Substitution does not help, because neither factor is the derivative of something inside the other. The product rule, though, is what makes products like this one. Differentiating xsinx gives sinx+xcosx, which holds the target and one extra term, sinx.
Remove the extra term by subtracting a function whose derivative is sinx. That function is −cosx, so the candidate is xsinx−(−cosx)=xsinx+cosx. Its derivative is sinx+xcosx−sinx, which is xcosx exactly.
A slope near x=1 settles it. There the target xcosx is cos1≈0.5403. The candidate is about 1.38177 at x=1 and 1.38231 at x=1.001. It climbs about 0.00054 over a step of 0.001, a rate of about 0.540.
The guess worked because x became 1 when differentiated, which left an extra term with no x in it. Integration by parts turns that guess into a method.
dxd(xsinx+cosx)=sinx+xcosx−sinx=xcosx
dxd(xsinx+cosx)=sinx+xcosx−sinx=xcosx
The rule
The formula
Integration by parts applies to an integral of a product. Name one factor u, and call the rest of the integrand, dx included, dv. Then du=u′(x) dx is the differential of u, and v is any one antiderivative of what dv holds, written without +C.
The formula trades the integral of udv for the integral of vdu. The product uv, the integrated term, is what the trade costs. The trade pays when the integral of vdu is easier than the one you started with.
∫udv=uv−∫vdu
Choosing u and dv
Choose u to be the factor that gets simpler when differentiated, and dv a factor you can integrate. A power of x drops a degree with each derivative. lnx and arctanx turn into fractions with no logarithm or inverse function left. ex,sinx and cosx stay just as hard either way, so they usually go in dv.
The order logarithmic, inverse trigonometric, algebraic, trigonometric, exponential, remembered as LIATE, puts the usual u first. It is a guide, not a law, and the table lists common cases.
Common choices of u and dv
Integrand
u
dv
v
xex
x
exdx
ex
xcosx
x
cosxdx
sinx
x2e3x
x2
e3xdx
e3x/3
xlnx
lnx
xdx
x2/2
arctanx
arctanx
dx
x
Why it works
Why it works
Start from the product rule, (uv)′=u′v+uv′. Integrating both sides undoes the derivative on the left, which gives uv=∫vu′dx+∫uv′dx, with the constants gathered into one +C at the end. Moving one integral across the equals sign gives ∫uv′dx=uv−∫vu′dx. Writing dv for v′dx and du for u′dx turns that into the formula.
The formula moves the derivative from one factor to the other. In ∫xexdx,x gives up its derivative, 1, and ex takes its antiderivative, ex. The new integrand is ex⋅1, with no x left. Nothing comes for free, and the integrated term xex carries the difference.
For a definite integral the same steps run between limits. The product rule integrated from a to b gives u(b)v(b)−u(a)v(a) on the left, which is why the integrated term is evaluated at both limits.
∫uv′dx=uv−∫vu′dx
The method
The method in six steps
The table works through ∫xe2xdx. If the integral in step 4 is harder than the one you started with, go back to step 1 and swap the choice.
∫xe2xdx=21xe2x−41e2x+C
∫xe2xdx=21xe2x−41e2x+C
Parts on the integral of xe2x
Step
What to do
For ∫xe2xdx
1
Choose u, the factor that gets simpler
u=x
2
Call the rest dv,dx included
dv=e2xdx
3
Find du and v
du=dx,v=21e2x
4
Write uv−∫vdu
21xe2x−∫21e2xdx
5
Finish the new integral and add C
21xe2x−41e2x+C
6
Check by differentiating
21e2x+xe2x−21e2x=xe2x
More than one round
Each round of parts on a power of x times ex,sinx or cosx lowers the power by one, so x2 needs two rounds. Keep the same kind of choice in every round, with the power of x as u. Switching in round two, with u=ex, undoes round one and hands back the integral you started from.
Some integrals come back after two rounds. Call I the integral of excosx. Parts with u=cosx, then with u=sinx, gives I=excosx+exsinx−I, an equation for I. Adding I to both sides and dividing by 2 gives I=ex(sinx+cosx)/2, and the +C goes on at the end.
∫excosxdx=2ex(sinx+cosx)+C
∫excosxdx=2ex(sinx+cosx)+C
Definite integrals
For a definite integral, evaluate the integrated term at both limits and subtract, then integrate vdu between the same limits. For the integral of xex from 0 to 1, the integrated term is 1⋅e−0⋅1=e, and the integral of ex from 0 to 1 is e−1. The value is e−(e−1)=1.
∫abudv=[uv]ab−∫abvdu
∫abudv=[uv]ab−∫abvdu
Where it breaks
Where it breaks
Parts helps only when the integral of vdu is easier than the integral of udv. With ∫xexdx, the choice u=ex and dv=xdx gives v=x2/2 and a new integral of (x2/2)ex, with a higher power than before. The formula is still true, but it moves the wrong way.
A product does not always call for parts. In ∫xex2dx the factor x is half the derivative of the inside x2, so substitution finishes it in one line. Parts with u=x would need an antiderivative of ex2, which no formula gives. ∫ex/xdx defeats both methods. Each round of parts raises the power of x in the denominator, and the integral has no antiderivative built from the usual functions. In the table, one small change to the integrand moves it from one method to the other, or past both.
The integral of a product is not the product of the integrals. ∫xexdx is not (x2/2)ex+C, whose derivative is xex+(x2/2)ex.
For a definite integral, u and v need continuous derivatives on the whole interval. lnx and 1/x blow up at x=0, so an integral of them from 0 is improper and needs a limit first.
Three integrals of products
Integral
What it needs
Result
∫xexdx
Parts, u=x
(x−1)ex+C
∫xex2dx
Substitution, u=x2
21ex2+C
∫ex/xdx
Neither works
No formula from the usual functions
Check your answer
Check your answer
Parts is the product rule run backward, so the surest test runs it forward again.
Check the answer with the product rule. Its derivative should be the integrand exactly. Differentiating xex+ex, a common sign slip, gives xex+2ex, which exposes the slip at once.
For a definite integral, bound the value. On the interval from 0 to 1 the integrand xex rises from 0 to e and bends upward. A single midpoint rectangle, (1/2)e0.5≈0.824, lies below the true area, and the trapezoid, e/2≈1.359, lies above it. The answer 1 sits between them.
Check the sign. A positive integrand integrated from left to right gives a positive value, so a negative result for the integral of xex from 0 to 1 means a sign was lost.
To have Chalk check the work, write it in a Math box. Put the integral on the first row and your antiderivative, with its +C, on the row below. The Checker marks it ✓ when its derivative is the integrand, and “Not an antiderivative of the integrand in row 1.” with ✗ when it isn’t. Chalk does not ask for the +C.xex−ex without it also reads ✓, because it is one antiderivative, so adding the constant for the whole family is up to you. A row that applies the formula, ∫xexdx=xex−∫exdx, is checked too, and the sign slip xex+∫exdx reads ✗.
For a definite integral, name the antiderivative and test it before you use it, as the lnx example does. Write F(x)=xex−ex, then F′(x)=xex, then F(1)−F(0)=1, and each row is checked. The sign slip, F(x)=xex+ex, makes the F′ row read ✗, and the message “Not the derivative of row 1.” says why. A bracket on its own row under the integral, [xex−ex] from 0 to 1 with the value below it, is checked too. A wrong bracket reads ✗, with a note to check the antiderivative by differentiating it.
A value written straight under an integral that needs parts is checked for some integrands, such as ∫01xexdx=1. For others, such as ∫1elnxdx, it reads “?”, because Chalk can’t follow that step of an integral yet. “?” means not verified, not wrong.
In ∫x3ex2dx, the usual choice is u=x3 and dv=ex2dx. Does that work, and if not, what does?
No, because ex2 has no antiderivative built from the usual functions, so v cannot be found. Take u=x2 and dv=xex2dx, so v=ex2/2. The new integral is ∫xex2dx, and the answer is (x2−1)ex2/2+C. A good dv has to be one you can integrate.
Reduction formulas and the factorial
Parts on xnex with u=xn gives ∫xnexdx=xnex−n∫xn−1exdx. The new integral has the same form with n one lower, so n rounds reach ∫exdx. A formula that lowers an index each time is a reduction formula. Laid out as two columns, the derivatives of xn beside the antiderivatives of ex, it becomes the tabular method, also called tabular integration, with signs alternating +, −, +.
The same step with e−x, on an interval reaching to infinity, shows that the integral of xne−x from 0 to ∞ is n times the one with n−1. The integral with n=0 is 1, so the value is n!=1⋅2 ⋯ n. With n allowed to be any number greater than −1, that integral is Γ(n+1), the gamma function at n+1. It converges for every such n and extends the factorial beyond whole numbers.
Parts also has a picture. Along a curve where u and v both increase, the region between the curve and the v-axis has area ∫udv, and the region between the curve and the u-axis has area ∫vdu. Together they fill the L-shaped difference u(b)v(b)−u(a)v(a) of two rectangles.
∫xnexdx=xnex−n∫xn−1exdx
∫xnexdx=xnex−n∫xn−1exdx
Common mistakes
Choosing u=ex and dv=xdx for ∫xexdx. The new integral, of (x2/2)ex, is harder than the first. Take u=x, which differentiates to 1, and the new integral is ∫exdx.
Dropping the minus sign in uv−∫vdu. For ∫xexdx it turns the right answer, xex−ex+C, into xex+ex+C, whose derivative carries an extra 2ex.
Evaluating the integrated term at the upper limit only. For the integral of xex from 1 to 2,[xex] is 2e2−e, not 2e2. It is part of the antiderivative, so both limits apply.
Leaving off the +C.xex−ex is one antiderivative of xex, and the answer is the whole family xex−ex+C. The constant goes on once, at the end, not on v.
Switching the choice in the second round. In ∫x2exdx, round two with u=ex and dv=2xdx brings back x2ex and ends at I=I. Keep the power of x as u in every round.
Treating ∫xexdx as (∫xdx)(∫exdx). That gives (x2/2)ex+C, whose derivative is xex+(x2/2)ex. The integral of a product is not the product of the integrals.
Key terms
Integration by parts
A method that reverses the product rule: ∫udv=uv−∫vdu. It suits a product in which one factor gets simpler when differentiated and the other is easy to integrate.
Product rule
To differentiate a product, take the derivative of the first factor times the second, plus the first times the derivative of the second: (uv)′=u′v+uv′.
Antiderivative
A function whose derivative is the given function, such as x3 for 3x2. Any two antiderivatives on one interval differ by a constant, which is why answers carry +C.
Integration by substitution
A method that reverses the chain rule: when an integrand has the form f(g(x))⋅g′(x), set u=g(x), so du=g′(x) dx, and integrate f(u) instead. A definite integral also converts its limits to u-values.
Factorial
For a positive integer n,n! is the product of the integers from 1 through n, and 0! is defined as 1. Factorials count arrangements of distinct objects.