Back to Learn

Why π Never Closes: The Math Behind the Pi Mandala

Irrational numbers, 22/7, 355/113 and the golden ratio — drawn as curves

Key takeaways

  • The pi curve z(θ) = e^(iθ) + e^(iπθ) closes only if π is a fraction — and it is not, so the line never returns to its start.
  • It nearly closes when π is close to a simple fraction: after 7 turns (22/7) and, much more precisely, after 113 turns (355/113).
  • Rational ratios p/q always close, after q turns, with |p − q|-fold symmetry.
  • The golden ratio φ is the “most irrational” number, so its curve avoids near-closures and fills space most evenly.
  • Draw any of them yourself in the Ratio Visualizer.

By the CymaVis team · Updated

The curve in plain words

Take an arrow of length 1 and spin it around a point once per turn. On its tip, mount a second arrow of the same length that spins π times as fast. Follow the tip of the second arrow and you get the figure that went viral as “the line that never closes.”

z(θ) = e^(iθ) + e^(iπθ)

Each term is a unit arrow rotating in the complex plane; θ counts the angle of the first arrow.

Replace π with any other number k and you get a different figure. That single dial — the speed ratio k — is all it takes to go from a heart-shaped loop to a dense mandala.

When does a curve close?

The drawing is back at its starting point only when both arrows point exactly where they started. The first arrow does that after every whole turn; the second after every whole number of its own turns. Both happen together after q turns of the first arrow only if the second has made a whole number p of turns in the same time — that is, only if k = p/q.

So every fraction gives a closed curve, and every irrational number gives a curve that never closes. π was proven irrational by Johann Lambert in 1761 (and transcendental by Ferdinand von Lindemann in 1882), so the pi curve is guaranteed to keep going forever without ever repeating.

Near misses: 22/7 and 355/113

An irrational number can still be very close to a fraction. The best fractions come from its continued fraction, and for π they are 3, 22/7, 333/106, 355/113 and so on.

  • After 7 turns the second arrow has turned 7π ≈ 21.991 times — just 0.009 of a turn short of 22. The curve almost closes into a 15-fold flower (22 − 7 = 15), then starts to drift.
  • After 113 turns it has turned 113π ≈ 354.99997 times — only 0.00003 of a turn short of 355. The miss is about a hundredth of a degree, invisible at normal zoom.

The fraction 355/113 was found by the Chinese mathematician Zu Chongzhi in the 5th century and matches π to six decimal places (3.141592…). Archimedes had already bounded π between 223/71 and 22/7 in the 3rd century BCE.

In the Ratio Visualizer, choose π and press +100 turns: the drawing jumps to just before the 113-turn near miss.

Closed flowers: rational ratios

For a fraction p/q in lowest terms, the curve closes after exactly q turns and has |p − q|-fold rotational symmetry. A few examples:

  • k = 2: closes after one turn with 1-fold symmetry — a cardioid-like loop.
  • k = 3 : 2: closes after 2 turns — the perfect fifth in music.
  • k = 22/7: closes after 7 turns with 15 petals.
  • k = −1: the two arrows cancel and reinforce in turn, tracing a straight line.

Negative ratios spin the second arrow the other way and give pointed, star-like shapes rather than rounded loops — try −2 or −3.

Why the golden ratio is the “most irrational” number

How well a number can be approximated by fractions is encoded in its continued fraction. Large terms mean an excellent fraction is nearby: π = [3; 7, 15, 1, 292, …], and that huge 292 is why 355/113 is so accurate.

The golden ratio φ = (1 + √5)/2 has the continued fraction [1; 1, 1, 1, …] — all ones, the smallest possible terms. Its best fractions are ratios of Fibonacci numbers (3/2, 5/3, 8/5, 13/8 …), and each is only a modest improvement on the last. In a precise sense φ is the hardest number to approximate, so its curve never has a dramatic near-closure and spreads most evenly around the ring.

The same property is why plants often space leaves and seeds by the golden angle (about 137.5°): it avoids lining up in rows, packing seeds evenly in a sunflower head.

A link to sound

Two circles turning at a ratio are the circular version of two vibrations at a frequency ratio. Musical intervals are simple ratios — 2 : 1 for an octave, 3 : 2 for a fifth — and draw closed, stable curves. Irrational ratios never line up, and two tones at such a ratio never settle into a repeating pattern either.

That is the same physics behind Lissajous figures in the Chladni simulator and the 19th-century harmonograph, a pendulum drawing machine that turned musical intervals into curves. In the Ratio Visualizer you can press Play both tones to hear the ratio you are drawing.

Frequently asked questions

Does the pi curve ever repeat?

No. Because π is irrational, the two arrows never complete whole turns at the same time, so the curve never returns to its exact starting point or repeats.

Why does the pi curve look almost closed after 7 turns?

Because π ≈ 22/7. After 7 turns the second arrow has made about 21.99 turns, only 0.009 of a turn short of closing.

What is the most irrational number?

The golden ratio φ ≈ 1.618. Its continued fraction consists entirely of 1s, which makes it the hardest number to approximate with fractions.

Can I make these curves with other numbers?

Yes. Any ratio works: fractions close into symmetric flowers, while irrational numbers like e and √2 produce never-closing mandalas.

Further reading

Keep reading