Average Error: 13.7 → 13.7
Time: 52.5s
Precision: 64
Internal Precision: 384
\[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 - \frac{\frac{\frac{\frac{1}{\left|x\right| \cdot 0.3275911 + 1} \cdot \left(-1.453152027 + \frac{1.061405429}{\left|x\right| \cdot 0.3275911 + 1}\right) + 1.421413741}{\left(\left|x\right| \cdot 0.3275911 + 1\right) \cdot \left(\left|x\right| \cdot 0.3275911 + 1\right)} + \left(\frac{\frac{-0.284496736}{\sqrt[3]{\left|x\right| \cdot 0.3275911 + 1} \cdot \sqrt[3]{\left|x\right| \cdot 0.3275911 + 1}}}{\sqrt[3]{\left|x\right| \cdot 0.3275911 + 1}} + 0.254829592\right)}{e^{\left|x\right| \cdot \left|x\right|}}}{\left|x\right| \cdot 0.3275911 + 1}\]

Error

Bits error versus x

Derivation

  1. Initial program 13.7

    \[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 add-cube-cbrt13.7

    \[\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 \left(-0.284496736 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(1.421413741 + \color{blue}{\left(\left(\sqrt[3]{\frac{1}{1 + 0.3275911 \cdot \left|x\right|}} \cdot \sqrt[3]{\frac{1}{1 + 0.3275911 \cdot \left|x\right|}}\right) \cdot \sqrt[3]{\frac{1}{1 + 0.3275911 \cdot \left|x\right|}}\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|}\]
  4. Taylor expanded around 0 13.7

    \[\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 \left(-0.284496736 + \frac{1}{1 + 0.3275911 \cdot \left|x\right|} \cdot \left(1.421413741 + \left(\left(\color{blue}{{\left(\frac{1}{0.3275911 \cdot \left|x\right| + 1}\right)}^{\frac{1}{3}}} \cdot \sqrt[3]{\frac{1}{1 + 0.3275911 \cdot \left|x\right|}}\right) \cdot \sqrt[3]{\frac{1}{1 + 0.3275911 \cdot \left|x\right|}}\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|}\]
  5. Applied simplify13.7

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

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

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

Runtime

Time bar (total: 52.5s)Debug log

herbie shell --seed '#(2151728608 3767143998 4065594768 704903143 4284770345 1704475780)' 
(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)))))))