



Bits error versus x




Bits error versus y
Results
| Original | 19.7 |
|---|---|
| Target | 0.1 |
| Herbie | 0.0 |
Initial program 19.7
Simplified19.7
rmApplied add-sqr-sqrt19.8
Applied times-frac19.8
Simplified19.8
Simplified0.0
rmApplied add-cbrt-cube0.0
Final simplification0.0
herbie shell --seed 2019005 +o rules:numerics
(FPCore (x y)
:name "Kahan p9 Example"
:pre (and (< 0 x 1) (< y 1))
:herbie-target
(if (< 0.5 (fabs (/ x y)) 2) (/ (* (- x y) (+ x y)) (+ (* x x) (* y y))) (- 1 (/ 2 (+ 1 (* (/ x y) (/ x y))))))
(/ (* (- x y) (+ x y)) (+ (* x x) (* y y))))
Time bar (total: 28.0s)Debug log
1 calls. Slowest were:
| 294.0ms | (/ (* (- x y) (+ x y)) (+ (* x x) (* y y))) |
1 alts after pruning (1 fresh and 0 done)
Merged error: 16.1b
Found 2 expressions with local error:
| 16.1b | (/ (* (- x y) (+ y x)) (fma x x (* y y))) |
| 0.0b | (fma x x (* y y)) |
2 calls. Slowest were:
| 11.0ms | (/ (* (- x y) (+ y x)) (fma x x (* y y))) |
| 0.0ms | (fma x x (* y y)) |
2 calls. Slowest were:
| 36.0ms | (/ (* (- x y) (+ y x)) (fma x x (* y y))) |
| 19.0ms | (fma x x (* y y)) |
28 calls. Slowest were:
| 554.0ms | (- (log (* (- x y) (+ y x))) (log (fma x x (* y y)))) |
| 342.0ms | (* (- (* x x) (* y y)) (+ y x)) |
| 311.0ms | (* (- (pow x 3) (pow y 3)) (+ y x)) |
4 alts after pruning (4 fresh and 0 done)
Merged error: 0.0b
Found 3 expressions with local error:
| 0.0b | (/ (- x y) (hypot x y)) |
| 0.0b | (/ (+ x y) (hypot x y)) |
| 0.0b | (* (/ (- x y) (hypot x y)) (/ (+ x y) (hypot x y))) |
3 calls. Slowest were:
| 7.0ms | (* (/ (- x y) (hypot x y)) (/ (+ x y) (hypot x y))) |
| 3.0ms | (/ (+ x y) (hypot x y)) |
| 3.0ms | (/ (- x y) (hypot x y)) |
3 calls. Slowest were:
| 79.0ms | (* (/ (- x y) (hypot x y)) (/ (+ x y) (hypot x y))) |
| 77.0ms | (/ (+ x y) (hypot x y)) |
| 48.0ms | (/ (- x y) (hypot x y)) |
102 calls. Slowest were:
| 432.0ms | (* (/ (- x y) (hypot x y)) (/ (+ x y) (hypot x y))) |
| 322.0ms | (/ (* (* (+ x y) (+ x y)) (+ x y)) (* (* (hypot x y) (hypot x y)) (hypot x y))) |
| 313.0ms | (+ (- (log (- x y)) (log (hypot x y))) (log (/ (+ x y) (hypot x y)))) |
5 alts after pruning (5 fresh and 0 done)
Merged error: 0b
Found 4 expressions with local error:
| 0.1b | (pow (/ (- x y) (hypot x y)) 3) |
| 0.1b | (pow (/ (+ y x) (hypot x y)) 3) |
| 0.0b | (/ (- x y) (hypot x y)) |
| 0.0b | (/ (+ y x) (hypot x y)) |
4 calls. Slowest were:
| 3.0ms | (/ (+ y x) (hypot x y)) |
| 3.0ms | (pow (/ (- x y) (hypot x y)) 3) |
| 3.0ms | (/ (- x y) (hypot x y)) |
4 calls. Slowest were:
| 66.0ms | (pow (/ (- x y) (hypot x y)) 3) |
| 65.0ms | (pow (/ (+ y x) (hypot x y)) 3) |
| 49.0ms | (/ (- x y) (hypot x y)) |
| 45.0ms | (/ (+ y x) (hypot x y)) |
131 calls. Slowest were:
| 958.0ms | (pow (/ 1 (* (cbrt (hypot x y)) (cbrt (hypot x y)))) 3) |
| 876.0ms | (pow (/ 1 (* (cbrt (hypot x y)) (cbrt (hypot x y)))) 3) |
| 860.0ms | (pow (/ 1 (* (cbrt (hypot x y)) (cbrt (hypot x y)))) 3) |
4 alts after pruning (4 fresh and 0 done)
Merged error: 0b
Found 4 expressions with local error:
| 0.0b | (/ (- x y) (hypot x y)) |
| 0.0b | (/ (- x y) (hypot x y)) |
| 0.0b | (/ (- x y) (hypot x y)) |
| 0.0b | (/ (+ x y) (hypot x y)) |
4 calls. Slowest were:
| 3.0ms | (/ (+ x y) (hypot x y)) |
| 3.0ms | (/ (- x y) (hypot x y)) |
| 3.0ms | (/ (- x y) (hypot x y)) |
4 calls. Slowest were:
| 45.0ms | (/ (- x y) (hypot x y)) |
| 44.0ms | (/ (- x y) (hypot x y)) |
| 44.0ms | (/ (- x y) (hypot x y)) |
| 43.0ms | (/ (+ x y) (hypot x y)) |
123 calls. Slowest were:
| 198.0ms | (/ (* (* (+ x y) (+ x y)) (+ x y)) (* (* (hypot x y) (hypot x y)) (hypot x y))) |
| 111.0ms | (/ (* (* (- x y) (- x y)) (- x y)) (* (* (hypot x y) (hypot x y)) (hypot x y))) |
| 91.0ms | (/ (* (* (- x y) (- x y)) (- x y)) (* (* (hypot x y) (hypot x y)) (hypot x y))) |
4 alts after pruning (3 fresh and 1 done)
Merged error: 0b
0% (0.0b remaining)
Error of 0.0b against oracle of 0.0b and baseline of 0.0b