Final Answer
$\frac{1}{2}e^x\cos\left(x\right)+\frac{1}{2}e^x\sin\left(x\right)+C_0$
Got another answer? Verify it here!
Step-by-step Solution
Specify the solving method
Choose an option Integrate using basic integrals Integrate by substitution Integrate by parts Suggest another method or feature
Send
1
We can solve the integral $\int e^x\cos\left(x\right)dx$ by applying integration by parts method to calculate the integral of the product of two functions, using the following formula
$\displaystyle\int u\cdot dv=u\cdot v-\int v \cdot du$
Intermediate steps
2
First, identify $u$ and calculate $du$
$\begin{matrix}\displaystyle{u=\cos\left(x\right)}\\ \displaystyle{du=-\sin\left(x\right)dx}\end{matrix}$
Explain this step further
3
Now, identify $dv$ and calculate $v$
$\begin{matrix}\displaystyle{dv=e^xdx}\\ \displaystyle{\int dv=\int e^xdx}\end{matrix}$
5
The integral of the exponential function is given by the following formula $\displaystyle \int a^xdx=\frac{a^x}{\ln(a)}$, where $a > 0$ and $a \neq 1$
$e^x$
Intermediate steps
6
Now replace the values of $u$, $du$ and $v$ in the last formula
$e^x\cos\left(x\right)+\int e^x\sin\left(x\right)dx$
Explain this step further
Intermediate steps
7
The integral $\int e^x\sin\left(x\right)dx$ results in: $e^x\sin\left(x\right)-\int e^x\cos\left(x\right)dx$
$e^x\sin\left(x\right)-\int e^x\cos\left(x\right)dx$
Explain this step further
8
This integral by parts turned out to be a cyclic one (the integral that we are calculating appeared again in the right side of the equation). We can pass it to the left side of the equation with opposite sign
$\int e^x\cos\left(x\right)dx=e^x\cos\left(x\right)-\int e^x\cos\left(x\right)dx+e^x\sin\left(x\right)$
9
Moving the cyclic integral to the left side of the equation
$\int e^x\cos\left(x\right)dx+\int e^x\cos\left(x\right)dx=e^x\cos\left(x\right)+e^x\sin\left(x\right)$
$2\int e^x\cos\left(x\right)dx=e^x\cos\left(x\right)+e^x\sin\left(x\right)$
11
Move the constant term $2$ dividing to the other side of the equation
$\int e^x\cos\left(x\right)dx=\frac{1}{2}\left(e^x\cos\left(x\right)+e^x\sin\left(x\right)\right)$
12
The integral results in
$\frac{1}{2}\left(e^x\cos\left(x\right)+e^x\sin\left(x\right)\right)$
13
Gather the results of all integrals
$\frac{1}{2}\left(e^x\cos\left(x\right)+e^x\sin\left(x\right)\right)$
14
As the integral that we are solving is an indefinite integral, when we finish integrating we must add the constant of integration $C$
$\frac{1}{2}\left(e^x\cos\left(x\right)+e^x\sin\left(x\right)\right)+C_0$
Intermediate steps
$\frac{1}{2}e^x\cos\left(x\right)+\frac{1}{2}e^x\sin\left(x\right)+C_0$
Explain this step further
Final Answer
$\frac{1}{2}e^x\cos\left(x\right)+\frac{1}{2}e^x\sin\left(x\right)+C_0$