Constructor
new FibonacciProgression(_initiator)
Creates an instance of FibonacciProgression.
Example
// Fibonacci progression starting at 0*
new tngs.FibonacciProgression(0) // 0, 1, 2, 3, 5, ...
// Fibonacci progression starting at 5
new tngs.FibonacciProgression(5) // 5, 8, 13, 21, 34, ...
// *To prevent repeating models, the beginning of the Fibonacci sequence is tweaked.
Parameters:
Name | Type | Description |
---|---|---|
_initiator |
number | The starting point in the Fibonacci sequence. |
Extends
Methods
Advance()
Moves to the next value in the series.
Reset()
Puts the progression in its initial state (_value = 0).
- Source:
- Overrides: