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

◆ pb_drand()

double precision function pb_drand ( integer  idumm)

Definition at line 10377 of file pdblastst.f.

10378*
10379* -- PBLAS test routine (version 2.0) --
10380* University of Tennessee, Knoxville, Oak Ridge National Laboratory,
10381* and University of California, Berkeley.
10382* April 1, 1998
10383*
10384* .. Scalar Arguments ..
10385 INTEGER IDUMM
10386* ..
10387*
10388* Purpose
10389* =======
10390*
10391* PB_DRAND generates the next number in the random sequence. This func-
10392* tion ensures that this number will be in the interval ( -1.0, 1.0 ).
10393*
10394* Arguments
10395* =========
10396*
10397* IDUMM (local input) INTEGER
10398* This argument is ignored, but necessary to a FORTRAN 77 func-
10399* tion.
10400*
10401* Further Details
10402* ===============
10403*
10404* On entry, the array IRAND stored in the common block RANCOM contains
10405* the information (2 integers) required to generate the next number in
10406* the sequence X( n ). This number is computed as
10407*
10408* X( n ) = ( 2^16 * IRAND( 2 ) + IRAND( 1 ) ) / d,
10409*
10410* where the constant d is the largest 32 bit positive integer. The
10411* array IRAND is then updated for the generation of the next number
10412* X( n+1 ) in the random sequence as follows X( n+1 ) = a * X( n ) + c.
10413* The constants a and c should have been preliminarily stored in the
10414* array IACS as 2 pairs of integers. The initial set up of IRAND and
10415* IACS is performed by the routine PB_SETRAN.
10416*
10417* -- Written on April 1, 1998 by
10418* Antoine Petitet, University of Tennessee, Knoxville 37996, USA.
10419*
10420* =====================================================================
10421*
10422* .. Parameters ..
10423 DOUBLE PRECISION ONE, TWO
10424 parameter( one = 1.0d+0, two = 2.0d+0 )
10425* ..
10426* .. External Functions ..
10427 DOUBLE PRECISION PB_DRAN
10428 EXTERNAL pb_dran
10429* ..
10430* .. Executable Statements ..
10431*
10432 pb_drand = one - two * pb_dran( idumm )
10433*
10434 RETURN
10435*
10436* End of PB_DRAND
10437*
double precision function pb_dran(idumm)
double precision function pb_drand(idumm)
Here is the call graph for this function:
Here is the caller graph for this function: