


Bits error versus re



Bits error versus im
Results
Initial program 36.9
Initial simplification13.0
Final simplification13.0
herbie shell --seed 2018365 +o rules:numerics
(FPCore (re im)
:name "math.sqrt on complex, imaginary part, im greater than 0 branch"
(* 0.5 (sqrt (* 2.0 (- (sqrt (+ (* re re) (* im im))) re)))))
Time bar (total: 9.7s)Debug log
2 alts after pruning (2 fresh and 0 done)
Merged error: 12.7b
Found 2 expressions with local error:
| 0.5b | (- (hypot re im) re) |
| 0.2b | (sqrt (* (- (hypot re im) re) 2.0)) |
2 calls. Slowest were:
| 8.0ms | (- (hypot re im) re) |
| 5.0ms | (sqrt (* (- (hypot re im) re) 2.0)) |
2 calls. Slowest were:
| 581.0ms | (sqrt (* (- (hypot re im) re) 2.0)) |
| 73.0ms | (- (hypot re im) re) |
11 calls. Slowest were:
| 181.0ms | (sqrt (* (- (* (hypot re im) (hypot re im)) (* re re)) 2.0)) |
| 80.0ms | (sqrt (* (- (pow (hypot re im) 3) (pow re 3)) 2.0)) |
| 3.0ms | (sqrt (- (hypot re im) re)) |
6 alts after pruning (5 fresh and 1 done)
Merged error: 12.4b
Found 3 expressions with local error:
| 0.5b | (- (hypot re im) re) |
| 0.3b | (* (sqrt (- (hypot re im) re)) (sqrt 2.0)) |
| 0.0b | (sqrt (- (hypot re im) re)) |
3 calls. Slowest were:
| 7.0ms | (* (sqrt (- (hypot re im) re)) (sqrt 2.0)) |
| 4.0ms | (- (hypot re im) re) |
| 4.0ms | (sqrt (- (hypot re im) re)) |
3 calls. Slowest were:
| 120.0ms | (* (sqrt (- (hypot re im) re)) (sqrt 2.0)) |
| 71.0ms | (sqrt (- (hypot re im) re)) |
| 30.0ms | (- (hypot re im) re) |
32 calls. Slowest were:
| 375.0ms | (* (* (* (sqrt (- (hypot re im) re)) (sqrt (- (hypot re im) re))) (sqrt (- (hypot re im) re))) (* (* (sqrt 2.0) (sqrt 2.0)) (sqrt 2.0))) |
| 160.0ms | (* (sqrt (- (* (hypot re im) (hypot re im)) (* re re))) (sqrt 2.0)) |
| 141.0ms | (sqrt (- (* (hypot re im) (hypot re im)) (* re re))) |
5 alts after pruning (4 fresh and 1 done)
Merged error: 12.4b
Found 4 expressions with local error:
| 0.5b | (- (hypot re im) re) |
| 0.5b | (- (hypot re im) re) |
| 0.4b | (* (sqrt (sqrt (- (hypot re im) re))) (sqrt (sqrt (- (hypot re im) re)))) |
| 0.3b | (* (* (sqrt (sqrt (- (hypot re im) re))) (sqrt (sqrt (- (hypot re im) re)))) (sqrt 2.0)) |
4 calls. Slowest were:
| 28.0ms | (* (* (sqrt (sqrt (- (hypot re im) re))) (sqrt (sqrt (- (hypot re im) re)))) (sqrt 2.0)) |
| 12.0ms | (* (sqrt (sqrt (- (hypot re im) re))) (sqrt (sqrt (- (hypot re im) re)))) |
| 3.0ms | (- (hypot re im) re) |
4 calls. Slowest were:
| 110.0ms | (* (* (sqrt (sqrt (- (hypot re im) re))) (sqrt (sqrt (- (hypot re im) re)))) (sqrt 2.0)) |
| 88.0ms | (* (sqrt (sqrt (- (hypot re im) re))) (sqrt (sqrt (- (hypot re im) re)))) |
| 31.0ms | (- (hypot re im) re) |
| 30.0ms | (- (hypot re im) re) |
76 calls. Slowest were:
| 388.0ms | (* (* (* (* (sqrt (sqrt (- (hypot re im) re))) (sqrt (sqrt (- (hypot re im) re)))) (sqrt (sqrt (- (hypot re im) re)))) (* (* (sqrt (sqrt (- (hypot re im) re))) (sqrt (sqrt (- (hypot re im) re)))) (sqrt (sqrt (- (hypot re im) re))))) (* (* (sqrt 2.0) (sqrt 2.0)) (sqrt 2.0))) |
| 231.0ms | (* (* (sqrt (sqrt (- (* (hypot re im) (hypot re im)) (* re re)))) (sqrt (sqrt (- (hypot re im) re)))) (sqrt 2.0)) |
| 202.0ms | (* (* (* (* (sqrt (sqrt (- (hypot re im) re))) (sqrt (sqrt (- (hypot re im) re)))) (* (sqrt (sqrt (- (hypot re im) re))) (sqrt (sqrt (- (hypot re im) re))))) (* (sqrt (sqrt (- (hypot re im) re))) (sqrt (sqrt (- (hypot re im) re))))) (* (* (sqrt 2.0) (sqrt 2.0)) (sqrt 2.0))) |
7 alts after pruning (5 fresh and 2 done)
Merged error: 12.3b
Found 4 expressions with local error:
| 14.5b | (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) |
| 0.2b | (sqrt (* (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) 2.0)) |
| 0.0b | (sqrt (hypot re im)) |
| 0.0b | (sqrt (hypot re im)) |
4 calls. Slowest were:
| 3.0ms | (sqrt (* (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) 2.0)) |
| 1.0ms | (sqrt (hypot re im)) |
| 1.0ms | (sqrt (hypot re im)) |
4 calls. Slowest were:
| 146.0ms | (sqrt (* (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) 2.0)) |
| 105.0ms | (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) |
| 56.0ms | (sqrt (hypot re im)) |
| 55.0ms | (sqrt (hypot re im)) |
21 calls. Slowest were:
| 5.0ms | (sqrt (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re))) |
| 2.0ms | (sqrt (* (cbrt (hypot re im)) (cbrt (hypot re im)))) |
| 2.0ms | (sqrt (* (cbrt (hypot re im)) (cbrt (hypot re im)))) |
12 alts after pruning (10 fresh and 2 done)
Merged error: 12.3b
0% (0.3b remaining)
Error of 13.0b against oracle of 12.7b and baseline of 13.0b