OverSim
|
Lifetime churn based on shifted pareto distribution. More...
#include <ParetoChurn.h>
Classes | |
struct | node_stat |
Public Member Functions | |
void | handleMessage (cMessage *msg) |
void | initializeChurn () |
ParetoChurn () | |
~ParetoChurn () | |
Public Member Functions inherited from ChurnGenerator | |
virtual int | numInitStages () const |
virtual void | initialize (int stage) |
void | setNodeType (const NodeType &t) |
const NodeType & | getNodeType () |
Protected Member Functions | |
void | updateDisplayString () |
void | createNode (double lifetime, double meanLifetime, double meanDeadtime, bool initialize) |
void | deleteNode (TransportAddress &addr, double meanLifetime, double meanDeadtime) |
double | shiftedPareto (double a, double b, int rng=0) |
implements a shifted pareto funcion | |
double | betaByMean (double mean, double alpha=3) |
returns a shifted pareto function's beta param by given mean and alpha | |
double | individualMeanTime (double mean) |
returns the individual mean life/dead time of a node | |
double | individualLifetime (double mean) |
returns a individual lifetime (or deadtime) based on a node's mean lifetime | |
double | residualLifetime (double mean) |
returns the resiidual lifetime (or deadtime) based on a node's mean lifetime | |
void | scheduleCreateNodeAt (double creationTime, double lifetime, double meanLifetime, double meanDeadtime) |
Private Attributes | |
GlobalStatistics * | globalStatistics |
double | initialMean |
mean of update interval during initalization phase | |
double | initialDeviation |
deviation of update interval during initalization phase | |
double | lifetimeMean |
mean node lifetime | |
double | deadtimeMean |
mean node deadtime | |
simtime_t | lastCreatetime |
simtime_t | lastDeletetime |
cMessage * | initFinishedTimer |
timer to signal end of init phase |
Additional Inherited Members | |
Public Attributes inherited from ChurnGenerator | |
bool | init |
still in initialization phase? | |
int | terminalCount |
current number of overlay terminals | |
Protected Attributes inherited from ChurnGenerator | |
UnderlayConfigurator * | underlayConfigurator |
int | targetOverlayTerminalNum |
final number of overlay terminals | |
NodeType | type |
the nodeType this generator is responsible for |
Lifetime churn based on shifted pareto distribution.
This class implements the curn model proposed in
Yao, Z.; Leonard, D.; Wang, X. & Loguinov, D. "Modeling Heterogeneous User Churn and Local Resilience of Unstructured P2P Networks" Proceedings of the 2006 14th IEEE International Conference on Network Protocols, 2006. ICNP '06. 2006, pp. 32–41
Definition at line 46 of file ParetoChurn.h.
|
inline |
Definition at line 51 of file ParetoChurn.h.
ParetoChurn::~ParetoChurn | ( | ) |
Definition at line 247 of file ParetoChurn.cc.
|
protected |
returns a shifted pareto function's beta param by given mean and alpha
mean | the wanted mean |
alpha | the alph param of the shifted pareto (defaults to 3) |
Definition at line 209 of file ParetoChurn.cc.
Referenced by individualLifetime(), individualMeanTime(), and residualLifetime().
|
protected |
Definition at line 162 of file ParetoChurn.cc.
Referenced by handleMessage().
|
protected |
Definition at line 184 of file ParetoChurn.cc.
Referenced by handleMessage().
|
virtual |
Implements ChurnGenerator.
Definition at line 132 of file ParetoChurn.cc.
|
protected |
returns a individual lifetime (or deadtime) based on a node's mean lifetime
mean | the node's men lifetime |
Definition at line 227 of file ParetoChurn.cc.
Referenced by deleteNode(), and initializeChurn().
|
protected |
returns the individual mean life/dead time of a node
mean | the global mean life/dead time |
Definition at line 221 of file ParetoChurn.cc.
Referenced by initializeChurn().
|
virtual |
Implements ChurnGenerator.
Definition at line 44 of file ParetoChurn.cc.
|
protected |
returns the resiidual lifetime (or deadtime) based on a node's mean lifetime
mean | the node's men lifetime |
Definition at line 235 of file ParetoChurn.cc.
Referenced by initializeChurn().
|
protected |
Definition at line 198 of file ParetoChurn.cc.
Referenced by deleteNode(), and initializeChurn().
|
protected |
implements a shifted pareto funcion
Definition at line 214 of file ParetoChurn.cc.
Referenced by individualLifetime(), individualMeanTime(), and residualLifetime().
|
protectedvirtual |
Implements ChurnGenerator.
Definition at line 240 of file ParetoChurn.cc.
|
private |
|
private |
Definition at line 102 of file ParetoChurn.h.
Referenced by createNode(), deleteNode(), and initializeChurn().
|
private |
timer to signal end of init phase
Definition at line 112 of file ParetoChurn.h.
Referenced by handleMessage(), initializeChurn(), ParetoChurn(), and ~ParetoChurn().
|
private |
deviation of update interval during initalization phase
Definition at line 105 of file ParetoChurn.h.
Referenced by initializeChurn().
|
private |
mean of update interval during initalization phase
Definition at line 104 of file ParetoChurn.h.
Referenced by initializeChurn().
|
private |
Definition at line 109 of file ParetoChurn.h.
Referenced by createNode(), and initializeChurn().
|
private |
Definition at line 110 of file ParetoChurn.h.
Referenced by deleteNode(), and initializeChurn().
|
private |