Average Error: 0.0 → 0.0
Time: 15.6s
Precision: 64
\[x \cdot \left(1 - y\right)\]
\[x \cdot \left(-y\right) + 1 \cdot x\]
x \cdot \left(1 - y\right)
x \cdot \left(-y\right) + 1 \cdot x
double f(double x, double y) {
        double r14525322 = x;
        double r14525323 = 1.0;
        double r14525324 = y;
        double r14525325 = r14525323 - r14525324;
        double r14525326 = r14525322 * r14525325;
        return r14525326;
}

double f(double x, double y) {
        double r14525327 = x;
        double r14525328 = y;
        double r14525329 = -r14525328;
        double r14525330 = r14525327 * r14525329;
        double r14525331 = 1.0;
        double r14525332 = r14525331 * r14525327;
        double r14525333 = r14525330 + r14525332;
        return r14525333;
}

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

    \[x \cdot \left(1 - y\right)\]
  2. Using strategy rm
  3. Applied sub-neg0.0

    \[\leadsto x \cdot \color{blue}{\left(1 + \left(-y\right)\right)}\]
  4. Applied distribute-rgt-in0.0

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

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

Reproduce

herbie shell --seed 2019168 
(FPCore (x y)
  :name "Data.Colour.RGBSpace.HSV:hsv from colour-2.3.3, H"
  (* x (- 1.0 y)))