Euclid · Bézout · Diophantine equations
An interactive introduction to number theory
Patterns,
Proofs, and Primes
Start with a rectangle. Rotate a necklace. Color Pascal’s triangle. Then follow the patterns all the way to a proof.
compute
→notice
→conjecture
→prove
→reuse
The course
One idea unlocks the next.
The sequence is a proof journey, not a catalogue: algorithms become structures, structures become symmetry, and symmetry becomes information about primes.
Primes · Euclid’s lemma · Unique factorization
Every integer has an address
Build arithmetic from the indivisible pieces.Convergents · Approximation · Pell equations
Fractions inside fractions
Read Euclid’s quotients as exceptional approximations.Congruences · Inverses · Chinese remainders
Arithmetic on a clock
Forget complete turns and preserve arithmetic structure.Necklace orbits · Fermat’s little theorem
A theorem you can rotate
Watch divisibility emerge from cyclic symmetry.Groups · Cosets · Lagrange · Euler
The reusable machine
Name the structure shared by clocks and rotations.Binomial coefficients · Valuations · Kummer
Arithmetic in Pascal’s triangle
Find prime divisibility hiding in base-p carries.Central coefficients · θ(x) · Chebyshev
How crowded are the primes?
Use the middle of Pascal’s triangle to count primes.Interactive companion
Touch the structure.
Every experiment is paired with a proof question. Computation is the microscope—not the oracle.
Algorithm lab
Tile the rectangle
Change the side lengths. The picture and proof trace update together.
Approximation lab
Build a continued fraction
Watch simple fractions close in on an irrational target.
Congruence lab
Wind around a clock
Explore residues, units, and the permutation hiding inside a finite group.
Units modulo 12
Multiplication by 5 rearranges these units:
Symmetry lab
Rotate a theorem
Color the beads, inspect the orbit, and see why prime length forces equal packets.
Rotational orbit · 5 distinct words
Divisibility lab
Color Pascal’s triangle
Reduce every entry modulo a prime. Base-p carries become a fractal you can see.
Look for it: blank cells are the coefficients divisible by 2. The repeating blocks are base-2 arithmetic made visible.
Prime-counting lab
How crowded are the primes?
Compare exact counting with the scale predicted by Chebyshev and the prime number theorem.
Practice architecture
From calculation to explanation.
Weekly work mixes three modes. The aim is not merely to get an answer, but to know what kind of reasoning produced it.
Fluency
Focused calculations make later proofs readable.
ExampleExpress gcd(527, 341) as 527x + 341y.
Reasoning
Intermediate claims guide students through complete proofs.
ExampleWhy does a nonconstant word of prime length have exactly p rotations?
Exploration
Generate evidence, form a conjecture, then test its limits.
ExampleColor Pascal’s triangle modulo p. What do its repeating blocks know about base p?
The central lesson
Proof is a way of seeing why a pattern had to appear.
Print the formal development. Use the web to experiment. Move between them until the computation and the proof tell the same story.