Average Error: 16.3 → 0.0
Time: 1.5s
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 r710012 = x;
        double r710013 = 1.0;
        double r710014 = r710013 - r710012;
        double r710015 = y;
        double r710016 = r710013 - r710015;
        double r710017 = r710014 * r710016;
        double r710018 = r710012 + r710017;
        return r710018;
}

double f(double x, double y) {
        double r710019 = x;
        double r710020 = y;
        double r710021 = r710019 * r710020;
        double r710022 = 1.0;
        double r710023 = r710021 + r710022;
        double r710024 = r710022 * r710020;
        double r710025 = r710023 - r710024;
        return r710025;
}

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 2020100 
(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))))