# How do you find the integral of cos(log_e(x)) dx?

Jun 8, 2015

First, try integration-by-parts with $u = \cos \left(\ln \left(x\right)\right)$, $\mathrm{du} = - \sin \left(\ln \left(x\right)\right) \cdot \frac{1}{x}$, $\mathrm{dv} = \mathrm{dx}$, and $v = x$ to get:

$\setminus \int \cos \left(\ln \left(x\right)\right) \setminus \mathrm{dx} = u v - \setminus \int v \setminus \mathrm{du} = x \cos \left(\ln \left(x\right)\right) + \setminus \int \sin \left(\ln \left(x\right)\right) \setminus \mathrm{dx}$.

Now use integration-by-parts again on this second integral with $u = \sin \left(\ln \left(x\right)\right)$, $\mathrm{du} = \cos \left(\ln \left(x\right)\right) \cdot \frac{1}{x}$, $\mathrm{dv} = \mathrm{dx}$, and $v = x$ to get

$\setminus \int \cos \left(\ln \left(x\right)\right) \setminus \mathrm{dx} = x \cos \left(\ln \left(x\right)\right) + \left(x \sin \left(\ln \left(x\right)\right) - \setminus \int \cos \left(\ln \left(x\right)\right) \setminus \mathrm{dx}\right)$.

Adding $\setminus \int \cos \left(\ln \left(x\right)\right) \setminus \mathrm{dx}$ to both sides of this last equation, dividing both sides by 2, and including the $+ C$ at the very end gives the answer:

$\setminus \int \cos \left(\ln \left(x\right)\right) \setminus \mathrm{dx} = \frac{1}{2} x \cos \left(\ln \left(x\right)\right) + \frac{1}{2} x \sin \left(\ln \left(x\right)\right) + C$.