edu.uci.ics.jung.algorithms.generators.random
Class MixedRandomGraphGenerator
java.lang.Object
edu.uci.ics.jung.algorithms.generators.random.MixedRandomGraphGenerator
public class MixedRandomGraphGenerator
- extends Object
Generates a mixed-mode random graph based on the output of BarabasiAlbertGenerator
.
Primarily intended for providing a heterogeneous sample graph for visualization testing, etc.
Method Summary |
static
|
generateMixedRandomGraph(org.apache.commons.collections15.Factory<Graph<V,E>> graphFactory,
org.apache.commons.collections15.Factory<V> vertexFactory,
org.apache.commons.collections15.Factory<E> edgeFactory,
Map<E,Number> edge_weights,
int num_vertices,
boolean parallel,
Set<V> seedVertices)
Returns a random mixed-mode graph. |
static
|
generateMixedRandomGraph(org.apache.commons.collections15.Factory<Graph<V,E>> graphFactory,
org.apache.commons.collections15.Factory<V> vertexFactory,
org.apache.commons.collections15.Factory<E> edgeFactory,
Map<E,Number> edge_weight,
int num_vertices,
Set<V> seedVertices)
Equivalent to generateMixedRandomGraph(edge_weight, num_vertices, true) . |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
MixedRandomGraphGenerator
public MixedRandomGraphGenerator()
generateMixedRandomGraph
public static <V,E> Graph<V,E> generateMixedRandomGraph(org.apache.commons.collections15.Factory<Graph<V,E>> graphFactory,
org.apache.commons.collections15.Factory<V> vertexFactory,
org.apache.commons.collections15.Factory<E> edgeFactory,
Map<E,Number> edge_weight,
int num_vertices,
Set<V> seedVertices)
- Equivalent to
generateMixedRandomGraph(edge_weight, num_vertices, true)
.
generateMixedRandomGraph
public static <V,E> Graph<V,E> generateMixedRandomGraph(org.apache.commons.collections15.Factory<Graph<V,E>> graphFactory,
org.apache.commons.collections15.Factory<V> vertexFactory,
org.apache.commons.collections15.Factory<E> edgeFactory,
Map<E,Number> edge_weights,
int num_vertices,
boolean parallel,
Set<V> seedVertices)
- Returns a random mixed-mode graph. Starts with a randomly generated
Barabasi-Albert (preferential attachment) generator
(4 initial vertices, 3 edges added at each step, and num_vertices - 4 evolution steps).
Then takes the resultant graph, replaces random undirected edges with directed
edges, and assigns random weights to each edge.
Copyright © 2009. All Rights Reserved.