Average Error: 0.0 → 0.0
Time: 5.6s
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 r97947 = x;
        double r97948 = r97947 * r97947;
        double r97949 = y;
        double r97950 = r97949 * r97949;
        double r97951 = r97948 + r97950;
        return r97951;
}

double f(double x, double y) {
        double r97952 = x;
        double r97953 = r97952 * r97952;
        double r97954 = y;
        double r97955 = r97954 * r97954;
        double r97956 = r97953 + r97955;
        return r97956;
}

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 2019326 
(FPCore (x y)
  :name "Graphics.Rasterific.Linear:$cquadrance from Rasterific-0.6.1"
  :precision binary64
  (+ (* x x) (* y y)))