infovis.graph
Class Algorithms
java.lang.Object
infovis.graph.Algorithms
public class Algorithms
- extends Object
- Version:
- $Revision: 1.13 $
- Author:
- Jean-Daniel Fekete
Algorithms
public Algorithms()
sortEdges
public static int[] sortEdges(Graph graph,
int vertex,
RowComparator comp)
copy
public static OpenIntIntHashMap copy(Graph fromGraph,
Graph toGraph)
- Copy one graph into another.
- Parameters:
fromGraph
- the source graphtoGraph
- the destination graph
- Returns:
- the mapping from the vertices in the source graph to the vertices
in the destination graph.
getOneCompnentGraph
public static Graph getOneCompnentGraph()
- Returns a bigger, undirected test graph with a just one component. This
graph consists of a clique of ten edges, a partial clique (randomly
generated, with edges of 0.6 probability), and one series of edges
running from the first node to the last.
Adapted from JUNG (jung.sourceforge.net)
- Returns:
- the testgraph
getGridGraph
public static Graph getGridGraph(int width,
int height)
findComponent
public static void findComponent(Graph g,
int vertex,
AbstractIntIntMap map)
labelConnectedComponents
public static int labelConnectedComponents(Graph graph,
IntColumn labels,
IntColumn sizes)
Copyright © 2005 by Jean-Daniel Fekete and INRIA, France All rights reserved.