In 1202, an Italian merchant’s son named Leonardo of Pisa — better known to history as Fibonacci — published a book called Liber Abaci (“Book of Calculation”). Most of the book was a practical introduction to Hindu-Arabic numerals for European readers, replacing the awkward Roman system with the digits 0-9 we still use. Tucked inside was a small problem about rabbit reproduction:
Suppose a pair of rabbits produces a new pair every month, and each new pair becomes reproductive after one month. Starting with one pair, how many pairs will there be after a year?
The answer requires counting: 1 pair in month 0, 1 in month 1, 2 in month 2, 3 in month 3, 5 in month 4, 8 in month 5, and so on. Each number is the sum of the previous two.
This sequence — 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144, … — is the Fibonacci sequence. It has become the most famous sequence in popular mathematics. It appears in pinecones and sunflowers, in financial charts and population biology, in computer algorithms and music theory. Its ratios converge to the golden ratio , a constant that has fascinated artists, architects, and mathematicians for millennia.
This article is about what the Fibonacci sequence actually is, what’s true and false in the popular legends about it, and what mathematics has discovered behind these simple-looking numbers.
The recurrence
Define by:
The sequence is: 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144, 233, 377, 610, …
This is one of the simplest non-trivial recurrence relations in mathematics. Each number depends on the previous two. The sequence grows roughly exponentially — but the exact growth rate involves an irrational number.
The closed form
Surprisingly, despite being defined by a recurrence over integers, the Fibonacci numbers admit an exact closed-form expression involving irrational numbers:
where is the golden ratio, and is its conjugate.
This is Binet’s formula. It was published by Jacques Binet in 1843, but Abraham de Moivre had derived essentially the same formula a century earlier. Note that and are the two roots of the polynomial — exactly the polynomial whose recurrence gives the Fibonacci sequence.
Since , the term decays to zero as grows. So for large :
Fibonacci numbers grow exponentially with base . Their ratios converge to . For large , you can compute the next Fibonacci number very accurately by multiplying the current one by and rounding.
The golden ratio
The number has been studied since antiquity. It satisfies the elegant relation , equivalently .
In geometry, is the ratio that produces the golden rectangle: a rectangle whose proportions are such that, if you remove a square from one end, what remains is a smaller golden rectangle similar to the original. This self-similar property is what makes the golden ratio aesthetically distinctive.
The golden ratio has the most boring possible continued fraction:
Just 1s, all the way down. As we discussed in our continued fractions piece, this means is in a precise sense the most irrational real number — the hardest to approximate by rational fractions. Its convergents are exactly ratios of consecutive Fibonacci numbers.
This connection — golden ratio as the most-irrational number, Fibonacci ratios as its best rational approximations — is one of the most elegant in number theory.
Where Fibonacci appears in nature
The popular reputation of Fibonacci numbers comes from their appearance in plants. The phenomenon is real, and the explanation is genuinely mathematical.
Consider a sunflower head. As new seeds are produced at the center, older seeds are pushed outward. The plant has to decide what angle to space new seeds at. If the angle is rational (say, 1/4 of a full turn), then after 4 seeds, you’d be exactly back where you started, and seeds would line up in 4 columns with big gaps between them — inefficient packing.
The optimal angle, it turns out, is related to the golden ratio: . This is called the golden angle, and it leads to the maximally non-overlapping spiral packing. Sunflower seeds spaced at this angle pack as densely as possible.
The number of visible spirals you can count in such a packing — going clockwise and counterclockwise — turns out to be consecutive Fibonacci numbers (commonly 21 and 34, or 34 and 55, depending on the size of the head).
This same effect produces:
- Fibonacci spiral counts in pinecones (often 8 and 13, or 13 and 21).
- Fibonacci spiral counts in pineapple scales.
- Fibonacci-related petal counts in many flower species.
- Fibonacci leaf arrangements (phyllotaxis) in many plants.
But popular accounts often overclaim. Not every flower has Fibonacci petals (corn poppies have 4). Not every plant uses the golden angle. The mathematical phenomenon is real and explains specific cases, but it’s not a universal law of nature.
Identities and properties
Fibonacci numbers have an enormous number of mathematical properties. A small sample:
Cassini’s identity: .
Catalan’s identity: .
Sum identity: .
Sum of squares: .
Divisibility: . So Fibonacci numbers’ GCDs are themselves Fibonacci numbers, indexed by GCDs of the original indices.
Periodicity modulo : For any , the sequence is eventually periodic. The period is called the Pisano period and has been studied extensively.
These identities are not just curiosities — they’re tools used in number-theoretic algorithms, cryptographic protocols, and competitive mathematics.
Computational uses
Fibonacci numbers appear in computer science in several places:
Fibonacci heaps — a data structure with excellent amortized performance — were named by Fredman and Tarjan in 1984 for their use of a Fibonacci-like growth pattern.
Fibonacci search — a search technique on sorted arrays — uses Fibonacci numbers to subdivide the search space, somewhat analogously to binary search but with different cache properties.
Recursion analysis: a naive recursive Fibonacci computation has runtime — exponential — because it computes the same sub-problems repeatedly. Memoizing the recursion brings it down to . This is the canonical first example used to teach dynamic programming.
Random number testing: Fibonacci-based pseudorandom number generators were widely used in the early days of computing. They’re now mostly superseded but still appear in some scientific simulation codes.
The history
The sequence has a longer history than European tradition acknowledges. Indian mathematicians studying the rhythms of Sanskrit poetry around the 6th century — Pingala, Virahanka, Hemachandra — described the same numbers in the context of counting metric patterns. A long syllable plus a short syllable totals 2 beats; how many ways can you pattern beats with longs and shorts? The answer is .
Fibonacci’s 1202 introduction to Europe, while not the original discovery, was historically pivotal because it brought the sequence into European mathematics during the early development of medieval algebra. The name “Fibonacci sequence” was coined much later, in the 19th century, by Édouard Lucas — who also studied many of the related sequences.
What Fibonacci numbers teach
For a student of mathematics, Fibonacci numbers are an entry point into deeper themes:
Recurrence relations: simple recursive definitions can produce sequences with surprising closed-form expressions involving irrational numbers. The same technique works for many other recurrences.
Asymptotic behavior: even when sequences are defined integer-by-integer, their asymptotic growth often involves continuous mathematics (the golden ratio, exponentials).
The bridge between discrete and continuous: Fibonacci’s recurrence is purely discrete; its analysis uses real analysis (limits, exponentials). Many similar problems in number theory and combinatorics have this discrete-continuous structure.
Modular periodicity: most arithmetic sequences become periodic modulo any integer. Studying these periods is a non-trivial branch of number theory.
For everyone else, Fibonacci numbers are a reminder that simple rules can produce rich behavior, and that the same mathematical patterns can appear in plants, financial markets, computer algorithms, and abstract number theory. The pattern is the substance; the specific applications are decoration.
The next time you see a sunflower, pineapple, or pinecone, look closely at the spirals. Count them. Most of the time, you’ll find Fibonacci numbers — not because nature deliberately uses them, but because the same mathematical optimum that produced Fibonacci’s rabbits also produces the densest packing under specific growth constraints. Convergent evolution, in the mathematical sense.
Eight hundred years after Fibonacci’s Liber Abaci, his rabbits are still multiplying. And in plants, computers, and number theory, his sequence keeps reappearing — sometimes in expected places, sometimes in places no one would have guessed.
That’s what makes a mathematical pattern stand the test of time.
Frequently asked
Are Fibonacci numbers really common in nature?
More common than you'd expect, but less universal than popular accounts suggest. Sunflower seed counts, pinecone spirals, and pineapple scales often follow Fibonacci. Petals on flowers often do (lilies have 3, buttercups 5, daisies often 21 or 34). But not every plant follows Fibonacci, and many examples in popular media are cherry-picked. The math behind why they appear at all is genuinely interesting — it's about optimal packing under specific growth constraints.
Did Fibonacci really invent the sequence?
He didn't invent it — Indian mathematicians had studied similar sequences in the context of poetry meter centuries earlier. But Fibonacci's 1202 book Liber Abaci introduced the sequence to European mathematics, in the context of a famous rabbit-population problem. The sequence is named for him by tradition, not for original invention.
What is the golden ratio's connection to the Parthenon?
Disputed. Popular books often claim the Parthenon and other classical Greek buildings were designed using the golden ratio, but most rigorous historical analysis finds little evidence for this. The golden ratio appears in art and architecture often enough to inspire interest, but the strong claims of widespread classical use don't hold up to scrutiny. The mathematics is real; the historical mythology is exaggerated.