?

Average Error: 0.71% → 0.58%
Time: 33.7s
Precision: binary64
Cost: 78912

?

\[\frac{2 + \left(\left(\sqrt{2} \cdot \left(\sin x - \frac{\sin y}{16}\right)\right) \cdot \left(\sin y - \frac{\sin x}{16}\right)\right) \cdot \left(\cos x - \cos y\right)}{3 \cdot \left(\left(1 + \frac{\sqrt{5} - 1}{2} \cdot \cos x\right) + \frac{3 - \sqrt{5}}{2} \cdot \cos y\right)} \]
\[\frac{2 + \sqrt{2} \cdot \left(\left(\sin y + \sin x \cdot -0.0625\right) \cdot \left(\left(\cos x - \cos y\right) \cdot \left(\sin x + \sin y \cdot -0.0625\right)\right)\right)}{3 + \mathsf{fma}\left(\cos y, \frac{6}{3 + \sqrt{5}}, \frac{\cos x}{0.16666666666666666 + \sqrt{0.1388888888888889}}\right)} \]
(FPCore (x y)
 :precision binary64
 (/
  (+
   2.0
   (*
    (*
     (* (sqrt 2.0) (- (sin x) (/ (sin y) 16.0)))
     (- (sin y) (/ (sin x) 16.0)))
    (- (cos x) (cos y))))
  (*
   3.0
   (+
    (+ 1.0 (* (/ (- (sqrt 5.0) 1.0) 2.0) (cos x)))
    (* (/ (- 3.0 (sqrt 5.0)) 2.0) (cos y))))))
(FPCore (x y)
 :precision binary64
 (/
  (+
   2.0
   (*
    (sqrt 2.0)
    (*
     (+ (sin y) (* (sin x) -0.0625))
     (* (- (cos x) (cos y)) (+ (sin x) (* (sin y) -0.0625))))))
  (+
   3.0
   (fma
    (cos y)
    (/ 6.0 (+ 3.0 (sqrt 5.0)))
    (/ (cos x) (+ 0.16666666666666666 (sqrt 0.1388888888888889)))))))
double code(double x, double y) {
	return (2.0 + (((sqrt(2.0) * (sin(x) - (sin(y) / 16.0))) * (sin(y) - (sin(x) / 16.0))) * (cos(x) - cos(y)))) / (3.0 * ((1.0 + (((sqrt(5.0) - 1.0) / 2.0) * cos(x))) + (((3.0 - sqrt(5.0)) / 2.0) * cos(y))));
}
double code(double x, double y) {
	return (2.0 + (sqrt(2.0) * ((sin(y) + (sin(x) * -0.0625)) * ((cos(x) - cos(y)) * (sin(x) + (sin(y) * -0.0625)))))) / (3.0 + fma(cos(y), (6.0 / (3.0 + sqrt(5.0))), (cos(x) / (0.16666666666666666 + sqrt(0.1388888888888889)))));
}
function code(x, y)
	return Float64(Float64(2.0 + Float64(Float64(Float64(sqrt(2.0) * Float64(sin(x) - Float64(sin(y) / 16.0))) * Float64(sin(y) - Float64(sin(x) / 16.0))) * Float64(cos(x) - cos(y)))) / Float64(3.0 * Float64(Float64(1.0 + Float64(Float64(Float64(sqrt(5.0) - 1.0) / 2.0) * cos(x))) + Float64(Float64(Float64(3.0 - sqrt(5.0)) / 2.0) * cos(y)))))
end
function code(x, y)
	return Float64(Float64(2.0 + Float64(sqrt(2.0) * Float64(Float64(sin(y) + Float64(sin(x) * -0.0625)) * Float64(Float64(cos(x) - cos(y)) * Float64(sin(x) + Float64(sin(y) * -0.0625)))))) / Float64(3.0 + fma(cos(y), Float64(6.0 / Float64(3.0 + sqrt(5.0))), Float64(cos(x) / Float64(0.16666666666666666 + sqrt(0.1388888888888889))))))
end
code[x_, y_] := N[(N[(2.0 + N[(N[(N[(N[Sqrt[2.0], $MachinePrecision] * N[(N[Sin[x], $MachinePrecision] - N[(N[Sin[y], $MachinePrecision] / 16.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[Sin[y], $MachinePrecision] - N[(N[Sin[x], $MachinePrecision] / 16.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[Cos[x], $MachinePrecision] - N[Cos[y], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(3.0 * N[(N[(1.0 + N[(N[(N[(N[Sqrt[5.0], $MachinePrecision] - 1.0), $MachinePrecision] / 2.0), $MachinePrecision] * N[Cos[x], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(3.0 - N[Sqrt[5.0], $MachinePrecision]), $MachinePrecision] / 2.0), $MachinePrecision] * N[Cos[y], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
code[x_, y_] := N[(N[(2.0 + N[(N[Sqrt[2.0], $MachinePrecision] * N[(N[(N[Sin[y], $MachinePrecision] + N[(N[Sin[x], $MachinePrecision] * -0.0625), $MachinePrecision]), $MachinePrecision] * N[(N[(N[Cos[x], $MachinePrecision] - N[Cos[y], $MachinePrecision]), $MachinePrecision] * N[(N[Sin[x], $MachinePrecision] + N[(N[Sin[y], $MachinePrecision] * -0.0625), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(3.0 + N[(N[Cos[y], $MachinePrecision] * N[(6.0 / N[(3.0 + N[Sqrt[5.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[Cos[x], $MachinePrecision] / N[(0.16666666666666666 + N[Sqrt[0.1388888888888889], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\frac{2 + \left(\left(\sqrt{2} \cdot \left(\sin x - \frac{\sin y}{16}\right)\right) \cdot \left(\sin y - \frac{\sin x}{16}\right)\right) \cdot \left(\cos x - \cos y\right)}{3 \cdot \left(\left(1 + \frac{\sqrt{5} - 1}{2} \cdot \cos x\right) + \frac{3 - \sqrt{5}}{2} \cdot \cos y\right)}
\frac{2 + \sqrt{2} \cdot \left(\left(\sin y + \sin x \cdot -0.0625\right) \cdot \left(\left(\cos x - \cos y\right) \cdot \left(\sin x + \sin y \cdot -0.0625\right)\right)\right)}{3 + \mathsf{fma}\left(\cos y, \frac{6}{3 + \sqrt{5}}, \frac{\cos x}{0.16666666666666666 + \sqrt{0.1388888888888889}}\right)}

Error?

Derivation?

  1. Initial program 0.71

    \[\frac{2 + \left(\left(\sqrt{2} \cdot \left(\sin x - \frac{\sin y}{16}\right)\right) \cdot \left(\sin y - \frac{\sin x}{16}\right)\right) \cdot \left(\cos x - \cos y\right)}{3 \cdot \left(\left(1 + \frac{\sqrt{5} - 1}{2} \cdot \cos x\right) + \frac{3 - \sqrt{5}}{2} \cdot \cos y\right)} \]
  2. Simplified0.72

    \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\sqrt{2}, \left(\sin y - \frac{\sin x}{16}\right) \cdot \left(\left(\sin x - \frac{\sin y}{16}\right) \cdot \left(\cos x - \cos y\right)\right), 2\right)}{\frac{\cos x \cdot \left(\sqrt{5} + -1\right)}{0.6666666666666666} + \mathsf{fma}\left(\cos y, \frac{3 - \sqrt{5}}{0.6666666666666666}, 3\right)}} \]
    Proof

    [Start]0.71

    \[ \frac{2 + \left(\left(\sqrt{2} \cdot \left(\sin x - \frac{\sin y}{16}\right)\right) \cdot \left(\sin y - \frac{\sin x}{16}\right)\right) \cdot \left(\cos x - \cos y\right)}{3 \cdot \left(\left(1 + \frac{\sqrt{5} - 1}{2} \cdot \cos x\right) + \frac{3 - \sqrt{5}}{2} \cdot \cos y\right)} \]
  3. Applied egg-rr25.29

    \[\leadsto \frac{\mathsf{fma}\left(\sqrt{2}, \left(\sin y - \frac{\sin x}{16}\right) \cdot \left(\left(\sin x - \frac{\sin y}{16}\right) \cdot \left(\cos x - \cos y\right)\right), 2\right)}{\color{blue}{\frac{\sqrt{\cos x}}{\sqrt{5} \cdot 0.16666666666666666 + 0.16666666666666666} \cdot \sqrt{\cos x}} + \mathsf{fma}\left(\cos y, \frac{3 - \sqrt{5}}{0.6666666666666666}, 3\right)} \]
  4. Simplified0.63

    \[\leadsto \frac{\mathsf{fma}\left(\sqrt{2}, \left(\sin y - \frac{\sin x}{16}\right) \cdot \left(\left(\sin x - \frac{\sin y}{16}\right) \cdot \left(\cos x - \cos y\right)\right), 2\right)}{\color{blue}{\frac{\cos x}{\mathsf{fma}\left(\sqrt{5}, 0.16666666666666666, 0.16666666666666666\right)}} + \mathsf{fma}\left(\cos y, \frac{3 - \sqrt{5}}{0.6666666666666666}, 3\right)} \]
    Proof

    [Start]25.29

    \[ \frac{\mathsf{fma}\left(\sqrt{2}, \left(\sin y - \frac{\sin x}{16}\right) \cdot \left(\left(\sin x - \frac{\sin y}{16}\right) \cdot \left(\cos x - \cos y\right)\right), 2\right)}{\frac{\sqrt{\cos x}}{\sqrt{5} \cdot 0.16666666666666666 + 0.16666666666666666} \cdot \sqrt{\cos x} + \mathsf{fma}\left(\cos y, \frac{3 - \sqrt{5}}{0.6666666666666666}, 3\right)} \]

    associate-*l/ [=>]25.29

    \[ \frac{\mathsf{fma}\left(\sqrt{2}, \left(\sin y - \frac{\sin x}{16}\right) \cdot \left(\left(\sin x - \frac{\sin y}{16}\right) \cdot \left(\cos x - \cos y\right)\right), 2\right)}{\color{blue}{\frac{\sqrt{\cos x} \cdot \sqrt{\cos x}}{\sqrt{5} \cdot 0.16666666666666666 + 0.16666666666666666}} + \mathsf{fma}\left(\cos y, \frac{3 - \sqrt{5}}{0.6666666666666666}, 3\right)} \]

    rem-square-sqrt [=>]0.63

    \[ \frac{\mathsf{fma}\left(\sqrt{2}, \left(\sin y - \frac{\sin x}{16}\right) \cdot \left(\left(\sin x - \frac{\sin y}{16}\right) \cdot \left(\cos x - \cos y\right)\right), 2\right)}{\frac{\color{blue}{\cos x}}{\sqrt{5} \cdot 0.16666666666666666 + 0.16666666666666666} + \mathsf{fma}\left(\cos y, \frac{3 - \sqrt{5}}{0.6666666666666666}, 3\right)} \]

    fma-def [=>]0.63

    \[ \frac{\mathsf{fma}\left(\sqrt{2}, \left(\sin y - \frac{\sin x}{16}\right) \cdot \left(\left(\sin x - \frac{\sin y}{16}\right) \cdot \left(\cos x - \cos y\right)\right), 2\right)}{\frac{\cos x}{\color{blue}{\mathsf{fma}\left(\sqrt{5}, 0.16666666666666666, 0.16666666666666666\right)}} + \mathsf{fma}\left(\cos y, \frac{3 - \sqrt{5}}{0.6666666666666666}, 3\right)} \]
  5. Taylor expanded in y around inf 0.62

    \[\leadsto \color{blue}{\frac{2 + \sqrt{2} \cdot \left(\left(\sin y - 0.0625 \cdot \sin x\right) \cdot \left(\left(\cos x - \cos y\right) \cdot \left(\sin x - 0.0625 \cdot \sin y\right)\right)\right)}{3 + \left(\frac{\cos x}{0.16666666666666666 \cdot \sqrt{5} + 0.16666666666666666} + 1.5 \cdot \left(\left(3 - \sqrt{5}\right) \cdot \cos y\right)\right)}} \]
  6. Applied egg-rr0.59

    \[\leadsto \frac{2 + \sqrt{2} \cdot \left(\left(\sin y - 0.0625 \cdot \sin x\right) \cdot \left(\left(\cos x - \cos y\right) \cdot \left(\sin x - 0.0625 \cdot \sin y\right)\right)\right)}{3 + \left(\frac{\cos x}{0.16666666666666666 \cdot \sqrt{5} + 0.16666666666666666} + 1.5 \cdot \left(\color{blue}{\frac{4}{\sqrt{5} + 3}} \cdot \cos y\right)\right)} \]
  7. Applied egg-rr0.58

    \[\leadsto \frac{2 + \sqrt{2} \cdot \left(\left(\sin y - 0.0625 \cdot \sin x\right) \cdot \left(\left(\cos x - \cos y\right) \cdot \left(\sin x - 0.0625 \cdot \sin y\right)\right)\right)}{3 + \color{blue}{\left(\frac{\cos x}{0.16666666666666666 + \sqrt{0.1388888888888889}} + \cos y \cdot \frac{6}{\sqrt{5} + 3}\right) \cdot 1}} \]
  8. Simplified0.58

    \[\leadsto \frac{2 + \sqrt{2} \cdot \left(\left(\sin y - 0.0625 \cdot \sin x\right) \cdot \left(\left(\cos x - \cos y\right) \cdot \left(\sin x - 0.0625 \cdot \sin y\right)\right)\right)}{3 + \color{blue}{\mathsf{fma}\left(\cos y, \frac{6}{\sqrt{5} + 3}, \frac{\cos x}{0.16666666666666666 + \sqrt{0.1388888888888889}}\right)}} \]
    Proof

    [Start]0.58

    \[ \frac{2 + \sqrt{2} \cdot \left(\left(\sin y - 0.0625 \cdot \sin x\right) \cdot \left(\left(\cos x - \cos y\right) \cdot \left(\sin x - 0.0625 \cdot \sin y\right)\right)\right)}{3 + \left(\frac{\cos x}{0.16666666666666666 + \sqrt{0.1388888888888889}} + \cos y \cdot \frac{6}{\sqrt{5} + 3}\right) \cdot 1} \]

    *-rgt-identity [=>]0.58

    \[ \frac{2 + \sqrt{2} \cdot \left(\left(\sin y - 0.0625 \cdot \sin x\right) \cdot \left(\left(\cos x - \cos y\right) \cdot \left(\sin x - 0.0625 \cdot \sin y\right)\right)\right)}{3 + \color{blue}{\left(\frac{\cos x}{0.16666666666666666 + \sqrt{0.1388888888888889}} + \cos y \cdot \frac{6}{\sqrt{5} + 3}\right)}} \]

    +-commutative [=>]0.58

    \[ \frac{2 + \sqrt{2} \cdot \left(\left(\sin y - 0.0625 \cdot \sin x\right) \cdot \left(\left(\cos x - \cos y\right) \cdot \left(\sin x - 0.0625 \cdot \sin y\right)\right)\right)}{3 + \color{blue}{\left(\cos y \cdot \frac{6}{\sqrt{5} + 3} + \frac{\cos x}{0.16666666666666666 + \sqrt{0.1388888888888889}}\right)}} \]

    metadata-eval [<=]0.58

    \[ \frac{2 + \sqrt{2} \cdot \left(\left(\sin y - 0.0625 \cdot \sin x\right) \cdot \left(\left(\cos x - \cos y\right) \cdot \left(\sin x - 0.0625 \cdot \sin y\right)\right)\right)}{3 + \left(\cos y \cdot \frac{\color{blue}{6 \cdot 1}}{\sqrt{5} + 3} + \frac{\cos x}{0.16666666666666666 + \sqrt{0.1388888888888889}}\right)} \]

    associate-*r/ [<=]0.58

    \[ \frac{2 + \sqrt{2} \cdot \left(\left(\sin y - 0.0625 \cdot \sin x\right) \cdot \left(\left(\cos x - \cos y\right) \cdot \left(\sin x - 0.0625 \cdot \sin y\right)\right)\right)}{3 + \left(\cos y \cdot \color{blue}{\left(6 \cdot \frac{1}{\sqrt{5} + 3}\right)} + \frac{\cos x}{0.16666666666666666 + \sqrt{0.1388888888888889}}\right)} \]

    fma-def [=>]0.58

    \[ \frac{2 + \sqrt{2} \cdot \left(\left(\sin y - 0.0625 \cdot \sin x\right) \cdot \left(\left(\cos x - \cos y\right) \cdot \left(\sin x - 0.0625 \cdot \sin y\right)\right)\right)}{3 + \color{blue}{\mathsf{fma}\left(\cos y, 6 \cdot \frac{1}{\sqrt{5} + 3}, \frac{\cos x}{0.16666666666666666 + \sqrt{0.1388888888888889}}\right)}} \]

    associate-*r/ [=>]0.58

    \[ \frac{2 + \sqrt{2} \cdot \left(\left(\sin y - 0.0625 \cdot \sin x\right) \cdot \left(\left(\cos x - \cos y\right) \cdot \left(\sin x - 0.0625 \cdot \sin y\right)\right)\right)}{3 + \mathsf{fma}\left(\cos y, \color{blue}{\frac{6 \cdot 1}{\sqrt{5} + 3}}, \frac{\cos x}{0.16666666666666666 + \sqrt{0.1388888888888889}}\right)} \]

    metadata-eval [=>]0.58

    \[ \frac{2 + \sqrt{2} \cdot \left(\left(\sin y - 0.0625 \cdot \sin x\right) \cdot \left(\left(\cos x - \cos y\right) \cdot \left(\sin x - 0.0625 \cdot \sin y\right)\right)\right)}{3 + \mathsf{fma}\left(\cos y, \frac{\color{blue}{6}}{\sqrt{5} + 3}, \frac{\cos x}{0.16666666666666666 + \sqrt{0.1388888888888889}}\right)} \]
  9. Final simplification0.58

    \[\leadsto \frac{2 + \sqrt{2} \cdot \left(\left(\sin y + \sin x \cdot -0.0625\right) \cdot \left(\left(\cos x - \cos y\right) \cdot \left(\sin x + \sin y \cdot -0.0625\right)\right)\right)}{3 + \mathsf{fma}\left(\cos y, \frac{6}{3 + \sqrt{5}}, \frac{\cos x}{0.16666666666666666 + \sqrt{0.1388888888888889}}\right)} \]

Alternatives

Alternative 1
Error0.58%
Cost72640
\[\frac{2 + \sqrt{2} \cdot \left(\left(\sin y + \sin x \cdot -0.0625\right) \cdot \left(\left(\cos x - \cos y\right) \cdot \left(\sin x + \sin y \cdot -0.0625\right)\right)\right)}{3 + \left(\frac{\cos x}{0.16666666666666666 + \sqrt{0.1388888888888889}} + \cos y \cdot \frac{6}{3 + \sqrt{5}}\right)} \]
Alternative 2
Error18.03%
Cost67016
\[\begin{array}{l} t_0 := \sin y - \frac{\sin x}{16}\\ t_1 := \sqrt{2} \cdot \sin x\\ t_2 := \frac{\sqrt{5}}{2}\\ t_3 := \cos x - \cos y\\ \mathbf{if}\;x \leq -0.125:\\ \;\;\;\;\frac{2 + t_1 \cdot \left(t_3 \cdot t_0\right)}{3 \cdot \left(1 + \left(\cos x \cdot \left(t_2 + -0.5\right) + \cos y \cdot \left(1.5 - t_2\right)\right)\right)}\\ \mathbf{elif}\;x \leq 0.18:\\ \;\;\;\;\frac{2 + \sqrt{2} \cdot \left(\left(\sin y + \sin x \cdot -0.0625\right) \cdot \left(\left(\sin x + \sin y \cdot -0.0625\right) \cdot \left(1 + \left(-0.5 \cdot \left(x \cdot x\right) - \cos y\right)\right)\right)\right)}{3 + \left(\frac{\cos x}{0.16666666666666666 + \sqrt{5} \cdot 0.16666666666666666} + 1.5 \cdot \left(\cos y \cdot \left(3 - \sqrt{5}\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2 + t_3 \cdot \left(t_1 \cdot t_0\right)}{3 \cdot \left(\left(1 + \cos x \cdot \frac{\sqrt{5} + -1}{2}\right) + \cos y \cdot \frac{\frac{4}{3 + \sqrt{5}}}{2}\right)}\\ \end{array} \]
Alternative 3
Error18.11%
Cost66633
\[\begin{array}{l} t_0 := \frac{\sqrt{5}}{2}\\ \mathbf{if}\;x \leq -0.00038 \lor \neg \left(x \leq 0.0031\right):\\ \;\;\;\;\frac{2 + \left(\sqrt{2} \cdot \sin x\right) \cdot \left(\left(\cos x - \cos y\right) \cdot \left(\sin y - \frac{\sin x}{16}\right)\right)}{3 \cdot \left(1 + \left(\cos x \cdot \left(t_0 + -0.5\right) + \cos y \cdot \left(1.5 - t_0\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2 + \sqrt{2} \cdot \left(\left(\sin y + \sin x \cdot -0.0625\right) \cdot \left(\left(\sin x + \sin y \cdot -0.0625\right) \cdot \left(1 - \cos y\right)\right)\right)}{3 + \left(\frac{\cos x}{0.16666666666666666 + \sqrt{5} \cdot 0.16666666666666666} + 1.5 \cdot \left(\cos y \cdot \left(3 - \sqrt{5}\right)\right)\right)}\\ \end{array} \]
Alternative 4
Error18.1%
Cost66632
\[\begin{array}{l} t_0 := \sin y - \frac{\sin x}{16}\\ t_1 := \sqrt{2} \cdot \sin x\\ t_2 := \frac{\sqrt{5}}{2}\\ t_3 := \cos x - \cos y\\ \mathbf{if}\;x \leq -0.00038:\\ \;\;\;\;\frac{2 + t_1 \cdot \left(t_3 \cdot t_0\right)}{3 \cdot \left(1 + \left(\cos x \cdot \left(t_2 + -0.5\right) + \cos y \cdot \left(1.5 - t_2\right)\right)\right)}\\ \mathbf{elif}\;x \leq 0.0136:\\ \;\;\;\;\frac{2 + \sqrt{2} \cdot \left(\left(\sin y + \sin x \cdot -0.0625\right) \cdot \left(\left(\sin x + \sin y \cdot -0.0625\right) \cdot \left(1 - \cos y\right)\right)\right)}{3 + \left(\frac{\cos x}{0.16666666666666666 + \sqrt{5} \cdot 0.16666666666666666} + 1.5 \cdot \left(\cos y \cdot \left(3 - \sqrt{5}\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2 + t_3 \cdot \left(t_1 \cdot t_0\right)}{3 \cdot \left(\left(1 + \cos x \cdot \frac{\sqrt{5} + -1}{2}\right) + \cos y \cdot \frac{\frac{4}{3 + \sqrt{5}}}{2}\right)}\\ \end{array} \]
Alternative 5
Error18.2%
Cost66505
\[\begin{array}{l} t_0 := \frac{\sqrt{5}}{2}\\ t_1 := \sin y - \frac{\sin x}{16}\\ \mathbf{if}\;x \leq -0.000145 \lor \neg \left(x \leq 1.8 \cdot 10^{-6}\right):\\ \;\;\;\;\frac{2 + \left(\sqrt{2} \cdot \sin x\right) \cdot \left(\left(\cos x - \cos y\right) \cdot t_1\right)}{3 \cdot \left(1 + \left(\cos x \cdot \left(t_0 + -0.5\right) + \cos y \cdot \left(1.5 - t_0\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{\mathsf{fma}\left(t_1, \left(\sqrt{2} \cdot \left(1 - \cos y\right)\right) \cdot \left(x + \sin y \cdot -0.0625\right), 2\right)}{3 \cdot \left(0.5 + \left(\sqrt{5} \cdot 0.5 + \cos y \cdot \left(1.5 + \sqrt{5} \cdot -0.5\right)\right)\right)}\\ \end{array} \]
Alternative 6
Error19.8%
Cost60104
\[\begin{array}{l} \mathbf{if}\;x \leq -8.6 \cdot 10^{-6}:\\ \;\;\;\;\frac{2 + {\sin x}^{2} \cdot \left(\left(\cos x - \cos y\right) \cdot \left(\sqrt{2} \cdot -0.0625\right)\right)}{3 \cdot \left(\left(1 + \cos x \cdot \frac{\sqrt{5} + -1}{2}\right) + \cos y \cdot \frac{3 - \sqrt{5}}{2}\right)}\\ \mathbf{elif}\;x \leq 1.8 \cdot 10^{-6}:\\ \;\;\;\;\frac{\mathsf{fma}\left(\sin y - \frac{\sin x}{16}, \left(\sqrt{2} \cdot \left(1 - \cos y\right)\right) \cdot \left(x + \sin y \cdot -0.0625\right), 2\right)}{3 \cdot \left(0.5 + \left(\sqrt{5} \cdot 0.5 + \cos y \cdot \left(1.5 + \sqrt{5} \cdot -0.5\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2 + \sqrt{2} \cdot \left(\left(\sin y + \sin x \cdot -0.0625\right) \cdot \left(\sin x \cdot \left(\cos x + -1\right)\right)\right)}{3 + \left(\frac{\cos x}{0.16666666666666666 + \sqrt{5} \cdot 0.16666666666666666} + 1.5 \cdot \left(\cos y \cdot \frac{4}{3 + \sqrt{5}}\right)\right)}\\ \end{array} \]
Alternative 7
Error19.86%
Cost59976
\[\begin{array}{l} t_0 := 3 - \sqrt{5}\\ t_1 := {\sin x}^{2}\\ \mathbf{if}\;x \leq -8.2 \cdot 10^{-5}:\\ \;\;\;\;\frac{2 + t_1 \cdot \left(\left(\cos x - \cos y\right) \cdot \left(\sqrt{2} \cdot -0.0625\right)\right)}{3 \cdot \left(\left(1 + \cos x \cdot \frac{\sqrt{5} + -1}{2}\right) + \cos y \cdot \frac{t_0}{2}\right)}\\ \mathbf{elif}\;x \leq 1.8 \cdot 10^{-6}:\\ \;\;\;\;\frac{\mathsf{fma}\left(\sin y - \frac{\sin x}{16}, \left(\sqrt{2} \cdot \left(1 - \cos y\right)\right) \cdot \left(x + \sin y \cdot -0.0625\right), 2\right)}{3 \cdot \left(0.5 + \left(\sqrt{5} \cdot 0.5 + \cos y \cdot \left(1.5 + \sqrt{5} \cdot -0.5\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2 + -0.0625 \cdot \left(\sqrt{2} \cdot \left(t_1 \cdot \left(\cos x + -1\right)\right)\right)}{3 + \left(\frac{\cos x}{0.16666666666666666 + \sqrt{5} \cdot 0.16666666666666666} + 1.5 \cdot \left(\cos y \cdot t_0\right)\right)}\\ \end{array} \]
Alternative 8
Error19.97%
Cost59780
\[\begin{array}{l} t_0 := 3 - \sqrt{5}\\ t_1 := 1.5 \cdot \left(\cos y \cdot t_0\right)\\ t_2 := {\sin x}^{2}\\ t_3 := 0.16666666666666666 + \sqrt{5} \cdot 0.16666666666666666\\ \mathbf{if}\;x \leq -2 \cdot 10^{-5}:\\ \;\;\;\;\frac{2 + t_2 \cdot \left(\left(\cos x - \cos y\right) \cdot \left(\sqrt{2} \cdot -0.0625\right)\right)}{3 \cdot \left(\left(1 + \cos x \cdot \frac{\sqrt{5} + -1}{2}\right) + \cos y \cdot \frac{t_0}{2}\right)}\\ \mathbf{elif}\;x \leq 1.6 \cdot 10^{-6}:\\ \;\;\;\;\frac{2 + -0.0625 \cdot \left(\sqrt{2} \cdot \left(\left(1 - \cos y\right) \cdot {\sin y}^{2}\right)\right)}{\frac{1}{t_3} + \left(3 + t_1\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2 + -0.0625 \cdot \left(\sqrt{2} \cdot \left(t_2 \cdot \left(\cos x + -1\right)\right)\right)}{3 + \left(\frac{\cos x}{t_3} + t_1\right)}\\ \end{array} \]
Alternative 9
Error20.41%
Cost53513
\[\begin{array}{l} t_0 := \frac{\cos x}{0.16666666666666666 + \sqrt{5} \cdot 0.16666666666666666}\\ \mathbf{if}\;y \leq -0.00065 \lor \neg \left(y \leq 5.6 \cdot 10^{-30}\right):\\ \;\;\;\;\frac{2 + \sqrt{2} \cdot \left(-0.0625 \cdot \left(\left(1 - \cos y\right) \cdot {\sin y}^{2}\right)\right)}{3 + \left(t_0 + 1.5 \cdot \left(\cos y \cdot \left(3 - \sqrt{5}\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2 + -0.0625 \cdot \left({\sin x}^{2} \cdot \left(\sqrt{2} \cdot \left(\cos x + -1\right)\right)\right)}{3 + \left(t_0 + 1.5 \cdot \left(\cos y \cdot \frac{4}{3 + \sqrt{5}}\right)\right)}\\ \end{array} \]
Alternative 10
Error19.95%
Cost53385
\[\begin{array}{l} t_0 := 1.5 \cdot \left(\cos y \cdot \left(3 - \sqrt{5}\right)\right)\\ t_1 := 0.16666666666666666 + \sqrt{5} \cdot 0.16666666666666666\\ \mathbf{if}\;x \leq -6.9 \cdot 10^{-6} \lor \neg \left(x \leq 1.75 \cdot 10^{-6}\right):\\ \;\;\;\;\frac{2 + -0.0625 \cdot \left(\sqrt{2} \cdot \left({\sin x}^{2} \cdot \left(\cos x + -1\right)\right)\right)}{3 + \left(\frac{\cos x}{t_1} + t_0\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2 + -0.0625 \cdot \left(\sqrt{2} \cdot \left(\left(1 - \cos y\right) \cdot {\sin y}^{2}\right)\right)}{\frac{1}{t_1} + \left(3 + t_0\right)}\\ \end{array} \]
Alternative 11
Error20.42%
Cost53385
\[\begin{array}{l} t_0 := 3 + \left(\frac{\cos x}{0.16666666666666666 + \sqrt{5} \cdot 0.16666666666666666} + 1.5 \cdot \left(\cos y \cdot \left(3 - \sqrt{5}\right)\right)\right)\\ \mathbf{if}\;y \leq -0.00076 \lor \neg \left(y \leq 5.6 \cdot 10^{-30}\right):\\ \;\;\;\;\frac{2 + \sqrt{2} \cdot \left(-0.0625 \cdot \left(\left(1 - \cos y\right) \cdot {\sin y}^{2}\right)\right)}{t_0}\\ \mathbf{else}:\\ \;\;\;\;\frac{2 + -0.0625 \cdot \left(\sqrt{2} \cdot \left({\sin x}^{2} \cdot \left(\cos x + -1\right)\right)\right)}{t_0}\\ \end{array} \]
Alternative 12
Error20.5%
Cost47433
\[\begin{array}{l} t_0 := 3 - \sqrt{5}\\ \mathbf{if}\;y \leq -1.16 \cdot 10^{-6} \lor \neg \left(y \leq 5.6 \cdot 10^{-30}\right):\\ \;\;\;\;\frac{2 + -0.0625 \cdot \left(\left(\sqrt{2} \cdot \left(1 - \cos y\right)\right) \cdot \left(0.5 - \frac{\cos \left(y + y\right)}{2}\right)\right)}{3 \cdot \left(\left(1 + \cos x \cdot \frac{\sqrt{5} + -1}{2}\right) + \cos y \cdot \frac{t_0}{2}\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2 + -0.0625 \cdot \left(\sqrt{2} \cdot \left({\sin x}^{2} \cdot \left(\cos x + -1\right)\right)\right)}{3 + \left(\frac{\cos x}{0.16666666666666666 + \sqrt{5} \cdot 0.16666666666666666} + 1.5 \cdot t_0\right)}\\ \end{array} \]
Alternative 13
Error20.48%
Cost46985
\[\begin{array}{l} t_0 := 3 - \sqrt{5}\\ t_1 := 0.16666666666666666 + \sqrt{5} \cdot 0.16666666666666666\\ \mathbf{if}\;x \leq -4.3 \cdot 10^{-6} \lor \neg \left(x \leq 1.8 \cdot 10^{-6}\right):\\ \;\;\;\;\frac{2 + -0.0625 \cdot \left(\sqrt{2} \cdot \left({\sin x}^{2} \cdot \left(\cos x + -1\right)\right)\right)}{3 + \left(\frac{\cos x}{t_1} + 1.5 \cdot t_0\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2 + -0.0625 \cdot \left(\sqrt{2} \cdot \left(\left(1 - \cos y\right) \cdot {\sin y}^{2}\right)\right)}{\frac{1}{t_1} + \left(3 + 1.5 \cdot \left(\cos y \cdot t_0\right)\right)}\\ \end{array} \]
Alternative 14
Error37.94%
Cost46857
\[\begin{array}{l} \mathbf{if}\;x \leq -6 \cdot 10^{-7} \lor \neg \left(x \leq 2.3 \cdot 10^{-7}\right):\\ \;\;\;\;\frac{2 + -0.0625 \cdot \left(\sqrt{2} \cdot \left({\sin x}^{2} \cdot \left(\cos x + -1\right)\right)\right)}{3 + \left(\frac{\cos x}{0.16666666666666666 + \sqrt{5} \cdot 0.16666666666666666} + 1.5 \cdot \left(3 - \sqrt{5}\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{0.6666666666666666}{0.5 + \mathsf{fma}\left(\mathsf{fma}\left(-0.5, \sqrt{5}, 1.5\right), \cos y, \sqrt{5} \cdot 0.5\right)}\\ \end{array} \]
Alternative 15
Error55.13%
Cost40776
\[\begin{array}{l} t_0 := \sqrt{5} \cdot 0.5\\ \mathbf{if}\;y \leq -2.55 \cdot 10^{-8}:\\ \;\;\;\;\frac{0.6666666666666666}{0.5 + \mathsf{fma}\left(\mathsf{fma}\left(-0.5, \sqrt{5}, 1.5\right), \cos y, t_0\right)}\\ \mathbf{elif}\;y \leq 1.9:\\ \;\;\;\;\frac{2 + -0.0625 \cdot \left(\left(\sqrt{2} \cdot \left(1 - \cos y\right)\right) \cdot \left(y \cdot y\right)\right)}{3 \cdot \left(\left(1 + \cos x \cdot \frac{\sqrt{5} + -1}{2}\right) + \cos y \cdot \frac{3 - \sqrt{5}}{2}\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{0.6666666666666666}{0.5 + \left(t_0 + \cos y \cdot \left(1.5 + \sqrt{5} \cdot -0.5\right)\right)}\\ \end{array} \]
Alternative 16
Error55.13%
Cost40776
\[\begin{array}{l} t_0 := \sqrt{5} \cdot 0.5\\ \mathbf{if}\;y \leq -2.55 \cdot 10^{-8}:\\ \;\;\;\;\frac{0.6666666666666666}{0.5 + \mathsf{fma}\left(\mathsf{fma}\left(-0.5, \sqrt{5}, 1.5\right), \cos y, t_0\right)}\\ \mathbf{elif}\;y \leq 1.9:\\ \;\;\;\;\frac{2 + -0.0625 \cdot \left(\left(\sqrt{2} \cdot \left(1 - \cos y\right)\right) \cdot \left(y \cdot y\right)\right)}{3 \cdot \left(\cos y \cdot \frac{3 - \sqrt{5}}{2} + \left(1 + \frac{2 \cdot \cos x}{\sqrt{5} + 1}\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{0.6666666666666666}{0.5 + \left(t_0 + \cos y \cdot \left(1.5 + \sqrt{5} \cdot -0.5\right)\right)}\\ \end{array} \]
Alternative 17
Error55.13%
Cost34504
\[\begin{array}{l} t_0 := \sqrt{5} \cdot 0.5\\ \mathbf{if}\;y \leq -2.55 \cdot 10^{-8}:\\ \;\;\;\;\frac{0.6666666666666666}{0.5 + \mathsf{fma}\left(\mathsf{fma}\left(-0.5, \sqrt{5}, 1.5\right), \cos y, t_0\right)}\\ \mathbf{elif}\;y \leq 1.5:\\ \;\;\;\;\frac{2 + -0.0625 \cdot \left(\left(y \cdot y\right) \cdot \left(\left(\sqrt{2} \cdot y\right) \cdot \left(y \cdot 0.5\right)\right)\right)}{3 \cdot \left(\left(1 + \cos x \cdot \frac{\sqrt{5} + -1}{2}\right) + \cos y \cdot \frac{3 - \sqrt{5}}{2}\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{0.6666666666666666}{0.5 + \left(t_0 + \cos y \cdot \left(1.5 + \sqrt{5} \cdot -0.5\right)\right)}\\ \end{array} \]
Alternative 18
Error57.31%
Cost32704
\[\frac{0.6666666666666666}{0.5 + \mathsf{fma}\left(\mathsf{fma}\left(-0.5, \sqrt{5}, 1.5\right), \cos y, \sqrt{5} \cdot 0.5\right)} \]
Alternative 19
Error57.31%
Cost20160
\[\frac{0.6666666666666666}{0.5 + \left(\sqrt{5} \cdot 0.5 + \cos y \cdot \left(1.5 + \sqrt{5} \cdot -0.5\right)\right)} \]

Error

Reproduce?

herbie shell --seed 2023125 
(FPCore (x y)
  :name "Diagrams.TwoD.Path.Metafont.Internal:hobbyF from diagrams-contrib-1.3.0.5"
  :precision binary64
  (/ (+ 2.0 (* (* (* (sqrt 2.0) (- (sin x) (/ (sin y) 16.0))) (- (sin y) (/ (sin x) 16.0))) (- (cos x) (cos y)))) (* 3.0 (+ (+ 1.0 (* (/ (- (sqrt 5.0) 1.0) 2.0) (cos x))) (* (/ (- 3.0 (sqrt 5.0)) 2.0) (cos y))))))