daisy.py

Created by gianfranco-oddenino

Created on May 25, 2026

264 Bytes

The script simulates phyllotaxis by placing n points (i = 0…n−1) in polar coordinates using the golden angle (≈137.507°) for the angular step and a radial law r = c·√i, producing a Fermat-like spiral that closely resembles the arrangement of florets in daisies and sunflowers.
Because the golden angle is an irrational fraction of a full turn, successive points avoid radial alignment and yield an even, space‑filling packing that mirrors the efficient floret placement observed in many Asteraceae (Compositae).


During your visit to our site, NumWorks needs to install "cookies" or use other technologies to collect data about you in order to:

With the exception of Cookies essential to the operation of the site, NumWorks leaves you the choice: you can accept Cookies for audience measurement by clicking on the "Accept and continue" button, or refuse these Cookies by clicking on the "Continue without accepting" button or by continuing your browsing. You can update your choice at any time by clicking on the link "Manage my cookies" at the bottom of the page. For more information, please consult our cookies policy.