Average Error: 0.0 → 0.0
Time: 11.7s
Precision: 64
\[e^{-\left(1 - x \cdot x\right)}\]
\[{\left(e^{-1}\right)}^{\left(1 - x \cdot x\right)}\]
e^{-\left(1 - x \cdot x\right)}
{\left(e^{-1}\right)}^{\left(1 - x \cdot x\right)}
double f(double x) {
        double r22733 = 1.0;
        double r22734 = x;
        double r22735 = r22734 * r22734;
        double r22736 = r22733 - r22735;
        double r22737 = -r22736;
        double r22738 = exp(r22737);
        return r22738;
}

double f(double x) {
        double r22739 = -1.0;
        double r22740 = exp(r22739);
        double r22741 = 1.0;
        double r22742 = x;
        double r22743 = r22742 * r22742;
        double r22744 = r22741 - r22743;
        double r22745 = pow(r22740, r22744);
        return r22745;
}

Error

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.0

    \[e^{-\left(1 - x \cdot x\right)}\]
  2. Using strategy rm
  3. Applied neg-mul-10.0

    \[\leadsto e^{\color{blue}{-1 \cdot \left(1 - x \cdot x\right)}}\]
  4. Applied exp-prod0.0

    \[\leadsto \color{blue}{{\left(e^{-1}\right)}^{\left(1 - x \cdot x\right)}}\]
  5. Final simplification0.0

    \[\leadsto {\left(e^{-1}\right)}^{\left(1 - x \cdot x\right)}\]

Reproduce

herbie shell --seed 2019305 
(FPCore (x)
  :name "exp neg sub"
  :precision binary64
  (exp (- (- 1 (* x x)))))