Average Error: 31.4 → 31.4
Time: 1.3s
Precision: binary64
\[\frac{\sqrt{\left(x \cdot x + y \cdot y\right) + z \cdot z}}{c}\]
\[\frac{\sqrt{\left(x \cdot x + y \cdot y\right) + z \cdot z}}{c}\]
\frac{\sqrt{\left(x \cdot x + y \cdot y\right) + z \cdot z}}{c}
\frac{\sqrt{\left(x \cdot x + y \cdot y\right) + z \cdot z}}{c}
double code(double x, double y, double z, double c) {
	return ((double) (((double) sqrt(((double) (((double) (((double) (x * x)) + ((double) (y * y)))) + ((double) (z * z)))))) / c));
}
double code(double x, double y, double z, double c) {
	return ((double) (((double) sqrt(((double) (((double) (((double) (x * x)) + ((double) (y * y)))) + ((double) (z * z)))))) / c));
}

Error

Bits error versus x

Bits error versus y

Bits error versus z

Bits error versus c

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 31.4

    \[\frac{\sqrt{\left(x \cdot x + y \cdot y\right) + z \cdot z}}{c}\]
  2. Final simplification31.4

    \[\leadsto \frac{\sqrt{\left(x \cdot x + y \cdot y\right) + z \cdot z}}{c}\]

Reproduce

herbie shell --seed 2020153 
(FPCore (x y z c)
  :name "(/ (sqrt (+ (+ (* x x) (* y y)) (* z z))) c)"
  :precision binary64
  (/ (sqrt (+ (+ (* x x) (* y y)) (* z z))) c))