Uploaded by dezigner fire

The History and Computation of the Golden Ratio

advertisement
The History and Computation of the Golden
Ratio and The Fibonacci Sequence
By: Savannah Norem and Jacob Meystrik
Table of Contents
●
Golden Ratio
●
Fibonacci
●
Binet’s Formula
●
Dynamic Programming
●
Matrix Exponentiation
●
Fast Doubling
●
Super duper cool math stuff I PROMISE
Who are we?
Savannah
●
●
●
Two cats
Trash TV (love is blind)
Not Trash books (current read: The Calculating Stars)
<- Franklin, TN
●
●
●
●
BS in 2018
Took a year off to try full time adulting
10/10 would not recommend
MS at the end of summer
AKA where I grew up
AKA consistently voted
one of the cutest towns
in TN
Jacob
●
B.S. Mathematics
●
M.S. Applied Mathematics (University of Tennessee Chattanooga, 2016)
●
M.S. Computer Science
●
tl;dr I’M A NERD
●
Security Engineer at JTV for the past 3ish years.
●
I am a musician and I own a cat, just in case the stereotype wasn’t
showing strong enough.
(Lee University, 2014)
(University of Tennessee Knoxville, c.Spring 2020)
Questions
1.
2.
3.
What’s your favorite example of the Fibonacci sequence in nature?
What are one problem and one advantage of using the golden ratio to
approximate Fibonacci numbers?
Name one corollary or extension of the Fibonacci sequence.
Why do we care when we can just google the nth
Fibonacci number?
1 - It shows up in nature a lot
2 - It’s cool
3 - People are still doing research using Fibonacci numbers
Background
The Golden Ratio
The Golden Ratio
Optimal Distribution of Seeds
The Golden Ratio
A fascinating approximation of the golden ratio comes from the Fibonacci
Sequence.
Fibonacci - A History
•
Born Leonardo Bonacci to Guglielmo Bonacci c.1170
•
Fibonacci means “Son of Bonacci” and is the name given to him by historians
as early as 1506.
•
Traveled the Mediterranean with his father who was a merchant and customs
officer.
•
Popularized the Hindu-Arabic numeral system in the Western world through
his composition Liber Abaci (Book of Calculation) in 1202.
Fibonacci - Concerning Rabbits
Obligatory Class Participation
Have any of you programmed using or calculating the
Fibonacci numbers?
Did any of you use a method more complex than recursion or
dynamic programming?
Fibonacci - The Sequence
Given F(0) = 1, F(1) = 1, and n ≥ 2
F(n - 2) + F(n - 1) = F(n)
1, 1, 2, 3, 5, 8, 13, 21, …
Binet’s Formula
*THIS IS REALLY FAST!*
What Happens When Rounding Errors Exists?
F(3) = 1.99992 ~ 2
F(16) = 986.698 ~ 987
F(18) = 2583.1 ~? 2584 <- rounding error due to lack of precision in phi.
Alternatives?
1.
Dynamic Programming
2.
Matrix Exponentiation
3.
Fast Doubling
Dynamic Programming
int Dynamic_Fibonacci(int n) {
int f[n];
f[0] = f[1] = 1;
for (int i = 2; i <= n; i++)
f[i] = f[i-1] + f[i-2];
return f[n];
}
int Dynamic_Fibonacci (int n) {
if(n == 0) return 1;
if(n == 1) return 1;
int f_1 = f_2 = 1;
int f_n;
for(int i = 2; i <= n; i++) {
f_n = f_1 + f_2;
f_1 = f_2;
f_2 = f_n;
}
return f_n;
}
Matrix Exponentiation
Example
So if we want to find the 5th Fibonacci number using this, first we look at what
powers of 2 we need to get there. We’ll need 1 and 4, and to get to 4 we’ll need 2.
One way we can see this is by looking at 5 in binary: 101 so we need the first and
third matrices that we get via exponentiation by squaring.
So we have two matrices that we care about, and we multiply
them together.
=
Remember what
they mean...
And since I intentionally chose a small number, we know that
the Fibonacci sequence goes 1,1,2,3,5,8 and can see that
this checks.
A Bigger Example...F(14)
14 in binary: 1110 -> so we need the 2nd, 3rd, and 4th
matrices that we get from exponentiation
2
2
=
=
So we end up with F(14) = 377
in 5 matrix multiplies.
This runs in log(n) time.
Fast Doubling
An extension of Matrix Exponentiation with redundant calculations removed.
This is the key thing,
And if you notice in our three matrices
a lot of these numbers repeat. The F(n+1) becomes F(n), and F(n) becomes
F(n-1). So when we’re using fast doubling, instead of calculating all four values of
the next matrix, we only need to newly find F(n+1), and we use the others that we
already know.
So that wraps up the algorithms that we would use to
find the nth number in the Fibonacci sequence, where n
>= 2 and a whole number.
But...what if it wasn’t?
And what if F(0) and F(1) weren’t 1?
Negafibonacci
Extension to all real or complex numbers
Lucas Numbers
It’s “Fibonacci” except F(0) = 2 and F(1) = 1
So...2,1,3,4,7,11,18,etc
They have some super interesting relationships but I want to point out this one:
Cassini and Catalan Identities
Current Research
“On Dual-Complex Numbers with Generalized Fibonacci and Lucas Numbers
Components” (2018)
“A Study on Dual Hyperbolic Fibonacci and Lucas Numbers” (2019)
“Investigation of Dual-Complex Fibonacci, Dual-Complex Lucas Numbers and
Their Properties” (2017)
Have some more color and cool examples:
Questions Again
1.
2.
3.
What’s your favorite example of the Fibonacci sequence in nature?
What are one problem and one advantage of using the golden ratio to
approximate Fibonacci numbers?
Name one corollary or extension of the Fibonacci sequence.
Sources
Fast Fibonacci algorithms
Fibonacci Numbers
https://www.youtube.com/watch?v=EEb6JP3NXBI&t=513s
The Fibonacci Numbers and Its Amazing Applications
Also, as with any good project, Wikipedia.
Download