Average Error: 0.0 → 0.0
Time: 5.2s
Precision: 64
\[x \cdot x + y \cdot y\]
\[x \cdot x + y \cdot y\]
x \cdot x + y \cdot y
x \cdot x + y \cdot y
double f(double x, double y) {
        double r150505 = x;
        double r150506 = r150505 * r150505;
        double r150507 = y;
        double r150508 = r150507 * r150507;
        double r150509 = r150506 + r150508;
        return r150509;
}

double f(double x, double y) {
        double r150510 = x;
        double r150511 = r150510 * r150510;
        double r150512 = y;
        double r150513 = r150512 * r150512;
        double r150514 = r150511 + r150513;
        return r150514;
}

Error

Bits error versus x

Bits error versus y

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.0

    \[x \cdot x + y \cdot y\]
  2. Final simplification0.0

    \[\leadsto x \cdot x + y \cdot y\]

Reproduce

herbie shell --seed 2019322 
(FPCore (x y)
  :name "Graphics.Rasterific.Linear:$cquadrance from Rasterific-0.6.1"
  :precision binary64
  (+ (* x x) (* y y)))