INET Framework for OMNeT++/OMNEST
|
Zipf distribution random object. More...
#include <HttpRandom.h>
Public Member Functions | |
rdZipf (int n, double alpha, bool baseZero=false) | |
rdZipf (cXMLAttributeMap attributes) | |
virtual double | draw () override |
virtual std::string | toString () override |
void | setN (int n) |
int | getN () |
void | setAlpha (double alpha) |
double | getAlpha () |
Public Member Functions inherited from inet::httptools::rdObject | |
virtual | ~rdObject () |
DISTR_TYPE | getType () |
std::string | typeStr () |
Protected Attributes | |
double | m_alpha = NaN |
int | m_number = 0 |
double | m_c = NaN |
bool | m_baseZero = false |
Protected Attributes inherited from inet::httptools::rdObject | |
DISTR_TYPE | m_type = dt_normal |
Private Member Functions | |
void | __initialize (int n, double alpha, bool baseZero) |
void | __setup_c () |
Additional Inherited Members | |
Protected Member Functions inherited from inet::httptools::rdObject | |
bool | _hasKey (cXMLAttributeMap attributes, std::string key) |
Zipf distribution random object.
Returns a random value from a zipf distribution (1/n^a), where a is the constant alpha and n is a order of popularity. See more details on http://en.wikipedia.org/wiki/Zipf.
inet::httptools::rdZipf::rdZipf | ( | int | n, |
double | alpha, | ||
bool | baseZero = false |
||
) |
inet::httptools::rdZipf::rdZipf | ( | cXMLAttributeMap | attributes | ) |
|
private |
|
private |
|
overridevirtual |
Implements inet::httptools::rdObject.
|
inline |
|
inline |
|
inline |
|
inline |
|
overridevirtual |
Reimplemented from inet::httptools::rdObject.
|
protected |
|
protected |
|
protected |
|
protected |