Average Error: 0.2 → 0.2
Time: 19.2s
Precision: 64
\[\frac{x}{y \cdot 3}\]
\[\frac{x}{y \cdot 3}\]
\frac{x}{y \cdot 3}
\frac{x}{y \cdot 3}
double f(double x, double y) {
        double r549236 = x;
        double r549237 = y;
        double r549238 = 3.0;
        double r549239 = r549237 * r549238;
        double r549240 = r549236 / r549239;
        return r549240;
}

double f(double x, double y) {
        double r549241 = x;
        double r549242 = y;
        double r549243 = 3.0;
        double r549244 = r549242 * r549243;
        double r549245 = r549241 / r549244;
        return r549245;
}

Error

Bits error versus x

Bits error versus y

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original0.2
Target0.2
Herbie0.2
\[\frac{\frac{x}{y}}{3}\]

Derivation

  1. Initial program 0.2

    \[\frac{x}{y \cdot 3}\]
  2. Final simplification0.2

    \[\leadsto \frac{x}{y \cdot 3}\]

Reproduce

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

  :herbie-target
  (/ (/ x y) 3)

  (/ x (* y 3)))