Average Error: 0.1 → 0.1
Time: 14.0s
Precision: 64
\[x + \left(y \cdot z\right) \cdot z\]
\[x + z \cdot \left(z \cdot y\right)\]
x + \left(y \cdot z\right) \cdot z
x + z \cdot \left(z \cdot y\right)
double f(double x, double y, double z) {
        double r771458 = x;
        double r771459 = y;
        double r771460 = z;
        double r771461 = r771459 * r771460;
        double r771462 = r771461 * r771460;
        double r771463 = r771458 + r771462;
        return r771463;
}

double f(double x, double y, double z) {
        double r771464 = x;
        double r771465 = z;
        double r771466 = y;
        double r771467 = r771465 * r771466;
        double r771468 = r771465 * r771467;
        double r771469 = r771464 + r771468;
        return r771469;
}

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.1

    \[x + \left(y \cdot z\right) \cdot z\]
  2. Final simplification0.1

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

Reproduce

herbie shell --seed 2019158 
(FPCore (x y z)
  :name "Statistics.Sample:robustSumVarWeighted from math-functions-0.1.5.2"
  (+ x (* (* y z) z)))