Average Error: 0.1 → 0.1
Time: 52.3s
Precision: 64
\[1 - x \cdot \left(0.2530000000000000026645352591003756970167 + x \cdot 0.1199999999999999955591079014993738383055\right)\]
\[1 - \mathsf{fma}\left(0.1199999999999999955591079014993738383055, x, 0.2530000000000000026645352591003756970167\right) \cdot x\]
1 - x \cdot \left(0.2530000000000000026645352591003756970167 + x \cdot 0.1199999999999999955591079014993738383055\right)
1 - \mathsf{fma}\left(0.1199999999999999955591079014993738383055, x, 0.2530000000000000026645352591003756970167\right) \cdot x
double f(double x) {
        double r3829208 = 1.0;
        double r3829209 = x;
        double r3829210 = 0.253;
        double r3829211 = 0.12;
        double r3829212 = r3829209 * r3829211;
        double r3829213 = r3829210 + r3829212;
        double r3829214 = r3829209 * r3829213;
        double r3829215 = r3829208 - r3829214;
        return r3829215;
}

double f(double x) {
        double r3829216 = 1.0;
        double r3829217 = 0.12;
        double r3829218 = x;
        double r3829219 = 0.253;
        double r3829220 = fma(r3829217, r3829218, r3829219);
        double r3829221 = r3829220 * r3829218;
        double r3829222 = r3829216 - r3829221;
        return r3829222;
}

Error

Bits error versus x

Derivation

  1. Initial program 0.1

    \[1 - x \cdot \left(0.2530000000000000026645352591003756970167 + x \cdot 0.1199999999999999955591079014993738383055\right)\]
  2. Simplified0.1

    \[\leadsto \color{blue}{1 - x \cdot \mathsf{fma}\left(0.1199999999999999955591079014993738383055, x, 0.2530000000000000026645352591003756970167\right)}\]
  3. Final simplification0.1

    \[\leadsto 1 - \mathsf{fma}\left(0.1199999999999999955591079014993738383055, x, 0.2530000000000000026645352591003756970167\right) \cdot x\]

Reproduce

herbie shell --seed 2019200 +o rules:numerics
(FPCore (x)
  :name "Numeric.SpecFunctions:invIncompleteGamma from math-functions-0.1.5.2, A"
  (- 1.0 (* x (+ 0.253 (* x 0.12)))))