Average Error: 0 → 0
Time: 619.0ms
Precision: 64
\[\frac{x + y}{2}\]
\[\frac{x + y}{2}\]
\frac{x + y}{2}
\frac{x + y}{2}
double f(double x, double y) {
        double r152616 = x;
        double r152617 = y;
        double r152618 = r152616 + r152617;
        double r152619 = 2.0;
        double r152620 = r152618 / r152619;
        return r152620;
}

double f(double x, double y) {
        double r152621 = x;
        double r152622 = y;
        double r152623 = r152621 + r152622;
        double r152624 = 2.0;
        double r152625 = r152623 / r152624;
        return r152625;
}

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

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

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

Reproduce

herbie shell --seed 2019323 +o rules:numerics
(FPCore (x y)
  :name "Data.Colour.RGB:hslsv from colour-2.3.3, A"
  :precision binary64
  (/ (+ x y) 2))