Average Error: 0.0 → 0.0
Time: 4.7s
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 r10825 = 0.5;
        double r10826 = x;
        double r10827 = r10826 * r10826;
        double r10828 = y;
        double r10829 = r10827 - r10828;
        double r10830 = r10825 * r10829;
        return r10830;
}

double f(double x, double y) {
        double r10831 = x;
        double r10832 = r10831 * r10831;
        double r10833 = y;
        double r10834 = r10832 - r10833;
        double r10835 = 0.5;
        double r10836 = r10834 * r10835;
        return r10836;
}

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 2019196 
(FPCore (x y)
  :name "System.Random.MWC.Distributions:standard from mwc-random-0.13.3.2"
  (* 0.5 (- (* x x) y)))