Average Error: 0.1 → 0.1
Time: 9.9s
Precision: 64
\[0.954929658551372 \cdot x - 0.12900613773279798 \cdot \left(\left(x \cdot x\right) \cdot x\right)\]
\[\left(0.954929658551372 - \left(x \cdot 0.12900613773279798\right) \cdot x\right) \cdot x\]
0.954929658551372 \cdot x - 0.12900613773279798 \cdot \left(\left(x \cdot x\right) \cdot x\right)
\left(0.954929658551372 - \left(x \cdot 0.12900613773279798\right) \cdot x\right) \cdot x
double f(double x) {
        double r363620 = 0.954929658551372;
        double r363621 = x;
        double r363622 = r363620 * r363621;
        double r363623 = 0.12900613773279798;
        double r363624 = r363621 * r363621;
        double r363625 = r363624 * r363621;
        double r363626 = r363623 * r363625;
        double r363627 = r363622 - r363626;
        return r363627;
}

double f(double x) {
        double r363628 = 0.954929658551372;
        double r363629 = x;
        double r363630 = 0.12900613773279798;
        double r363631 = r363629 * r363630;
        double r363632 = r363631 * r363629;
        double r363633 = r363628 - r363632;
        double r363634 = r363633 * r363629;
        return r363634;
}

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.954929658551372 \cdot x - 0.12900613773279798 \cdot \left(\left(x \cdot x\right) \cdot x\right)\]
  2. Simplified0.1

    \[\leadsto \color{blue}{x \cdot \left(0.954929658551372 - 0.12900613773279798 \cdot \left(x \cdot x\right)\right)}\]
  3. Using strategy rm
  4. Applied associate-*r*0.1

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

    \[\leadsto \left(0.954929658551372 - \left(x \cdot 0.12900613773279798\right) \cdot x\right) \cdot x\]

Reproduce

herbie shell --seed 2019128 
(FPCore (x)
  :name "Rosa's Benchmark"
  (- (* 0.954929658551372 x) (* 0.12900613773279798 (* (* x x) x))))