Public Member Functions | |
ParetoVariableImpl () | |
ParetoVariableImpl (double m) | |
ParetoVariableImpl (double m, double s) | |
ParetoVariableImpl (double m, double s, double b) | |
Constructs a pareto random variable with the specified mean. | |
ParetoVariableImpl (const ParetoVariableImpl &c) | |
virtual double | GetValue () |
virtual RandomVariableBase * | Copy () const |
Static Public Member Functions | |
static double | GetSingleValue (double m, double s, double b=0) |
Private Attributes | |
double | m_mean |
double | m_shape |
double | m_bound |
Definition at line 702 of file random-variable.cc.
ns3::ParetoVariableImpl::ParetoVariableImpl | ( | ) |
Constructs a pareto random variable with a mean of 1 and a shape parameter of 1.5
Definition at line 763 of file random-variable.cc.
Referenced by Copy().
ns3::ParetoVariableImpl::ParetoVariableImpl | ( | double | m | ) | [explicit] |
Constructs a pareto random variable with specified mean and shape parameter of 1.5
m | Mean value of the distribution |
Definition at line 766 of file random-variable.cc.
ns3::ParetoVariableImpl::ParetoVariableImpl | ( | double | m, | |
double | s | |||
) |
Constructs a pareto random variable with the specified mean value and shape parameter.
m | Mean value of the distribution | |
s | Shape parameter for the distribution |
Definition at line 769 of file random-variable.cc.
ns3::ParetoVariableImpl::ParetoVariableImpl | ( | double | m, | |
double | s, | |||
double | b | |||
) |
Constructs a pareto random variable with the specified mean.
value, shape (alpha), and upper bound. Since pareto distributions can theoretically return unbounded values, it is sometimes useful to specify a fixed upper limit. Note however when the upper limit is specified, the true mean of the distribution is slightly smaller than the mean value specified.
m | Mean value | |
s | Shape parameter | |
b | Upper limit on returned values |
Definition at line 772 of file random-variable.cc.
ns3::ParetoVariableImpl::ParetoVariableImpl | ( | const ParetoVariableImpl & | c | ) |
Definition at line 775 of file random-variable.cc.
RandomVariableBase * ns3::ParetoVariableImpl::Copy | ( | void | ) | const [virtual] |
Implements ns3::RandomVariableBase.
Definition at line 797 of file random-variable.cc.
References ParetoVariableImpl().
double ns3::ParetoVariableImpl::GetSingleValue | ( | double | m, | |
double | s, | |||
double | b = 0 | |||
) | [static] |
m | The mean value of the distribution from which the return value is drawn. | |
s | The shape parameter of the distribution from which the return value is drawn. | |
b | The upper bound to which to restrict return values |
Definition at line 802 of file random-variable.cc.
References ns3::RandomVariableBase::Initialize(), ns3::RngStream::InitializeStream(), ns3::RandomVariableBase::m_static_generator, and ns3::RngStream::RandU01().
double ns3::ParetoVariableImpl::GetValue | ( | ) | [virtual] |
Implements ns3::RandomVariableBase.
Definition at line 779 of file random-variable.cc.
References ns3::RandomVariableBase::Initialize(), ns3::RandomVariableBase::initialized, ns3::RngStream::InitializeStream(), m_bound, ns3::RandomVariableBase::m_generator, m_mean, m_shape, ns3::RngStream::RandU01(), ns3::RngStream::ResetNthSubstream(), and ns3::RandomVariableBase::runNumber.
double ns3::ParetoVariableImpl::m_bound [private] |
Definition at line 760 of file random-variable.cc.
Referenced by GetValue().
double ns3::ParetoVariableImpl::m_mean [private] |
Definition at line 758 of file random-variable.cc.
Referenced by GetValue().
double ns3::ParetoVariableImpl::m_shape [private] |
Definition at line 759 of file random-variable.cc.
Referenced by GetValue().