Average Error: 0.3 → 0.3
Time: 23.3s
Precision: 64
\[\left(x \cdot 27\right) \cdot y\]
\[x \cdot \left(y \cdot 27\right)\]
\left(x \cdot 27\right) \cdot y
x \cdot \left(y \cdot 27\right)
double f(double x, double y) {
        double r216801 = x;
        double r216802 = 27.0;
        double r216803 = r216801 * r216802;
        double r216804 = y;
        double r216805 = r216803 * r216804;
        return r216805;
}

double f(double x, double y) {
        double r216806 = x;
        double r216807 = y;
        double r216808 = 27.0;
        double r216809 = r216807 * r216808;
        double r216810 = r216806 * r216809;
        return r216810;
}

Error

Bits error versus x

Bits error versus y

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.3

    \[\left(x \cdot 27\right) \cdot y\]
  2. Using strategy rm
  3. Applied associate-*l*0.3

    \[\leadsto \color{blue}{x \cdot \left(27 \cdot y\right)}\]
  4. Simplified0.3

    \[\leadsto x \cdot \color{blue}{\left(y \cdot 27\right)}\]
  5. Final simplification0.3

    \[\leadsto x \cdot \left(y \cdot 27\right)\]

Reproduce

herbie shell --seed 2020043 +o rules:numerics
(FPCore (x y)
  :name "Diagrams.Solve.Polynomial:cubForm  from diagrams-solve-0.1, F"
  :precision binary64
  (* (* x 27) y))