Average Error: 0.0 → 0.0
Time: 2.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 r2511 = x;
        double r2512 = 2.0;
        double r2513 = r2511 * r2512;
        double r2514 = r2511 * r2511;
        double r2515 = r2513 + r2514;
        double r2516 = y;
        double r2517 = r2516 * r2516;
        double r2518 = r2515 + r2517;
        return r2518;
}

double f(double x, double y) {
        double r2519 = x;
        double r2520 = 2.0;
        double r2521 = r2519 * r2520;
        double r2522 = r2519 * r2519;
        double r2523 = r2521 + r2522;
        double r2524 = y;
        double r2525 = r2524 * r2524;
        double r2526 = r2523 + r2525;
        return r2526;
}

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