# $\cos{n^2}/n$ series convergence

Given series $\sum_{n=1}^{\infty}\frac {\cos(n^2)}n$.

It is easy to prove it does not converge absolutely.

I need to prove that it converges сonditionally.

I thought about using Dirichlet's test because $1/n$ series is monotone and $\lim_{n\rightarrow\infty} 1/n = 0$.

So the thing i need to prove is $\left|\sum_{1}^k \cos(n^2)\right| < M,\ \forall k$.

If there was $\cos(n)$ instead of $n^2$, it would be easy to prove this statement by multiplication and division by $\cos(0.5)$ and then using some trigonometric formula so that $\left|\sum_{1}^k \cos(n^2)\right| = \left|\frac{cos(0.5)-cos(n-0.5)}{\cos(0.5)}\right| < 2$ or something like that. But this approach seems to be impossible for $\cos(n^2)$.

Maybe there is a way to prove it using the fact that $\int \cos(x^2) = \sqrt{2/\pi}$?

Or any simpler way?

• Your bounds would need to go from $1$ to $\infty$ since $\frac{\cos(n^2)}{n}$ is undefined at $0$. – Kaj Hansen May 25 '14 at 23:02
• Sure, I'll fix it, thanks. – Daniel May 25 '14 at 23:03

It is sufficient to show that $$\left|\sum_{n=0}^{N}\cos(n^2)\right|\leq C\sqrt{N}\log N\tag{1}$$ to ensure convergence by partial summation. Consider that: $$\left\|\sum_{n=1}^{N}e^{in^2}\right\|^2 = \left(\sum_{n=1}^{N}e^{in^2}\right)\cdot\left(\sum_{n=1}^{N}e^{-in^2}\right)=N+\sum_{d=1}^{N-1}\sum_{r=1}^{N-d}2\cos(2dr+d^2),\tag{2}$$ and that: $$(2)\ll \sum_{d=1}^{N-1}\min\left(N-d,\left\|\frac{d}{\pi}\right\|^{-1}\right)\tag{3}$$ (where $\|x\|$ denotes the distance of $x$ from the closest integer) by the usual arguments about simple exponential sums. If now we take $\frac{a}{q}$ as a good rational approximation of $\frac{1}{\pi}$, $\left|\frac{a}{q}-\frac{1}{\pi}\right|<\frac{1}{3Nq}$, it is not difficult to see that: $$(3)\ll \sum_{\substack{d=1\\q\nmid d}}^{N}\left\|\frac{a d}{q}\right\|^{-1}\ll(N+q)\log q\ll N\log N,\tag{4}$$ hence $(1)$ holds and the series $\sum_{n=1}^{+\infty}\frac{\cos n^2}{n}$ converges.
• This is also known as "Weyl differencing trick". $(1)$ is just a consequence of the general en.wikipedia.org/wiki/Weyl%27s_inequality . – Jack D'Aurizio May 25 '14 at 23:31
• You can call it "generalized Dirichlet test", but is just partial summation. What we have is: $$\sum_{n=1}^{N}\frac{\cos(n^2)}{n}=\frac{1}{N}\sum_{n=1}^{N}\cos(n^2)+\sum_{n=1}^{N-1}\frac{1}{n(n+1)}\sum_{k=1}^{n}\cos(n^2)\ll\sum_{n=1}^{N}\frac{\sqrt{n}\log n}{n^2}.$$ – Jack D'Aurizio May 26 '14 at 2:14
• Hi, great solution! I have a question: can you give some estimates for sums of form $\sum_{n=1}^N exp( i f(n))$ where $f$ is not a polynomial, but a bit more complicated, say $f(n) = \sqrt{n}$. ? – Orest Bucicovschi Aug 18 '17 at 11:28