SEED48 - set random seed.

(Compatible with UNIX System V C)

Usage:

unsigned short *seed48(unsigned short *);
oldptr = seed48(newseed);

Where:

unsigned short newseed[3];
represents a 48-bit number that will be used as the seed for pseudo-random number generation. Each element of "newseed" contains 16 bits of the number.
unsigned short *oldptr;
is filled with a pointer to the old seed or most recent pseudo-random number generated. This has the same format as "newseed".

Description:

"seed48" sets a seed for various random number generation routines ("drand48", "lrand48", and "mrand48"). The difference between "seed48" and "srand48" is that "seed48" sets all 48 bits of the random seed while "srand48" only sets the top 32 bits of the seed (the bottom bits are filled with the constant 330e16).

See Also:

expl c lib srand48
expl c lib drand48
expl c lib erand48
expl c lib jrand48
expl c lib srand48
expl c lib mrand48
expl c lib nrand48
expl c lib lcong48
expl c lib rand

Copyright © 1996, Thinkage Ltd.