Average Error: 0.2 → 0.1
Time: 12.6s
Precision: 64
\[0.954929658551372 \cdot x - 0.12900613773279798 \cdot \left(\left(x \cdot x\right) \cdot x\right)\]
\[0.954929658551372 \cdot x - \left(0.12900613773279798 \cdot \left(x \cdot x\right)\right) \cdot x\]
0.954929658551372 \cdot x - 0.12900613773279798 \cdot \left(\left(x \cdot x\right) \cdot x\right)
0.954929658551372 \cdot x - \left(0.12900613773279798 \cdot \left(x \cdot x\right)\right) \cdot x
double f(double x) {
        double r440858 = 0.954929658551372;
        double r440859 = x;
        double r440860 = r440858 * r440859;
        double r440861 = 0.12900613773279798;
        double r440862 = r440859 * r440859;
        double r440863 = r440862 * r440859;
        double r440864 = r440861 * r440863;
        double r440865 = r440860 - r440864;
        return r440865;
}

double f(double x) {
        double r440866 = 0.954929658551372;
        double r440867 = x;
        double r440868 = r440866 * r440867;
        double r440869 = 0.12900613773279798;
        double r440870 = r440867 * r440867;
        double r440871 = r440869 * r440870;
        double r440872 = r440871 * r440867;
        double r440873 = r440868 - r440872;
        return r440873;
}

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.954929658551372 \cdot x - 0.12900613773279798 \cdot \left(\left(x \cdot x\right) \cdot x\right)\]
  2. Using strategy rm
  3. Applied associate-*r*0.1

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

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

Reproduce

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