Average Error: 0.0 → 0.0
Time: 822.0ms
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 r427772 = x;
        double r427773 = 2.0;
        double r427774 = r427772 * r427773;
        double r427775 = r427772 * r427772;
        double r427776 = r427774 + r427775;
        double r427777 = y;
        double r427778 = r427777 * r427777;
        double r427779 = r427776 + r427778;
        return r427779;
}

double f(double x, double y) {
        double r427780 = x;
        double r427781 = 2.0;
        double r427782 = r427780 * r427781;
        double r427783 = r427780 * r427780;
        double r427784 = r427782 + r427783;
        double r427785 = y;
        double r427786 = r427785 * r427785;
        double r427787 = r427784 + r427786;
        return r427787;
}

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