Average Error: 23.0 → 23.0
Time: 21.4s
Precision: 64
\[\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}\]
\[\frac{z \cdot \left(t - a\right) + x \cdot y}{\left(b - y\right) \cdot z + y}\]
\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}
\frac{z \cdot \left(t - a\right) + x \cdot y}{\left(b - y\right) \cdot z + y}
double f(double x, double y, double z, double t, double a, double b) {
        double r34381211 = x;
        double r34381212 = y;
        double r34381213 = r34381211 * r34381212;
        double r34381214 = z;
        double r34381215 = t;
        double r34381216 = a;
        double r34381217 = r34381215 - r34381216;
        double r34381218 = r34381214 * r34381217;
        double r34381219 = r34381213 + r34381218;
        double r34381220 = b;
        double r34381221 = r34381220 - r34381212;
        double r34381222 = r34381214 * r34381221;
        double r34381223 = r34381212 + r34381222;
        double r34381224 = r34381219 / r34381223;
        return r34381224;
}

double f(double x, double y, double z, double t, double a, double b) {
        double r34381225 = z;
        double r34381226 = t;
        double r34381227 = a;
        double r34381228 = r34381226 - r34381227;
        double r34381229 = r34381225 * r34381228;
        double r34381230 = x;
        double r34381231 = y;
        double r34381232 = r34381230 * r34381231;
        double r34381233 = r34381229 + r34381232;
        double r34381234 = b;
        double r34381235 = r34381234 - r34381231;
        double r34381236 = r34381235 * r34381225;
        double r34381237 = r34381236 + r34381231;
        double r34381238 = r34381233 / r34381237;
        return r34381238;
}

Error

Bits error versus x

Bits error versus y

Bits error versus z

Bits error versus t

Bits error versus a

Bits error versus b

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original23.0
Target17.7
Herbie23.0
\[\frac{z \cdot t + y \cdot x}{y + z \cdot \left(b - y\right)} - \frac{a}{\left(b - y\right) + \frac{y}{z}}\]

Derivation

  1. Initial program 23.0

    \[\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}\]
  2. Final simplification23.0

    \[\leadsto \frac{z \cdot \left(t - a\right) + x \cdot y}{\left(b - y\right) \cdot z + y}\]

Reproduce

herbie shell --seed 2019192 
(FPCore (x y z t a b)
  :name "Development.Shake.Progress:decay from shake-0.15.5"

  :herbie-target
  (- (/ (+ (* z t) (* y x)) (+ y (* z (- b y)))) (/ a (+ (- b y) (/ y z))))

  (/ (+ (* x y) (* z (- t a))) (+ y (* z (- b y)))))