Average Error: 13.9 → 13.9
Time: 6.6m
Precision: 64
Internal Precision: 576
\[1 - \left(\frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(0.254829592 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(-0.284496736 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(1.421413741 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(-1.453152027 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot 1.061405429\right)\right)\right)\right)\right) \cdot e^{-\left|x\right| \cdot \left|x\right|}\]
\[1 - e^{\left(-\left|x\right|\right) \cdot \left|x\right|} \cdot \left(\frac{1}{1 + \left|x\right| \cdot 0.3275911} \cdot \left(0.254829592 + \frac{\frac{1}{1 + \left|x\right| \cdot 0.3275911} \cdot \left(-0.284496736 \cdot -0.284496736 - \left(\frac{1}{1 + \left|x\right| \cdot 0.3275911} \cdot \left(\left(1.061405429 \cdot \frac{1}{1 + \left|x\right| \cdot 0.3275911} + -1.453152027\right) \cdot \frac{1}{1 + \left|x\right| \cdot 0.3275911} + 1.421413741\right)\right) \cdot \left(\frac{1}{1 + \left|x\right| \cdot 0.3275911} \cdot \left(\left(1.061405429 \cdot \frac{1}{1 + \left|x\right| \cdot 0.3275911} + -1.453152027\right) \cdot \frac{1}{1 + \left|x\right| \cdot 0.3275911} + 1.421413741\right)\right)\right)}{-0.284496736 - \sqrt[3]{\left(\left(\frac{1}{1 + \left|x\right| \cdot 0.3275911} \cdot \left(\left(1.061405429 \cdot \frac{1}{1 + \left|x\right| \cdot 0.3275911} + -1.453152027\right) \cdot \frac{1}{1 + \left|x\right| \cdot 0.3275911} + 1.421413741\right)\right) \cdot \left(\frac{1}{1 + \left|x\right| \cdot 0.3275911} \cdot \left(\left(1.061405429 \cdot \frac{1}{1 + \left|x\right| \cdot 0.3275911} + -1.453152027\right) \cdot \frac{1}{1 + \left|x\right| \cdot 0.3275911} + 1.421413741\right)\right)\right) \cdot \left(\frac{1}{1 + \left|x\right| \cdot 0.3275911} \cdot \left(\left(1.061405429 \cdot \frac{1}{1 + \left|x\right| \cdot 0.3275911} + -1.453152027\right) \cdot \frac{1}{1 + \left|x\right| \cdot 0.3275911} + 1.421413741\right)\right)}}\right)\right)\]

Error

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 13.9

    \[1 - \left(\frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(0.254829592 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(-0.284496736 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(1.421413741 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(-1.453152027 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot 1.061405429\right)\right)\right)\right)\right) \cdot e^{-\left|x\right| \cdot \left|x\right|}\]
  2. Using strategy rm
  3. Applied flip-+13.9

    \[\leadsto 1 - \left(\frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(0.254829592 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \color{blue}{\frac{-0.284496736 \cdot -0.284496736 - \left(\frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(1.421413741 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(-1.453152027 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot 1.061405429\right)\right)\right) \cdot \left(\frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(1.421413741 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(-1.453152027 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot 1.061405429\right)\right)\right)}{-0.284496736 - \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(1.421413741 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(-1.453152027 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot 1.061405429\right)\right)}}\right)\right) \cdot e^{-\left|x\right| \cdot \left|x\right|}\]
  4. Applied associate-*r/13.9

    \[\leadsto 1 - \left(\frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(0.254829592 + \color{blue}{\frac{\frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(-0.284496736 \cdot -0.284496736 - \left(\frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(1.421413741 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(-1.453152027 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot 1.061405429\right)\right)\right) \cdot \left(\frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(1.421413741 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(-1.453152027 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot 1.061405429\right)\right)\right)\right)}{-0.284496736 - \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(1.421413741 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(-1.453152027 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot 1.061405429\right)\right)}}\right)\right) \cdot e^{-\left|x\right| \cdot \left|x\right|}\]
  5. Using strategy rm
  6. Applied add-cbrt-cube13.9

    \[\leadsto 1 - \left(\frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(0.254829592 + \frac{\frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(-0.284496736 \cdot -0.284496736 - \left(\frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(1.421413741 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(-1.453152027 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot 1.061405429\right)\right)\right) \cdot \left(\frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(1.421413741 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(-1.453152027 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot 1.061405429\right)\right)\right)\right)}{-0.284496736 - \color{blue}{\sqrt[3]{\left(\left(\frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(1.421413741 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(-1.453152027 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot 1.061405429\right)\right)\right) \cdot \left(\frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(1.421413741 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(-1.453152027 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot 1.061405429\right)\right)\right)\right) \cdot \left(\frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(1.421413741 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(-1.453152027 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot 1.061405429\right)\right)\right)}}}\right)\right) \cdot e^{-\left|x\right| \cdot \left|x\right|}\]
  7. Final simplification13.9

    \[\leadsto 1 - e^{\left(-\left|x\right|\right) \cdot \left|x\right|} \cdot \left(\frac{1}{1 + \left|x\right| \cdot 0.3275911} \cdot \left(0.254829592 + \frac{\frac{1}{1 + \left|x\right| \cdot 0.3275911} \cdot \left(-0.284496736 \cdot -0.284496736 - \left(\frac{1}{1 + \left|x\right| \cdot 0.3275911} \cdot \left(\left(1.061405429 \cdot \frac{1}{1 + \left|x\right| \cdot 0.3275911} + -1.453152027\right) \cdot \frac{1}{1 + \left|x\right| \cdot 0.3275911} + 1.421413741\right)\right) \cdot \left(\frac{1}{1 + \left|x\right| \cdot 0.3275911} \cdot \left(\left(1.061405429 \cdot \frac{1}{1 + \left|x\right| \cdot 0.3275911} + -1.453152027\right) \cdot \frac{1}{1 + \left|x\right| \cdot 0.3275911} + 1.421413741\right)\right)\right)}{-0.284496736 - \sqrt[3]{\left(\left(\frac{1}{1 + \left|x\right| \cdot 0.3275911} \cdot \left(\left(1.061405429 \cdot \frac{1}{1 + \left|x\right| \cdot 0.3275911} + -1.453152027\right) \cdot \frac{1}{1 + \left|x\right| \cdot 0.3275911} + 1.421413741\right)\right) \cdot \left(\frac{1}{1 + \left|x\right| \cdot 0.3275911} \cdot \left(\left(1.061405429 \cdot \frac{1}{1 + \left|x\right| \cdot 0.3275911} + -1.453152027\right) \cdot \frac{1}{1 + \left|x\right| \cdot 0.3275911} + 1.421413741\right)\right)\right) \cdot \left(\frac{1}{1 + \left|x\right| \cdot 0.3275911} \cdot \left(\left(1.061405429 \cdot \frac{1}{1 + \left|x\right| \cdot 0.3275911} + -1.453152027\right) \cdot \frac{1}{1 + \left|x\right| \cdot 0.3275911} + 1.421413741\right)\right)}}\right)\right)\]

Runtime

Time bar (total: 6.6m)Debug logProfile

herbie shell --seed 2018250 
(FPCore (x)
  :name "Jmat.Real.erf"
  (- 1 (* (* (/ 1 (+ 1 (* 0.3275911 (fabs x)))) (+ 0.254829592 (* (/ 1 (+ 1 (* 0.3275911 (fabs x)))) (+ -0.284496736 (* (/ 1 (+ 1 (* 0.3275911 (fabs x)))) (+ 1.421413741 (* (/ 1 (+ 1 (* 0.3275911 (fabs x)))) (+ -1.453152027 (* (/ 1 (+ 1 (* 0.3275911 (fabs x)))) 1.061405429))))))))) (exp (- (* (fabs x) (fabs x)))))))