Discrete distribution random number generation function
RandInt(g,i,j)
Returns a rundom number from the discrete uniform distribution over the integer (i,i+1,...,j), using RngStream g
model Example
CMRG.RngStream g;
Real u[5];
algorithm
when initial() then
g := CMRG.CreateStream();
end when;
when time <= 0 then
for i in 1:5 loop
(u[i],g) := CMRG.RandInt(g);
end for;
end when;
end Example;
// u = {8,8,7,9,2}
function RandInt input RngStream g; input Integer i; input Integer j; output Integer out; output RngStream gout; end RandInt;