File randgraph.hpp¶
FileList > epiworld > randgraph.hpp
Go to the source code of this file
Public Functions¶
| Type | Name |
|---|---|
| void | rewire_degseq (TDat * agents, Model< TSeq > * model, epiworld_double proportion) |
| void | rewire_degseq (std::vector< Agent< TSeq > > * agents, Model< TSeq > * model, epiworld_double proportion) |
| void | rewire_degseq (AdjList * agents, Model< TSeq > * model, epiworld_double proportion) |
| AdjList | rgraph_bernoulli (epiworld_fast_uint n, epiworld_double p, bool directed, Model< TSeq > & model) |
| AdjList | rgraph_bernoulli2 (epiworld_fast_uint n, epiworld_double p, bool directed, Model< TSeq > & model) |
| AdjList | rgraph_blocked (epiworld_fast_uint n, epiworld_fast_uint blocksize, epiworld_fast_uint ncons, Model< TSeq > &) Generates a blocked network. |
| AdjList | rgraph_ring_lattice (epiworld_fast_uint n, epiworld_fast_uint k, bool directed=false) |
| AdjList | rgraph_smallworld (epiworld_fast_uint n, epiworld_fast_uint k, epiworld_double p, bool directed, Model< TSeq > & model) Smallworld network (Watts-Strogatz) |
Public Functions Documentation¶
function rewire_degseq¶
template<typename TSeq, typename TDat>
inline void rewire_degseq (
TDat * agents,
Model < TSeq > * model,
epiworld_double proportion
)
function rewire_degseq¶
template<typename TSeq>
inline void rewire_degseq (
std::vector< Agent < TSeq > > * agents,
Model < TSeq > * model,
epiworld_double proportion
)
function rewire_degseq¶
template<typename TSeq>
inline void rewire_degseq (
AdjList * agents,
Model < TSeq > * model,
epiworld_double proportion
)
function rgraph_bernoulli¶
template<typename TSeq>
inline AdjList rgraph_bernoulli (
epiworld_fast_uint n,
epiworld_double p,
bool directed,
Model < TSeq > & model
)
function rgraph_bernoulli2¶
template<typename TSeq>
inline AdjList rgraph_bernoulli2 (
epiworld_fast_uint n,
epiworld_double p,
bool directed,
Model < TSeq > & model
)
function rgraph_blocked¶
Generates a blocked network.
template<typename TSeq>
inline AdjList rgraph_blocked (
epiworld_fast_uint n,
epiworld_fast_uint blocksize,
epiworld_fast_uint ncons,
Model < TSeq > &
)
Since block sizes and number of connections between blocks are fixed, this routine is fully deterministic.
Template parameters:
TSeq
Parameters:
nSize of the networkblocksizeSize of the block.nconsNumber of connections between blocksmodelA model
Returns:
function rgraph_ring_lattice¶
inline AdjList rgraph_ring_lattice (
epiworld_fast_uint n,
epiworld_fast_uint k,
bool directed=false
)
function rgraph_smallworld¶
Smallworld network (Watts-Strogatz)
template<typename TSeq>
inline AdjList rgraph_smallworld (
epiworld_fast_uint n,
epiworld_fast_uint k,
epiworld_double p,
bool directed,
Model < TSeq > & model
)
Template parameters:
TSeq
Parameters:
nkpdirectedmodel
Returns:
The documentation for this class was generated from the following file epiworld-src/include/epiworld/randgraph.hpp