Average Error: 0 → 0
Time: 327.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 r294459 = x;
        double r294460 = y;
        double r294461 = r294459 + r294460;
        double r294462 = 2.0;
        double r294463 = r294461 / r294462;
        return r294463;
}

double f(double x, double y) {
        double r294464 = x;
        double r294465 = y;
        double r294466 = r294464 + r294465;
        double r294467 = 2.0;
        double r294468 = r294466 / r294467;
        return r294468;
}

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 2020042 +o rules:numerics
(FPCore (x y)
  :name "Data.Colour.RGB:hslsv from colour-2.3.3, A"
  :precision binary64
  (/ (+ x y) 2))