Average Error: 16.3 → 0.0
Time: 903.0ms
Precision: 64
\[x + \left(1 - x\right) \cdot \left(1 - y\right)\]
\[\left(x \cdot y + 1\right) - 1 \cdot y\]
x + \left(1 - x\right) \cdot \left(1 - y\right)
\left(x \cdot y + 1\right) - 1 \cdot y
double f(double x, double y) {
        double r623735 = x;
        double r623736 = 1.0;
        double r623737 = r623736 - r623735;
        double r623738 = y;
        double r623739 = r623736 - r623738;
        double r623740 = r623737 * r623739;
        double r623741 = r623735 + r623740;
        return r623741;
}

double f(double x, double y) {
        double r623742 = x;
        double r623743 = y;
        double r623744 = r623742 * r623743;
        double r623745 = 1.0;
        double r623746 = r623744 + r623745;
        double r623747 = r623745 * r623743;
        double r623748 = r623746 - r623747;
        return r623748;
}

Error

Bits error versus x

Bits error versus y

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original16.3
Target0.0
Herbie0.0
\[y \cdot x - \left(y - 1\right)\]

Derivation

  1. Initial program 16.3

    \[x + \left(1 - x\right) \cdot \left(1 - y\right)\]
  2. Taylor expanded around 0 0.0

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

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

Reproduce

herbie shell --seed 2020001 
(FPCore (x y)
  :name "Graphics.Rendering.Chart.Plot.Vectors:renderPlotVectors from Chart-1.5.3"
  :precision binary64

  :herbie-target
  (- (* y x) (- y 1))

  (+ x (* (- 1 x) (- 1 y))))