Average Error: 0.0 → 0.0
Time: 7.7s
Precision: 64
\[\left(x \cdot 2.0 + x \cdot x\right) + y \cdot y\]
\[y \cdot y + \left(x \cdot x + x \cdot 2.0\right)\]
\left(x \cdot 2.0 + x \cdot x\right) + y \cdot y
y \cdot y + \left(x \cdot x + x \cdot 2.0\right)
double f(double x, double y) {
        double r19999739 = x;
        double r19999740 = 2.0;
        double r19999741 = r19999739 * r19999740;
        double r19999742 = r19999739 * r19999739;
        double r19999743 = r19999741 + r19999742;
        double r19999744 = y;
        double r19999745 = r19999744 * r19999744;
        double r19999746 = r19999743 + r19999745;
        return r19999746;
}

double f(double x, double y) {
        double r19999747 = y;
        double r19999748 = r19999747 * r19999747;
        double r19999749 = x;
        double r19999750 = r19999749 * r19999749;
        double r19999751 = 2.0;
        double r19999752 = r19999749 * r19999751;
        double r19999753 = r19999750 + r19999752;
        double r19999754 = r19999748 + r19999753;
        return r19999754;
}

Error

Bits error versus x

Bits error versus y

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original0.0
Target0.0
Herbie0.0
\[y \cdot y + \left(2.0 \cdot x + x \cdot x\right)\]

Derivation

  1. Initial program 0.0

    \[\left(x \cdot 2.0 + x \cdot x\right) + y \cdot y\]
  2. Final simplification0.0

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

Reproduce

herbie shell --seed 2019163 +o rules:numerics
(FPCore (x y)
  :name "Numeric.Log:$clog1p from log-domain-0.10.2.1, A"

  :herbie-target
  (+ (* y y) (+ (* 2.0 x) (* x x)))

  (+ (+ (* x 2.0) (* x x)) (* y y)))