Average Error: 13.4 → 0.1
Time: 4.5s
Precision: 64
\[\frac{\sin x \cdot \sinh y}{x}\]
\[\frac{1}{\frac{x}{\sin x}} \cdot \sinh y\]
\frac{\sin x \cdot \sinh y}{x}
\frac{1}{\frac{x}{\sin x}} \cdot \sinh y
double f(double x, double y) {
        double r502824 = x;
        double r502825 = sin(r502824);
        double r502826 = y;
        double r502827 = sinh(r502826);
        double r502828 = r502825 * r502827;
        double r502829 = r502828 / r502824;
        return r502829;
}

double f(double x, double y) {
        double r502830 = 1.0;
        double r502831 = x;
        double r502832 = sin(r502831);
        double r502833 = r502831 / r502832;
        double r502834 = r502830 / r502833;
        double r502835 = y;
        double r502836 = sinh(r502835);
        double r502837 = r502834 * r502836;
        return r502837;
}

Error

Bits error versus x

Bits error versus y

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original13.4
Target0.2
Herbie0.1
\[\sin x \cdot \frac{\sinh y}{x}\]

Derivation

  1. Initial program 13.4

    \[\frac{\sin x \cdot \sinh y}{x}\]
  2. Using strategy rm
  3. Applied associate-/l*0.7

    \[\leadsto \color{blue}{\frac{\sin x}{\frac{x}{\sinh y}}}\]
  4. Using strategy rm
  5. Applied associate-/r/0.1

    \[\leadsto \color{blue}{\frac{\sin x}{x} \cdot \sinh y}\]
  6. Using strategy rm
  7. Applied clear-num0.1

    \[\leadsto \color{blue}{\frac{1}{\frac{x}{\sin x}}} \cdot \sinh y\]
  8. Final simplification0.1

    \[\leadsto \frac{1}{\frac{x}{\sin x}} \cdot \sinh y\]

Reproduce

herbie shell --seed 2019353 +o rules:numerics
(FPCore (x y)
  :name "Linear.Quaternion:$ccosh from linear-1.19.1.3"
  :precision binary64

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

  (/ (* (sin x) (sinh y)) x))