designcoding
About Table of Contents Keywords Monthly Archive
Support designcoding!

Fibonacci Spiral with Rhino Python

July 30, 2017 | Algorithms
#fibonacci #phyllotaxis #rhino-python #spiral

As studied earlier in Grasshopper here, the sunflower spiral, or Phyllotaxis, or Fibonacci’s spiral, could be drawn as an exercise of looping in Rhino Python.

Fibonacci Spiral with Rhino Python fibonacci, phyllotaxis
import rhinoscriptsyntax as rs
import math
s = 137.508
for n in range(0,500):
    t = math.sqrt(n)
    g = n * s
    z = rs.Polar([0,0,0],g,t)
    rs.AddCircle(z,0.3)

Phyllotaxis is the arrangement or patterning of leaves, flowers, or other plant parts around a stem or axis. Thus, it refers to the specific geometric arrangement of these structures in plants. The term “phyllotaxis” comes from the Greek words “phyllon” (meaning “leaf”) and “taxis” (meaning “arrangement” or “order”).

Phyllotaxis can vary widely among different plant species, and it often follows specific mathematical patterns. One of the most well-known patterns is the Fibonacci sequence, in which each number is the sum of the two preceding ones (e.g., 0, 1, 1, 2, 3, 5, 8, 13, …). In some plants, the number of spirals or whorls of leaves or other plant parts follows the Fibonacci sequence. This results in a visually appealing arrangement.

If you are new to Rhino Python, you may wonder how you are going to write this code. Just type EditPythonScript in the Rhino command bar and open the Python editor. Then, write the code you see above and hit F5 to run it. Alternatively, I prepared a Grasshopper definition including the same Python code as a component. Here it is:

Fibonacci Spiral with Rhino Python Grasshopper definition
Grasshopper definition (GH)Download

Cite this post

Yazar, T. (2017, July 30). Fibonacci Spiral with Rhino Python. designcoding. Retrieved August 24, 2026, from https://www.designcoding.net/fermats-spiral-with-rhino-python/

Related Posts

Sunflower Spiral

December 22, 2011

Sunflower Spiral (or Phyllotaxis) can be constructed in Grasshopper according to Vogel’s model of parametric relationships. This model uses polar coordinates. The Grasshopper file is still working after more than 11 years -15.12.2022. This is such a powerful quality of Grasshopper, I think. It’s a good example of utilizing polar coordinates. It’s also fun to play with the parameters and constraints of the Sunflower Spiral. Also, there are very interesting results if you also connect the polar angle value to…

Fibonacci Portraits

December 27, 2023

“In the heart of a sunflower’s embrace, its seeds weave a poetic tale—a dance of two spirals, parastichies they’re called. One unfurls gracefully from the center in the hush of clockwise whispers, while its counterpart whispers secrets in the tender breaths of counterclockwise motion. A subtle ballet unfolds, where the number of these spirals gracefully mirrors the whispers of adjacent Fibonacci numbers, composing a delicate symphony in the sun-kissed fields.” says ChatGPT if I force it to be a little…

Fibonacci Dome

March 1, 2024

This is the continuation of my previous study on the Fibonacci lattice on a spherical surface, creating a Fibonacci Dome structure. The panelization of curved forms with flat surfaces has been a favorite topic in architectural geometry. The trigonometric layout of the Fibonacci sequence generates a spherical formation, while the Faceted Dome component handles planarity. Here, I further enhanced the previous code into a pavilion design. The essential part of the code is about the placement of points on the half…

Fibonacci Sphere

April 12, 2023

This website explains the problem and several solutions. I managed to implement the formulas to convert a 2D square grid into spherical coordinates. The Fibonacci Sphere is one of the solutions to the equal distribution of points on a sphere. It is not the best solution to this problem. But it is regarded as a quick and efficient one. Suitable for me. I developed this Grasshopper code by studying the above website and some other sources. The code starts with…

Spiral Staircase

April 17, 2023

This is a basic Grasshopper exercise, covering many fundamental topics. The aim is to create the parametric model of a spiral staircase. This is more educational than functional, I guess. Below is the explanation of the Grasshopper definition in three parts. Helix Points for the Spiral Staircase In the first part of the definition, I am defining the points ordered on a helix. First, I calculate the number of steps by dividing the total height value by the height of…

  • Chapters

    • Algorithms
    • Discourses
    • Fabrications
    • Studios
  • Explore

    • All Keywords
    • Table of Contents
    • Monthly Archive
    • #grasshopper
    • #linear-algebra
    • #parametric-curve
    • #tutorial
    • #vector
    • #polyhedra
    • #design-object
    • #bezier-curve
    • #image-sampler
    • #simulation
    • #fourier
    • #rhinoceros
    • #dome
    • #sphere
    • #pattern
    • #design-education
    • #dual
    • #art
    • #growth
    • #vector-field
  • Search

  • Support designcoding!

  • Enjoying designcoding? Support me on Patreon to keep it growing. Thank you!

  • copyright 2026 designcoding.net | about | privacy policy | end user license agreement