Average Error: 0.0 → 0.0
Time: 5.1s
Precision: 64
\[\left(1 - x\right) - y\]
\[1 - \left(x + y\right)\]
\left(1 - x\right) - y
1 - \left(x + y\right)
double f(double x, double y) {
        double r16184339 = 1.0;
        double r16184340 = x;
        double r16184341 = r16184339 - r16184340;
        double r16184342 = y;
        double r16184343 = r16184341 - r16184342;
        return r16184343;
}

double f(double x, double y) {
        double r16184344 = 1.0;
        double r16184345 = x;
        double r16184346 = y;
        double r16184347 = r16184345 + r16184346;
        double r16184348 = r16184344 - r16184347;
        return r16184348;
}

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.0

    \[\left(1 - x\right) - y\]
  2. Using strategy rm
  3. Applied associate--l-0.0

    \[\leadsto \color{blue}{1 - \left(x + y\right)}\]
  4. Final simplification0.0

    \[\leadsto 1 - \left(x + y\right)\]

Reproduce

herbie shell --seed 2019171 
(FPCore (x y)
  :name "Data.Colour.CIE.Chromaticity:chromaCoords from colour-2.3.3"
  (- (- 1.0 x) y))