Homepage Blogs What is the Fibonacci Sequence? What is its rule, and how is it found?
Coderspace Pro Coderspace Pro

What is the Fibonacci Sequence? What is its rule, and how is it found?

7 Minutes Reading Time · 23.01.2025
What is the Fibonacci Sequence? What is its rule, and how is it found?

Summarize this content with artificial intelligence!

There are numbers we constantly see in nature. For example, 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144, 233, 377. These are collectively called the Fibonacci sequence. 

Perhaps you know this pattern. The sum of the first and the second gives the third number, and it continues in this way. That is, each new number arises as the sum of the two preceding numbers.

The Fibonacci sequence is a sequence where each number is the sum of the two preceding numbers. The first two terms are 0 and 1. The terms of this sequence are known as Fibonacci numbers.

Mathematically, we can express this as follows:

xn = xn-1 + xn-2

Beyond being a mathematical sequence, the Fibonacci sequence is a pattern frequently encountered in nature 🌻 and art 🖼️. For example, we can mention the perfect spiral shape of a sea snail or the vortex of a hurricane.

The Fibonacci sequence can also be associated with the number of petals on flowers, the arrangement of pinecones, the shells of some animals, and the spiral patterns of galaxies.

Sunflower seeds, leaves, branches, and petals grow in a spiral shape. Why? Because in this way, new leaves do not block sunlight from older leaves, or the maximum amount of rain or dew is directed towards the roots.

In fact, the spiral turn in a plant is often in the form of the ratio of two consecutive (one following another) Fibonacci numbers. For example:

  • A half turn is 1/2 (1 and 2 are Fibonacci numbers),
  • The ratio 3/5 is also common (both are Fibonacci numbers),
  • The ratio 5/8 as well, and all of these increasingly approach the golden ratio.

That's why Fibonacci numbers are very common in plants. 

Numbers like 1, 2, 3, 5, 8, 13, 21, ... etc., surprisingly appear in many places.

Here is a daisy with 21 petals. 👇🌼 Of course, there may be a bit more or less, because some may have fallen off or may still be growing.

Mathematical ideas related to the Fibonacci sequence date back to ancient Sanskrit texts between 600 and 800 BCE. However, in modern times, we have associated this sequence with many subjects, from computer science to sunflower seeds.

 

How Did the Fibonacci Number Sequence Emerge?

The first thing to know is that this sequence does not actually belong to Fibonacci. In fact, he was never referred to by the name "Fibonacci." 

Mathematician Keith Devlin from Stanford University says that historians in the 19th century gave this mathematician the nickname "Fibonacci" to distinguish him from another famous Leonardo of Pisa.

This sequence was first discovered 1300 years ago by a mathematician in India

It was introduced to the West in 1202 by the Italian mathematician Leonardo of Pisa, aka Fibonacci. He was also the first to introduce Arabic numerals to Europe (and yes, if he hadn't, Europe might still be using Roman numerals).

Leonardo Fibonacci introduced this sequence in his work "Liber Abaci" published in 1202, but he was not the first to discover the mathematical pattern. This work showed how to perform calculations, detailing arithmetic to be used in tasks like profit and loss tracking and outstanding debt balances.

In fact, Leonardo of Pisa introduced the sequence through a problem about rabbits. The problem was: How many pairs of rabbits can a single pair produce in one year? 

Think about it. Start with one male and one female rabbit. After one month, they mature and give birth to another pair of rabbits. A month later, these rabbits also start reproducing and give birth to another male and female. So after one year, how many rabbits will you have?

That's when the mathematical equation comes into play. Although it sounds complex, it's quite simple.

Apart from a few short paragraphs about the reproduction of these rabbits, Leonardo of Pisa never mentioned the sequence again. 

 

The Logic of the Fibonacci Sequence

The Fibonacci sequence can be mathematically defined as follows:

  • F(0) = 0
  • F(1) = 1
  • F(n) = F(n-1) + F(n-2) (for n > 1)

There are two numbers at the beginning of this sequence: usually 0 and 1. Then, each new number in the sequence is calculated as the sum of the two previous numbers. That is, at each step, we add the previous number and the one before that. 

Now let's see how we can do this operation step by step:

  1. Let's take 0 and 1 as the starting values.
    • First two numbers: 0 and 1.
  2. To find the next number, we add 0 and 1:
    • Now the sequence is: 0, 1, 1.
  3. To find the next number, we add the last two numbers:
    • Now the sequence is: 0, 1, 1, 2.
  4. We add the last two numbers:
    • Now the sequence is: 0, 1, 1, 2, 3.
  5. We add the last two numbers:
    • Now the sequence is: 0, 1, 1, 2, 3, 5.

We continue this process, obtaining a new number each time by adding the last two numbers. In this way, the sequence continues as: 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144, 233, 377, ...

The sequence continues infinitely, and each new number is the sum of the two preceding numbers. 

 

Examples of the Fibonacci Sequence 

In terms of application, Fibonacci numbers appear surprisingly often in nature. From the unfolding leaves of desert succulents, to pinecones and sunflower seeds. Even to the shells of some snails...

Plants

We can observe these numbers very clearly in plants in nature. For example, if you split a banana, you'll see it has 3 separate sections. If you cut an apple, you'll see it has 5 sections. In flowers, you can see 1,1,2,3,5,8,13 petals. 

The number of rows of seeds in sunflowers and pinecones always forms Fibonacci numbers. 

The reason our plants grow in this way is not because they are some kind of mysterious, mystical things. They develop like this because they need to place as many seeds as possible in a small area, and this is the way to do it.

 

Honeybees

It is said that the family tree of honeybees, especially how they inherit their DNA, closely follows the Fibonacci sequence and the golden ratio. 🐝

A honeybee colony consists of a queen, a few male bees, and many worker bees. 

According to research, female worker bees receive half of their DNA from the mother, that is, the queen, and half from the father.

On the other hand, male bees come from unfertilized eggs. This means they have only one parent. So male bees get all their DNA from their mothers.

Therefore, the Fibonacci numbers express a male bee's family tree as one parent, two grandparents, three great-grandparents, and so on.

 

Storms

Natural phenomena like hurricanes and tornadoes often follow the Fibonacci sequence. Next time you see a spiral-drawing hurricane on the weather radar, you can look at the distinct Fibonacci spiral in the clouds on the screen. 🌪️

 

Human Body

When you look at yourself in the mirror, you will notice that many parts of your body follow the numbers one, two, three, and five. You have one nose, two eyes, three segments in each limb, and five fingers on each hand. 

Interestingly, each of the 2 hands with 5 digits and the 8 fingers also consist of 3 parts.

 

The Fibonacci Sequence and the Golden Ratio

Besides frequently encountering the numbers themselves, we can also see the proportions between them in many places. 

If you divide any Fibonacci number in the sequence by the one that precedes it, you get numbers approaching 1.618. The Greeks discovered this long ago and named it PHI. Today, we call it the golden ratio

It is said that Phi was used by the ancient Greek sculptor Phidias to depict physical perfection.

For example, it is said that he used Phi as the ratio between the total height of a statue and the distance from the base of the feet to the navel. 

 

Fibonacci Spiral

The Fibonacci spiral is a geometric pattern derived from the Fibonacci sequence. It is created by drawing a series of connected quarter circles inside a series of squares sized according to the Fibonacci sequence.

The spiral starts with a small square, followed by a larger square adjacent to the first. The next square is sized according to the sum of the previous two squares, and so on. 

Each quarter circle fits perfectly into the next square in the sequence, forming a spiral pattern that expands outward infinitely. The larger the numbers in the Fibonacci sequence, the closer the ratio approaches the golden ratio (≈1.618).

Let's calculate the ratio of every two consecutive terms in the Fibonacci sequence and see how they form the golden ratio.

  • F2 / F1 = 1/1 = 1
  • F3 / F2 = 2/1 = 2
  • F4 / F3 = 3/2 = 1.5
  • F5 / F4 = 5/3 = 1.667
  • F6 / F5 = 8/5 = 1.6
  • F7 / F6 = 13/8 = 1.625
  • F8 / F7 = 21/13 = 1.615
  • F9 / F8 = 34/21 = 1.619
  • F10 / F9 = 55/34 = 1.617
  • F11 / F10 = 89/55 = 1.618 = Golden Ratio

 

The Fibonacci Sequence and Programming

The Fibonacci sequence is a pattern frequently encountered in programming. We can solve this sequence, where each number is the sum of the two preceding numbers, in various ways in different programming languages.

The Fibonacci sequence is often taught in algorithms and data structures courses because it teaches basic mathematical concepts and helps develop some problem-solving techniques.

For example, optimization techniques during the calculation of the sequence offer important lessons on the efficiency of algorithms.

Summarize this content with artificial intelligence!

CONTENTS
Topic content

Introduction to Programming with Python 🧑‍💻 Learn Python, the core language of data science, software, and analytics, from scratch. Explore Now!
Introduction to Programming with Python 🧑‍💻 Learn Python, the core language of data science, software, and analytics, from scratch. Explore Now!

Recommended Contents

All Blogs
What is Natural Language Understanding (NLU)?
What is Natural Language Understanding (NLU)?
What is Natural Language Understanding (NLU)?

When we think about it, language is one of our most powerful tools. We use it to express our feelings and thoughts. We can leverage the power of lang…

6 Minutes Reading Time
Research
03.11.2025
What is Java? What is it used for?
What is Java? What is it used for?
What is Java? What is it used for?

Java is a widely used object-oriented programming language that runs on billions of devices, including laptops, mobile devices, game consoles, medica…

7 Minutes Reading Time
Software Development
06.10.2025
Popular Java Frameworks
Popular Java Frameworks
Popular Java Frameworks

Java is one of the most popular programming languages. It offers versatility and flexibility with the "write once, run anywhere" philosophy. To enhan…

4 Minutes Reading Time
Software Development
01.10.2025