Description Usage Arguments Value References Examples
The Fibonacci sequence is defined by a recurrence relation where f_n denotes the series up to n points.
f_n = f_{n-1} + f_{n-2}
With initial coniditions:
f_1 = 1, \qquad f_2 = 2
1 | fibonacci(n)
|
n |
Integer designating the stopping point of the Fibonacci sequence |
array of the Fibonacci sequence up to n.
Moler, C. (2011). Numerical computing with MATLAB (1st ed.). Philadelphia, Pa: Society for Industrial & Applied Mathematics.
1 | fibonacci(5)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.