Global approximations to the error function of real argument for vectorized computation
arXiv:2504.05068
Abstract
The error function of real argument can be approximated to a given uniform relative accuracy by a single closed-form expression for the whole variable range either in terms of addition, multiplication, division, and square root operations only, or also using the exponential function. The coefficients have been tabulated for up to 128-bit precision. Tests of a computer code implementation using the standard single- and double-precision floating-point arithmetic show good performance and vectorizability. Approximations to the complementary error function have also been found, including those where only additions, multiplications, and one division are needed to reach a uniform absolute accuracy.