Average Error: 0.1 → 0.6
Time: 24.7s
Precision: 64
\[\sin x \cdot \frac{\sinh y}{y}\]
\[\mathsf{fma}\left(\sin x, \left(\left(\sqrt[3]{\mathsf{fma}\left(y \cdot y, \frac{1}{120}, \frac{1}{6}\right)} \cdot \left(\left(\sqrt[3]{\sqrt[3]{\mathsf{fma}\left(y \cdot y, \frac{1}{120}, \frac{1}{6}\right)}} \cdot \sqrt[3]{\sqrt[3]{\mathsf{fma}\left(y \cdot y, \frac{1}{120}, \frac{1}{6}\right)}}\right) \cdot \sqrt[3]{\sqrt[3]{\mathsf{fma}\left(y \cdot y, \frac{1}{120}, \frac{1}{6}\right)}}\right)\right) \cdot \sqrt[3]{\mathsf{fma}\left(y \cdot y, \frac{1}{120}, \frac{1}{6}\right)}\right) \cdot \left(y \cdot y\right), \sin x\right)\]
\sin x \cdot \frac{\sinh y}{y}
\mathsf{fma}\left(\sin x, \left(\left(\sqrt[3]{\mathsf{fma}\left(y \cdot y, \frac{1}{120}, \frac{1}{6}\right)} \cdot \left(\left(\sqrt[3]{\sqrt[3]{\mathsf{fma}\left(y \cdot y, \frac{1}{120}, \frac{1}{6}\right)}} \cdot \sqrt[3]{\sqrt[3]{\mathsf{fma}\left(y \cdot y, \frac{1}{120}, \frac{1}{6}\right)}}\right) \cdot \sqrt[3]{\sqrt[3]{\mathsf{fma}\left(y \cdot y, \frac{1}{120}, \frac{1}{6}\right)}}\right)\right) \cdot \sqrt[3]{\mathsf{fma}\left(y \cdot y, \frac{1}{120}, \frac{1}{6}\right)}\right) \cdot \left(y \cdot y\right), \sin x\right)
double f(double x, double y) {
        double r6574964 = x;
        double r6574965 = sin(r6574964);
        double r6574966 = y;
        double r6574967 = sinh(r6574966);
        double r6574968 = r6574967 / r6574966;
        double r6574969 = r6574965 * r6574968;
        return r6574969;
}

double f(double x, double y) {
        double r6574970 = x;
        double r6574971 = sin(r6574970);
        double r6574972 = y;
        double r6574973 = r6574972 * r6574972;
        double r6574974 = 0.008333333333333333;
        double r6574975 = 0.16666666666666666;
        double r6574976 = fma(r6574973, r6574974, r6574975);
        double r6574977 = cbrt(r6574976);
        double r6574978 = cbrt(r6574977);
        double r6574979 = r6574978 * r6574978;
        double r6574980 = r6574979 * r6574978;
        double r6574981 = r6574977 * r6574980;
        double r6574982 = r6574981 * r6574977;
        double r6574983 = r6574982 * r6574973;
        double r6574984 = fma(r6574971, r6574983, r6574971);
        return r6574984;
}

Error

Bits error versus x

Bits error versus y

Derivation

  1. Initial program 0.1

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

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

    \[\leadsto \sin x \cdot \color{blue}{\mathsf{fma}\left(\frac{1}{6}, y \cdot y, \mathsf{fma}\left(\frac{1}{120} \cdot \left(y \cdot y\right), y \cdot y, 1\right)\right)}\]
  4. Taylor expanded around inf 0.6

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

    \[\leadsto \color{blue}{\mathsf{fma}\left(\sin x, \left(y \cdot y\right) \cdot \mathsf{fma}\left(y \cdot y, \frac{1}{120}, \frac{1}{6}\right), \sin x\right)}\]
  6. Using strategy rm
  7. Applied add-cube-cbrt0.6

    \[\leadsto \mathsf{fma}\left(\sin x, \left(y \cdot y\right) \cdot \color{blue}{\left(\left(\sqrt[3]{\mathsf{fma}\left(y \cdot y, \frac{1}{120}, \frac{1}{6}\right)} \cdot \sqrt[3]{\mathsf{fma}\left(y \cdot y, \frac{1}{120}, \frac{1}{6}\right)}\right) \cdot \sqrt[3]{\mathsf{fma}\left(y \cdot y, \frac{1}{120}, \frac{1}{6}\right)}\right)}, \sin x\right)\]
  8. Using strategy rm
  9. Applied add-cube-cbrt0.6

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

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

Reproduce

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