



Bits error versus x
Results
| Original | 40.7 |
|---|---|
| Target | 39.8 |
| Herbie | 0.0 |
Initial program 40.7
Simplified0.0
Final simplification0.0
herbie shell --seed 2019010 +o rules:numerics
(FPCore (x)
:name "Kahan's exp quotient"
:herbie-target
(if (and (< x 1) (> x -1)) (/ (- (exp x) 1) (log (exp x))) (/ (- (exp x) 1) x))
(/ (- (exp x) 1) x))
Time bar (total: 3.8s)Debug log
| 7.0ms | (/ (- (exp x) 1) x) |
1 alts after pruning (1 fresh and 0 done)
Merged error: 0.0b
Found 1 expressions with local error:
| 0.0b | (/ (expm1 x) x) |
| 3× | associate-/l* |
| 2× | add-cube-cbrt |
| 2× | *-un-lft-identity |
| 2× | add-sqr-sqrt |
| 1× | add-log-exp |
| 1× | expm1-udef |
| 1× | div-inv |
| 1× | log1p-expm1-u |
| 1× | add-exp-log |
| 1× | div-sub |
| 1× | add-cbrt-cube |
| 1× | frac-2neg |
| 1× | clear-num |
| 1× | pow1 |
| 1× | expm1-log1p-u |
| 5.0ms | (/ (expm1 x) x) |
| 36.0ms | (/ (expm1 x) x) |
| 70.0ms | (* -1 (/ (- 1 (exp x)) x)) |
| 37.0ms | (+ (* 1/2 x) (+ (* 1/6 (pow x 2)) 1)) |
| 9.0ms | (/ (- (exp x) 1) x) |
| 1.0ms | (* (cbrt (expm1 x)) (cbrt (expm1 x))) |
| 1.0ms | (/ (exp x) x) |
2 alts after pruning (1 fresh and 1 done)
Merged error: 0b
Found 2 expressions with local error:
| 0.0b | (/ 1 (/ x (expm1 x))) |
| 0.0b | (/ x (expm1 x)) |
| 7× | associate-/r* |
| 4× | add-cube-cbrt |
| 4× | *-un-lft-identity |
| 4× | add-sqr-sqrt |
| 3× | div-inv |
| 3× | add-exp-log |
| 3× | pow1 |
| 2× | add-log-exp |
| 2× | log1p-expm1-u |
| 2× | add-cbrt-cube |
| 2× | frac-2neg |
| 2× | clear-num |
| 2× | expm1-log1p-u |
| 1× | inv-pow |
| 1× | pow-flip |
| 1× | associate-/r/ |
| 1× | rec-exp |
| 1.0ms | (/ 1 (/ x (expm1 x))) |
| 1.0ms | (/ x (expm1 x)) |
| 29.0ms | (/ 1 (/ x (expm1 x))) |
| 29.0ms | (/ x (expm1 x)) |
| 93.0ms | (* -1 (/ (- 1 (exp x)) x)) |
| 89.0ms | (- (+ (* 1/12 (pow x 2)) 1) (* 1/2 x)) |
| 33.0ms | (+ (* 1/2 x) (+ (* 1/6 (pow x 2)) 1)) |
| 8.0ms | (/ (- (exp x) 1) x) |
| 5.0ms | (/ x (- (exp x) 1)) |
2 alts after pruning (0 fresh and 2 done)
Merged error: 0b
0% (0.0b remaining)
Error of 0.0b against oracle of 0.0b and baseline of 0.0b