Average Error: 0.2 → 0.2
Time: 8.2s
Precision: binary64
\[\cosh x \cdot \frac{\sin y}{y}\]
\[\frac{0.5 \cdot \left(e^{x} \cdot \sin y\right) + 0.5 \cdot \left(\sin y \cdot e^{-x}\right)}{y}\]
\cosh x \cdot \frac{\sin y}{y}
\frac{0.5 \cdot \left(e^{x} \cdot \sin y\right) + 0.5 \cdot \left(\sin y \cdot e^{-x}\right)}{y}
(FPCore (x y) :precision binary64 (* (cosh x) (/ (sin y) y)))
(FPCore (x y)
 :precision binary64
 (/ (+ (* 0.5 (* (exp x) (sin y))) (* 0.5 (* (sin y) (exp (- x))))) y))
double code(double x, double y) {
	return cosh(x) * (sin(y) / y);
}
double code(double x, double y) {
	return ((0.5 * (exp(x) * sin(y))) + (0.5 * (sin(y) * exp(-x)))) / y;
}

Error

Bits error versus x

Bits error versus y

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original0.2
Target0.2
Herbie0.2
\[\frac{\cosh x \cdot \sin y}{y}\]

Derivation

  1. Initial program 0.2

    \[\cosh x \cdot \frac{\sin y}{y}\]
  2. Using strategy rm
  3. Applied associate-*r/_binary64_150240.2

    \[\leadsto \color{blue}{\frac{\cosh x \cdot \sin y}{y}}\]
  4. Simplified0.2

    \[\leadsto \frac{\color{blue}{\sin y \cdot \cosh x}}{y}\]
  5. Taylor expanded around inf 0.2

    \[\leadsto \color{blue}{\frac{0.5 \cdot \left(e^{x} \cdot \sin y\right) + 0.5 \cdot \left(e^{-x} \cdot \sin y\right)}{y}}\]
  6. Final simplification0.2

    \[\leadsto \frac{0.5 \cdot \left(e^{x} \cdot \sin y\right) + 0.5 \cdot \left(\sin y \cdot e^{-x}\right)}{y}\]

Reproduce

herbie shell --seed 2021015 
(FPCore (x y)
  :name "Linear.Quaternion:$csinh from linear-1.19.1.3"
  :precision binary64

  :herbie-target
  (/ (* (cosh x) (sin y)) y)

  (* (cosh x) (/ (sin y) y)))