Class LinearizedChordDiagramGraphGenerator<V,E>
- Type Parameters:
V
- the graph vertex typeE
- the graph edge type
- All Implemented Interfaces:
GraphGenerator<V,
E, V>
The generator makes precise several unspecified mathematical details of the Barabási-Albert model, such as the initial configuration of the first nodes, and whether the $m$ links assigned to a new node are added one by one, or simultaneously, etc. The generator is described in the paper: Bélaa Bollobás and Oliver Riordan. The Diameter of a Scale-Free Random Graph. Journal Combinatorica, 24(1): 5--34, 2004.
In contrast with the Barabási-Albert model, the model of Bollobás and Riordan allows for multiple
edges (parallel-edges) and self-loops. They show, however, that their number will be small. This
means that this generator works only on graphs which allow multiple edges (parallel-edges) such
as Pseudograph
or DirectedPseudograph
.
The generator starts with a graph of one node and grows the network by adding $n-1$ additional nodes. The additional nodes are added one by one and each of them is connected to $m$ previously added nodes (or to itself with a small probability), where the probability of connecting to a node is proportional to its degree.
- Author:
- Dimitrios Michail
-
Constructor Summary
ConstructorDescriptionLinearizedChordDiagramGraphGenerator
(int n, int m) ConstructorLinearizedChordDiagramGraphGenerator
(int n, int m, long seed) ConstructorLinearizedChordDiagramGraphGenerator
(int n, int m, Random rng) Constructor -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.jgrapht.generate.GraphGenerator
generateGraph
-
Constructor Details
-
LinearizedChordDiagramGraphGenerator
public LinearizedChordDiagramGraphGenerator(int n, int m) Constructor- Parameters:
n
- number of nodesm
- number of edges of each new node added during the network growth- Throws:
IllegalArgumentException
- in case of invalid parameters
-
LinearizedChordDiagramGraphGenerator
public LinearizedChordDiagramGraphGenerator(int n, int m, long seed) Constructor- Parameters:
n
- number of nodesm
- number of edges of each new node added during the network growthseed
- seed for the random number generator- Throws:
IllegalArgumentException
- in case of invalid parameters
-
LinearizedChordDiagramGraphGenerator
Constructor- Parameters:
n
- number of nodesm
- number of edges of each new node added during the network growthrng
- the random number generator to use- Throws:
IllegalArgumentException
- in case of invalid parameters
-
-
Method Details
-
generateGraph
Generates an instance.- Specified by:
generateGraph
in interfaceGraphGenerator<V,
E, V> - Parameters:
target
- the target graph, which must allow self-loops and parallel edgesresultMap
- not used by this generator, can be null- Throws:
IllegalArgumentException
- if the graph does not allow self-loops or parallel edges
-