Average Error: 0.0 → 0.0
Time: 3.3s
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 r269512 = x;
        double r269513 = y;
        double r269514 = r269512 + r269513;
        double r269515 = r269512 / r269514;
        return r269515;
}

double f(double x, double y) {
        double r269516 = x;
        double r269517 = y;
        double r269518 = r269516 + r269517;
        double r269519 = r269516 / r269518;
        return r269519;
}

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 2020035 +o rules:numerics
(FPCore (x y)
  :name "AI.Clustering.Hierarchical.Internal:average from clustering-0.2.1, A"
  :precision binary64
  (/ x (+ x y)))