Average Error: 0 → 0
Time: 664.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 r167948 = x;
        double r167949 = y;
        double r167950 = r167948 + r167949;
        double r167951 = 2.0;
        double r167952 = r167950 / r167951;
        return r167952;
}

double f(double x, double y) {
        double r167953 = x;
        double r167954 = y;
        double r167955 = r167953 + r167954;
        double r167956 = 2.0;
        double r167957 = r167955 / r167956;
        return r167957;
}

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