polycore 0.1.3

Fields, prime fields, sparse and dense polynomials, and sparse echelon forms.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
use num_bigint::BigUint;
use polycore::lehmer;

fn fib(n: usize) -> BigUint {
    let (mut a, mut b) = (BigUint::from(0u32), BigUint::from(1u32));
    for _ in 0..n {
        (a, b) = (b.clone(), a + b);
    }
    a
}

fn main() {
    let g = lehmer::gcd(&fib(300), &fib(200));
    println!("gcd(F_300, F_200) = {g}");
    println!("F_100             = {}", fib(100));
}