next up previous index
Next: G115 Approximate Vavilov Up: CERNLIB Previous: G106 Gamma Distribution

G110 Landau Distribution

Routine ID: G110
Author(s): K.S. KölbigLibrary: MATHLIB
Submitter: Submitted: 30.08.1985
Language: FortranRevised: 15.03.1993

The LANDAU function subprogram package contains six independent subprograms for the calculation of the following functions related to the Landau distribution:

The density φ(λ) {12πi}∫c-i&inf;c+i&inf;exp(λs + s lns) ds,

the distribution Φ(λ) -&inf;λφ(λ) d λ,

the derivative φ'(λ) {dφ(λ)dλ},

the first moment Φ1(x) {1Φ(x)} ∫-&inf;xλφ(λ) d λ,

the second moment Φ2(x) {1Φ(x)} ∫-&inf;xλ2φ(λ) d λ,

the inverse ofΦ(x) Ψ(x) Φ-1(x).

The function Ψ(x) can be used to generate Landau random numbers (see Usage).

Structure:

FUNCTION subprograms
User Entry Names: DENLAN, DISLAN, DIFLAN, XM1LAN, XM2LAN, RANLAN
Obsolete User Entry Names: DSTLAN DISLAN

Usage:

In any arithmetic expression,
DENLAN(X)φ(X) ,
DISLAN(X)Φ(X) ,
DIFLAN(X)φ'(X) ,
XM1LAN(X)Φ1(X) ,
XM2LAN(X)Φ2(X) ,
RANLAN(X)Ψ(X) ,

where DENLAN, DISLAN, DIFLAN, XM1LAN, XM2LAN, RANLAN and X are of type REAL.

To generate a set of Landau random numbers, RANLAN should be referenced repeatedly, using as argument a random number from a uniform distribution over the interval (0,1).

Method:

Approximation by rational functions. For reason of speed, RANLAN proceeds mainly by table look-up and quadratic interpolation.

Accuracy:

At least six significant digits (five for RANLAN) are correct.

Restrictions:

  1. Underflow may occur for DENLAN, DISLAN and DIFLAN if X is negative and (moderately) large.
  2. No test is made whether X for RANLAN lies outside the interval (0,1), and hence no error message is printed.

Notes:

This program package is a version of the CPC Program Library package LANDAU (Ref. 1).

References:

  1. K.S. Kölbig and B. Schorr, A program package for the Landau distribution, Computer Phys. Comm. 31 (1984) 97--111.

G115



next up previous index
Next: G115 Approximate Vavilov Up: CERNLIB Previous: G106 Gamma Distribution


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