Average Error: 22.9 → 22.9
Time: 18.2s
Precision: 64
\[\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}\]
\[\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}\]
\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}
\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}
double f(double x, double y, double z, double t, double a, double b) {
        double r498369 = x;
        double r498370 = y;
        double r498371 = r498369 * r498370;
        double r498372 = z;
        double r498373 = t;
        double r498374 = a;
        double r498375 = r498373 - r498374;
        double r498376 = r498372 * r498375;
        double r498377 = r498371 + r498376;
        double r498378 = b;
        double r498379 = r498378 - r498370;
        double r498380 = r498372 * r498379;
        double r498381 = r498370 + r498380;
        double r498382 = r498377 / r498381;
        return r498382;
}

double f(double x, double y, double z, double t, double a, double b) {
        double r498383 = x;
        double r498384 = y;
        double r498385 = r498383 * r498384;
        double r498386 = z;
        double r498387 = t;
        double r498388 = a;
        double r498389 = r498387 - r498388;
        double r498390 = r498386 * r498389;
        double r498391 = r498385 + r498390;
        double r498392 = b;
        double r498393 = r498392 - r498384;
        double r498394 = r498386 * r498393;
        double r498395 = r498384 + r498394;
        double r498396 = r498391 / r498395;
        return r498396;
}

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

Original22.9
Target18.0
Herbie22.9
\[\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 22.9

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

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

Reproduce

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

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

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