Show that $\sum_{n=1}^N \ \sum_{x^2+y^2 = n,} 1 = \pi N +\mathcal{O}\bigl( \sqrt{N}\bigr)$

71 Views Asked by At

I am need to show that:

$$\sum_{n=1}^N \ \sum_{x^2+y^2 = n,} 1 = \pi N +\mathcal{O}\bigl( \sqrt{N}\bigr).$$

My attempt goes as follows: $\sum_{n=1}^N \ \sum_{x^2+y^2 = n,} 1$ can be imagined as a set of lattice points contained in a circle of radius $\sqrt{N}$ (centered at $0$), so $\pi N$ denotes the area of said circle and $2\pi\sqrt{N}$ its circumference. We observe that we can relate each lattice point (with the exception of $0$) to a unit square. Since lattice points can lie in the interior and on the margin of the said circle we have:

$$\sum_{n=1}^N \ \sum_{x^2+y^2 = n,} 1 \le \pi N + 2\pi \sqrt{N}+1 \quad (\forall N \ge 1)$$

, where the $+1$ is because of the $0$-point.

I think my proof would benefit from some more rigor. Could you give me some suggestions on how to make it more formal?

1

There are 1 best solutions below

0
On BEST ANSWER

For $(x,y)\in\mathbb{Z}^2$ such that $x^2+y^2\leqslant N$, we consider a unite square centered around $(x,y)$ so that $$\sum_{n=1}^N\sum_{x^2+y^2=n}1$$ is the area of the reunion of these squares. According to Pythagorean theorem, the reunion of these squares is in between the disks of radius $\sqrt{N}-\frac{\sqrt{2}}{2}$ and $\sqrt{N}+\frac{\sqrt{2}}{2}$ (this is because the length of the diagonal of such a square is $\sqrt{2}$). Here is the case $N=4$ :

Thus $$ \pi\left(\sqrt{N}-\frac{\sqrt{2}}{{2}}\right)^2\leqslant\sum_{n=1}^N\sum_{x^2+y^2=n}1\leqslant\pi\left(\sqrt{N}+\frac{\sqrt{2}}{2}\right)^2 $$ and finally $$ \sum_{n=1}^N\sum_{x^2+y^2=n}1=\pi N+\mathcal{O}(\sqrt{N}) $$