This package contains some examples that show the use of the RandomLib library and its components.
CMRGSimple, Mean, VariatesSimple and VariatesSimple2 are very simple examples of uniform random number and random variates generation.
Test is a larger test case for uniform random number generation. This example is based in the test code provided by L'Ecuyer with his RngStream C implementation.
This example has been used for validating the implementation of the CMRG library in comparison with the results obtained with the mentioned C implementation.
Licensed by Victorino Sanz under the Modelica License 2
Copyright 2009, Victorino Sanz.
This Modelica packages is free software and the use is completely at your ouwn risk; it can be redistributed and/or modified under the terms of the Modelica license 2, see the license conditions (including the disclaimer of warranty) here or at http://www.modelica.org/licenses/ModelicaLicense2
Name | Description |
---|---|
CMRGSimple | generates 10 random numbers from an RngStream |
Mean | generates random variates (one per second) and calculates the mean of the generated samples |
VariatesSimple | generates 5 random variates with Exponential(5) distribution |
VariatesSimple2 | generates a discrete variate of each distribution at each integration step |
Test | Pierre L'Ecuyer test program for RngStreams |