![]() |
LINE Solver (C++)
Templated C++ port of the LINE queueing solver
|
One MATLAB global random stream, as left by rng(seed). More...
#include <line/gen/matlab_rng.h>
Public Member Functions | |
| MatlabRng (long long seed=0) | |
| void | reseed (long long seed) |
| MATLAB rng(seed). | |
| double | rand () |
| One MATLAB rand draw. | |
| int | randi (int lo, int hi) |
| MATLAB randi([lo, hi]). | |
| std::vector< std::size_t > | randperm (std::size_t n) |
| MATLAB randperm(n), returned 0-based. | |
| std::vector< double > | randfixedsum (std::size_t n, double s, double a, double b) |
| One column of randfixedsum(n,1,s,a,b) (matlab/lib/thirdparty/randfixedsum.m): draws rand(n-1,1) twice, then rand(n,1) for the permutation. | |
One MATLAB global random stream, as left by rng(seed).
Definition at line 39 of file matlab_rng.h.
|
inlineexplicit |
Definition at line 41 of file matlab_rng.h.
|
inline |
One MATLAB rand draw.
Definition at line 47 of file matlab_rng.h.
Referenced by randfixedsum(), randi(), and randperm().
|
inline |
One column of randfixedsum(n,1,s,a,b) (matlab/lib/thirdparty/randfixedsum.m): draws rand(n-1,1) twice, then rand(n,1) for the permutation.
Definition at line 67 of file matlab_rng.h.
References rand(), and randperm().
Referenced by line::gen::randfixedsumone().
|
inline |
MATLAB randi([lo, hi]).
Definition at line 50 of file matlab_rng.h.
References rand().
Referenced by line::gen::rand_spanning_tree(), and line::gen::randintfixedsum().
|
inline |
MATLAB randperm(n), returned 0-based.
Definition at line 53 of file matlab_rng.h.
References rand().
Referenced by line::gen::rand_graph(), and randfixedsum().
|
inline |
MATLAB rng(seed).
Definition at line 44 of file matlab_rng.h.