Math / Pure Structure
Number theory is arithmetic that remembers structure.
Addition and multiplication look familiar in number theory, but familiar operations start leaving visible fingerprints: divisibility, remainders, prime factorization, and cyclic repetition. The field is deep because the integers are simple enough to doodle and stubborn enough to keep surprising you. If you want the nearest algebraic continuation, go next to field theory; if you want the software-facing echo, go to parsers.
Intuition First
A good first feeling for number theory is that integers carry more memory than real-number arithmetic suggests. Ask whether one number divides another, or what remains after division, and suddenly arithmetic stops being smooth and starts forming textures: periodicity, factor families, prime bottlenecks, and repeating cycles. The divisibility handles below turn that feeling into a few reusable ideas.
This is why clocks are such a useful entry point. A clock throws away full turns and remembers only the residue class. That small act of forgetting is mathematically productive. It lets you see congruence as a pattern language: two numbers can be different in the usual sense and still be the same from the perspective of a chosen modulus, which is exactly the move that prepares you for prime fields.
Prime numbers
Primes act like structural atoms. They are not the only important objects, but many later patterns depend on how integers break into prime pieces.
anchor: divisibility handlesCongruence
Saying two numbers are congruent modulo n means they land in the same residue class after division by n.
anchor: modular clockField bridge
Prime moduli are special because modular arithmetic modulo p behaves cleanly enough to form a field.
next: prime fieldsPortable Diagram: Multiplication On A Clock
This SVG diagram maps each residue i to k × i (mod n). When the modulus is prime, the nonzero residues behave more cleanly; when the modulus shares factors with the multiplier, the pattern folds inward and exposes divisibility. That contrast is the bridge into field theory and a useful analogy for parser equivalence classes.
Move the controls to compare prime and composite moduli.
Divisibility Handles
Prime
A prime is a number with no nontrivial divisors. In number theory, primes often mark the points where arithmetic becomes cleaner or more rigid.
field theory anchor: prime fieldsGreatest Common Divisor
The gcd tells you how much two numbers overlap structurally. In the modular clock, it controls whether the pattern permutes or collapses.
anchor: modular clockResidue Class
Residues are arithmetic positions remembered after full turns are forgotten. They are the central visual objects in modular arithmetic.
category anchor: composition squareEuclidean Habit
The Euclidean algorithm is a way of thinking, not only a procedure: keep dividing, keep tracking remainders, and structure eventually appears.
complexity anchor: growth intuitionNeighbor Routes
Field Theory
Finite fields often begin with modular arithmetic modulo a prime. Number theory supplies the raw material that field theory organizes.
route: Prime fieldsCombinatorics
Residue classes, partitions, and finite counting arguments often overlap, especially when periodicity or recurrence matters.
route: Combinatorics intuitionCategory Theory
Category language can make arithmetic feel less isolated by treating operations and preserved structure as first-class relationships.
route: Category insightParsers
Even bespoke parser design benefits from number-theoretic habits: small generators, repeating states, and residue-like equivalence classes.
route: Parser doodles