Average Error: 0.1 → 0.2
Time: 13.8s
Precision: 64
\[\frac{x \cdot x - 3.0}{6.0}\]
\[0.16666666666666666 \cdot \left(x \cdot x\right) - 0.5\]
\frac{x \cdot x - 3.0}{6.0}
0.16666666666666666 \cdot \left(x \cdot x\right) - 0.5
double f(double x) {
        double r3333873 = x;
        double r3333874 = r3333873 * r3333873;
        double r3333875 = 3.0;
        double r3333876 = r3333874 - r3333875;
        double r3333877 = 6.0;
        double r3333878 = r3333876 / r3333877;
        return r3333878;
}

double f(double x) {
        double r3333879 = 0.16666666666666666;
        double r3333880 = x;
        double r3333881 = r3333880 * r3333880;
        double r3333882 = r3333879 * r3333881;
        double r3333883 = 0.5;
        double r3333884 = r3333882 - r3333883;
        return r3333884;
}

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

    \[\frac{x \cdot x - 3.0}{6.0}\]
  2. Taylor expanded around 0 0.2

    \[\leadsto \color{blue}{0.16666666666666666 \cdot {x}^{2} - 0.5}\]
  3. Simplified0.2

    \[\leadsto \color{blue}{\left(x \cdot x\right) \cdot 0.16666666666666666 - 0.5}\]
  4. Final simplification0.2

    \[\leadsto 0.16666666666666666 \cdot \left(x \cdot x\right) - 0.5\]

Reproduce

herbie shell --seed 2019163 +o rules:numerics
(FPCore (x)
  :name "Numeric.SpecFunctions:invIncompleteBetaWorker from math-functions-0.1.5.2, H"
  (/ (- (* x x) 3.0) 6.0))