Average Error: 0.0 → 0.6
Time: 4.3s
Precision: 64
\[\sin x \cdot \frac{\sinh y}{y}\]
\[\sin x \cdot \frac{\mathsf{fma}\left(\frac{1}{6}, {y}^{3}, \mathsf{fma}\left(\frac{1}{120}, {y}^{5}, y\right)\right)}{y}\]
\sin x \cdot \frac{\sinh y}{y}
\sin x \cdot \frac{\mathsf{fma}\left(\frac{1}{6}, {y}^{3}, \mathsf{fma}\left(\frac{1}{120}, {y}^{5}, y\right)\right)}{y}
double f(double x, double y) {
        double r120659 = x;
        double r120660 = sin(r120659);
        double r120661 = y;
        double r120662 = sinh(r120661);
        double r120663 = r120662 / r120661;
        double r120664 = r120660 * r120663;
        return r120664;
}

double f(double x, double y) {
        double r120665 = x;
        double r120666 = sin(r120665);
        double r120667 = 0.16666666666666666;
        double r120668 = y;
        double r120669 = 3.0;
        double r120670 = pow(r120668, r120669);
        double r120671 = 0.008333333333333333;
        double r120672 = 5.0;
        double r120673 = pow(r120668, r120672);
        double r120674 = fma(r120671, r120673, r120668);
        double r120675 = fma(r120667, r120670, r120674);
        double r120676 = r120675 / r120668;
        double r120677 = r120666 * r120676;
        return r120677;
}

Error

Bits error versus x

Bits error versus y

Derivation

  1. Initial program 0.0

    \[\sin x \cdot \frac{\sinh y}{y}\]
  2. Taylor expanded around 0 0.6

    \[\leadsto \sin x \cdot \frac{\color{blue}{\frac{1}{6} \cdot {y}^{3} + \left(\frac{1}{120} \cdot {y}^{5} + y\right)}}{y}\]
  3. Simplified0.6

    \[\leadsto \sin x \cdot \frac{\color{blue}{\mathsf{fma}\left(\frac{1}{6}, {y}^{3}, \mathsf{fma}\left(\frac{1}{120}, {y}^{5}, y\right)\right)}}{y}\]
  4. Final simplification0.6

    \[\leadsto \sin x \cdot \frac{\mathsf{fma}\left(\frac{1}{6}, {y}^{3}, \mathsf{fma}\left(\frac{1}{120}, {y}^{5}, y\right)\right)}{y}\]

Reproduce

herbie shell --seed 2020025 +o rules:numerics
(FPCore (x y)
  :name "Linear.Quaternion:$ccos from linear-1.19.1.3"
  :precision binary64
  (* (sin x) (/ (sinh y) y)))