Average Error: 0.1 → 0.1
Time: 19.0s
Precision: 64
\[\left(\left(x - \left(y + 0.5\right) \cdot \log y\right) + y\right) - z\]
\[\left(\left(x - \left(y + 0.5\right) \cdot \log y\right) + y\right) - z\]
\left(\left(x - \left(y + 0.5\right) \cdot \log y\right) + y\right) - z
\left(\left(x - \left(y + 0.5\right) \cdot \log y\right) + y\right) - z
double f(double x, double y, double z) {
        double r343778 = x;
        double r343779 = y;
        double r343780 = 0.5;
        double r343781 = r343779 + r343780;
        double r343782 = log(r343779);
        double r343783 = r343781 * r343782;
        double r343784 = r343778 - r343783;
        double r343785 = r343784 + r343779;
        double r343786 = z;
        double r343787 = r343785 - r343786;
        return r343787;
}

double f(double x, double y, double z) {
        double r343788 = x;
        double r343789 = y;
        double r343790 = 0.5;
        double r343791 = r343789 + r343790;
        double r343792 = log(r343789);
        double r343793 = r343791 * r343792;
        double r343794 = r343788 - r343793;
        double r343795 = r343794 + r343789;
        double r343796 = z;
        double r343797 = r343795 - r343796;
        return r343797;
}

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

Original0.1
Target0.1
Herbie0.1
\[\left(\left(y + x\right) - z\right) - \left(y + 0.5\right) \cdot \log y\]

Derivation

  1. Initial program 0.1

    \[\left(\left(x - \left(y + 0.5\right) \cdot \log y\right) + y\right) - z\]
  2. Final simplification0.1

    \[\leadsto \left(\left(x - \left(y + 0.5\right) \cdot \log y\right) + y\right) - z\]

Reproduce

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

  :herbie-target
  (- (- (+ y x) z) (* (+ y 0.5) (log y)))

  (- (+ (- x (* (+ y 0.5) (log y))) y) z))