Generation of very simple pseudo-random numbers.
#include <LcgRandom.h>
|
Protected Member Functions inherited from marenv::calc::LcgRandomBase |
| | LcgRandomBase (uint32_t seed) |
| |
| uint32_t | rnd () |
| |
Protected Attributes inherited from marenv::calc::LcgRandomBase |
|
uint32_t | _seed |
| | The current seed (changed for each random number generation).
|
| |
|
uint32_t | a |
| | Integer used in the generation of next random number.
|
| |
|
uint32_t | c |
| | Integer used in the generation of next random number.
|
| |
|
uint32_t | m |
| | Integer used in the generation of next random number.
|
| |
◆ LcgRandomTrunc()
| marenv::calc::LcgRandomTrunc::LcgRandomTrunc |
( |
uint32_t |
seed = 0 | ) |
|
Constructs the random number generator with a seed number
- Parameters
-
◆ rnd()
| uint32_t marenv::calc::LcgRandomTrunc::rnd |
( |
| ) |
|
Get random integer between 0 and 4294967295
- Returns
- Random integer between 0 and 4294967295
The documentation for this class was generated from the following file:
- /update_root/webfhsim/reloadrepos/marenv/include/marenv/calc/LcgRandom.h