An implementation of the recurrence of WELL generators in R language
Description
An implementation of the recurrence of WELL generators in R language for testing purposes. It is too slow to be used for random number generation.
Usage
1 2 
rngWELLScriptR(n, s, generator, includeState=FALSE)

Arguments
n 
Integer. The length of the output sequence. 
s 
An 0,1matrix representing the state of the required WELL generator
as obtained by 
generator 
Character string. Name of the generator from the list

includeState 
Logical. Controls, whether the output should contain the final internal state additionally to the numerical output or not. 
Value
If includeState=FALSE
, a numeric vector of length n
containing
the numerical output of the generator.
If includeState=TRUE
, a list with components x
(the numerical
output) and state
(the final internal state of the generator).
See Also
getWELLState
Examples
1 2 3 4 5 6  set.generator("WELL", order=512, version="a", seed=123456)
s < getWELLState()
x < runif(500)
y < rngWELLScriptR(500, s, "512a")
all(x == y)
# [1] TRUE
