Average Error: 0.0 → 0.0
Time: 19.9s
Precision: 64
\[e^{\log 2 \cdot x + \left(\pi \cdot x\right) \cdot i}\]
\[e^{\left(\pi \cdot i + \log 2\right) \cdot x}\]
e^{\log 2 \cdot x + \left(\pi \cdot x\right) \cdot i}
e^{\left(\pi \cdot i + \log 2\right) \cdot x}
double f(double x, double i) {
        double r57583702 = 2.0;
        double r57583703 = log(r57583702);
        double r57583704 = x;
        double r57583705 = r57583703 * r57583704;
        double r57583706 = atan2(1.0, 0.0);
        double r57583707 = r57583706 * r57583704;
        double r57583708 = i;
        double r57583709 = r57583707 * r57583708;
        double r57583710 = r57583705 + r57583709;
        double r57583711 = exp(r57583710);
        return r57583711;
}

double f(double x, double i) {
        double r57583712 = atan2(1.0, 0.0);
        double r57583713 = i;
        double r57583714 = r57583712 * r57583713;
        double r57583715 = 2.0;
        double r57583716 = log(r57583715);
        double r57583717 = r57583714 + r57583716;
        double r57583718 = x;
        double r57583719 = r57583717 * r57583718;
        double r57583720 = exp(r57583719);
        return r57583720;
}

Error

Bits error versus x

Bits error versus i

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.0

    \[e^{\log 2 \cdot x + \left(\pi \cdot x\right) \cdot i}\]
  2. Simplified0.0

    \[\leadsto \color{blue}{e^{\left(i \cdot \pi + \log 2\right) \cdot x}}\]
  3. Final simplification0.0

    \[\leadsto e^{\left(\pi \cdot i + \log 2\right) \cdot x}\]

Reproduce

herbie shell --seed 1 
(FPCore (x i)
  :name "exp(log(2)*x + PI*x*i)"
  (exp (+ (* (log 2.0) x) (* (* PI x) i))))