org.jgrapht.experimental
Class PartiteRandomGraphGenerator<V,E>

java.lang.Object
  extended by org.jgrapht.experimental.PartiteRandomGraphGenerator<V,E>
All Implemented Interfaces:
GraphGenerator<V,E,Object[]>

public class PartiteRandomGraphGenerator<V,E>
extends Object
implements GraphGenerator<V,E,Object[]>

PartiteRandomGraphGenerator generates a partite uniform random graph of any size. A partite uniform random graph contains edges chosen independently uniformly at random from the set of possible edges between partition classes.

Since:
Sep 13, 2004
Author:
Michael Behrisch

Constructor Summary
PartiteRandomGraphGenerator(int[] numVertices, int numEdges)
          Construct a new PartiteRandomGraphGenerator for a k-partite graph.
PartiteRandomGraphGenerator(int numVertices1, int numVertices2, int numEdges)
          Construct a new PartiteRandomGraphGenerator for a bipartite graph.
 
Method Summary
 void generateGraph(Graph<V,E> target, VertexFactory<V> vertexFactory, Map<String,Object[]> resultMap)
          TODO hb 30-nov-05: document me
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PartiteRandomGraphGenerator

public PartiteRandomGraphGenerator(int numVertices1,
                                   int numVertices2,
                                   int numEdges)
Construct a new PartiteRandomGraphGenerator for a bipartite graph.

Parameters:
numVertices1 - number of vertices in the first partition
numVertices2 - number of vertices in the second partition
numEdges - number of edges to be generated
Throws:
IllegalArgumentException

PartiteRandomGraphGenerator

public PartiteRandomGraphGenerator(int[] numVertices,
                                   int numEdges)
Construct a new PartiteRandomGraphGenerator for a k-partite graph.

Parameters:
numVertices - number of vertices in the k partitions
numEdges - number of edges to be generated between any two partitions
Throws:
IllegalArgumentException
Method Detail

generateGraph

public void generateGraph(Graph<V,E> target,
                          VertexFactory<V> vertexFactory,
                          Map<String,Object[]> resultMap)
TODO hb 30-nov-05: document me

Specified by:
generateGraph in interface GraphGenerator<V,E,Object[]>
Parameters:
target -
vertexFactory -
resultMap - some array of vertices
See Also:
GraphGenerator.generateGraph(org.jgrapht.Graph, org.jgrapht.VertexFactory, java.util.Map)


Copyright © 2013. All rights reserved.