Average Error: 0.2 → 0.1
Time: 20.7s
Precision: 64
\[0.9549296585513720181381813745247200131416 \cdot x - 0.1290061377327979819096270830414141528308 \cdot \left(\left(x \cdot x\right) \cdot x\right)\]
\[\left(x \cdot 0.9549296585513720181381813745247200131416 - 0.1290061377327979819096270830414141528308 \cdot {x}^{3}\right) + 0 \cdot x\]
0.9549296585513720181381813745247200131416 \cdot x - 0.1290061377327979819096270830414141528308 \cdot \left(\left(x \cdot x\right) \cdot x\right)
\left(x \cdot 0.9549296585513720181381813745247200131416 - 0.1290061377327979819096270830414141528308 \cdot {x}^{3}\right) + 0 \cdot x
double f(double x) {
        double r21262 = 0.954929658551372;
        double r21263 = x;
        double r21264 = r21262 * r21263;
        double r21265 = 0.12900613773279798;
        double r21266 = r21263 * r21263;
        double r21267 = r21266 * r21263;
        double r21268 = r21265 * r21267;
        double r21269 = r21264 - r21268;
        return r21269;
}

double f(double x) {
        double r21270 = x;
        double r21271 = 0.954929658551372;
        double r21272 = r21270 * r21271;
        double r21273 = 0.12900613773279798;
        double r21274 = 3.0;
        double r21275 = pow(r21270, r21274);
        double r21276 = r21273 * r21275;
        double r21277 = r21272 - r21276;
        double r21278 = 0.0;
        double r21279 = r21278 * r21270;
        double r21280 = r21277 + r21279;
        return r21280;
}

Error

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.2

    \[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 add-cube-cbrt1.4

    \[\leadsto x \cdot \left(\color{blue}{\left(\sqrt[3]{0.9549296585513720181381813745247200131416} \cdot \sqrt[3]{0.9549296585513720181381813745247200131416}\right) \cdot \sqrt[3]{0.9549296585513720181381813745247200131416}} - 0.1290061377327979819096270830414141528308 \cdot \left(x \cdot x\right)\right)\]
  5. Applied prod-diff1.4

    \[\leadsto x \cdot \color{blue}{\left(\mathsf{fma}\left(\sqrt[3]{0.9549296585513720181381813745247200131416} \cdot \sqrt[3]{0.9549296585513720181381813745247200131416}, \sqrt[3]{0.9549296585513720181381813745247200131416}, -\left(x \cdot x\right) \cdot 0.1290061377327979819096270830414141528308\right) + \mathsf{fma}\left(-x \cdot x, 0.1290061377327979819096270830414141528308, \left(x \cdot x\right) \cdot 0.1290061377327979819096270830414141528308\right)\right)}\]
  6. Applied distribute-lft-in1.4

    \[\leadsto \color{blue}{x \cdot \mathsf{fma}\left(\sqrt[3]{0.9549296585513720181381813745247200131416} \cdot \sqrt[3]{0.9549296585513720181381813745247200131416}, \sqrt[3]{0.9549296585513720181381813745247200131416}, -\left(x \cdot x\right) \cdot 0.1290061377327979819096270830414141528308\right) + x \cdot \mathsf{fma}\left(-x \cdot x, 0.1290061377327979819096270830414141528308, \left(x \cdot x\right) \cdot 0.1290061377327979819096270830414141528308\right)}\]
  7. Simplified0.1

    \[\leadsto \color{blue}{\left(x \cdot 0.9549296585513720181381813745247200131416 - 0.1290061377327979819096270830414141528308 \cdot {x}^{3}\right)} + x \cdot \mathsf{fma}\left(-x \cdot x, 0.1290061377327979819096270830414141528308, \left(x \cdot x\right) \cdot 0.1290061377327979819096270830414141528308\right)\]
  8. Simplified0.1

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

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

Reproduce

herbie shell --seed 2019303 +o rules:numerics
(FPCore (x)
  :name "Rosa's Benchmark"
  :precision binary64
  (- (* 0.95492965855137202 x) (* 0.129006137732797982 (* (* x x) x))))