Average Error: 0.0 → 0.0
Time: 756.0ms
Precision: binary64
\[x - \frac{2 \cdot y + z}{3}\]
\[x - \frac{2 \cdot y + z}{3}\]
x - \frac{2 \cdot y + z}{3}
x - \frac{2 \cdot y + z}{3}
double code(double x, double y, double z) {
	return ((double) (x - ((double) (((double) (((double) (2.0 * y)) + z)) / 3.0))));
}
double code(double x, double y, double z) {
	return ((double) (x - ((double) (((double) (((double) (2.0 * y)) + z)) / 3.0))));
}

Error

Bits error versus x

Bits error versus y

Bits error versus z

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.0

    \[x - \frac{2 \cdot y + z}{3}\]
  2. Final simplification0.0

    \[\leadsto x - \frac{2 \cdot y + z}{3}\]

Reproduce

herbie shell --seed 2020153 
(FPCore (x y z)
  :name "(- x (/ (+ (* 2 y) z) 3))"
  :precision binary64
  (- x (/ (+ (* 2.0 y) z) 3.0)))