<s>[INST] Help in evaluating $\int_0^{\infty} \frac{2 \sin x \cos^2 x}{x e^{x \sqrt{3}}} dx$ I need some help in evaluating $ \displaystyle \int_0^{\infty} dx \frac{2 \sin x \cos^2 x}{x e^{x \sqrt{3}}}$
The original question: Evaluate $\displaystyle \int_0^{\infty} dx \frac{e^{- x \sqrt 3}}{x} (1 - \sin x)(1 + 2 \sin x - \cos 2x)$
Using $\cos 2x = 1 - 2\sin^2 x$ and $1 - \sin^2 x = \cos^2 x$ I was able to get it into the above form. However, I do not know how to proceed. I would  like some guidance rather than a full answer, please.
 [/INST] I would consider the Laplace transform
$$F(p)=\int_0^{\infty} dx \, \frac{\sin{x}}{x} \cos^2{x} \, e^{-p x}$$
Then
$$\begin{align}F'(p) &= -\int_0^{\infty} dx \, \sin{x} \cos^2{x} \, e^{-p x}\\ &= -\frac14 \int_0^{\infty} dx \,(\sin{3 x}+\sin{x}) e^{-p x}\\ &= -\frac14 \left (\frac{3}{p^2+9}+\frac1{p^2+1} \right )\end{align}$$
Thus
$$F(p) = -\frac14 \left (\arctan{\frac{p}{3}}+\arctan{p} \right ) +C$$
The integration constant is
$$\begin{align}C &= \int_0^{\infty} dx \frac{\sin{x}}{x} \cos^2{x}\\ &= \frac14 \int_0^{\infty} dx \frac{\sin{3 x}}{x} + \frac14 \int_0^{\infty} dx \frac{\sin{x}}{x} \\ &= \frac14 \left ( \frac{\pi}{2} + \frac{\pi}{2}\right )\\ &= \frac{\pi}{4}\end{align}$$
so that
$$F(p) = \frac{\pi}{4} - \frac14 \left (\arctan{\frac{p}{3}}+\arctan{p}  \right ) $$
and your answer is $2 F(\sqrt{3})$ (which accounts for the factor of two in the original integral):
$$\begin{align}2 F(\sqrt{3}) &= \frac{\pi}{2} - \frac12 \left (\arctan{\frac{\sqrt{3}}{3}}+\arctan{\sqrt{3}}  \right )\\ &= \frac{\pi}{2} - \frac12 \left (\frac{\pi}{6} + \frac{\pi}{3} \right ) \\ &= \frac{\pi}{4}\end{align}$$
</s>