Average Error: 2.9 → 0.1
Time: 14.1s
Precision: 64
\[x + \frac{y}{1.12837916709551256 \cdot e^{z} - x \cdot y}\]
\[x + \frac{\sqrt{1}}{1.12837916709551256 \cdot \frac{e^{z}}{y} - x}\]
x + \frac{y}{1.12837916709551256 \cdot e^{z} - x \cdot y}
x + \frac{\sqrt{1}}{1.12837916709551256 \cdot \frac{e^{z}}{y} - x}
double f(double x, double y, double z) {
        double r515560 = x;
        double r515561 = y;
        double r515562 = 1.1283791670955126;
        double r515563 = z;
        double r515564 = exp(r515563);
        double r515565 = r515562 * r515564;
        double r515566 = r515560 * r515561;
        double r515567 = r515565 - r515566;
        double r515568 = r515561 / r515567;
        double r515569 = r515560 + r515568;
        return r515569;
}

double f(double x, double y, double z) {
        double r515570 = x;
        double r515571 = 1.0;
        double r515572 = sqrt(r515571);
        double r515573 = 1.1283791670955126;
        double r515574 = z;
        double r515575 = exp(r515574);
        double r515576 = y;
        double r515577 = r515575 / r515576;
        double r515578 = r515573 * r515577;
        double r515579 = r515578 - r515570;
        double r515580 = r515572 / r515579;
        double r515581 = r515570 + r515580;
        return r515581;
}

Error

Bits error versus x

Bits error versus y

Bits error versus z

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original2.9
Target0.0
Herbie0.1
\[x + \frac{1}{\frac{1.12837916709551256}{y} \cdot e^{z} - x}\]

Derivation

  1. Initial program 2.9

    \[x + \frac{y}{1.12837916709551256 \cdot e^{z} - x \cdot y}\]
  2. Using strategy rm
  3. Applied clear-num2.9

    \[\leadsto x + \color{blue}{\frac{1}{\frac{1.12837916709551256 \cdot e^{z} - x \cdot y}{y}}}\]
  4. Using strategy rm
  5. Applied add-sqr-sqrt2.9

    \[\leadsto x + \frac{\color{blue}{\sqrt{1} \cdot \sqrt{1}}}{\frac{1.12837916709551256 \cdot e^{z} - x \cdot y}{y}}\]
  6. Applied associate-/l*2.9

    \[\leadsto x + \color{blue}{\frac{\sqrt{1}}{\frac{\frac{1.12837916709551256 \cdot e^{z} - x \cdot y}{y}}{\sqrt{1}}}}\]
  7. Simplified0.1

    \[\leadsto x + \frac{\sqrt{1}}{\color{blue}{1.12837916709551256 \cdot \frac{e^{z}}{y} - x}}\]
  8. Final simplification0.1

    \[\leadsto x + \frac{\sqrt{1}}{1.12837916709551256 \cdot \frac{e^{z}}{y} - x}\]

Reproduce

herbie shell --seed 2020042 +o rules:numerics
(FPCore (x y z)
  :name "Numeric.SpecFunctions:invErfc from math-functions-0.1.5.2, A"
  :precision binary64

  :herbie-target
  (+ x (/ 1 (- (* (/ 1.1283791670955126 y) (exp z)) x)))

  (+ x (/ y (- (* 1.1283791670955126 (exp z)) (* x y)))))