



Bits error versus a




Bits error versus b




Bits error versus c
| Original | 33.6 |
|---|---|
| Target | 20.5 |
| Herbie | 7.1 |
if b < -9.13115209614994337e44Initial program 37.2
Simplified37.2
Taylor expanded around -inf 6.0
Simplified6.0
if -9.13115209614994337e44 < b < -4.3571849990037956e-308Initial program 9.2
Simplified9.2
rmApplied clear-num9.3
Simplified9.3
if -4.3571849990037956e-308 < b < 1.34309843668829568e38Initial program 28.3
Simplified28.3
rmApplied flip-+28.4
Simplified16.5
rmApplied associate-/r*16.5
Simplified9.1
if 1.34309843668829568e38 < b Initial program 57.0
Simplified57.0
Taylor expanded around inf 4.2
Final simplification7.1
herbie shell --seed 2020181
(FPCore (a b c)
:name "The quadratic formula (r1)"
:precision binary64
:herbie-target
(if (< b 0.0) (/ (+ (neg b) (sqrt (- (* b b) (* (* 4.0 a) c)))) (* 2.0 a)) (/ c (* a (/ (- (neg b) (sqrt (- (* b b) (* (* 4.0 a) c)))) (* 2.0 a)))))
(/ (+ (neg b) (sqrt (- (* b b) (* (* 4.0 a) c)))) (* 2.0 a)))