Average Error: 0.1 → 0
Time: 7.2s
Precision: 64
\[\left(\left(d1 \cdot d1\right) \cdot d1\right) \cdot d1\]
\[{d1}^{4}\]
\left(\left(d1 \cdot d1\right) \cdot d1\right) \cdot d1
{d1}^{4}
double f(double d1) {
        double r10587704 = d1;
        double r10587705 = r10587704 * r10587704;
        double r10587706 = r10587705 * r10587704;
        double r10587707 = r10587706 * r10587704;
        return r10587707;
}

double f(double d1) {
        double r10587708 = d1;
        double r10587709 = 4.0;
        double r10587710 = pow(r10587708, r10587709);
        return r10587710;
}

Error

Bits error versus d1

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original0.1
Target0
Herbie0
\[{d1}^{4}\]

Derivation

  1. Initial program 0.1

    \[\left(\left(d1 \cdot d1\right) \cdot d1\right) \cdot d1\]
  2. Using strategy rm
  3. Applied pow30.1

    \[\leadsto \color{blue}{{d1}^{3}} \cdot d1\]
  4. Applied pow-plus0

    \[\leadsto \color{blue}{{d1}^{\left(3 + 1\right)}}\]
  5. Simplified0

    \[\leadsto {d1}^{\color{blue}{4}}\]
  6. Final simplification0

    \[\leadsto {d1}^{4}\]

Reproduce

herbie shell --seed 2019142 +o rules:numerics
(FPCore (d1)
  :name "FastMath repmul"

  :herbie-target
  (pow d1 4)

  (* (* (* d1 d1) d1) d1))