Average Error: 0.0 → 0.0
Time: 2.5s
Precision: 64
\[x \cdot e^{y \cdot y}\]
\[\left(x \cdot {\left(e^{y}\right)}^{\left(\frac{y}{2}\right)}\right) \cdot \sqrt{e^{y \cdot y}}\]
x \cdot e^{y \cdot y}
\left(x \cdot {\left(e^{y}\right)}^{\left(\frac{y}{2}\right)}\right) \cdot \sqrt{e^{y \cdot y}}
double f(double x, double y) {
        double r660161 = x;
        double r660162 = y;
        double r660163 = r660162 * r660162;
        double r660164 = exp(r660163);
        double r660165 = r660161 * r660164;
        return r660165;
}

double f(double x, double y) {
        double r660166 = x;
        double r660167 = y;
        double r660168 = exp(r660167);
        double r660169 = 2.0;
        double r660170 = r660167 / r660169;
        double r660171 = pow(r660168, r660170);
        double r660172 = r660166 * r660171;
        double r660173 = r660167 * r660167;
        double r660174 = exp(r660173);
        double r660175 = sqrt(r660174);
        double r660176 = r660172 * r660175;
        return r660176;
}

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.0
Target0.0
Herbie0.0
\[x \cdot {\left(e^{y}\right)}^{y}\]

Derivation

  1. Initial program 0.0

    \[x \cdot e^{y \cdot y}\]
  2. Using strategy rm
  3. Applied add-sqr-sqrt0.1

    \[\leadsto x \cdot \color{blue}{\left(\sqrt{e^{y \cdot y}} \cdot \sqrt{e^{y \cdot y}}\right)}\]
  4. Applied associate-*r*0.1

    \[\leadsto \color{blue}{\left(x \cdot \sqrt{e^{y \cdot y}}\right) \cdot \sqrt{e^{y \cdot y}}}\]
  5. Using strategy rm
  6. Applied add-log-exp0.1

    \[\leadsto \left(x \cdot \sqrt{e^{\color{blue}{\log \left(e^{y}\right)} \cdot y}}\right) \cdot \sqrt{e^{y \cdot y}}\]
  7. Applied exp-to-pow0.0

    \[\leadsto \left(x \cdot \sqrt{\color{blue}{{\left(e^{y}\right)}^{y}}}\right) \cdot \sqrt{e^{y \cdot y}}\]
  8. Applied sqrt-pow10.0

    \[\leadsto \left(x \cdot \color{blue}{{\left(e^{y}\right)}^{\left(\frac{y}{2}\right)}}\right) \cdot \sqrt{e^{y \cdot y}}\]
  9. Final simplification0.0

    \[\leadsto \left(x \cdot {\left(e^{y}\right)}^{\left(\frac{y}{2}\right)}\right) \cdot \sqrt{e^{y \cdot y}}\]

Reproduce

herbie shell --seed 2020034 +o rules:numerics
(FPCore (x y)
  :name "Data.Number.Erf:$dmerfcx from erf-2.0.0.0"
  :precision binary64

  :herbie-target
  (* x (pow (exp y) y))

  (* x (exp (* y y))))