Average Error: 0 → 0
Time: 701.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 r11458449 = x;
        double r11458450 = y;
        double r11458451 = r11458449 + r11458450;
        double r11458452 = 2.0;
        double r11458453 = r11458451 / r11458452;
        return r11458453;
}

double f(double x, double y) {
        double r11458454 = y;
        double r11458455 = x;
        double r11458456 = r11458454 + r11458455;
        double r11458457 = 2.0;
        double r11458458 = r11458456 / r11458457;
        return r11458458;
}

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