Average Error: 0 → 0
Time: 628.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 r149229 = x;
        double r149230 = y;
        double r149231 = r149229 + r149230;
        double r149232 = 2.0;
        double r149233 = r149231 / r149232;
        return r149233;
}

double f(double x, double y) {
        double r149234 = x;
        double r149235 = y;
        double r149236 = r149234 + r149235;
        double r149237 = 2.0;
        double r149238 = r149236 / r149237;
        return r149238;
}

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))