public static double erf(final double x) {
		if (Math.abs(x) > 40) {
			return x > 0 ? 1 : -1;
		}
		return 1 - erfc(x);
	}
Calculates an approximation of {@code erf}: erf(x) = 2/&radic;&pi;
<sub>0</sub>&int;<sup>x</sup> e<sup>-t<sup>2</sup></sup>dt,
with a maximum relative error less than 2<sup>-53</sup>
(~ 1.1*10<sup>-16</sup>) in absolute value.

@see <a href="https://dx.doi.org/10.2139/ssrn.4487559">
    Yaya D. Dia: Approximate Incomplete Integrals, Application to
    Complementary Error Function</a>
@see #erfc(double)

@param x the input value
@return an approximation of {@code erf}
jenetics.incubator/src/main/java/io/jenetics/incubator/math/Erf.java