Average Error: 14.2 → 0.1
Time: 3.8s
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 r496746 = x;
        double r496747 = sin(r496746);
        double r496748 = y;
        double r496749 = sinh(r496748);
        double r496750 = r496747 * r496749;
        double r496751 = r496750 / r496746;
        return r496751;
}

double f(double x, double y) {
        double r496752 = 1.0;
        double r496753 = x;
        double r496754 = sin(r496753);
        double r496755 = r496753 / r496754;
        double r496756 = r496752 / r496755;
        double r496757 = y;
        double r496758 = sinh(r496757);
        double r496759 = r496756 * r496758;
        return r496759;
}

Error

Bits error versus x

Bits error versus y

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

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

Derivation

  1. Initial program 14.2

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

    \[\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 2020062 +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))