Average Error: 0.0 → 0.0
Time: 10.5s
Precision: 64
\[200 \cdot \left(x - y\right)\]
\[x \cdot 200 + \left(-y\right) \cdot 200\]
200 \cdot \left(x - y\right)
x \cdot 200 + \left(-y\right) \cdot 200
double f(double x, double y) {
        double r308749 = 200.0;
        double r308750 = x;
        double r308751 = y;
        double r308752 = r308750 - r308751;
        double r308753 = r308749 * r308752;
        return r308753;
}

double f(double x, double y) {
        double r308754 = x;
        double r308755 = 200.0;
        double r308756 = r308754 * r308755;
        double r308757 = y;
        double r308758 = -r308757;
        double r308759 = r308758 * r308755;
        double r308760 = r308756 + r308759;
        return r308760;
}

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

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

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

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

    \[\leadsto \color{blue}{x \cdot 200} + 200 \cdot \left(-y\right)\]
  6. Simplified0.0

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

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

Reproduce

herbie shell --seed 2020047 
(FPCore (x y)
  :name "Data.Colour.CIE:cieLABView from colour-2.3.3, C"
  :precision binary64
  (* 200 (- x y)))