Average Error: 0.0 → 0.1
Time: 10.3s
Precision: 64
\[\frac{2.307529999999999859028321225196123123169 + x \cdot 0.2706100000000000171951342053944244980812}{1 + x \cdot \left(0.992290000000000005364597654988756403327 + x \cdot 0.04481000000000000260680366181986755691469\right)} - x\]
\[\mathsf{fma}\left(\mathsf{fma}\left(x, 0.2706100000000000171951342053944244980812, 2.307529999999999859028321225196123123169\right), \sqrt{\frac{1}{\mathsf{fma}\left(\mathsf{fma}\left(x, 0.04481000000000000260680366181986755691469, 0.992290000000000005364597654988756403327\right), x, 1\right)}} \cdot \sqrt{\frac{1}{\mathsf{fma}\left(\mathsf{fma}\left(x, 0.04481000000000000260680366181986755691469, 0.992290000000000005364597654988756403327\right), x, 1\right)}}, -x\right)\]
\frac{2.307529999999999859028321225196123123169 + x \cdot 0.2706100000000000171951342053944244980812}{1 + x \cdot \left(0.992290000000000005364597654988756403327 + x \cdot 0.04481000000000000260680366181986755691469\right)} - x
\mathsf{fma}\left(\mathsf{fma}\left(x, 0.2706100000000000171951342053944244980812, 2.307529999999999859028321225196123123169\right), \sqrt{\frac{1}{\mathsf{fma}\left(\mathsf{fma}\left(x, 0.04481000000000000260680366181986755691469, 0.992290000000000005364597654988756403327\right), x, 1\right)}} \cdot \sqrt{\frac{1}{\mathsf{fma}\left(\mathsf{fma}\left(x, 0.04481000000000000260680366181986755691469, 0.992290000000000005364597654988756403327\right), x, 1\right)}}, -x\right)
double f(double x) {
        double r2776328 = 2.30753;
        double r2776329 = x;
        double r2776330 = 0.27061;
        double r2776331 = r2776329 * r2776330;
        double r2776332 = r2776328 + r2776331;
        double r2776333 = 1.0;
        double r2776334 = 0.99229;
        double r2776335 = 0.04481;
        double r2776336 = r2776329 * r2776335;
        double r2776337 = r2776334 + r2776336;
        double r2776338 = r2776329 * r2776337;
        double r2776339 = r2776333 + r2776338;
        double r2776340 = r2776332 / r2776339;
        double r2776341 = r2776340 - r2776329;
        return r2776341;
}

double f(double x) {
        double r2776342 = x;
        double r2776343 = 0.27061;
        double r2776344 = 2.30753;
        double r2776345 = fma(r2776342, r2776343, r2776344);
        double r2776346 = 1.0;
        double r2776347 = 0.04481;
        double r2776348 = 0.99229;
        double r2776349 = fma(r2776342, r2776347, r2776348);
        double r2776350 = 1.0;
        double r2776351 = fma(r2776349, r2776342, r2776350);
        double r2776352 = r2776346 / r2776351;
        double r2776353 = sqrt(r2776352);
        double r2776354 = r2776353 * r2776353;
        double r2776355 = -r2776342;
        double r2776356 = fma(r2776345, r2776354, r2776355);
        return r2776356;
}

Error

Bits error versus x

Derivation

  1. Initial program 0.0

    \[\frac{2.307529999999999859028321225196123123169 + x \cdot 0.2706100000000000171951342053944244980812}{1 + x \cdot \left(0.992290000000000005364597654988756403327 + x \cdot 0.04481000000000000260680366181986755691469\right)} - x\]
  2. Simplified0.0

    \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(x, 0.2706100000000000171951342053944244980812, 2.307529999999999859028321225196123123169\right)}{\mathsf{fma}\left(\mathsf{fma}\left(x, 0.04481000000000000260680366181986755691469, 0.992290000000000005364597654988756403327\right), x, 1\right)} - x}\]
  3. Using strategy rm
  4. Applied div-inv0.0

    \[\leadsto \color{blue}{\mathsf{fma}\left(x, 0.2706100000000000171951342053944244980812, 2.307529999999999859028321225196123123169\right) \cdot \frac{1}{\mathsf{fma}\left(\mathsf{fma}\left(x, 0.04481000000000000260680366181986755691469, 0.992290000000000005364597654988756403327\right), x, 1\right)}} - x\]
  5. Applied fma-neg0.0

    \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(x, 0.2706100000000000171951342053944244980812, 2.307529999999999859028321225196123123169\right), \frac{1}{\mathsf{fma}\left(\mathsf{fma}\left(x, 0.04481000000000000260680366181986755691469, 0.992290000000000005364597654988756403327\right), x, 1\right)}, -x\right)}\]
  6. Using strategy rm
  7. Applied add-sqr-sqrt0.1

    \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(x, 0.2706100000000000171951342053944244980812, 2.307529999999999859028321225196123123169\right), \color{blue}{\sqrt{\frac{1}{\mathsf{fma}\left(\mathsf{fma}\left(x, 0.04481000000000000260680366181986755691469, 0.992290000000000005364597654988756403327\right), x, 1\right)}} \cdot \sqrt{\frac{1}{\mathsf{fma}\left(\mathsf{fma}\left(x, 0.04481000000000000260680366181986755691469, 0.992290000000000005364597654988756403327\right), x, 1\right)}}}, -x\right)\]
  8. Final simplification0.1

    \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(x, 0.2706100000000000171951342053944244980812, 2.307529999999999859028321225196123123169\right), \sqrt{\frac{1}{\mathsf{fma}\left(\mathsf{fma}\left(x, 0.04481000000000000260680366181986755691469, 0.992290000000000005364597654988756403327\right), x, 1\right)}} \cdot \sqrt{\frac{1}{\mathsf{fma}\left(\mathsf{fma}\left(x, 0.04481000000000000260680366181986755691469, 0.992290000000000005364597654988756403327\right), x, 1\right)}}, -x\right)\]

Reproduce

herbie shell --seed 2019179 +o rules:numerics
(FPCore (x)
  :name "Numeric.SpecFunctions:invIncompleteGamma from math-functions-0.1.5.2, C"
  (- (/ (+ 2.30753 (* x 0.27061)) (+ 1.0 (* x (+ 0.99229 (* x 0.04481))))) x))