Average Error: 0.1 → 0.1
Time: 5.4s
Precision: binary64
Cost: 13248
\[x \cdot \sin y + z \cdot \cos y\]
\[x \cdot \sin y + z \cdot \cos y\]
x \cdot \sin y + z \cdot \cos y
x \cdot \sin y + z \cdot \cos y
(FPCore (x y z) :precision binary64 (+ (* x (sin y)) (* z (cos y))))
(FPCore (x y z) :precision binary64 (+ (* x (sin y)) (* z (cos y))))
double code(double x, double y, double z) {
	return (x * sin(y)) + (z * cos(y));
}
double code(double x, double y, double z) {
	return (x * sin(y)) + (z * cos(y));
}

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
Error8.9
Cost7048
\[\begin{array}{l} \mathbf{if}\;z \leq -25934546194.779972 \lor \neg \left(z \leq 1.9371862556234732 \cdot 10^{+113}\right):\\ \;\;\;\;z \cdot \cos y\\ \mathbf{else}:\\ \;\;\;\;x \cdot \sin y + z\\ \end{array}\]
Alternative 2
Error17.8
Cost7555
\[\begin{array}{l} \mathbf{if}\;z \leq -13055071917.42417:\\ \;\;\;\;z \cdot \cos y\\ \mathbf{elif}\;z \leq -2.1377071873663266 \cdot 10^{-239}:\\ \;\;\;\;z + x \cdot y\\ \mathbf{elif}\;z \leq 5.878550368919599 \cdot 10^{-147}:\\ \;\;\;\;x \cdot \sin y\\ \mathbf{else}:\\ \;\;\;\;z \cdot \cos y\\ \end{array}\]
Alternative 3
Error17.0
Cost6920
\[\begin{array}{l} \mathbf{if}\;y \leq -1.3024106302462862 \cdot 10^{-07} \lor \neg \left(y \leq 5.4648702024981715 \cdot 10^{+20}\right):\\ \;\;\;\;x \cdot \sin y\\ \mathbf{else}:\\ \;\;\;\;z + y \cdot \left(x + y \cdot \left(z \cdot -0.5\right)\right)\\ \end{array}\]
Alternative 4
Error31.1
Cost320
\[z + x \cdot y\]
Alternative 5
Error39.7
Cost64
\[z\]
Alternative 6
Error61.8
Cost64
\[-1\]
Alternative 7
Error61.8
Cost64
\[1\]

Error

Derivation

  1. Initial program 0.1

    \[x \cdot \sin y + z \cdot \cos y\]
  2. Simplified0.1

    \[\leadsto \color{blue}{x \cdot \sin y + z \cdot \cos y}\]
  3. Final simplification0.1

    \[\leadsto x \cdot \sin y + z \cdot \cos y\]

Reproduce

herbie shell --seed 2021044 
(FPCore (x y z)
  :name "Diagrams.ThreeD.Transform:aboutX from diagrams-lib-1.3.0.3, B"
  :precision binary64
  (+ (* x (sin y)) (* z (cos y))))