Average Error: 0.0 → 0.0
Time: 1.6min
Precision: binary64
Cost: 448
\[x + y \cdot \left(z + x\right)\]
\[x + y \cdot \left(x + z\right)\]
x + y \cdot \left(z + x\right)
x + y \cdot \left(x + z\right)
(FPCore (x y z) :precision binary64 (+ x (* y (+ z x))))
(FPCore (x y z) :precision binary64 (+ x (* y (+ x z))))
double code(double x, double y, double z) {
	return x + (y * (z + x));
}
double code(double x, double y, double z) {
	return x + (y * (x + z));
}

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

Alternatives

Alternative 1
Error0.9
Cost648
\[\begin{array}{l} \mathbf{if}\;y \leq -0.9915933825682126 \lor \neg \left(y \leq 6.161311737209512 \cdot 10^{-09}\right):\\ \;\;\;\;y \cdot \left(x + z\right)\\ \mathbf{else}:\\ \;\;\;\;x + y \cdot z\\ \end{array}\]
Alternative 2
Error12.5
Cost648
\[\begin{array}{l} \mathbf{if}\;y \leq -3.3189895676687136 \cdot 10^{-64} \lor \neg \left(y \leq 1.539707023242084 \cdot 10^{-64}\right):\\ \;\;\;\;y \cdot \left(x + z\right)\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array}\]
Alternative 3
Error23.6
Cost1615
\[\begin{array}{l} \mathbf{if}\;y \leq -1.767097151838892 \cdot 10^{+99}:\\ \;\;\;\;x \cdot y\\ \mathbf{elif}\;y \leq -2.217625604918875 \cdot 10^{-56}:\\ \;\;\;\;y \cdot z\\ \mathbf{elif}\;y \leq 4.78047581618741 \cdot 10^{-64}:\\ \;\;\;\;x\\ \mathbf{elif}\;y \leq 7576974284072711 \lor \neg \left(y \leq 9.721438915267512 \cdot 10^{+211}\right) \land y \leq 7.613433346793353 \cdot 10^{+256}:\\ \;\;\;\;y \cdot z\\ \mathbf{else}:\\ \;\;\;\;x \cdot y\\ \end{array}\]
Alternative 4
Error25.0
Cost834
\[\begin{array}{l} \mathbf{if}\;x \leq -8.887636648204338 \cdot 10^{-87}:\\ \;\;\;\;x\\ \mathbf{elif}\;x \leq 3.27982273925082 \cdot 10^{-77}:\\ \;\;\;\;y \cdot z\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array}\]
Alternative 5
Error34.6
Cost64
\[x\]

Error

Time

Derivation

  1. Initial program 0.0

    \[x + y \cdot \left(z + x\right)\]
  2. Using strategy rm
  3. Applied +-commutative_binary64_20540.0

    \[\leadsto \color{blue}{y \cdot \left(z + x\right) + x}\]
  4. Simplified0.0

    \[\leadsto \color{blue}{x + y \cdot \left(x + z\right)}\]
  5. Final simplification0.0

    \[\leadsto x + y \cdot \left(x + z\right)\]

Reproduce

herbie shell --seed 2021040 
(FPCore (x y z)
  :name "Main:bigenough2 from A"
  :precision binary64
  (+ x (* y (+ z x))))