V116: Double Precision Uniform Random Numbers

Author(s): F. James Library: MATHLIB
Submitter: Submitted: 15.03.1994
Language: Fortran Revised:

RM48 generates pseudorandom numbers using a double-precision (64-bit) adaptation of RANMAR (V113). The floating-point numbers in the interval (0,1), the end points excluded, have 48 significant bits of mantissa (additional bits of mantissa, if supported by the hardware, are zero). Both the code and the results are portable, provided the floating-point mode is adapted to the computer being used (for example, single-precision mode on 64-bit machines, double-precision mode on 32-bit machines).

Structure:

SUBROUTINE Subprograms
User Entry Names: RM48, RM48IN, RM48UT

Usage:

    CALL RM48(RVEC,LEN)
returns a vector RVEC of LEN 64-bit random floating-point numbers in (0,1), the end points excluded. RVEC is an array of length LEN at least. It is of type DOUBLE PRECISION on 32-bit machines, and of type REAL otherwise.
    CALL RM48IN(I1,N1,N2)
initializes the generator from one 32-bit integer I1, and number counts N1, N2 (for initializing, set tex2html_wrap_inline64 , but to restart a previously generated sequence, use values output by RM48UT).
    CALL RM48UT(I1,N1,N2)
outputs the value of the original seed and the two number counts, to be used for restarting by initializing to I1 and skipping tex2html_wrap_inline66 numbers.

Method:

The method is that of RANMAR (V113).
tex2html_wrap_inline68


Michel Goossens Wed Jun 5 08:42:02 METDST 1996