Average Error: 0.0 → 0.0
Time: 10.2s
Precision: 64
\[\frac{x}{x + y}\]
\[\frac{x}{x + y}\]
\frac{x}{x + y}
\frac{x}{x + y}
double f(double x, double y) {
        double r225458 = x;
        double r225459 = y;
        double r225460 = r225458 + r225459;
        double r225461 = r225458 / r225460;
        return r225461;
}

double f(double x, double y) {
        double r225462 = x;
        double r225463 = y;
        double r225464 = r225462 + r225463;
        double r225465 = r225462 / r225464;
        return r225465;
}

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.0

    \[\frac{x}{x + y}\]
  2. Final simplification0.0

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

Reproduce

herbie shell --seed 2020047 +o rules:numerics
(FPCore (x y)
  :name "AI.Clustering.Hierarchical.Internal:average from clustering-0.2.1, A"
  :precision binary64
  (/ x (+ x y)))