Average Error: 0.7 → 0.0
Time: 23.6s
Precision: 64
\[\left(\left(\left(\left(\left(\left(\left(x \cdot x - 7 \cdot x\right) \cdot x + 28 \cdot {x}^{2}\right) \cdot x - 56 \cdot {x}^{3}\right) \cdot x + 70 \cdot {x}^{4}\right) \cdot x - 56 \cdot {x}^{5}\right) \cdot x + 28 \cdot {x}^{6}\right) \cdot x - 8 \cdot {x}^{7}\right) \cdot x\]
\[{x}^{9} - 1 \cdot {x}^{8}\]
\left(\left(\left(\left(\left(\left(\left(x \cdot x - 7 \cdot x\right) \cdot x + 28 \cdot {x}^{2}\right) \cdot x - 56 \cdot {x}^{3}\right) \cdot x + 70 \cdot {x}^{4}\right) \cdot x - 56 \cdot {x}^{5}\right) \cdot x + 28 \cdot {x}^{6}\right) \cdot x - 8 \cdot {x}^{7}\right) \cdot x
{x}^{9} - 1 \cdot {x}^{8}
double f(double x) {
        double r213866 = x;
        double r213867 = r213866 * r213866;
        double r213868 = 7.0;
        double r213869 = r213868 * r213866;
        double r213870 = r213867 - r213869;
        double r213871 = r213870 * r213866;
        double r213872 = 28.0;
        double r213873 = 2.0;
        double r213874 = pow(r213866, r213873);
        double r213875 = r213872 * r213874;
        double r213876 = r213871 + r213875;
        double r213877 = r213876 * r213866;
        double r213878 = 56.0;
        double r213879 = 3.0;
        double r213880 = pow(r213866, r213879);
        double r213881 = r213878 * r213880;
        double r213882 = r213877 - r213881;
        double r213883 = r213882 * r213866;
        double r213884 = 70.0;
        double r213885 = 4.0;
        double r213886 = pow(r213866, r213885);
        double r213887 = r213884 * r213886;
        double r213888 = r213883 + r213887;
        double r213889 = r213888 * r213866;
        double r213890 = 5.0;
        double r213891 = pow(r213866, r213890);
        double r213892 = r213878 * r213891;
        double r213893 = r213889 - r213892;
        double r213894 = r213893 * r213866;
        double r213895 = 6.0;
        double r213896 = pow(r213866, r213895);
        double r213897 = r213872 * r213896;
        double r213898 = r213894 + r213897;
        double r213899 = r213898 * r213866;
        double r213900 = 8.0;
        double r213901 = pow(r213866, r213868);
        double r213902 = r213900 * r213901;
        double r213903 = r213899 - r213902;
        double r213904 = r213903 * r213866;
        return r213904;
}

double f(double x) {
        double r213905 = x;
        double r213906 = 9.0;
        double r213907 = pow(r213905, r213906);
        double r213908 = 1.0;
        double r213909 = 8.0;
        double r213910 = pow(r213905, r213909);
        double r213911 = r213908 * r213910;
        double r213912 = r213907 - r213911;
        return r213912;
}

Error

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.7

    \[\left(\left(\left(\left(\left(\left(\left(x \cdot x - 7 \cdot x\right) \cdot x + 28 \cdot {x}^{2}\right) \cdot x - 56 \cdot {x}^{3}\right) \cdot x + 70 \cdot {x}^{4}\right) \cdot x - 56 \cdot {x}^{5}\right) \cdot x + 28 \cdot {x}^{6}\right) \cdot x - 8 \cdot {x}^{7}\right) \cdot x\]
  2. Taylor expanded around 0 0.1

    \[\leadsto \color{blue}{\left({x}^{8} - 1 \cdot {x}^{7}\right)} \cdot x\]
  3. Taylor expanded around 0 0.0

    \[\leadsto \color{blue}{{x}^{9} - 1 \cdot {x}^{8}}\]
  4. Final simplification0.0

    \[\leadsto {x}^{9} - 1 \cdot {x}^{8}\]

Reproduce

herbie shell --seed 1 
(FPCore (x)
  :name "(((((((x*x-7*x)*x+28*pow(x,2))*x - 56*pow(x,3))*x + 70*pow(x,4))*x - 56*pow(x, 5))*x + 28*pow(x, 6))*x - 8*pow(x, 7))*x"
  :precision binary64
  (* (- (* (+ (* (- (* (+ (* (- (* (+ (* (- (* x x) (* 7 x)) x) (* 28 (pow x 2))) x) (* 56 (pow x 3))) x) (* 70 (pow x 4))) x) (* 56 (pow x 5))) x) (* 28 (pow x 6))) x) (* 8 (pow x 7))) x))