The above write-ups are a bit opaque. Normal

arithmetic operates on infinitely many numbers 1, 2, 3, ... while

modular arithmetic only uses finitely many, and the

numbers wrap around at some point. The obvious example is

clock time, which goes 1, 2, 3, ..., 11, 12, 1, 2, 3, ...

The maximum number (12 in the case of a clock) is called the modulus. The word *modulo* is Latin for "with the modulus...".

Addition works normally up to the modulus, so 5 + 6 = 11, then beyond that you discard the modulus: 5 + 9 = 14 = 2 (modulo 12). Nine hours after five o'clock is two o'clock.

The equation a = b (modulo c) means that if you throw away enough copies of c from one side, you get a = b. For example, what is 147 modulo 9? Well throw away 90, and that leaves 147 = 57 (modulo 9). Nine somethings are 54, so we can throw that away, leaving 147 = 3 (modulo 9).

In programming, the MOD function (however that's written in the particular language) reduces an arbitrary number to something in the range from 0 to the maximum. So 147 MOD 9 returns 3. As 0 = n (modulo n) for any n, the MOD function always returns 0 rather than n in that case.

The official terminology is a = b (modulo c), but often you know you are operating with a particular modulus, and simply write a = b, e.g. 1 = 13.

For all the good technical details see integers modulo n.