Average Error: 0.1 → 0.1
Time: 10.4s
Precision: 64
\[\frac{\left(x + y\right) - z}{t \cdot 2}\]
\[\frac{\left(x + y\right) - z}{t \cdot 2}\]
\frac{\left(x + y\right) - z}{t \cdot 2}
\frac{\left(x + y\right) - z}{t \cdot 2}
double f(double x, double y, double z, double t) {
        double r35105 = x;
        double r35106 = y;
        double r35107 = r35105 + r35106;
        double r35108 = z;
        double r35109 = r35107 - r35108;
        double r35110 = t;
        double r35111 = 2.0;
        double r35112 = r35110 * r35111;
        double r35113 = r35109 / r35112;
        return r35113;
}

double f(double x, double y, double z, double t) {
        double r35114 = x;
        double r35115 = y;
        double r35116 = r35114 + r35115;
        double r35117 = z;
        double r35118 = r35116 - r35117;
        double r35119 = t;
        double r35120 = 2.0;
        double r35121 = r35119 * r35120;
        double r35122 = r35118 / r35121;
        return r35122;
}

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. Using strategy rm
  5. Applied sub-div0.1

    \[\leadsto \color{blue}{\frac{\left(x + y\right) - z}{t \cdot 2}}\]
  6. Final simplification0.1

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

Reproduce

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