Simpact Cyan
Population based event driven simulation using mNRM
Public Member Functions | Protected Member Functions | List of all members
PopulationDistribution Class Referenceabstract

Base class for picking random numbers according to some kind of age distribution. More...

#include <populationdistribution.h>

Inheritance diagram for PopulationDistribution:
Inheritance graph
[legend]
Collaboration diagram for PopulationDistribution:
Collaboration graph
[legend]

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

GslRandomNumberGeneratorgetRandomNumberGenerator ()
 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...
 

Detailed Description

Base class for picking random numbers according to some kind of age distribution.

Constructor & Destructor Documentation

PopulationDistribution::PopulationDistribution ( GslRandomNumberGenerator pRndGen)

Constructor of the class, in which you need to specify a random number generator which can then be used internally.

Member Function Documentation

GslRandomNumberGenerator* PopulationDistribution::getRandomNumberGenerator ( )
inlineprotected

This function can be used to obtain the random number generator specified in the constructor.

virtual double PopulationDistribution::pickAge ( bool  male) const
pure virtual

This function generates the random age, for either a man or a woman.

Implemented in PopulationDistributionCSV.


The documentation for this class was generated from the following files: