SCALAPACK 2.2.2
LAPACK: Linear Algebra PACKage
Loading...
Searching...
No Matches

◆ pb_drand()

double precision function pb_drand ( integer  idumm)

Definition at line 11494 of file pzblastst.f.

11495*
11496* -- PBLAS test routine (version 2.0) --
11497* University of Tennessee, Knoxville, Oak Ridge National Laboratory,
11498* and University of California, Berkeley.
11499* April 1, 1998
11500*
11501* .. Scalar Arguments ..
11502 INTEGER IDUMM
11503* ..
11504*
11505* Purpose
11506* =======
11507*
11508* PB_DRAND generates the next number in the random sequence. This func-
11509* tion ensures that this number will be in the interval ( -1.0, 1.0 ).
11510*
11511* Arguments
11512* =========
11513*
11514* IDUMM (local input) INTEGER
11515* This argument is ignored, but necessary to a FORTRAN 77 func-
11516* tion.
11517*
11518* Further Details
11519* ===============
11520*
11521* On entry, the array IRAND stored in the common block RANCOM contains
11522* the information (2 integers) required to generate the next number in
11523* the sequence X( n ). This number is computed as
11524*
11525* X( n ) = ( 2^16 * IRAND( 2 ) + IRAND( 1 ) ) / d,
11526*
11527* where the constant d is the largest 32 bit positive integer. The
11528* array IRAND is then updated for the generation of the next number
11529* X( n+1 ) in the random sequence as follows X( n+1 ) = a * X( n ) + c.
11530* The constants a and c should have been preliminarily stored in the
11531* array IACS as 2 pairs of integers. The initial set up of IRAND and
11532* IACS is performed by the routine PB_SETRAN.
11533*
11534* -- Written on April 1, 1998 by
11535* Antoine Petitet, University of Tennessee, Knoxville 37996, USA.
11536*
11537* =====================================================================
11538*
11539* .. Parameters ..
11540 DOUBLE PRECISION ONE, TWO
11541 parameter( one = 1.0d+0, two = 2.0d+0 )
11542* ..
11543* .. External Functions ..
11544 DOUBLE PRECISION PB_DRAN
11545 EXTERNAL pb_dran
11546* ..
11547* .. Executable Statements ..
11548*
11549 pb_drand = one - two * pb_dran( idumm )
11550*
11551 RETURN
11552*
11553* End of PB_DRAND
11554*
double precision function pb_dran(idumm)
double precision function pb_drand(idumm)
Here is the call graph for this function: