Crate facto

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 rug::Integer;
pub use redc;

Modules§

factoring
Factorization algorithms for integers
primality
Primality checking algorithms for integers

Structs§

EmptyFactoringEventSubscriptor
Stub observer, for when no event callbacks are required
LucasCertificate
The certificate tree for the lucas certificate
LucasCertificateElement
Element of the lucas certificate tree, representing one number

Enums§

PrimalityCertainty
Grade of certainty for primality check

Traits§

CertifiedFactorization
Factorize number while possible updating a lucas certificate
Factoring
Factor number into it’s prime factors
FactoringEventSubscriptor
Observer with callbacks relating to events during the factorization of an integer
Primality
Optimized methods of checking and certifying primality