Average Error: 0 → 0
Time: 324.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 r338099 = x;
        double r338100 = y;
        double r338101 = r338099 + r338100;
        double r338102 = 2.0;
        double r338103 = r338101 / r338102;
        return r338103;
}

double f(double x, double y) {
        double r338104 = x;
        double r338105 = y;
        double r338106 = r338104 + r338105;
        double r338107 = 2.0;
        double r338108 = r338106 / r338107;
        return r338108;
}

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