pub fn calculate_entropy(length: usize, pool_size: usize) -> f64
Calculates entropy.
Returns f64::NEG_INFINITY
if pool_size
is 0
let entropy = upwd::calculate_entropy(12, 64);
assert_eq!(entropy, 72.0);
Panics when casting BigUint to f64.
This usually means that the entropy will be greater than 1024 bits.