Average Error: 0.0 → 0.0
Time: 1.6s
Precision: 64
\[0.707110000000000016 \cdot \left(\frac{2.30753 + x \cdot 0.27061000000000002}{1 + x \cdot \left(0.992290000000000005 + x \cdot 0.044810000000000003\right)} - x\right)\]
\[0.707110000000000016 \cdot \left(\left(2.30753 + x \cdot 0.27061000000000002\right) \cdot \frac{1}{1 + x \cdot \left(0.992290000000000005 + x \cdot 0.044810000000000003\right)} - x\right)\]
0.707110000000000016 \cdot \left(\frac{2.30753 + x \cdot 0.27061000000000002}{1 + x \cdot \left(0.992290000000000005 + x \cdot 0.044810000000000003\right)} - x\right)
0.707110000000000016 \cdot \left(\left(2.30753 + x \cdot 0.27061000000000002\right) \cdot \frac{1}{1 + x \cdot \left(0.992290000000000005 + x \cdot 0.044810000000000003\right)} - x\right)
double f(double x) {
        double r93704 = 0.70711;
        double r93705 = 2.30753;
        double r93706 = x;
        double r93707 = 0.27061;
        double r93708 = r93706 * r93707;
        double r93709 = r93705 + r93708;
        double r93710 = 1.0;
        double r93711 = 0.99229;
        double r93712 = 0.04481;
        double r93713 = r93706 * r93712;
        double r93714 = r93711 + r93713;
        double r93715 = r93706 * r93714;
        double r93716 = r93710 + r93715;
        double r93717 = r93709 / r93716;
        double r93718 = r93717 - r93706;
        double r93719 = r93704 * r93718;
        return r93719;
}

double f(double x) {
        double r93720 = 0.70711;
        double r93721 = 2.30753;
        double r93722 = x;
        double r93723 = 0.27061;
        double r93724 = r93722 * r93723;
        double r93725 = r93721 + r93724;
        double r93726 = 1.0;
        double r93727 = 1.0;
        double r93728 = 0.99229;
        double r93729 = 0.04481;
        double r93730 = r93722 * r93729;
        double r93731 = r93728 + r93730;
        double r93732 = r93722 * r93731;
        double r93733 = r93727 + r93732;
        double r93734 = r93726 / r93733;
        double r93735 = r93725 * r93734;
        double r93736 = r93735 - r93722;
        double r93737 = r93720 * r93736;
        return r93737;
}

Error

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.0

    \[0.707110000000000016 \cdot \left(\frac{2.30753 + x \cdot 0.27061000000000002}{1 + x \cdot \left(0.992290000000000005 + x \cdot 0.044810000000000003\right)} - x\right)\]
  2. Using strategy rm
  3. Applied div-inv0.0

    \[\leadsto 0.707110000000000016 \cdot \left(\color{blue}{\left(2.30753 + x \cdot 0.27061000000000002\right) \cdot \frac{1}{1 + x \cdot \left(0.992290000000000005 + x \cdot 0.044810000000000003\right)}} - x\right)\]
  4. Final simplification0.0

    \[\leadsto 0.707110000000000016 \cdot \left(\left(2.30753 + x \cdot 0.27061000000000002\right) \cdot \frac{1}{1 + x \cdot \left(0.992290000000000005 + x \cdot 0.044810000000000003\right)} - x\right)\]

Reproduce

herbie shell --seed 2020062 
(FPCore (x)
  :name "Numeric.SpecFunctions:invErfc from math-functions-0.1.5.2, B"
  :precision binary64
  (* 0.70711 (- (/ (+ 2.30753 (* x 0.27061)) (+ 1 (* x (+ 0.99229 (* x 0.04481))))) x)))