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 r729119 = x;
        double r729120 = 2.0;
        double r729121 = r729119 * r729120;
        double r729122 = r729119 * r729119;
        double r729123 = r729121 + r729122;
        double r729124 = y;
        double r729125 = r729124 * r729124;
        double r729126 = r729123 + r729125;
        return r729126;
}

double f(double x, double y) {
        double r729127 = x;
        double r729128 = 2.0;
        double r729129 = r729127 * r729128;
        double r729130 = r729127 * r729127;
        double r729131 = r729129 + r729130;
        double r729132 = y;
        double r729133 = r729132 * r729132;
        double r729134 = r729131 + r729133;
        return r729134;
}

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 2020034 +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)))