Average Error: 0.1 → 0.1
Time: 1.8s
Precision: 64
\[\frac{\left(x + y\right) - z}{t \cdot 2}\]
\[\frac{x + y}{t \cdot 2} - \frac{z}{t \cdot 2}\]
\frac{\left(x + y\right) - z}{t \cdot 2}
\frac{x + y}{t \cdot 2} - \frac{z}{t \cdot 2}
double f(double x, double y, double z, double t) {
        double r28063 = x;
        double r28064 = y;
        double r28065 = r28063 + r28064;
        double r28066 = z;
        double r28067 = r28065 - r28066;
        double r28068 = t;
        double r28069 = 2.0;
        double r28070 = r28068 * r28069;
        double r28071 = r28067 / r28070;
        return r28071;
}

double f(double x, double y, double z, double t) {
        double r28072 = x;
        double r28073 = y;
        double r28074 = r28072 + r28073;
        double r28075 = t;
        double r28076 = 2.0;
        double r28077 = r28075 * r28076;
        double r28078 = r28074 / r28077;
        double r28079 = z;
        double r28080 = r28079 / r28077;
        double r28081 = r28078 - r28080;
        return r28081;
}

Error

Bits error versus x

Bits error versus y

Bits error versus z

Bits error versus t

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.1

    \[\frac{\left(x + y\right) - z}{t \cdot 2}\]
  2. Using strategy rm
  3. Applied div-sub0.1

    \[\leadsto \color{blue}{\frac{x + y}{t \cdot 2} - \frac{z}{t \cdot 2}}\]
  4. Final simplification0.1

    \[\leadsto \frac{x + y}{t \cdot 2} - \frac{z}{t \cdot 2}\]

Reproduce

herbie shell --seed 2020056 
(FPCore (x y z t)
  :name "Optimisation.CirclePacking:place from circle-packing-0.1.0.4, B"
  :precision binary64
  (/ (- (+ x y) z) (* t 2)))