Integrals Involving sin x, cos x and Exponential Functions

Step-by-Step Worked Examples, Integration by Parts Techniques, Exercises, and References

Tutorial to find integrals involving the product of \( \sin(x) \) or \( \cos(x) \) with exponential functions. Exercises with answers are provided at the bottom of the page.

All the integrals included in the examples below are evaluated using Integration by Parts, given by:

\[ \int U \dfrac{dV}{dx} \, dx = UV - \int \dfrac{dU}{dx} V \, dx \]

Integration by parts is particularly useful for evaluating integrals of products of functions of the form \( U \dfrac{dV}{dx} \).

Note: In what follows, \( C \) represents the constant of integration.

Examples with Detailed Solutions

Example 1

Evaluate the integral:

\[ \int \sin(x) e^x \, dx \]
Solution to Example 1

Let \( u = \sin(x) \) and \( \dfrac{dv}{dx} = e^x \), which gives \( u' = \cos(x) \) and \( v = \displaystyle \int e^x \, dx = e^x \).

Using integration by parts:

\[ \int \sin(x)e^x \, dx = \sin(x)e^x - \int \cos(x)e^x \, dx \]

Apply integration by parts a second time to the term \( \displaystyle \int \cos(x)e^x \, dx \):

\[ \int \sin(x)e^x \, dx = \sin(x)e^x - \left( \cos(x)e^x - \int (-\sin(x))e^x \, dx \right) \] \[ \int \sin(x)e^x \, dx = \sin(x)e^x - \cos(x)e^x - \int \sin(x)e^x \, dx \]

Since the integral on the right is the same as the original integral, we can combine them by adding \( \int \sin(x)e^x \, dx \) to both sides:

\[ 2 \int \sin(x)e^x \, dx = \sin(x)e^x - \cos(x)e^x \]

Dividing by 2 gives the final result:

\[ \int \sin(x)e^x \, dx = \dfrac{1}{2} e^x (\sin(x) - \cos(x)) + C \]

Example 2

Evaluate the integral:

\[ \int \cos(2x) \, e^x \, dx \]
Solution to Example 2

Let \( u = \cos(2x) \) and \( \dfrac{dv}{dx} = e^x \), which gives \( u' = -2\sin(2x) \) and \( v = e^x \).

Apply integration by parts:

\[ \begin{aligned} \int \cos(2x)e^x \, dx &= \cos(2x)e^x - \int e^x (-2\sin(2x)) \, dx \\[6pt] &= \cos(2x)e^x + 2 \int e^x \sin(2x) \, dx \end{aligned} \]

Apply integration by parts to the new integral \( \int e^x \sin(2x) \, dx \) (letting \( w = \sin(2x) \) and \( dw/dx = e^x \)):

\[ \begin{aligned} \int \cos(2x)e^x \, dx &= \cos(2x)e^x + 2 \left( \sin(2x)e^x - 2 \int \cos(2x)e^x \, dx \right) \\[6pt] &= \cos(2x)e^x + 2\sin(2x)e^x - 4 \int \cos(2x)e^x \, dx \end{aligned} \]

Grouping the identical integrals on the left-hand side:

\[ 5 \int \cos(2x)e^x \, dx = e^x (\cos(2x) + 2\sin(2x)) \]

Thus, the integral is:

\[ \int \cos(2x) \, e^x \, dx = \dfrac{1}{5} e^x ( \cos(2x) + 2 \sin(2x) ) + C \]

Example 3

Evaluate the integral:

\[ \int \sin(3x + 2) \, e^{3x} \, dx \]
Solution to Example 3

Let \( u = \sin(3x + 2) \) and \( \dfrac{dv}{dx} = e^{3x} \), which gives \( u' = 3\cos(3x + 2) \) and \( v = \dfrac{1}{3}e^{3x} \).

Apply integration by parts:

\[ \int \sin(3x + 2) \, e^{3x} \, dx = \dfrac{1}{3}\sin(3x + 2)e^{3x} - \int \cos(3x + 2) \left(\dfrac{1}{3}e^{3x}\right) \, dx \]

Apply integration by parts one more time to \( \int \cos(3x + 2) e^{3x} \, dx \):

\[ \int \sin(3x + 2) e^{3x} \, dx = \dfrac{1}{3} \sin(3x + 2) e^{3x} - \left( \dfrac{1}{3}\cos(3x + 2)e^{3x} + \int \sin(3x + 2)e^{3x} \, dx \right) \]

Grouping the integrals:

\[ 2 \int \sin(3x + 2) e^{3x} \, dx = \dfrac{1}{3} e^{3x} \left( \sin(3x + 2) - \cos(3x + 2) \right) \]

Dividing by 2:

\[ \int \sin(3x + 2) e^{3x} \, dx = \dfrac{1}{6} e^{3x} ( \sin(3x + 2) - \cos(3x + 2) ) + C \]

Example 4

Evaluate the integral:

\[ \int \cos(4x) \, e^{2x + 5} \, dx \]
Solution to Example 4

Let \( u = \cos(4x) \) and \( \dfrac{dv}{dx} = e^{2x + 5} \). Applying integration by parts twice:

\[ \begin{aligned} \int \cos(4x)e^{2x + 5} \, dx &= \tfrac{1}{2} e^{2x + 5} \cos(4x) + 2 \int e^{2x + 5} \sin(4x) \, dx \\[6pt] &= \tfrac{1}{2} e^{2x + 5} \cos(4x) + 2 \left( \tfrac{1}{2} e^{2x + 5} \sin(4x) - 2 \int e^{2x + 5} \cos(4x) \, dx \right) \end{aligned} \]

Simplifying and gathering terms:

\[ 5 \int \cos(4x) e^{2x+5} \, dx = \dfrac{1}{2} e^{2x+5} \cos(4x) + e^{2x+5} \sin(4x) \]

Dividing by 5 gives the final solution:

\[ \int \cos(4x) \, e^{2x + 5} \, dx = \dfrac{1}{10} e^{2x + 5} ( \cos(4x) + 2 \sin(4x) ) + C \]

Exercises

Evaluate the following integrals:

  1. \( \displaystyle \int \cos(x) \, e^x \, dx \)
  2. \( \displaystyle \int \sin(2x) \, e^{3x} \, dx \)
  3. \( \displaystyle \int \cos(-3x + 5) \, e^{5x} \, dx \)
  4. \( \displaystyle \int \sin(-4x + 3) \, e^{-2x + 1} \, dx \)
Answers to Above Exercises
  1. \( \dfrac{1}{2} e^x ( \cos(x) + \sin(x) ) + C \)
  2. \( \dfrac{1}{13} e^{3x} ( 3 \sin(2x) - 2 \cos(2x)) + C \)
  3. \( \dfrac{1}{34} e^{5x} ( 5 \cos(-3x + 5) - 3 \sin(-3x + 5) ) + C \)
  4. \( \dfrac{1}{10} e^{-2x + 1} ( 2 \cos(-4x + 3) - \sin(-4x + 3) ) + C \)

More References and Links