UseCalcPro
Home
MathFinanceHealthConstructionAutoPetsGardenCraftsFood & BrewingToolsSportsMarineEducationTravel
Blog
  1. Home
  2. Math

Fibonacci Calculator

Fibonacci numbers, golden ratio, and sequence generation

F(10)

55

Terms

11

φ (phi)

1.618034

Enter 0–78. Generates the sequence F(0) through F(n).

Uses the property that n is Fibonacci if 5n²±4 is a perfect square.

F(10)

55

Golden Ratio (φ)

1.61803399

Binet Formula

55

Formulas Used

Fibonacci Recurrence

F(n) = F(n-1) + F(n-2), with F(0) = 0, F(1) = 1

Each Fibonacci number is the sum of the two preceding numbers in the sequence.

Where:

F(n)= The nth Fibonacci number
n= Position in the sequence (0-indexed)

Binet's Formula

F(n) = (φⁿ - ψⁿ) / √5

Direct formula using the golden ratio, avoiding iterative computation.

Where:

φ= (1 + √5) / 2 ≈ 1.618 (golden ratio)
ψ= (1 - √5) / 2 ≈ -0.618 (conjugate)
√5= Square root of 5 ≈ 2.236

Golden Ratio

φ = (1 + √5) / 2 ≈ 1.6180339887...

The limit of F(n+1)/F(n) as n approaches infinity. An irrational number with unique mathematical properties.

Where:

φ= Phi, the golden ratio
√5= Square root of 5

Example Calculations

1Calculate F(10)

Inputs

Position (n)10

Result

F(10)55
Sequence0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55
F(10)/F(9)1.6176...

F(10) = F(9) + F(8) = 34 + 21 = 55. The ratio 55/34 ≈ 1.6176 is close to the golden ratio 1.6180.

2Calculate F(20)

Inputs

Position (n)20

Result

F(20)6,765
F(20)/F(19)1.6180339...
Golden Ratio1.6180339887...

F(20) = 6,765. The ratio F(20)/F(19) = 6765/4181 = 1.6180339... matches the golden ratio to 7 decimal places.

3Check if 144 is Fibonacci

Inputs

Check Number144

Result

Is Fibonacci?Yes
PositionF(12) = 144
5n² + 4103,684 = 322²

5 × 144² + 4 = 5 × 20,736 + 4 = 103,684 = 322². Since this is a perfect square, 144 is a Fibonacci number (F(12)).

Frequently Asked Questions

Q

What is the Fibonacci sequence?

The Fibonacci sequence starts with 0 and 1, and each subsequent number is the sum of the two preceding ones: 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144, and so on. It was introduced to Western mathematics by Leonardo of Pisa (Fibonacci) in 1202.

  • F(0) = 0, F(1) = 1, then F(n) = F(n-1) + F(n-2)
  • First 10 terms: 0, 1, 1, 2, 3, 5, 8, 13, 21, 34
  • Named after Leonardo of Pisa (Fibonacci), c. 1202
  • Originally described rabbit population growth
  • Appears throughout nature: sunflowers, pinecones, shells
nF(n)Calculation
00Base case
11Base case
553 + 2
105534 + 21
206,7654,181 + 2,584
Q

What is the golden ratio and how does it relate to Fibonacci?

The golden ratio (phi, φ) equals (1 + √5) / 2, approximately 1.6180339887. The ratio of consecutive Fibonacci numbers F(n+1)/F(n) converges to phi as n increases. By F(10)/F(9) = 55/34 = 1.6176..., it is already accurate to 3 decimal places.

  • φ = (1 + √5) / 2 ≈ 1.6180339887...
  • F(n+1)/F(n) approaches φ as n increases
  • F(3)/F(2) = 2/1 = 2.0 (rough approximation)
  • F(10)/F(9) = 55/34 = 1.6176... (3 decimal accuracy)
  • F(20)/F(19) = 6765/4181 = 1.6180339... (7 decimal accuracy)
RatioValueError from φ
F(5)/F(4) = 5/31.66670.0486
F(8)/F(7) = 21/131.61540.0027
F(10)/F(9) = 55/341.61760.0004
F(15)/F(14) = 610/3771.618030.00001
Q

What is Binet's formula for Fibonacci numbers?

Binet's formula computes F(n) directly without iteration: F(n) = (φ^n - ψ^n) / √5, where φ = (1+√5)/2 and ψ = (1-√5)/2. Since |ψ| < 1, the ψ^n term shrinks rapidly, so F(n) ≈ round(φ^n / √5) for n >= 0.

  • F(n) = (φⁿ - ψⁿ) / √5
  • φ = (1+√5)/2 ≈ 1.618 (golden ratio)
  • ψ = (1-√5)/2 ≈ -0.618 (conjugate)
  • |ψ^n| < 0.5 for all n >= 0, so rounding works
  • Allows O(1) computation of any Fibonacci number
nIterative F(n)Binet FormulaMatch
555.000Yes
105555.000Yes
206,7656,765.000Yes
30832,040832,040.000Yes
Q

How do I check if a number is a Fibonacci number?

A positive integer n is a Fibonacci number if and only if 5n² + 4 or 5n² - 4 is a perfect square. For example, 13: 5(169) + 4 = 849 (not square), 5(169) - 4 = 841 = 29² (perfect square), so 13 is Fibonacci.

  • Test: n is Fibonacci if 5n² + 4 or 5n² - 4 is a perfect square
  • 13: 5(169) - 4 = 841 = 29², so yes
  • 14: 5(196) + 4 = 984 (not square), 5(196) - 4 = 976 (not square), so no
  • Works for all non-negative integers
Number5n²+45n²-4Fibonacci?
8324 = 18²316Yes
13849841 = 29²Yes
14984976No
212209 = 47²2201Yes
Q

Where do Fibonacci numbers appear in nature?

Fibonacci numbers appear in many natural phenomena: the number of petals on flowers (lilies have 3, buttercups 5, daisies 13 or 21), spiral patterns in sunflower heads and pinecones, and the branching of trees. The golden spiral based on Fibonacci rectangles models nautilus shells.

  • Flower petals: lily (3), buttercup (5), daisy (13, 21, 34)
  • Sunflower spirals: typically 34 clockwise and 55 counterclockwise
  • Pinecone spirals: 8 and 13 spirals in opposite directions
  • Tree branching patterns follow Fibonacci counts
  • Nautilus shell growth approximates the golden spiral
Natural PhenomenonFibonacci NumbersPattern
Lily petals3Petal count
Sunflower34, 55Opposing spirals
Pinecone8, 13Opposing spirals
Pineapple8, 13, 21Hexagonal scales

The Fibonacci Sequence and Golden Ratio

1

How the Fibonacci Sequence Works

F(10) = 55, F(20) = 6,765, and F(50) = 12,586,269,025 — the sequence grows exponentially because each term is the sum of the two before it. Starting from F(0) = 0 and F(1) = 1, the rule F(n) = F(n−1) + F(n−2) generates every subsequent number. Leonardo of Pisa introduced this recurrence in his 1202 book Liber Abaci to model rabbit population growth under idealized conditions.

The first 15 terms are 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144, 233, 377. By F(30) the numbers exceed 800,000, and by F(100) they surpass 3.54 × 10²⁰. This rapid growth makes iterative computation expensive for large n, which is why Binet’s closed-form formula becomes essential for direct calculation.

Every positive integer can be represented as a sum of non-consecutive Fibonacci numbers — a result known as Zeckendorf’s theorem. For example, 100 = 89 + 8 + 3. This property is the basis for Fibonacci coding, a data compression scheme used in some search engine indexing systems.

Fibonacci numbers grow exponentially while consecutive ratios converge to φ
nF(n)F(n)/F(n−1)Digits
551.66671
10551.61762
206,7651.61803404
30832,0401.61803406
5012,586,269,0251.618033988711
2

The Golden Ratio Connection

The golden ratio φ = (1 + √5) / 2 ≈ 1.6180339887 is the limit of F(n+1)/F(n) as n increases. By F(10)/F(9) = 55/34 = 1.6176, the ratio already matches φ to 3 decimal places. By F(20)/F(19) = 6,765/4,181, the match extends to 7 decimal places. This convergence is not gradual — the error halves roughly every term.

Binet’s formula makes the connection explicit: F(n) = (φⁿ − ψⁿ) / √5, where ψ = (1 − √5)/2 ≈ −0.618. Since |ψ| < 1, the term ψⁿ shrinks to zero, so F(n) ≈ round(φⁿ / √5) for all n ≥ 0. This gives O(1) computation of any Fibonacci number, though floating-point precision limits accuracy beyond roughly F(70) on standard 64-bit hardware.

The golden ratio appears in geometry, art, and architecture. A golden rectangle (sides in ratio φ:1) can be subdivided into a square and a smaller golden rectangle indefinitely, generating the golden spiral. The Ratio Calculator can verify golden ratio proportions in design work, and the Logarithm Calculator helps compute how many Fibonacci terms are needed to reach a given magnitude.

Consecutive Ratio Convergence to φφn=3n=5n=7n=10n=15n=20ConvergingWithin 0.00001 of φ
3

Fibonacci Numbers in Nature and Applications

Sunflower heads contain 34 clockwise and 55 counterclockwise spirals — two consecutive Fibonacci numbers. Pinecones typically show 8 and 13 spirals, pineapples display 8, 13, and 21 hexagonal scales, and flower petals overwhelmingly come in Fibonacci counts: lilies have 3, buttercups 5, delphiniums 8, marigolds 13, daisies 21 or 34.

In computer science, Fibonacci numbers appear in algorithm analysis. Fibonacci heaps achieve O(1) amortized insert and decrease-key operations, making them optimal for Dijkstra’s shortest-path algorithm. Fibonacci search divides arrays using Fibonacci ratios instead of halving, which can outperform binary search on hardware where comparison is cheaper than division.

Financial analysts use Fibonacci retracement levels (23.6%, 38.2%, 50%, 61.8%) derived from ratios within the sequence to identify potential support and resistance in price charts. The 61.8% level comes directly from the golden ratio: 1/φ = 0.618. While not scientifically proven as predictive, these levels are self-reinforcing because millions of traders watch the same numbers.

Fibonacci numbers appear across biology, computer science, and finance
DomainFibonacci ApplicationSpecific Numbers
BotanySpiral phyllotaxis3, 5, 8, 13, 21, 34, 55
CS: Data StructuresFibonacci heapsO(1) amortized insert
CS: SearchFibonacci searchArray partitioning by F(n)
FinanceRetracement levels23.6%, 38.2%, 61.8%
4

Testing if a Number is Fibonacci

A positive integer n is a Fibonacci number if and only if 5n² + 4 or 5n² − 4 is a perfect square. For 144: 5 × 20,736 + 4 = 103,684 = 322², confirming F(12) = 144. For 14: 5 × 196 + 4 = 984 and 5 × 196 − 4 = 976 — neither is a perfect square, so 14 is not Fibonacci.

This test runs in O(1) time with basic arithmetic, making it far faster than generating the sequence up to n. The Square Root Calculator can help verify whether the test values are perfect squares when working by hand. For the 100 integers from 1 to 100, only 10 are Fibonacci numbers (1, 2, 3, 5, 8, 13, 21, 34, 55, 89), illustrating how sparse the sequence becomes as numbers grow.

Fibonacci Checker: 5n²±4 Perfect Square Testn = 13 (IS Fibonacci)5(169)+4 = 849 ✘5(169)−4 = 841 = 29² ✔F(7) = 13n = 14 (NOT Fibonacci)5(196)+4 = 984 ✘5(196)−4 = 976 ✘Neither is a perfect squaren = 144 (IS Fibonacci)5(20736)+4 = 103684= 322² ✔F(12) = 144n = 100 (NOT Fibonacci)5(10000)+4 = 50004 ✘5(10000)−4 = 49996 ✘Between F(11)=89 and F(12)=144

The density of Fibonacci numbers among all integers approaches zero. Among the first N integers, approximately log₁₀(N) / log₁₀(φ) are Fibonacci numbers — roughly 2.08 × log₁₀(N). For N = 1,000,000, that is only 30 Fibonacci numbers.

Related Calculators

GCD & LCM Calculator

Euclidean algorithm for GCD and LCM

Prime Factorization

Factor tree and divisor analysis

Ratio Calculator

Solve and simplify ratios and proportions

Percent Calculator

Calculate percentages quickly and accurately

Pythagorean Theorem Calculator

Solve a\u00B2 + b\u00B2 = c\u00B2 for any missing side with step-by-step solutions. Identifies Pythagorean triples and calculates triangle area, perimeter, and angles.

Distance Calculator

Calculate the distance between two points in 2D or 3D using the distance formula. Shows squared distance, midpoint, components, and step-by-step work.

Related Resources

GCD & LCM Calculator

Find greatest common divisor and least common multiple

Prime Factorization Calculator

Break numbers into prime factors

Statistics Calculator

Descriptive statistics for data sets

Square Root Calculator

Calculate square roots and nth roots

Last Updated: Mar 26, 2026

This calculator is provided for informational and educational purposes only. Results are estimates and should not be considered professional financial, medical, legal, or other advice. Always consult a qualified professional before making important decisions. UseCalcPro is not responsible for any actions taken based on calculator results.

UseCalcPro
FinanceHealthMath

© 2026 UseCalcPro