# Trouble with this integration by parts integral

$$\int e^{6x}\cos7x \mathrm dx$$

I was trying integration by parts:

$$\int e^{6x}\cos7x \mathrm dx = \frac{1}{7}e^{6x}\sin(7x)-\frac{6}{7}\int e^{6x}\sin(7x)\mathrm dx$$

however I get an equally hard integral on the right.

• Try it one more time! Dec 4, 2023 at 20:07
• Does this answer your question? Integral of $\int e^{2x} \sin 3x\, dx$ Dec 4, 2023 at 20:10

Hint: Integrate by parts a second time. The $$e^{6x}\cos(7x)$$ term will reappear. Rearrange the equation by combining it with the original on the lefthand side.
In general, \begin{aligned} \frac{b}{a} I+\frac{a}{b} I = & \frac{b}{a} \int e^{a x} \cos (b x) d x+\frac{a}{b} \int e^{a x} \cos (b x) d x \\ = & \frac{1}{a} \int e^{a x} d(\sin b x)+\frac{1}{b} \int \cos (b x) d\left(e^{a x}\right) \\ = & \frac{1}{a}\left[e^{a x} \sin b x d x-a \int e^{a x} \sin b x d x\right] +\frac{1}{b}\left[e^{a x} \cos b x+b \int e^{a x} \cos b x\right]+c \\=& \frac{e^{a x}}{ab}(b \sin b x+a \cos b x)+c\\ I= & \frac{e^{a x}}{a^2+b^2}(b \sin b x+a \cos b x)+C \end{aligned}
\begin{align}I(a,b)=&\int e^{ax}\cos(bx)dx\\ =&e^{ax}\frac{\sin(bx)}{b}-\int ae^{ax}\frac{\sin(bx)}{b}dx\\ =&e^{ax}\frac{\sin(bx)}{b}-\left(\color{red}{-}ae^{ax}\frac{\color{red}{\cos(bx)}}{b^2}\color{red}{+}\int a^2e^{ax}\frac{\color{red}{\cos(bx)}}{b^2}\right)\\ =&e^{ax}\frac{\sin(bx)}{b}+ae^{ax}\frac{\cos(bx)}{b^2}-\frac{a^2}{b^2}\underbrace{\int e^{ax}\cos(bx)dx}_{I(a,b)}\\ I(a,b)=&e^{ax}\frac{\sin(bx)}{b}+ae^{ax}\frac{\cos(bx)}{b^2}-\frac{a^2}{b^2}I(a,b)\\ \left(1+\frac{a^2}{b^2}\right)I(a,b)=&e^{ax}\frac{\sin(bx)}{b}+ae^{ax}\frac{\cos(bx)}{b^2}&\end{align} Now its simple to rearrange for $$I(a,b)$$. Note the same technique will work for: $$\int e^{ax}\sin(bx)dx$$ Taking advantage of the periodicity of both functions higher order derivatives.