Average Error: 0.2 → 0.2
Time: 17.6s
Precision: 64
\[\left(x \cdot 3\right) \cdot y - z\]
\[\left(x \cdot 3\right) \cdot y - z\]
\left(x \cdot 3\right) \cdot y - z
\left(x \cdot 3\right) \cdot y - z
double f(double x, double y, double z) {
        double r580728 = x;
        double r580729 = 3.0;
        double r580730 = r580728 * r580729;
        double r580731 = y;
        double r580732 = r580730 * r580731;
        double r580733 = z;
        double r580734 = r580732 - r580733;
        return r580734;
}

double f(double x, double y, double z) {
        double r580735 = x;
        double r580736 = 3.0;
        double r580737 = r580735 * r580736;
        double r580738 = y;
        double r580739 = r580737 * r580738;
        double r580740 = z;
        double r580741 = r580739 - r580740;
        return r580741;
}

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

Target

Original0.2
Target0.2
Herbie0.2
\[x \cdot \left(3 \cdot y\right) - z\]

Derivation

  1. Initial program 0.2

    \[\left(x \cdot 3\right) \cdot y - z\]
  2. Final simplification0.2

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

Reproduce

herbie shell --seed 2019326 
(FPCore (x y z)
  :name "Diagrams.Solve.Polynomial:cubForm  from diagrams-solve-0.1, B"
  :precision binary64

  :herbie-target
  (- (* x (* 3 y)) z)

  (- (* (* x 3) y) z))