Average Error: 0.0 → 0.0
Time: 7.9s
Precision: 64
\[0.5 \cdot \left(x \cdot x - y\right)\]
\[\left(x \cdot x - y\right) \cdot 0.5\]
0.5 \cdot \left(x \cdot x - y\right)
\left(x \cdot x - y\right) \cdot 0.5
double f(double x, double y) {
        double r341769 = 0.5;
        double r341770 = x;
        double r341771 = r341770 * r341770;
        double r341772 = y;
        double r341773 = r341771 - r341772;
        double r341774 = r341769 * r341773;
        return r341774;
}

double f(double x, double y) {
        double r341775 = x;
        double r341776 = r341775 * r341775;
        double r341777 = y;
        double r341778 = r341776 - r341777;
        double r341779 = 0.5;
        double r341780 = r341778 * r341779;
        return r341780;
}

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

    \[0.5 \cdot \left(x \cdot x - y\right)\]
  2. Final simplification0.0

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

Reproduce

herbie shell --seed 2019172 
(FPCore (x y)
  :name "System.Random.MWC.Distributions:standard from mwc-random-0.13.3.2"
  (* 0.5 (- (* x x) y)))