Integrate cos (lnx) dx Integrating by parts:
I'm having a hard time choosing the $u$, $du$, $v$ and $dv$...
I gave it a shot.
$u = \ln x \implies du = 1/x \ dx$
$v= \  ?$
$dv =  \cos \ dx$

$$ \int \cos(\ln x)\ dx $$
$$ \mbox{Let}\ u=\ln x \Rightarrow du=\frac{1}{x}dx\Rightarrow e^udu =dx $$
$$ \int e^u\cos u\ du $$
Now we can use the fact that
$$ \int e^{\alpha u}\cos(\beta u)\ du =\frac{e^{\alpha u}(\alpha\cos(\beta u)+\beta\sin(\beta u))}{\alpha^2+\beta^2}+C $$
To see that 
$$ \int e^u\cos u\ du= \frac{e^{u}(\cos u+\sin u)}{2} +C $$
Therefore 
$$ \int \cos(\ln x)\ dx = \frac{1}{2}x(\cos(\ln x)+\sin(\ln x)) +C $$
