Integral points on a circle Given radius $r$ which is an integer and center $(0,0)$, find the number of integral points on the circumference of the circle.

You are looking for solutions to $m^2 + n^2 = r^2$ for a given $r$.  Clearly $(\pm r, 0), (0, \pm r)$ are four solutions. For others, this is equivalent to finding Pythagorean triples with the same hypotenuse.  You should be able to find a lot of references on this online.
In fact you can derive that, if the prime factorisation of $r = 2^a \prod p_i^{b_i} \prod q_j^{c_j}$ where $p_i \equiv 1\pmod 4$ and $q_i \equiv 3 \pmod 4$, then $f(r) =\dfrac{1}{2}\left(\prod (2b_i + 1) - 1 \right)$ is the number of such triplets.
Each such triple has corresponding solutions in the other three quadrants, so in total we have $4f(r)+4$ integer points on the circle.
