# How to prove $\sum_{n=1}^{\infty} \frac{\sin n\theta \sin \sqrt{n}}{n}$ is convergent or not

I want to check whether $$\sum_{n=1}^{\infty} \frac{\sin n\theta \sin \sqrt{n}}{n}$$ is convergent or not. $$\theta$$ is a real number. What I know is $$|\sum_{n=1}^{N}\sin n\theta| = |\frac{\cos \frac{\theta}{2} - \cos(N+\frac{1}{2})\theta}{2\sin\frac{\theta}{2}}| \leq \frac{1}{|\sin \frac{\theta}{2}|}$$ for $$\theta\neq 2k\pi$$. Let's assume $$\theta \neq 2k\pi$$. So by Dirichlet test, $$\sum_{n=1}^{\infty} \frac{\sin n\theta}{n}$$ is convergent. But I don't quite know how to solve the original one. Any hint or something? Thank you so much!

We may use a combination of summation by parts and the Denjoy-Koksma inequality, since $$\sin\sqrt{n}$$ is approximately constant on short intervals.
Clearly if we manage to prove that $$\sum_{n\geq 1}\frac{1}{n}\cos(n\theta\pm\sqrt{n})$$ is convergent/divergent we are done. Let $$\left\{\frac{p_m}{q_m}\right\}_{m\geq 1}$$ be the sequence of convergents of the continued fraction of $$\pi$$. $$\cos x$$ is Lipschitz-continuous and $$\left|\pi q_m-p_m\right|\leq\frac{1}{q_m}$$, hence $$\sum_{n=1}^{p_m}\frac{\cos(n\theta\pm\sqrt{n})}{n}=H_{p_m}-\sum_{n=1}^{p_m}\frac{1-\cos(n\theta+\sqrt{n})}{n}$$ can be effectively approximated by $$H_{p_m}-\int_{0}^{\pi q_m}\frac{1-\cos(\theta x+\sqrt{x})}{x}\,dx = H_{p_m}-4\int_{0}^{\sqrt{\pi q_m}}\frac{\sin^2\left(\frac{\theta}{4} x^2+\frac{1}{2}x\right)}{x}\,dx$$ due to the Denjoy-Koksma inequality. Invoking the Laplace transform, the problem boils down to checking the convergence of the usual Fresnel integrals and their squares. In a more elementary way, $$\sin^2\left(\frac{\theta}{4}x^2+\frac{1}{2}x\right)$$ has mean value convergent to $$\frac{1}{2}$$ on long intervals, hence the singular part of the last integral is $$4\cdot \frac{1}{2}\log\sqrt{\pi q_m} = \log(\pi q_m)$$ cancelling the singular part of $$H_{p_m}$$, i.e. $$\log(p_m)$$. This should be enough to state the convergence of the original series, at least for $$\theta\not\in\pi\mathbb{Z}$$. If $$\theta=0$$ we have an interesting sub-question. Since $$\sum_{n=p_m}^{p_{m+1}}\frac{\sin\sqrt{n}}{n}\approx \int_{p_m}^{p_{m+1}}\frac{\sin\sqrt{x}}{x}\,dx$$ and $$\int_{0}^{+\infty}\frac{\sin\sqrt{x}}{x}\,dx=\pi$$, it is natural to wonder about a closed form for $$\pi-\sum_{n\geq 1}\frac{\sin\sqrt{n}}{n}.$$