Integration by Parts Calculator

Published on: July 18, 2026
Final Answer: Free | Full Steps: Plus

This Integration by Parts Calculator integrates a product of two functions, and shows the working line by line. One factor is chosen to be differentiated and the other to be integrated, and the formula trades the original integral for an easier one. Choosing the wrong factor makes the new integral harder rather than simpler. Following the same pattern every time keeps that choice deliberate instead of accidental.

Step-by-step method

  1. Set up the problem.
  2. Write the integration by parts formula.
  3. Choose u and dv (LIATE: Log, Inverse trig, Algebraic, Trig, Exponential), then find du and v as Step 3a and Step 3b.
  4. Substitute u, v and du into the formula.
  5. Integrate the remaining integral.
  6. Simplify and add C.

Formula: Integration by Parts

For a product of two functions, pick u to differentiate and dv to integrate, then use uv minus the integral of v du.

\(\int u \, dv = uv - \int v \, du\)

Useful Tips to Remember

The formula is \(\int u\,dv = uv - \int v\,du\). Choose \(u\) as the part that gets simpler when differentiated, using the LIATE order: logarithmic, inverse trigonometric, algebraic, trigonometric, exponential. Sometimes the rule must be used twice. Add \(+C\) at the end, and check the answer by differentiating it.

Required knowledge

Where Is Integration by Parts Used?

Integration by parts integrates a product of two functions, using \(\int u\,dv = uv - \int v\,du\), which comes from the product rule. It handles integrals like \(\int x e^x\,dx\) and \(\int x \sin x\,dx\) that simpler rules cannot. Physicists use it to find work, energy and averages in quantum mechanics, and engineers use it in signal analysis and in Fourier and Laplace transforms. In probability, it gives the expected value of continuous distributions, and in economics it values income that changes over time.

  • Integrating products like \(x e^x\) and \(x \ln x\)
  • Working out Laplace and Fourier transforms in engineering
  • Finding expected values in probability
  • Calculating work and energy in physics
  • Valuing changing income streams in finance

Integration by Parts Practice Problems

Example 1 integrates \(x e^x\), and Example 2 integrates \(x\cos x\). Try choosing \(u\) and \(dv\) yourself before opening each example. For two more free worked examples, check out the Integration by Parts Notes.

The worked examples below go through the same pattern from start to finish, so you can compare every step with your own working. For more practice, the notes page goes further with extra worked examples and fuller explanations of the ideas behind each step. Use them together to check your answers and to understand why each step works.

See Example 1 Hide Example 1

Problem

\(\int x e^{x}\, dx\)

Approach

Step-by-step method

  1. Set up the problem.
  2. Write the integration by parts formula.
  3. Choose u and dv (LIATE: Log, Inverse trig, Algebraic, Trig, Exponential), then find du and v as Step 3a and Step 3b.
  4. Substitute u, v and du into the formula.
  5. Integrate the remaining integral.
  6. Simplify and add C.

Formula

Formula: Integration by Parts

For a product of two functions, pick u to differentiate and dv to integrate, then use uv minus the integral of v du.

\(\int u \, dv = uv - \int v \, du\)

Step 1

Step 1 - Set up the problem.

In this problem: We are integrating a product of two different kinds of functions.

\(\int x e^{x}\, dx\)

Step 2

Step 2 - Write the integration by parts formula.

In this problem: Integration by parts trades one integral for an easier one.

\(\int u \, dv = uv - \int v \, du\)

Step 3

Step 3 - Choose u and dv.

In this problem: By LIATE, choose \(u = x\) and \(dv = e^{x} \, dx\).

\(\begin{gathered} u = x \\ dv = e^{x}\, dx \end{gathered}\)

Step 3a

Step 3a - Differentiate u to find du.

In this problem: The derivative of \(x\) is \(1\).

\(du = 1\, dx\)

Step 3b

Step 3b - Integrate dv to find v.

In this problem: The integral of \(e^{x}\) is \(e^{x}\). The constant C is left until the end.

\(v = \int e^{x}\, dx = e^{x}\)

Step 4

Step 4 - Substitute u, v and du into the formula.

In this problem: Put u, v and du into the formula.

\(\int x e^{x}\, dx = \left(x\right)\left(e^{x}\right) - \int e^{x}\, dx\)

Step 5

Step 5 - Integrate the remaining integral.

In this problem: The remaining integral is \(\int e^{x}\, dx\).

\(\int e^{x}\, dx = e^{x}\)

Step 6

Step 6 - Simplify and add C.

In this problem: Put the result of Step 5 into Step 4, simplify and add C.

\(\int x e^{x}\, dx = \left(x\right)\left(e^{x}\right) - e^{x} + C = x e^{x} - e^{x} + C\)

Final Answer

\(\int x e^{x}\, dx = x e^{x} - e^{x} + C\)
See Example 2 Hide Example 2

Problem

\(\int x \cos{\left(x \right)}\, dx\)

Approach

Step-by-step method

  1. Set up the problem.
  2. Write the integration by parts formula.
  3. Choose u and dv (LIATE: Log, Inverse trig, Algebraic, Trig, Exponential), then find du and v as Step 3a and Step 3b.
  4. Substitute u, v and du into the formula.
  5. Integrate the remaining integral.
  6. Simplify and add C.

Formula

Formula: Integration by Parts

For a product of two functions, pick u to differentiate and dv to integrate, then use uv minus the integral of v du.

\(\int u \, dv = uv - \int v \, du\)

Step 1

Step 1 - Set up the problem.

In this problem: We are integrating a product of two different kinds of functions.

\(\int x \cos{\left(x \right)}\, dx\)

Step 2

Step 2 - Write the integration by parts formula.

In this problem: Integration by parts trades one integral for an easier one.

\(\int u \, dv = uv - \int v \, du\)

Step 3

Step 3 - Choose u and dv.

In this problem: By LIATE, choose \(u = x\) and \(dv = \cos{\left(x \right)} \, dx\).

\(\begin{gathered} u = x \\ dv = \cos{\left(x \right)}\, dx \end{gathered}\)

Step 3a

Step 3a - Differentiate u to find du.

In this problem: The derivative of \(x\) is \(1\).

\(du = 1\, dx\)

Step 3b

Step 3b - Integrate dv to find v.

In this problem: The integral of \(\cos{\left(x \right)}\) is \(\sin\left(x\right)\). The constant C is left until the end.

\(v = \int \cos{\left(x \right)}\, dx = \sin\left(x\right)\)

Step 4

Step 4 - Substitute u, v and du into the formula.

In this problem: Put u, v and du into the formula.

\(\int x \cos{\left(x \right)}\, dx = \left(x\right)\left(\sin\left(x\right)\right) - \int \sin{\left(x \right)}\, dx\)

Step 5

Step 5 - Integrate the remaining integral.

In this problem: The remaining integral is \(\int \sin{\left(x \right)}\, dx\).

\(\int \sin{\left(x \right)}\, dx = -\cos\left(x\right)\)

Step 6

Step 6 - Simplify and add C.

In this problem: Put the result of Step 5 into Step 4, simplify and add C.

\(\int x \cos{\left(x \right)}\, dx = \left(x\right)\left(\sin\left(x\right)\right) - \left(-\cos\left(x\right)\right) + C = x \sin{\left(x \right)} + \cos{\left(x \right)} + C\)

Final Answer

\(\int x \cos{\left(x \right)}\, dx = x \sin{\left(x \right)} + \cos{\left(x \right)} + C\)

Notes and Practice Mode

Example Problems

Click one to load it into the box and solve it.