3 ms·
Gotta love that Herbie also provides just `1` as alternative. "66.8% accurate, 305.0× speedup" But the expression you get if you disable "numerics" ruleset (wh
by zokier 3y ago
Gotta love that Herbie also provides just `1` as alternative. "66.8% accurate, 305.0× speedup"
But the expression you get if you disable "numerics" ruleset (which includes expm1) is pretty wild also:
(if (<= (exp x) 4504410275303423/4503599627370496)
(+
1
(+ (* 1/24 (pow x 3)) (* x (+ 1/2 (* x 1/6)))))
(/ (+ (exp x) -1) (log (exp x)))))