public class ErdosRenyiGenerator extends java.lang.Object implements GraphGenerator
Constructor and Description |
---|
ErdosRenyiGenerator(int numVertices,
double p) |
Modifier and Type | Method and Description |
---|---|
ArchetypeGraph |
generateGraph()
Returns a graph in which each pair of vertices is connected by
an undirected edge with the probability specified by the constructor.
|
void |
setSeed(long seed) |
public ErdosRenyiGenerator(int numVertices, double p)
numVertices
- number of vertices graph should havep
- Connection's probability between 2 verticespublic ArchetypeGraph generateGraph()
generateGraph
in interface GraphGenerator
public void setSeed(long seed)