pub fn almost_equal_f64(a: f64, b: f64, epsilon: f64) -> bool
Expand description
Return true when arguments are the same within some rounding error.
For instance almost_equal(x, x.to_degrees().to_radians(), f64::EPSILON)
should hold true for all x.
The epsilon
can be f64::EPSILON
to handle simple transforms (like degrees -> radians)
but should be higher to handle more complex transformations.