Warning: main(/www/www/htdocs/style/globals.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/lib_ref/s/srand48.html on line 1
Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/globals.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/lib_ref/s/srand48.html on line 1
Warning: main(/www/www/htdocs/style/header.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/lib_ref/s/srand48.html on line 8
Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/header.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/lib_ref/s/srand48.html on line 8
Initialize a sequence of pseudo-random numbers
#include <stdlib.h>
void srand48( long seed );
- seed
- The seed of the sequence of pseudo-random integers.
libc
Use the -l c option to
qcc
to link against this library.
This library is usually included automatically.
The srand48() is used to initialize the internal buffer
r(n) of drand48(),
lrand48(), and mrand48() such that the 32 bits of
the seed value are
copied into the upper 32 bits of r(n),
with the lower 16 bits of r(n) arbitrarily being set to 0x330E.
Additionally, the constant multiplicand
and addend of the algorithm are reset to the default values:
the multiplicand a = 0xFDEECE66D = 25214903917 and
the addend c = 0xB = 11.
POSIX 1003.1 XSI
Safety: | |
Cancellation point |
No |
Interrupt handler |
No |
Signal handler |
Yes |
Thread |
Yes |
drand48(),
erand48(),
jrand48(),
lcong48(),
lrand48(),
mrand48(),
nrand48(),
seed48()
Warning: main(/www/www/htdocs/style/footer.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/lib_ref/s/srand48.html on line 120
Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/footer.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/lib_ref/s/srand48.html on line 120