Compaq Fortran for Tru64 UNIX Alpha Systems V5.4

erf, erfc, derf, derfc (3f)


Syntax

  real*4 erf, x, e
  external erf
  e = erf ( x )

  real*4 erfc, x, e
  external erfc
  e = erfc ( x )

  real*8 derf, dx, d
  external derf
  d = derf ( dx )

  real*8 derfc, dx, d
  external derfc
  d = derfc ( dx )

Description

  The erf function returns the error function of x defined as follows:

      erf(x) = 2/sqrt(pi)*integral from 0 to x of exp(-t*t) dt

  The erfc function returns 1.0 - erf(x).

  The derf function is the double precision version of erf, and derfc is the
  double precision version of erfc.

  The entry for the erfc function is provided because of the extreme loss of
  relative accuracy if erf(x) is called for large x and the result is
  subtracted from 1.

See Also

  erf(3m), math(3m)