Average Error: 0.1 → 0.1
Time: 22.4s
Precision: 64
\[\cosh x \cdot \frac{\sin y}{y}\]
\[\mathsf{expm1}\left(\mathsf{log1p}\left(\frac{\sin y}{y}\right)\right) \cdot \cosh x\]
\cosh x \cdot \frac{\sin y}{y}
\mathsf{expm1}\left(\mathsf{log1p}\left(\frac{\sin y}{y}\right)\right) \cdot \cosh x
double f(double x, double y) {
        double r20538639 = x;
        double r20538640 = cosh(r20538639);
        double r20538641 = y;
        double r20538642 = sin(r20538641);
        double r20538643 = r20538642 / r20538641;
        double r20538644 = r20538640 * r20538643;
        return r20538644;
}

double f(double x, double y) {
        double r20538645 = y;
        double r20538646 = sin(r20538645);
        double r20538647 = r20538646 / r20538645;
        double r20538648 = log1p(r20538647);
        double r20538649 = expm1(r20538648);
        double r20538650 = x;
        double r20538651 = cosh(r20538650);
        double r20538652 = r20538649 * r20538651;
        return r20538652;
}

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.1
Target0.1
Herbie0.1
\[\frac{\cosh x \cdot \sin y}{y}\]

Derivation

  1. Initial program 0.1

    \[\cosh x \cdot \frac{\sin y}{y}\]
  2. Using strategy rm
  3. Applied expm1-log1p-u0.1

    \[\leadsto \cosh x \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\frac{\sin y}{y}\right)\right)}\]
  4. Final simplification0.1

    \[\leadsto \mathsf{expm1}\left(\mathsf{log1p}\left(\frac{\sin y}{y}\right)\right) \cdot \cosh x\]

Reproduce

herbie shell --seed 2019172 +o rules:numerics
(FPCore (x y)
  :name "Linear.Quaternion:$csinh from linear-1.19.1.3"

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

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