Average Error: 0.2 → 0.1
Time: 20.3s
Precision: 64
\[0.954929658551372 \cdot x - 0.12900613773279798 \cdot \left(\left(x \cdot x\right) \cdot x\right)\]
\[0.954929658551372 \cdot x - 0.12900613773279798 \cdot {x}^{3}\]
0.954929658551372 \cdot x - 0.12900613773279798 \cdot \left(\left(x \cdot x\right) \cdot x\right)
0.954929658551372 \cdot x - 0.12900613773279798 \cdot {x}^{3}
double f(double x) {
        double r832766 = 0.954929658551372;
        double r832767 = x;
        double r832768 = r832766 * r832767;
        double r832769 = 0.12900613773279798;
        double r832770 = r832767 * r832767;
        double r832771 = r832770 * r832767;
        double r832772 = r832769 * r832771;
        double r832773 = r832768 - r832772;
        return r832773;
}

double f(double x) {
        double r832774 = 0.954929658551372;
        double r832775 = x;
        double r832776 = r832774 * r832775;
        double r832777 = 0.12900613773279798;
        double r832778 = 3.0;
        double r832779 = pow(r832775, r832778);
        double r832780 = r832777 * r832779;
        double r832781 = r832776 - r832780;
        return r832781;
}

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 pow10.2

    \[\leadsto 0.954929658551372 \cdot x - 0.12900613773279798 \cdot \left(\left(x \cdot x\right) \cdot \color{blue}{{x}^{1}}\right)\]
  4. Applied pow20.2

    \[\leadsto 0.954929658551372 \cdot x - 0.12900613773279798 \cdot \left(\color{blue}{{x}^{2}} \cdot {x}^{1}\right)\]
  5. Applied pow-prod-up0.1

    \[\leadsto 0.954929658551372 \cdot x - 0.12900613773279798 \cdot \color{blue}{{x}^{\left(2 + 1\right)}}\]
  6. Simplified0.1

    \[\leadsto 0.954929658551372 \cdot x - 0.12900613773279798 \cdot {x}^{\color{blue}{3}}\]
  7. Final simplification0.1

    \[\leadsto 0.954929658551372 \cdot x - 0.12900613773279798 \cdot {x}^{3}\]

Reproduce

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