next up previous index
Next: C302 Gamma Function Up: CERNLIB Previous: C300 Error Function

C301 Normal Frequency Function

Routine ID: C301
Author(s): G.A. ErskineLibrary: MATHLIB
Submitter: K.S. KölbigSubmitted: 07.06.1992
Language: FortranRevised:

Function subprograms FREQ and DFREQ compute the normal frequency function

freq(x) {1}∫-&inf;xe-{12}t2 dt,

defined for all values of the real argument x.

On CDC and Cray computers, the double-precision version DFREQ is not available.

Structure:

FUNCTION subprograms
User Entry Names: FREQ, DFREQ

Usage:

In any arithmetic expression, FREQ(X) or DFREQ(X) has the value freq( X),

where FREQ is of type REAL, DFREQ is of type DOUBLE PRECISION, and X has the same type as the function name.

Method:

Computation by rational Chebyshev approximation for the error function, using the formula

freq(x) =
{12}+ {12} erf (x/2) (x≥0),

{12} erfc (|x|/2) (x<0).

.

Accuracy:

FREQ has full single-precision accuracy (slightly less on CDC and Cray computers). DFREQ has an accuracy of 15 significant digits.

References:

  1. W.J. Cody, Rational Chebyshev approximations for the error function, Math. Comp. 22 (1969) 631--637.

C302


Janne Saarela
Mon Apr 3 15:06:23 METDST 1995