Average Error: 0.0 → 0.0
Time: 6.5s
Precision: 64
\[x \cdot \left(1 - y\right)\]
\[\left(1 - y\right) \cdot x\]
x \cdot \left(1 - y\right)
\left(1 - y\right) \cdot x
double f(double x, double y) {
        double r171276 = x;
        double r171277 = 1.0;
        double r171278 = y;
        double r171279 = r171277 - r171278;
        double r171280 = r171276 * r171279;
        return r171280;
}

double f(double x, double y) {
        double r171281 = 1.0;
        double r171282 = y;
        double r171283 = r171281 - r171282;
        double r171284 = x;
        double r171285 = r171283 * r171284;
        return r171285;
}

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

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

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

Reproduce

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