Average Error: 0.1 → 0.1
Time: 34.6s
Precision: 64
\[0.9549296585513720181381813745247200131416 \cdot x - 0.1290061377327979819096270830414141528308 \cdot \left(\left(x \cdot x\right) \cdot x\right)\]
\[\left(0.9549296585513720181381813745247200131416 - \left(x \cdot x\right) \cdot 0.1290061377327979819096270830414141528308\right) \cdot x\]
0.9549296585513720181381813745247200131416 \cdot x - 0.1290061377327979819096270830414141528308 \cdot \left(\left(x \cdot x\right) \cdot x\right)
\left(0.9549296585513720181381813745247200131416 - \left(x \cdot x\right) \cdot 0.1290061377327979819096270830414141528308\right) \cdot x
double f(double x) {
        double r1098654 = 0.954929658551372;
        double r1098655 = x;
        double r1098656 = r1098654 * r1098655;
        double r1098657 = 0.12900613773279798;
        double r1098658 = r1098655 * r1098655;
        double r1098659 = r1098658 * r1098655;
        double r1098660 = r1098657 * r1098659;
        double r1098661 = r1098656 - r1098660;
        return r1098661;
}

double f(double x) {
        double r1098662 = 0.954929658551372;
        double r1098663 = x;
        double r1098664 = r1098663 * r1098663;
        double r1098665 = 0.12900613773279798;
        double r1098666 = r1098664 * r1098665;
        double r1098667 = r1098662 - r1098666;
        double r1098668 = r1098667 * r1098663;
        return r1098668;
}

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 - \left(0.1290061377327979819096270830414141528308 \cdot x\right) \cdot x\right)}\]
  3. Taylor expanded around 0 0.1

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

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

    \[\leadsto \left(0.9549296585513720181381813745247200131416 - \left(x \cdot x\right) \cdot 0.1290061377327979819096270830414141528308\right) \cdot x\]

Reproduce

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