#fibonacci #no-std #math

no-std quickfib

A no_std compatible Fibonacci calculation algorithm implemented in Rust

1 stable release

1.0.0 Jun 20, 2024

#1836 in Algorithms

MIT license

5KB
80 lines

Quickfib

Quickly calculate fibbonacci numbers.


lib.rs:

Fast fibbonacci algorithm.

This crate provides a fast implementation of the fibbonacci algorithm, no_std compatible. The algorithm is based on the following formula:

F(2n) = F(n) * (2 * F(n+1) - F(n))
F(2n+1) = F(n)^2 + F(n+1)^2

No runtime deps