Fibonacci Spirals



This python code generates output in SVG:

It needs the svgwrite module, and optionally the pyDelaunay2D package (for Voronoi Regions).

The method of H. Vogel

The position of each point \(n\) is given by the formula \(\theta ={\frac {2\pi }{\phi ^{2}}}n,\ r=c{\sqrt {n}}\) where \(c\) controls the spacing between points.

\(\phi\) is the Golden Ratio, or \(1+\sqrt{5} \over 2\), the most irrational of all numbers.

A 'standard' spiral: constant size dots with constant spacing:

Colored alternately red, green, blue:

Each point on the spiral is at the center of a Voronoi region. This more closely resembles the packing of seeds in a sunflower.

The next two color the regions in sequence, alternating through the colors of the rainbow. Each color is used n times, where the n follows the Fibonacci sequence: 1, 1, 2, 3, 5, 8, 13, 21, 34...