Average Error: 0 → 0
Time: 840.0ms
Precision: 64
\[\frac{x + y}{2}\]
\[\frac{y + x}{2}\]
\frac{x + y}{2}
\frac{y + x}{2}
double f(double x, double y) {
        double r10200559 = x;
        double r10200560 = y;
        double r10200561 = r10200559 + r10200560;
        double r10200562 = 2.0;
        double r10200563 = r10200561 / r10200562;
        return r10200563;
}

double f(double x, double y) {
        double r10200564 = y;
        double r10200565 = x;
        double r10200566 = r10200564 + r10200565;
        double r10200567 = 2.0;
        double r10200568 = r10200566 / r10200567;
        return r10200568;
}

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{y + x}{2}\]

Reproduce

herbie shell --seed 2019172 
(FPCore (x y)
  :name "Data.Colour.RGB:hslsv from colour-2.3.3, A"
  (/ (+ x y) 2.0))