QIRAN 3 "30 June 2000" "Version 1.00"

Table of contents


NAME

qiran - Quadruple-precision pseudo-random integer in (x..y)

SYNOPSIS

Fortran (77, 90, 95, HPF):
f77 [ flags ] file(s) ... -L/usr/local/lib -lgjl
REAL*16 FUNCTION qiran(x,y)
REAL*16             x,           y
C (K&R, 89, 99), C++ (98):
cc [ flags ] -I/usr/local/include file(s) ... -L/usr/local/lib -lgjl
Use
#include <gampsi.h>
to get this prototype:
fortran_quadruple_precision qiran(const fortran_quadruple_precision * x_, const fortran_quadruple_precision * y_);

NB: The definition of C/C++ data types fortran_ xxx, and the mapping of Fortran external names to C/C++ external names, is handled by the C/C++ header file. That way, the same function or subroutine name can be used in C, C++, and Fortran code, independent of compiler conventions for mangling of external names in these programming languages.

Last code modification: 30-Jun-2000


DESCRIPTION

Return a pseudo-random integer value, represented in quadruple precision, in the range (x..y), excluding endpoint y, where x >= y (a relation that is NOT checked).

The underlying pseudo-random number generator is dran(), which produces about 58 random bits.

The range of representable integers is 0 .. (2**p - 1), where p is the number of bits in the significand of a quadruple-precision number.

In IEEE 754 quadruple-precision arithmetic, p = 113, corresponding to the range 0 .. 10384593717069655257060992658440192 (about 0 .. 1.04e+34).


SEE ALSO

airan(3), diran(3).

AUTHORS

The algorithms and code are described in detail in the paper
Algorithm xxx: Quadruple-Precision Gamma(x) and psi(x) Functions for Real Arguments
in ACM Transactions on Mathematical Software, Volume ??, Number ??, Pages ????--???? and ????--????, 2001, by
Nelson H. F. Beebe
Center for Scientific Computing
University of Utah
Department of Mathematics, 110 LCB
155 S 1400 E RM 233
Salt Lake City, UT 84112-0090
Tel: +1 801 581 5254
FAX: +1 801 581 4148
Email: beebe@math.utah.edu, beebe@acm.org, beebe@computer.org
WWW URL: http://www.math.utah.edu/~beebe
and
James S. Ball
University of Utah
Department of Physics
Salt Lake City, UT 84112-0830
USA
Tel: +1 801 581 8397
FAX: +1 801 581 6256
Email: ball@physics.utah.edu
WWW URL: http://www.physics.utah.edu/people/faculty/ball.html