Average Error: 0.0 → 0.0
Time: 47.7s
Precision: 64
\[\left(x + y\right) \cdot \left(1.0 - z\right)\]
\[\left(x + y\right) \cdot \left(-z\right) + \left(x + y\right) \cdot 1.0\]
\left(x + y\right) \cdot \left(1.0 - z\right)
\left(x + y\right) \cdot \left(-z\right) + \left(x + y\right) \cdot 1.0
double f(double x, double y, double z) {
        double r2302545 = x;
        double r2302546 = y;
        double r2302547 = r2302545 + r2302546;
        double r2302548 = 1.0;
        double r2302549 = z;
        double r2302550 = r2302548 - r2302549;
        double r2302551 = r2302547 * r2302550;
        return r2302551;
}

double f(double x, double y, double z) {
        double r2302552 = x;
        double r2302553 = y;
        double r2302554 = r2302552 + r2302553;
        double r2302555 = z;
        double r2302556 = -r2302555;
        double r2302557 = r2302554 * r2302556;
        double r2302558 = 1.0;
        double r2302559 = r2302554 * r2302558;
        double r2302560 = r2302557 + r2302559;
        return r2302560;
}

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

Derivation

  1. Initial program 0.0

    \[\left(x + y\right) \cdot \left(1.0 - z\right)\]
  2. Using strategy rm
  3. Applied sub-neg0.0

    \[\leadsto \left(x + y\right) \cdot \color{blue}{\left(1.0 + \left(-z\right)\right)}\]
  4. Applied distribute-rgt-in0.0

    \[\leadsto \color{blue}{1.0 \cdot \left(x + y\right) + \left(-z\right) \cdot \left(x + y\right)}\]
  5. Final simplification0.0

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

Reproduce

herbie shell --seed 2019165 
(FPCore (x y z)
  :name "Optimisation.CirclePacking:place from circle-packing-0.1.0.4, H"
  (* (+ x y) (- 1.0 z)))