Average Error: 0.1 → 0.1
Time: 1.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 r716904 = x;
        double r716905 = 3.0;
        double r716906 = r716904 * r716905;
        double r716907 = y;
        double r716908 = r716906 * r716907;
        double r716909 = z;
        double r716910 = r716908 - r716909;
        return r716910;
}

double f(double x, double y, double z) {
        double r716911 = x;
        double r716912 = 3.0;
        double r716913 = r716911 * r716912;
        double r716914 = y;
        double r716915 = r716913 * r716914;
        double r716916 = z;
        double r716917 = r716915 - r716916;
        return r716917;
}

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.1
Target0.1
Herbie0.1
\[x \cdot \left(3 \cdot y\right) - z\]

Derivation

  1. Initial program 0.1

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

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

Reproduce

herbie shell --seed 2020047 
(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))