Previous | ToC | Next Labs: Cryptography. Part 2. Math Alive

Modular Arithmetic and Fermat


You may have heard of Fermat's last theorem. Its proof involves modular arithmetic (and much more!). Fermat also used modular arithmetic to discover many other interesting things about numbers.
For instance: can you find two numbers x and y so that the sum of their squares, x2 + y2, is exactly 3 more than a multiple of 4, that is
x2 + y2 = 4n + 3 or x2 + y2 = 3 (mod 4) ?
Try it!
(Please choose x and y between 0 and 9999 to prevent overflow).

Sum of Squares (mod 4) Calculator



Previous | ToC | Next Last Modified: August 2008