The convergence of $\int_0^\infty \frac{1}{x}e^{\cos x}\sin\sin x dx$. The convergence of $\int_0^\infty \frac{1}{x}e^{\cos x}\sin\sin x dx$? Writting $\frac{1}{x \sin 2x}2 e^{\cos x} \sin x\cdot \sin \sin x \cos x$, ... There should be some cancellations, but how to make it prcise. if $e^{\cos x}$ is absent, it seems easy.
 A: Since convergence at $0$ is straightforward (the integrand is actually bounded there), I'll address convergence at $\infty$, which holds by the following result:
If $f(x)$ is a periodic function whose integral over one period equals $0$, then $\int_1^\infty f(x)/x \,dx$ converges.
(The OP follows since $f(x) = e^{\cos x} \sin(\sin x)$ is periodic with period $2\pi$ and odd, so that $\int_{-\pi}^\pi f(x)\,dx = 0.$)
Proof: Define $F(x)$ to be an antiderivative of $f(x)$. Note that the assumption that the integral of $f(x)$ over one period equals $0$ implies that $F(x)$ is periodic with the same period; since it is also continuous, it is absolutely bounded, say by $B$. In particular.
$\lim_{T\to\infty} F(x)/x = 0$ by the squeeze theorem, and $\int_1^\infty F(x)/x^2\,dx$ converges absolutely by comparison with $\int_1^\infty B/x^2\,dx$.
Then, integrating by parts,
$$
\int_1^T \frac{f(x)}x \,dx = \frac{F(x)}x \bigg|_1^T + \int_1^T \frac{F(x)}{x^2} \,dx = \frac{F(T)}T - F(1) + \int_1^T \frac{F(x)}{x^2} \,dx,
$$
so that
$$
\int_1^\infty \frac{f(x)}x \,dx = \lim_{T\to\infty} \bigg( \frac{F(T)}T - F(1) + \int_1^T \frac{F(x)}{x^2} \,dx \bigg) = -F(1) + \int_1^\infty \frac{F(x)}{x^2} \,dx
$$
converges.
Moral: when we think an integral converges because part of the integrand is oscillating, integrate by parts to integrate the oscillating part of the integrand. This often results in no big loss from the integrated part of the integrand and a significant gain from the differentiated part of the integrand.
