Average Error: 0.1 → 0.1
Time: 22.0s
Precision: 64
\[0.9549296585513720181381813745247200131416 \cdot x - 0.1290061377327979819096270830414141528308 \cdot \left(\left(x \cdot x\right) \cdot x\right)\]
\[x \cdot 0.9549296585513720181381813745247200131416 + \left(-0.1290061377327979819096270830414141528308 \cdot {x}^{3}\right)\]
0.9549296585513720181381813745247200131416 \cdot x - 0.1290061377327979819096270830414141528308 \cdot \left(\left(x \cdot x\right) \cdot x\right)
x \cdot 0.9549296585513720181381813745247200131416 + \left(-0.1290061377327979819096270830414141528308 \cdot {x}^{3}\right)
double f(double x) {
        double r17519 = 0.954929658551372;
        double r17520 = x;
        double r17521 = r17519 * r17520;
        double r17522 = 0.12900613773279798;
        double r17523 = r17520 * r17520;
        double r17524 = r17523 * r17520;
        double r17525 = r17522 * r17524;
        double r17526 = r17521 - r17525;
        return r17526;
}

double f(double x) {
        double r17527 = x;
        double r17528 = 0.954929658551372;
        double r17529 = r17527 * r17528;
        double r17530 = 0.12900613773279798;
        double r17531 = 3.0;
        double r17532 = pow(r17527, r17531);
        double r17533 = r17530 * r17532;
        double r17534 = -r17533;
        double r17535 = r17529 + r17534;
        return r17535;
}

Error

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.1

    \[0.9549296585513720181381813745247200131416 \cdot x - 0.1290061377327979819096270830414141528308 \cdot \left(\left(x \cdot x\right) \cdot x\right)\]
  2. Simplified0.1

    \[\leadsto \color{blue}{x \cdot \left(0.9549296585513720181381813745247200131416 - 0.1290061377327979819096270830414141528308 \cdot \left(x \cdot x\right)\right)}\]
  3. Using strategy rm
  4. Applied sub-neg0.1

    \[\leadsto x \cdot \color{blue}{\left(0.9549296585513720181381813745247200131416 + \left(-0.1290061377327979819096270830414141528308 \cdot \left(x \cdot x\right)\right)\right)}\]
  5. Applied distribute-lft-in0.1

    \[\leadsto \color{blue}{x \cdot 0.9549296585513720181381813745247200131416 + x \cdot \left(-0.1290061377327979819096270830414141528308 \cdot \left(x \cdot x\right)\right)}\]
  6. Simplified0.1

    \[\leadsto x \cdot 0.9549296585513720181381813745247200131416 + \color{blue}{\left(-0.1290061377327979819096270830414141528308 \cdot {x}^{3}\right)}\]
  7. Final simplification0.1

    \[\leadsto x \cdot 0.9549296585513720181381813745247200131416 + \left(-0.1290061377327979819096270830414141528308 \cdot {x}^{3}\right)\]

Reproduce

herbie shell --seed 2019326 +o rules:numerics
(FPCore (x)
  :name "Rosa's Benchmark"
  :precision binary64
  (- (* 0.954929658551372 x) (* 0.12900613773279798 (* (* x x) x))))