Average Error: 0.1 → 0.1
Time: 14.4s
Precision: 64
\[0.9549296585513720181381813745247200131416 \cdot x - 0.1290061377327979819096270830414141528308 \cdot \left(\left(x \cdot x\right) \cdot x\right)\]
\[x \cdot 0.9549296585513720181381813745247200131416 + \left(-{x}^{3} \cdot 0.1290061377327979819096270830414141528308\right)\]
0.9549296585513720181381813745247200131416 \cdot x - 0.1290061377327979819096270830414141528308 \cdot \left(\left(x \cdot x\right) \cdot x\right)
x \cdot 0.9549296585513720181381813745247200131416 + \left(-{x}^{3} \cdot 0.1290061377327979819096270830414141528308\right)
double f(double x) {
        double r19504 = 0.954929658551372;
        double r19505 = x;
        double r19506 = r19504 * r19505;
        double r19507 = 0.12900613773279798;
        double r19508 = r19505 * r19505;
        double r19509 = r19508 * r19505;
        double r19510 = r19507 * r19509;
        double r19511 = r19506 - r19510;
        return r19511;
}

double f(double x) {
        double r19512 = x;
        double r19513 = 0.954929658551372;
        double r19514 = r19512 * r19513;
        double r19515 = 3.0;
        double r19516 = pow(r19512, r19515);
        double r19517 = 0.12900613773279798;
        double r19518 = r19516 * r19517;
        double r19519 = -r19518;
        double r19520 = r19514 + r19519;
        return r19520;
}

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(-{x}^{3} \cdot 0.1290061377327979819096270830414141528308\right)}\]
  7. Final simplification0.1

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

Reproduce

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