Average Error: 2.8 → 0.0
Time: 9.2s
Precision: 64
\[x + \frac{y}{1.12837916709551256 \cdot e^{z} - x \cdot y}\]
\[\frac{1}{1.12837916709551256 \cdot \frac{e^{z}}{y} - x} + x\]
x + \frac{y}{1.12837916709551256 \cdot e^{z} - x \cdot y}
\frac{1}{1.12837916709551256 \cdot \frac{e^{z}}{y} - x} + x
double f(double x, double y, double z) {
        double r351800 = x;
        double r351801 = y;
        double r351802 = 1.1283791670955126;
        double r351803 = z;
        double r351804 = exp(r351803);
        double r351805 = r351802 * r351804;
        double r351806 = r351800 * r351801;
        double r351807 = r351805 - r351806;
        double r351808 = r351801 / r351807;
        double r351809 = r351800 + r351808;
        return r351809;
}

double f(double x, double y, double z) {
        double r351810 = 1.0;
        double r351811 = 1.1283791670955126;
        double r351812 = z;
        double r351813 = exp(r351812);
        double r351814 = y;
        double r351815 = r351813 / r351814;
        double r351816 = r351811 * r351815;
        double r351817 = x;
        double r351818 = r351816 - r351817;
        double r351819 = r351810 / r351818;
        double r351820 = r351819 + r351817;
        return r351820;
}

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.8
Target0.0
Herbie0.0
\[x + \frac{1}{\frac{1.12837916709551256}{y} \cdot e^{z} - x}\]

Derivation

  1. Initial program 2.8

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

    \[\leadsto x + \color{blue}{\frac{1}{\frac{1.12837916709551256 \cdot e^{z} - x \cdot y}{y}}}\]
  4. Using strategy rm
  5. Applied *-un-lft-identity2.8

    \[\leadsto x + \frac{1}{\frac{1.12837916709551256 \cdot e^{z} - x \cdot y}{\color{blue}{1 \cdot y}}}\]
  6. Applied *-un-lft-identity2.8

    \[\leadsto x + \frac{1}{\frac{\color{blue}{1 \cdot \left(1.12837916709551256 \cdot e^{z} - x \cdot y\right)}}{1 \cdot y}}\]
  7. Applied times-frac2.8

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

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

    \[\leadsto x + \frac{1}{1 \cdot \color{blue}{\left(1.12837916709551256 \cdot \frac{e^{z}}{y} - x\right)}}\]
  10. Final simplification0.0

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

Reproduce

herbie shell --seed 2020047 +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)))))