function erf1(y) {
    var ysq = y * y;
    var xnum = P[0][4] * ysq;
    var xden = ysq;
    var i;

    for (i = 0; i < 3; i += 1) {
      xnum = (xnum + P[0][i]) * ysq;
      xden = (xden + Q[0][i]) * ysq;
    }

    return y * (xnum + P[0][3]) / (xden + Q[0][3]);
  }
Approximates the error function erf() for x <= 0.46875 using this function:
              n
erf(x) = x * sum (p_j * x^(2j)) / (q_j * x^(2j))
             j=0