Courses
Courses for Kids
Free study material
Offline Centres
More
Store Icon
Store
seo-qna
SearchIcon
banner

Evaluate the following integral: $I=\int{{{e}^{x}}\left( \cos x-\sin x \right)dx}$

Answer
VerifiedVerified
585.6k+ views
Hint: We will split the given function in order to simplify it. We will integrate the simplified function using the method of integration by parts, since the integrand will be a product of two types of functions. The formula for integration by parts for functions $u$ and $v$ with respect to $x$ is as follows,
$\int{uvdx}=u\int{vdx}-\int{\left( \dfrac{du}{dx}\cdot \int{vdx} \right)}dx$ .

Complete step-by-step answer:
The function we have to integrate is ${{e}^{x}}(\cos x-\sin x)$. We will split it in the following manner,
${{e}^{x}}(\cos x-\sin x)={{e}^{x}}\cos x-{{e}^{x}}\sin x$
Now, the integral will become
$\begin{align}
  & I=\int{{{e}^{x}}\left( \cos x-\sin x \right)dx} \\
 & =\int{{{e}^{x}}\cos xdx}-\int{{{e}^{x}}\sin xdx}
\end{align}$
We will first integrate the first term of the above equation. As the first term is a product of the exponential function and a trigonometric function, we will use the method of integration by parts. The formula for integration by parts for functions $u$ and $v$ with respect to $x$ is as follows,
$\int{uvdx}=u\int{vdx}-\int{\left( \dfrac{du}{dx}\cdot \int{vdx} \right)}dx$ .
Substituting $u=\cos x$ and $v={{e}^{x}}$ in the above formula, we get the following,
$\int{\cos x\cdot {{e}^{x}}dx}=\cos x\cdot \int{{{e}^{x}}dx}-\int{\left[ \dfrac{d(\cos x)}{dx}\int{{{e}^{x}}dx} \right]dx}$
Simplifying this expression, we get
$\begin{align}
  & \int{\cos x\cdot {{e}^{x}}dx}=\cos x\cdot {{e}^{x}}-\int{-\sin x\cdot {{e}^{x}}dx} \\
 & ={{e}^{x}}\cos x+\int{{{e}^{x}}\sin xdx}
\end{align}$
Now we will substitute this expression in place of the first term of $I$, we have the following equation,
$I={{e}^{x}}\cos x+\int{{{e}^{x}}\sin xdx}-\int{{{e}^{x}}\sin xdx}$
Since, the terms with integrals will cancel out, we will get $I=={{e}^{x}}\cos x+c$ where $c$ is the integration constant.
Therefore, the value of the integration is $I={{e}^{x}}\cos x+c$.

Note: It is important to understand by observing the function how it should be simplified. The simplification should help us realize which method of integration needs to be used. We are aware that the sine function and cosine function are related to each other via differentiation and integration. So, we chose to integrate the function by parts. Application of the formula for integration by parts needs to be done carefully since the second term in it has an integral inside an integral.