Average Error: 9.8 → 0.2
Time: 11.1s
Precision: 64
\[\frac{x}{y \cdot y}\]
\[\frac{\frac{x}{y}}{y}\]
\frac{x}{y \cdot y}
\frac{\frac{x}{y}}{y}
double f(double x, double y) {
        double r19340939 = x;
        double r19340940 = y;
        double r19340941 = r19340940 * r19340940;
        double r19340942 = r19340939 / r19340941;
        return r19340942;
}

double f(double x, double y) {
        double r19340943 = x;
        double r19340944 = y;
        double r19340945 = r19340943 / r19340944;
        double r19340946 = r19340945 / r19340944;
        return r19340946;
}

Error

Bits error versus x

Bits error versus y

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original9.8
Target0.2
Herbie0.2
\[\frac{\frac{x}{y}}{y}\]

Derivation

  1. Initial program 9.8

    \[\frac{x}{y \cdot y}\]
  2. Using strategy rm
  3. Applied associate-/r*0.2

    \[\leadsto \color{blue}{\frac{\frac{x}{y}}{y}}\]
  4. Final simplification0.2

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

Reproduce

herbie shell --seed 2019163 
(FPCore (x y)
  :name "Physics.ForceLayout:coulombForce from force-layout-0.4.0.2"

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

  (/ x (* y y)))