9.248. SRAND

9.248 SRAND — Reinitialize the random number generator

Description:
SRAND reinitializes the pseudo-random number generator called by RAND and IRAND. The new seed used by the generator is specified by the required argument SEED.
Standard:
GNU extension
Class:
Subroutine
Syntax:
CALL SRAND(SEED)
Arguments:
SEED Shall be a scalar INTEGER(kind=4).
Return value:
Does not return anything.
Example:
See RAND and IRAND for examples.
Notes:
The Fortran standard specifies the intrinsic subroutines RANDOM_SEED to initialize the pseudo-random number generator and RANDOM_NUMBER to