Average Error: 0.0 → 0.1
Time: 1.9s
Precision: 64
\[e^{\left(x \cdot y\right) \cdot y}\]
\[\mathsf{log1p}\left(\mathsf{expm1}\left(e^{\left(x \cdot y\right) \cdot y}\right)\right)\]
e^{\left(x \cdot y\right) \cdot y}
\mathsf{log1p}\left(\mathsf{expm1}\left(e^{\left(x \cdot y\right) \cdot y}\right)\right)
double f(double x, double y) {
        double r221641 = x;
        double r221642 = y;
        double r221643 = r221641 * r221642;
        double r221644 = r221643 * r221642;
        double r221645 = exp(r221644);
        return r221645;
}

double f(double x, double y) {
        double r221646 = x;
        double r221647 = y;
        double r221648 = r221646 * r221647;
        double r221649 = r221648 * r221647;
        double r221650 = exp(r221649);
        double r221651 = expm1(r221650);
        double r221652 = log1p(r221651);
        return r221652;
}

Error

Bits error versus x

Bits error versus y

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.0

    \[e^{\left(x \cdot y\right) \cdot y}\]
  2. Using strategy rm
  3. Applied log1p-expm1-u0.1

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

    \[\leadsto \mathsf{log1p}\left(\mathsf{expm1}\left(e^{\left(x \cdot y\right) \cdot y}\right)\right)\]

Reproduce

herbie shell --seed 2020046 +o rules:numerics
(FPCore (x y)
  :name "Data.Random.Distribution.Normal:normalF from random-fu-0.2.6.2"
  :precision binary64
  (exp (* (* x y) y)))