Average Error: 28.3 → 0.5
Time: 5.4m
Precision: 64
Internal Precision: 576
\[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}{2 \cdot a}\]
\[\frac{\frac{\left(c \cdot a\right) \cdot \left(-4\right)}{\sqrt{\sqrt[3]{{\left((\left(-c\right) \cdot \left(a \cdot 4\right) + \left(b \cdot b\right))_*\right)}^{3}}} + b}}{2 \cdot a}\]

Error

Bits error versus a

Bits error versus b

Bits error versus c

Derivation

  1. Initial program 28.3

    \[\frac{\left(-b\right) + \sqrt{b \cdot b - \left(4 \cdot a\right) \cdot c}}{2 \cdot a}\]
  2. Applied simplify28.3

    \[\leadsto \color{blue}{\frac{\sqrt{(\left(4 \cdot a\right) \cdot \left(-c\right) + \left(b \cdot b\right))_*} - b}{2 \cdot a}}\]
  3. Using strategy rm
  4. Applied flip--28.3

    \[\leadsto \frac{\color{blue}{\frac{\sqrt{(\left(4 \cdot a\right) \cdot \left(-c\right) + \left(b \cdot b\right))_*} \cdot \sqrt{(\left(4 \cdot a\right) \cdot \left(-c\right) + \left(b \cdot b\right))_*} - b \cdot b}{\sqrt{(\left(4 \cdot a\right) \cdot \left(-c\right) + \left(b \cdot b\right))_*} + b}}}{2 \cdot a}\]
  5. Applied simplify0.4

    \[\leadsto \frac{\frac{\color{blue}{\left(c \cdot a\right) \cdot \left(-4\right)}}{\sqrt{(\left(4 \cdot a\right) \cdot \left(-c\right) + \left(b \cdot b\right))_*} + b}}{2 \cdot a}\]
  6. Using strategy rm
  7. Applied add-cbrt-cube0.5

    \[\leadsto \frac{\frac{\left(c \cdot a\right) \cdot \left(-4\right)}{\sqrt{\color{blue}{\sqrt[3]{\left((\left(4 \cdot a\right) \cdot \left(-c\right) + \left(b \cdot b\right))_* \cdot (\left(4 \cdot a\right) \cdot \left(-c\right) + \left(b \cdot b\right))_*\right) \cdot (\left(4 \cdot a\right) \cdot \left(-c\right) + \left(b \cdot b\right))_*}}} + b}}{2 \cdot a}\]
  8. Applied simplify0.5

    \[\leadsto \frac{\frac{\left(c \cdot a\right) \cdot \left(-4\right)}{\sqrt{\sqrt[3]{\color{blue}{{\left((\left(-c\right) \cdot \left(a \cdot 4\right) + \left(b \cdot b\right))_*\right)}^{3}}}} + b}}{2 \cdot a}\]

Runtime

Time bar (total: 5.4m)Debug logProfile

herbie shell --seed '#(1072107073 2127697367 3936270018 2300570620 2134894798 4023771849)' +o rules:numerics
(FPCore (a b c)
  :name "Quadratic roots, narrow range"
  :pre (and (< 1.0536712127723509e-08 a 94906265.62425156) (< 1.0536712127723509e-08 b 94906265.62425156) (< 1.0536712127723509e-08 c 94906265.62425156))
  (/ (+ (- b) (sqrt (- (* b b) (* (* 4 a) c)))) (* 2 a)))