<< randperm | Random |
lst = rng('enginelist') |
rng('default') |
s = rng('default') |
rng('shuffle') |
s = rng('shuffle') |
rng(seed) |
s = rng(seed) |
rng(seed, generator) |
s = rng(seed, generator) |
rng('shuffle', generator) |
s = rng('shuffle', generator) |
s = rng |
rng(s) |
an integer value: new seed for random generator
a string: 'twister', 'twister64', 'laggedfibonacci607'
a struct
a cell of strings.
a struct
lst = rng('enginelist') returns the list of available random number generator.
rng('default') puts the settings of the random number generator to default values.
s = rng('default') puts the settings of the random number generator to default values.
rng('shuffle') puts the settings of the random number generator to default values and returns previous generator as an struct.
s = rng('shuffle') seeds the random number generator based on the current time.
rng(seed) seeds the random number generator using the nonnegative integer.
s = rng(seed) seeds the random number generator using the nonnegative integer and returns previous generator as an struct.
rng(seed, generator) seeds the random number generator using the nonnegative integer and specify also the type of generator used.
s = rng(seed, generator) seeds the random number generator using the nonnegative integer and specify also the type of generator used and returns previous generator as an struct.
rng('shuffle', generator) seeds the random number generator based on the current time and specify also the type of generator used.
s = rng('shuffle', generator) seeds the random number generator based on the current time,specify also the type of generator used and returns previous generator as an struct.
s = rng returns current generator as an struct.
rng(s) restores the settings of the random number generator using a previous struct returned by s = rng.
rng('default');
r = rng()
lst = rng('enginelist')
Version | Description |
---|---|
1.0.0 | initial version |
Allan CORNET