Average Error: 17.6 → 17.6
Time: 1.8s
Precision: binary64
\[\left(-b\right) + \frac{\sqrt{{b}^{2} - \left(4 \cdot a\right) \cdot c}}{2} \cdot a\]
\[\frac{\sqrt{{b}^{2} - \left(4 \cdot a\right) \cdot c}}{2} \cdot a - b\]

Error

Bits error versus b

Bits error versus a

Bits error versus c

Derivation

  1. Initial program 17.6

    \[\left(-b\right) + \frac{\sqrt{{b}^{2} - \left(4 \cdot a\right) \cdot c}}{2} \cdot a\]
  2. Simplified17.6

    \[\leadsto \color{blue}{\frac{\sqrt{{b}^{2} - \left(4 \cdot a\right) \cdot c}}{2} \cdot a - b}\]
  3. Final simplification17.6

    \[\leadsto \frac{\sqrt{{b}^{2} - \left(4 \cdot a\right) \cdot c}}{2} \cdot a - b\]

Reproduce

herbie shell --seed 2020153 
(FPCore (b a c)
  :name "(+ (- b) (* (/ (sqrt (- (pow b 2) (* (* 4 a) c))) 2) a))"
  :precision binary64
  (+ (neg b) (* (/ (sqrt (- (pow b 2.0) (* (* 4.0 a) c))) 2.0) a)))