Skip to content

Commit 8eef535

Browse files
committed
feat(Analysis/SpecificLimits/Fibonacci): prove that the ratio of consecutive Fibonacci numbers tends to the golden ratio
1 parent a2df56f commit 8eef535

2 files changed

Lines changed: 36 additions & 0 deletions

File tree

Mathlib.lean

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2031,6 +2031,7 @@ import Mathlib.Analysis.SpecialFunctions.Trigonometric.Series
20312031
import Mathlib.Analysis.SpecialFunctions.Trigonometric.Sinc
20322032
import Mathlib.Analysis.SpecificLimits.ArithmeticGeometric
20332033
import Mathlib.Analysis.SpecificLimits.Basic
2034+
import Mathlib.Analysis.SpecificLimits.Fibonacci
20342035
import Mathlib.Analysis.SpecificLimits.FloorPow
20352036
import Mathlib.Analysis.SpecificLimits.Normed
20362037
import Mathlib.Analysis.SpecificLimits.RCLike
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
/-
2+
Copyright (c) 2025 Snir Broshi. All rights reserved.
3+
Released under Apache 2.0 license as described in the file LICENSE.
4+
Authors: Snir Broshi
5+
-/
6+
import Mathlib.Analysis.SpecificLimits.Normed
7+
import Mathlib.Data.Real.GoldenRatio
8+
9+
/-!
10+
# The ratio of consecutive Fibonacci numbers
11+
12+
We prove that the ratio of consecutive Fibonacci numbers tends to the golden ratio.
13+
-/
14+
15+
open Nat Real Filter Tendsto goldenRatio
16+
17+
/-- The limit of `fib (n + 1) / fib n` as `n → ∞` is the golden ratio. -/
18+
theorem tendsto_fib_succ_div_fib_atTop :
19+
Tendsto (fun n ↦ (fib (n + 1) / fib n : ℝ)) atTop <| nhds φ := by
20+
have h₁ n : (fib (n + 1) / fib n : ℝ) = (φ - ψ * (ψ / φ) ^ n) / (1 - (ψ / φ) ^ n) := by
21+
simp only [coe_fib_eq, pow_succ, div_pow]
22+
field_simp
23+
have h₂ := tendsto_pow_atTop_nhds_zero_of_abs_lt_one (r := ψ / φ) <| by
24+
rw [abs_div, div_lt_one <| by positivity, abs_of_pos goldenRatio_pos, abs_lt]
25+
ring_nf
26+
bound
27+
rw [show φ = (φ - ψ * 0) / (1 - 0) by ring, funext h₁]
28+
exact const_sub _ (const_mul _ h₂) |>.div (const_sub _ h₂) <| by simp
29+
30+
/-- The limit of `fib n / fib (n + 1)` as `n → ∞` is the negative conjugate of the golden ratio. -/
31+
theorem tendsto_fib_div_fib_succ_atTop :
32+
Tendsto (fun n ↦ (fib n / fib (n + 1) : ℝ)) atTop <| nhds <| -ψ := by
33+
convert tendsto_fib_succ_div_fib_atTop.inv₀ (by positivity) using 2
34+
· rw [inv_div]
35+
· rw [inv_goldenRatio]

0 commit comments

Comments
 (0)