Skip to main content

rational_to_f64

Function rational_to_f64 

Source
pub fn rational_to_f64(r: &Rational) -> f64
Expand description

Convert a (small) rational to f64 via bit-shift scaling so neither endpoint overflows during the division.