Simpact Cyan
Population based event driven simulation using mNRM
|
Base class for picking random numbers according to some kind of age distribution. More...
#include <populationdistribution.h>
Public Member Functions | |
PopulationDistribution (GslRandomNumberGenerator *pRndGen) | |
Constructor of the class, in which you need to specify a random number generator which can then be used internally. More... | |
virtual double | pickAge (bool male) const =0 |
This function generates the random age, for either a man or a woman. More... | |
Public Member Functions inherited from errut::ErrorBase | |
ErrorBase () | |
Creates an instance without an explicit object name. More... | |
ErrorBase (const std::string &objName) | |
Creates an instance with the object name set to objName . More... | |
std::string | getObjectName () const |
Returns the stored object name. More... | |
std::string | getErrorString () const |
Returns the currently stored error message. More... | |
Protected Member Functions | |
GslRandomNumberGenerator * | getRandomNumberGenerator () |
This function can be used to obtain the random number generator specified in the constructor. More... | |
Protected Member Functions inherited from errut::ErrorBase | |
void | setErrorString (const std::string &str) const |
Derived classes can use this member function to store an error message. More... | |
Base class for picking random numbers according to some kind of age distribution.
PopulationDistribution::PopulationDistribution | ( | GslRandomNumberGenerator * | pRndGen | ) |
Constructor of the class, in which you need to specify a random number generator which can then be used internally.
|
inlineprotected |
This function can be used to obtain the random number generator specified in the constructor.
|
pure virtual |
This function generates the random age, for either a man or a woman.
Implemented in PopulationDistributionCSV.