Average Error: 0.0 → 0.0
Time: 32.3s
Precision: 64
\[0.7071100000000000163069557856942992657423 \cdot \left(\frac{2.307529999999999859028321225196123123169 + x \cdot 0.2706100000000000171951342053944244980812}{1 + x \cdot \left(0.992290000000000005364597654988756403327 + x \cdot 0.04481000000000000260680366181986755691469\right)} - x\right)\]
\[\left(\frac{\mathsf{fma}\left(0.2706100000000000171951342053944244980812, x, 2.307529999999999859028321225196123123169\right)}{\mathsf{fma}\left(\mathsf{fma}\left(0.04481000000000000260680366181986755691469, x, 0.992290000000000005364597654988756403327\right), x, 1\right)} - x\right) \cdot 0.7071100000000000163069557856942992657423\]
0.7071100000000000163069557856942992657423 \cdot \left(\frac{2.307529999999999859028321225196123123169 + x \cdot 0.2706100000000000171951342053944244980812}{1 + x \cdot \left(0.992290000000000005364597654988756403327 + x \cdot 0.04481000000000000260680366181986755691469\right)} - x\right)
\left(\frac{\mathsf{fma}\left(0.2706100000000000171951342053944244980812, x, 2.307529999999999859028321225196123123169\right)}{\mathsf{fma}\left(\mathsf{fma}\left(0.04481000000000000260680366181986755691469, x, 0.992290000000000005364597654988756403327\right), x, 1\right)} - x\right) \cdot 0.7071100000000000163069557856942992657423
double f(double x) {
        double r67893 = 0.70711;
        double r67894 = 2.30753;
        double r67895 = x;
        double r67896 = 0.27061;
        double r67897 = r67895 * r67896;
        double r67898 = r67894 + r67897;
        double r67899 = 1.0;
        double r67900 = 0.99229;
        double r67901 = 0.04481;
        double r67902 = r67895 * r67901;
        double r67903 = r67900 + r67902;
        double r67904 = r67895 * r67903;
        double r67905 = r67899 + r67904;
        double r67906 = r67898 / r67905;
        double r67907 = r67906 - r67895;
        double r67908 = r67893 * r67907;
        return r67908;
}

double f(double x) {
        double r67909 = 0.27061;
        double r67910 = x;
        double r67911 = 2.30753;
        double r67912 = fma(r67909, r67910, r67911);
        double r67913 = 0.04481;
        double r67914 = 0.99229;
        double r67915 = fma(r67913, r67910, r67914);
        double r67916 = 1.0;
        double r67917 = fma(r67915, r67910, r67916);
        double r67918 = r67912 / r67917;
        double r67919 = r67918 - r67910;
        double r67920 = 0.70711;
        double r67921 = r67919 * r67920;
        return r67921;
}

Error

Bits error versus x

Derivation

  1. Initial program 0.0

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

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

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

Reproduce

herbie shell --seed 2019326 +o rules:numerics
(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)))