



Bits error versus re




Bits error versus im
Results
| Original | 37.3 |
|---|---|
| Target | 32.7 |
| Herbie | 17.3 |
if (* 2.0 (+ im re)) < -7.995196897578388e+158Initial program 61.9
rmApplied flip-+61.9
Applied associate-*r/61.9
Applied sqrt-div61.9
Applied simplify55.1
Taylor expanded around -inf 38.5
if -7.995196897578388e+158 < (* 2.0 (+ im re)) < 1.039506264253617e-256Initial program 32.2
rmApplied flip-+32.2
Applied associate-*r/32.2
Applied sqrt-div32.4
Applied simplify19.8
rmApplied add-sqr-sqrt19.8
Applied sqrt-prod19.9
Applied sqrt-prod20.0
Applied times-frac19.9
Applied simplify7.4
if 1.039506264253617e-256 < (* 2.0 (+ im re)) < 1.1014827247221702e-160 or 5.777851359155679e+154 < (* 2.0 (+ im re)) < 7.739821105146112e+232Initial program 60.2
Taylor expanded around inf 29.4
if 1.1014827247221702e-160 < (* 2.0 (+ im re)) < 5.777851359155679e+154Initial program 0.2
rmApplied add-sqr-sqrt0.2
Applied sqrt-prod0.3
if 7.739821105146112e+232 < (* 2.0 (+ im re)) Initial program 61.2
Taylor expanded around 0 26.0
Time bar (total: 3.2m)Debug logProfile
herbie shell --seed '#(1072967564 1937075727 894099792 790700740 1036514779 1027793188)'
(FPCore (re im)
:name "math.sqrt on complex, real part"
:herbie-target
(if (< re 0) (* 0.5 (* (sqrt 2) (sqrt (/ (* im im) (- (sqrt (+ (* re re) (* im im))) re))))) (* 0.5 (sqrt (* 2.0 (+ (sqrt (+ (* re re) (* im im))) re)))))
(* 0.5 (sqrt (* 2.0 (+ (sqrt (+ (* re re) (* im im))) re)))))