Spirograph Mathematics — Hypotrochoids, Epitrochoids & Cycloids
Spirograph mathematics is the elegant geometry behind the looping, flower-like patterns produced when one circle rolls along another. Each curve is a member of the trochoid family — most famously the hypotrochoid, epitrochoid and cycloid — and every shape is fully described by a small set of parametric equations. What looks like an intricate work of art is in fact a precise consequence of a few radii and a single pen offset. Understanding this matters because the same modelling appears far beyond a child's drawing toy: in gear design, in the security guilloche printed on banknotes, and in the rotating-vector view that connects to Fourier analysis. This article explains how the curves are generated, why they close, what controls their behaviour, and where the geometry turns up in the real world.
Hypotrochoids and Epitrochoids: Circles Rolling on Circles
The classic Spirograph effect comes from rolling a small circle of radius r against a larger fixed circle of radius R, then tracking a pen held at distance d from the centre of the moving circle. When the small circle rolls along the inside of the fixed one, the traced curve is a hypotrochoid. Its standard parametric form is:
x(t) = (R − r)·cos(t) + d·cos(((R − r)/r)·t)
y(t) = (R − r)·sin(t) − d·sin(((R − r)/r)·t)
When the small circle rolls around the outside of the fixed circle instead, the result is an epitrochoid, with the sums and signs adjusted to (R + r). In both cases the curve is built from two rotations: the slow sweep of the rolling circle's centre around the big circle, and the faster spin of the pen around that moving centre. The ratio of those two rotation rates, (R ∓ r)/r, is what sets the overall character of the pattern.
The parameter d changes the personality of the curve dramatically. If d = r, the pen sits on the rim and the curve sharpens into cusps; if d < r the loops become rounded waves (the curtate case); and if d > r they swell into overlapping loops (the prolate case). British engineer Denys Fisher's mid-1960s toy fixed these radii using toothed plastic wheels and rings, so each hole in the wheel simply selected a different value of d, while swapping wheels and rings changed R and r. The whole device is, in effect, an analogue parametric-equation plotter.
Cycloids, Gear Ratios and Why Patterns Close
The simplest member of the family is the cycloid, traced by a point on the rim of a circle rolling along a straight line rather than around another circle. Its equations are x(t) = r·(t − sin t) and y(t) = r·(1 − cos t). Although it looks humble, the cycloid is mathematically remarkable: it is the solution to the brachistochrone problem, the curve of fastest descent under gravity, and it is also a tautochrone, meaning a bead released anywhere on it reaches the bottom in the same time. These discoveries by Bernoulli, Huygens and others made the cycloid a celebrated object in seventeenth-century mathematics.
For the circular cases, the decisive question is whether the pattern eventually closes back on itself. This depends entirely on the ratio R/r. If that ratio is a rational number, written in lowest terms as p/q, the rolling circle returns to its exact starting orientation after a whole number of trips, and the curve closes. The reduced numerator p then gives the number of cusps, petals or loops in the finished design. So a ratio such as 5/3 produces a five-pointed pattern, while 7/2 produces a seven-pointed one. This is why Spirograph wheels are labelled with tooth counts: the tooth ratio is the radius ratio, guaranteeing a clean closed figure.
If the ratio is irrational, the curve never closes. It keeps laying down fresh arcs and, in principle, would fill an entire annular band without ever repeating — a small but genuine doorway into the study of dynamical systems and dense orbits. In practice the toy can only approximate irrational ratios, but the idea shows how a familiar object touches deep mathematics.
Real-World Applications
Trochoid geometry is far more than decorative. The same families of curves recur across engineering and design:
- Gear and cam design: epicycloid and hypocycloid profiles give smooth, low-friction contact between meshing gear teeth and are central to cycloidal drives used in robotics and precision machinery.
- Rotary engines: the Wankel engine's combustion chamber is bounded by an epitrochoid, with the triangular rotor following the curve as it turns.
- Security printing: intricate guilloche patterns on banknotes, passports and share certificates are layered trochoids, hard to reproduce without the original mathematical parameters.
- Astronomy and history: the Ptolemaic model of the heavens described planetary motion using epicycles — circles rolling on circles — the very same construction that generates these curves.
Common Misconceptions
A frequent error is treating Spirograph curves as identical to polar rose curves. Roses follow r = a·cos(k·theta) and form a separate family; they merely resemble trochoids in some cases. Another misconception is that more holes or wheels create fundamentally new shapes — in reality every pattern is the same equation with different values of R, r and d. People also assume the patterns are random or hand-skilled, when the geometry is fully deterministic: identical settings always reproduce an identical figure. Finally, the number of petals is often guessed from the larger circle, but it is actually fixed by the reduced numerator of the radius ratio, not by either radius alone.
Frequently Asked Questions
What is the difference between a hypotrochoid and an epitrochoid? A hypotrochoid is traced by a point attached to a small circle rolling inside a larger fixed circle, while an epitrochoid is traced by a point on a small circle rolling around the outside of a fixed circle. The Spirograph toy uses the hypotrochoid case.
What is a cycloid? A cycloid is the curve traced by a point on the rim of a circle as it rolls along a straight line. It is the simplest member of the trochoid family and has notable physical properties, including being the solution to the brachistochrone problem.
Why does the pattern eventually close back on itself? The pattern closes when the ratio of the two circle radii is a rational number. The curve returns to its starting point after the rolling circle completes a whole number of revolutions matching the reduced fraction of the radii.
What determines the number of petals or loops?
If the radius ratio is written as a reduced fraction R/r = p/q, the curve forms p cusps or petals before closing. The pen offset distance d controls whether those features are sharp cusps, rounded loops or gentle waves.
Is a Spirograph curve the same as a rose curve?
Not exactly. Rose curves are defined in polar form as r = a cos(k theta) and are a distinct family, though many Spirograph patterns visually resemble roses. Both belong to the broader world of mathematically generated decorative curves.
What is the role of the parameter d?
The parameter d is the distance of the drawing point from the centre of the rolling circle. When d equals the rolling radius the curve is a true cycloid or trochoid with cusps; smaller or larger values give curtate or prolate variants with smooth loops.
Can Spirograph patterns be described with Fourier series?
Yes. Because the equations are sums of sine and cosine terms, trochoids are naturally expressed as combinations of rotating vectors, the same epicycle idea that underpins Fourier analysis and the historical Ptolemaic model of planetary motion.
Who invented the Spirograph?
The toy was developed by British engineer Denys Fisher and released in the mid 1960s. The underlying mathematics of trochoids, however, dates back centuries to mathematicians such as Albrecht Durer and the study of cycloids by Galileo and others.
Are these curves used outside of art and toys?
Yes. Epicycloid and hypocycloid profiles appear in gear tooth design, cycloidal drives, the Wankel rotary engine and anti-counterfeiting guilloche patterns on banknotes and certificates.
What happens if the radius ratio is irrational?
If the ratio of the radii is irrational the curve never exactly closes. It keeps tracing new positions and, given infinite time, would densely fill an annular region without ever repeating, illustrating a link to dynamical systems.
Try It Yourself
The best way to build intuition is to vary the radii and pen offset and watch the behaviour change in real time. Explore these interactive simulations:
- cardioid-spirograph — generate hypotrochoids and epitrochoids by adjusting the gear ratios.
- rose-curve — compare the closely related polar rose family.
- fourier-epicycles — see how rotating vectors build up curves, linking Spirographs to Fourier analysis.
Conclusion
Spirograph patterns reward a closer look: behind every loop and petal lies a compact set of parametric equations governed by two radii and a pen offset. The hypotrochoid, epitrochoid and cycloid are all expressions of the same simple idea — a circle rolling against a line or another circle — yet they connect to gear engineering, rotary engines, security printing and the rotating-vector mathematics of Fourier series. Whether you treat them as art, as geometry or as a gateway to dynamical systems, these curves show how a humble toy can encode genuinely deep and beautiful mathematics. Experiment with the simulations above to see the equations come alive.