Average Error: 0.1 → 0.1
Time: 2.1s
Precision: 64
\[1 - x \cdot \left(0.253 + x \cdot 0.12\right)\]
\[1 - \left(x \cdot 0.253 + x \cdot \left(x \cdot 0.12\right)\right)\]
1 - x \cdot \left(0.253 + x \cdot 0.12\right)
1 - \left(x \cdot 0.253 + x \cdot \left(x \cdot 0.12\right)\right)
double f(double x) {
        double r64404 = 1.0;
        double r64405 = x;
        double r64406 = 0.253;
        double r64407 = 0.12;
        double r64408 = r64405 * r64407;
        double r64409 = r64406 + r64408;
        double r64410 = r64405 * r64409;
        double r64411 = r64404 - r64410;
        return r64411;
}

double f(double x) {
        double r64412 = 1.0;
        double r64413 = x;
        double r64414 = 0.253;
        double r64415 = r64413 * r64414;
        double r64416 = 0.12;
        double r64417 = r64413 * r64416;
        double r64418 = r64413 * r64417;
        double r64419 = r64415 + r64418;
        double r64420 = r64412 - r64419;
        return r64420;
}

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

    \[1 - x \cdot \left(0.253 + x \cdot 0.12\right)\]
  2. Using strategy rm
  3. Applied distribute-lft-in0.1

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

    \[\leadsto 1 - \left(x \cdot 0.253 + x \cdot \left(x \cdot 0.12\right)\right)\]

Reproduce

herbie shell --seed 2020036 
(FPCore (x)
  :name "Numeric.SpecFunctions:invIncompleteGamma from math-functions-0.1.5.2, A"
  :precision binary64
  (- 1 (* x (+ 0.253 (* x 0.12)))))