Average Error: 0.0 → 0.0
Time: 15.9s
Precision: 64
\[\frac{x - y}{2 - \left(x + y\right)}\]
\[\frac{x - y}{2 - \left(y + x\right)}\]
\frac{x - y}{2 - \left(x + y\right)}
\frac{x - y}{2 - \left(y + x\right)}
double f(double x, double y) {
        double r580449 = x;
        double r580450 = y;
        double r580451 = r580449 - r580450;
        double r580452 = 2.0;
        double r580453 = r580449 + r580450;
        double r580454 = r580452 - r580453;
        double r580455 = r580451 / r580454;
        return r580455;
}

double f(double x, double y) {
        double r580456 = x;
        double r580457 = y;
        double r580458 = r580456 - r580457;
        double r580459 = 2.0;
        double r580460 = r580457 + r580456;
        double r580461 = r580459 - r580460;
        double r580462 = r580458 / r580461;
        return r580462;
}

Error

Bits error versus x

Bits error versus y

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original0.0
Target0.0
Herbie0.0
\[\frac{x}{2 - \left(x + y\right)} - \frac{y}{2 - \left(x + y\right)}\]

Derivation

  1. Initial program 0.0

    \[\frac{x - y}{2 - \left(x + y\right)}\]
  2. Final simplification0.0

    \[\leadsto \frac{x - y}{2 - \left(y + x\right)}\]

Reproduce

herbie shell --seed 2019195 
(FPCore (x y)
  :name "Data.Colour.RGB:hslsv from colour-2.3.3, C"

  :herbie-target
  (- (/ x (- 2.0 (+ x y))) (/ y (- 2.0 (+ x y))))

  (/ (- x y) (- 2.0 (+ x y))))