



Bits error versus x




Bits error versus y
Results
| Original | 20.5 |
|---|---|
| Target | 0.0 |
| Herbie | 0.0 |
Initial program 20.5
Simplified20.5
rmApplied add-sqr-sqrt20.5
Applied times-frac20.5
Simplified20.4
Simplified0.0
rmApplied associate-*l/0.0
rmApplied associate-/l*0.0
Final simplification0.0
herbie shell --seed 2019002 +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: 53.2s)Debug log
1 calls. Slowest were:
| 409.0ms | (/ (* (- x y) (+ x y)) (+ (* x x) (* y y))) |
1 alts after pruning (1 fresh and 0 done)
Merged error: 19.5b
Found 2 expressions with local error:
| 19.5b | (/ (* (- x y) (+ y x)) (fma x x (* y y))) |
| 0.0b | (fma x x (* y y)) |
2 calls. Slowest were:
| 12.0ms | (/ (* (- x y) (+ y x)) (fma x x (* y y))) |
| 0.0ms | (fma x x (* y y)) |
2 calls. Slowest were:
| 54.0ms | (/ (* (- x y) (+ y x)) (fma x x (* y y))) |
| 28.0ms | (fma x x (* y y)) |
28 calls. Slowest were:
| 437.0ms | (* (- (* x x) (* y y)) (+ (pow y 3) (pow x 3))) |
| 401.0ms | (* (- (* x x) (* y y)) (+ y x)) |
| 331.0ms | (* (- (pow x 3) (pow y 3)) (+ y x)) |
3 alts after pruning (3 fresh and 0 done)
Merged error: 0.0b
Found 4 expressions with local error:
| 0.0b | (* (/ (- x y) (hypot x y)) (/ (+ x y) (hypot x y))) |
| 0.0b | (/ (+ x y) (hypot x y)) |
| 0.0b | (/ (- x y) (hypot x y)) |
| 0.0b | (hypot x y) |
4 calls. Slowest were:
| 8.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)) |
4 calls. Slowest were:
| 74.0ms | (/ (- x y) (hypot x y)) |
| 69.0ms | (* (/ (- x y) (hypot x y)) (/ (+ x y) (hypot x y))) |
| 65.0ms | (/ (+ x y) (hypot x y)) |
| 41.0ms | (hypot x y) |
105 calls. Slowest were:
| 405.0ms | (+ (- (log (- x y)) (log (hypot x y))) (- (log (+ x y)) (log (hypot x y)))) |
| 373.0ms | (* (/ (- x y) (hypot x y)) (/ (+ x y) (hypot x y))) |
| 362.0ms | (/ (* (* (+ x y) (+ x y)) (+ x y)) (* (* (hypot x y) (hypot x y)) (hypot x y))) |
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) (/ (+ x y) (hypot x y))) (hypot x y)) |
| 0.0b | (hypot x y) |
| 0.0b | (hypot x y) |
4 calls. Slowest were:
| 8.0ms | (/ (* (- x y) (/ (+ x y) (hypot x y))) (hypot x y)) |
| 3.0ms | (/ (+ x y) (hypot x y)) |
| 0.0ms | (hypot x y) |
4 calls. Slowest were:
| 79.0ms | (/ (* (- x y) (/ (+ x y) (hypot x y))) (hypot x y)) |
| 79.0ms | (/ (+ x y) (hypot x y)) |
| 43.0ms | (hypot x y) |
| 36.0ms | (hypot x y) |
60 calls. Slowest were:
| 392.0ms | (/ (* (* (+ x y) (+ x y)) (+ x y)) (* (* (hypot x y) (hypot x y)) (hypot x y))) |
| 317.0ms | (/ (* (* (* (- x y) (- x y)) (- x y)) (/ (* (* (+ x y) (+ x y)) (+ x y)) (* (* (hypot x y) (hypot x y)) (hypot x y)))) (* (* (hypot x y) (hypot x y)) (hypot x y))) |
| 284.0ms | (* (- (pow x 3) (pow y 3)) (/ (+ x y) (hypot x y))) |
3 alts after pruning (3 fresh and 0 done)
Merged error: 0b
Found 4 expressions with local error:
| 0.0b | (/ (+ x y) (hypot x y)) |
| 0.0b | (/ (hypot x y) (/ (+ x y) (hypot x y))) |
| 0.0b | (/ (- x y) (/ (hypot x y) (/ (+ x y) (hypot x y)))) |
| 0.0b | (hypot x y) |
4 calls. Slowest were:
| 6.0ms | (/ (- x y) (/ (hypot x y) (/ (+ x y) (hypot x y)))) |
| 5.0ms | (/ (hypot x y) (/ (+ x y) (hypot x y))) |
| 3.0ms | (/ (+ x y) (hypot x y)) |
4 calls. Slowest were:
| 70.0ms | (/ (hypot x y) (/ (+ x y) (hypot x y))) |
| 62.0ms | (/ (+ x y) (hypot x y)) |
| 56.0ms | (/ (- x y) (/ (hypot x y) (/ (+ x y) (hypot x y)))) |
| 30.0ms | (hypot x y) |
457 calls. Slowest were:
| 686.0ms | (/ (sqrt (- x y)) (/ (* (cbrt (hypot x y)) (cbrt (hypot x y))) (/ 1 (sqrt (hypot x y))))) |
| 682.0ms | (/ (* (cbrt (- x y)) (cbrt (- x y))) (/ (* (cbrt (hypot x y)) (cbrt (hypot x y))) (/ (sqrt (+ x y)) 1))) |
| 628.0ms | (/ (* (cbrt (- x y)) (cbrt (- x y))) (/ (* (cbrt (hypot x y)) (cbrt (hypot x y))) (/ 1 (* (cbrt (hypot x y)) (cbrt (hypot x y)))))) |
3 alts after pruning (2 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