Automatic Differentiation
 
Loading...
Searching...
No Matches

◆ erfcx_small()

double stan::math::internal::erfcx_small ( double  x)
inline

Degree-18 polynomial for |x| < 0.46875.

A Chebyshev-economized expansion of erfcx about zero, so it needs no library call and no branch on the sign of x. Its low-order coefficients reproduce the Maclaurin series of erfcx exactly (1, -2/sqrt(pi), 1, ...), which is a useful check that the fit is right.

Evaluated by Estrin's method: four independent degree-3 blocks are combined in x^4 and x^8.

Parameters
xargument, |x| < 0.46875
Returns
scaled complementary error function

Definition at line 176 of file erfcx.hpp.