Examples demonstrating the usage of the functions in package Random
This package contains examples demonstrating the usage of the functions in package Random.
Extends from Modelica.Icons.ExamplesPackage (Icon for packages containing runnable examples).
Name | Description |
---|---|
GenerateRandomNumbers | Generate random numbers with the various random number generators |
Generate random numbers with the various random number generators
This example demonstrates how to utilize the random number generators of package Math.Random.Generators in a Modelica model. The example calculates random numbers in the range 0 .. 1 of the available random number generators periodically with a sample period of 0.05 s. Simulations results are shown in the figure below:
Extends from Modelica.Icons.Example (Icon for runnable examples).
Name | Description |
---|---|
samplePeriod | Sample period for the generation of random numbers [s] |
globalSeed | Global seed to initialize random number generator |
localSeed | Local seed to initialize random number generator |
id | A unique number used to sort equations correctly |