Labs / Mathematics

Modular Arithmetic

The numbers 0 to m − 1 sit on a circular clock. Press play and the hand hops around by k each tick — adding or multiplying — drawing chords that trace the pattern of the operation. Tap any number to start the walk somewhere new, and drag the sliders to change the modulus and the step.

step 0residue 0cycle 12/12gcd 1 ✓ all

What to try