Average Error: 0.3 → 0.3
Time: 21.9s
Precision: 64
\[\left(x \cdot 27.0\right) \cdot y\]
\[\left(y \cdot 27.0\right) \cdot x\]
\left(x \cdot 27.0\right) \cdot y
\left(y \cdot 27.0\right) \cdot x
double f(double x, double y) {
        double r11730017 = x;
        double r11730018 = 27.0;
        double r11730019 = r11730017 * r11730018;
        double r11730020 = y;
        double r11730021 = r11730019 * r11730020;
        return r11730021;
}

double f(double x, double y) {
        double r11730022 = y;
        double r11730023 = 27.0;
        double r11730024 = r11730022 * r11730023;
        double r11730025 = x;
        double r11730026 = r11730024 * r11730025;
        return r11730026;
}

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.0\right) \cdot y\]
  2. Using strategy rm
  3. Applied associate-*l*0.3

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

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

Reproduce

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