Crate facto

source · []
Expand description

Integer factorization, primality checking and primality certification

use facto::{Factoring, Primality};
assert_eq!(65u64.factor(), vec![5, 13]);
assert!(13u64.is_prime());
assert!(!14u64.is_prime());
dbg!(101u64.generate_lucas_certificate());

Re-exports

pub use redc;
pub use rug::Integer;

Modules

Factorization algorithms for integers

Primality checking algorithms for integers

Structs

Stub observer, for when no event callbacks are required

The certificate tree for the lucas certificate

Element of the lucas certificate tree, representing one number

Enums

Grade of certainty for primality check

Traits

Factorize number while possible updating a lucas certificate

Factor number into it’s prime factors

Observer with callbacks relating to events during the factorization of an integer

Optimized methods of checking and certifying primality