Average Error: 0.0 → 0.0
Time: 7.8s
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 r220792 = x;
        double r220793 = y;
        double r220794 = r220792 + r220793;
        double r220795 = r220792 / r220794;
        return r220795;
}

double f(double x, double y) {
        double r220796 = x;
        double r220797 = y;
        double r220798 = r220796 + r220797;
        double r220799 = r220796 / r220798;
        return r220799;
}

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