Convergence of $\sum_{n=1}^\infty \cos(\pi n^2)(\sqrt{n+1}-\sqrt{n})$ I want to test the convergence of $$\sum_{n=1}^\infty \cos(\pi n^2)(\sqrt{n+1}-\sqrt{n})$$
First of all, $\cos(\pi n^2)=-1$ if $n$ is odd, and $\cos(\pi n^2)=1$ if $n$ is even. That is, $\cos(\pi n^2)=(-1)^n$. So the summation reduces to $$\sum_{n=1}^\infty (-1)^n(\sqrt{n+1}-\sqrt{n})$$
and I don't know what to do from here. I tried the ratio test, root test and comparison test, got nothing. and I don't feel it would converge since $$\sum_{n=1}^\infty (\sqrt{n+1}-\sqrt{n})=\sum_{n=1}^\infty\int_n^{n+1}\frac23 x^\frac32 dx=\int_1^\infty\frac23 x^\frac32 dx=\infty$$ 
Maybe I can use this result but I don't know how, or is this approach wrong?
 A: You are so close to the solution!
You can write
$$\sqrt{n+1}-\sqrt{n}=\frac{\left(\sqrt{n+1}-\sqrt{n}\right)\left(\sqrt{n+1}+\sqrt{n}\right)}{\left(\sqrt{n+1}+\sqrt{n}\right)}=\frac{n+1-n}{\left(\sqrt{n+1}+\sqrt{n}\right)}=\frac{1}{\left(\sqrt{n+1}+\sqrt{n}\right)}=a_n$$
Note now that $a_n$ decreases to zero as $n\to\infty$, and $(-1)^n$ is uniformly bounded by $1$ - with respect to $n$. So, by the Leibnitz criterion, you have that the series:
$$\sum_{n=1}^{\infty}(-1)^na_n$$
is convergent.
Your comment about the integral of $a_n$ was accurate, when reffering to $\sum\limits_{n=1}^\infty$, but is not valid when we multiply by $(-1)^n$.
Bonus: In the same way one can show that the series:
$$\sum_{n=1}^\infty\frac{(-1)^n}{n}$$
is convergent, even if $\sum\limits_{n=1}^\infty\frac{1}{n}=\infty$.
A: Hint: Alternating series test
A series $\sum_{n=1}^\infty (-1)^na_n$ for $a_n$'s either all positive or all negative converges if:
(1) $a_n\to0$ as $n\to \infty$
(2) $a_n$ decreases monotonically
A: Apply alternating series test. You have $a_n:= \sqrt{n+1} - \sqrt n$ decreasing, nonnegative and converging to $0$.
A: Our sum is $\sum_{k=1}^\infty\left(\sqrt{2k+1}-2\sqrt{2k}+\sqrt{2k-1}\right)$, where we have paired the $n=2k-1$ and $n=2k$ terms. Now $\sqrt{2k\pm 1}=\sqrt{2k}\left(1\pm\frac{1}{4k}-\frac{1}{32k^2}+\cdots\right)$ so $\sqrt{2k+ 1}-2\sqrt{2k}+\sqrt{2k-1}\approx-\frac{\sqrt{2k}}{16k^2}\in\mathcal{O}(k^{-3/2})$, which establishes convergence.
