Average Error: 0.0 → 0.0
Time: 5.9s
Precision: 64
\[\left(x \cdot 2 + x \cdot x\right) + y \cdot y\]
\[\left(x \cdot 2 + x \cdot x\right) + y \cdot y\]
\left(x \cdot 2 + x \cdot x\right) + y \cdot y
\left(x \cdot 2 + x \cdot x\right) + y \cdot y
double f(double x, double y) {
        double r284401 = x;
        double r284402 = 2.0;
        double r284403 = r284401 * r284402;
        double r284404 = r284401 * r284401;
        double r284405 = r284403 + r284404;
        double r284406 = y;
        double r284407 = r284406 * r284406;
        double r284408 = r284405 + r284407;
        return r284408;
}

double f(double x, double y) {
        double r284409 = x;
        double r284410 = 2.0;
        double r284411 = r284409 * r284410;
        double r284412 = r284409 * r284409;
        double r284413 = r284411 + r284412;
        double r284414 = y;
        double r284415 = r284414 * r284414;
        double r284416 = r284413 + r284415;
        return r284416;
}

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 \cdot x + x \cdot x\right)\]

Derivation

  1. Initial program 0.0

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

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

Reproduce

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

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

  (+ (+ (* x 2) (* x x)) (* y y)))