QuickGraph


AlgorithmExtensions

Namespace: QuickGraph.Algorithms

Various extension methods to build algorithms

Static members

Static memberDescription
Clone(...)
Signature: (g:IVertexAndEdgeListGraph<'TVertex,'TEdge> * vertexCloner:Func<'TVertex,'TVertex> * edgeCloner:Func<'TEdge,'TVertex,'TVertex,'TEdge> * clone:IMutableVertexAndEdgeSet<'TVertex,'TEdge>) -> unit
Type parameters: 'TVertex, 'TEdge

Clones a graph to another graph

ComputeDisjointSet(visitedGraph)
Signature: visitedGraph:IUndirectedGraph<'TVertex,'TEdge> -> IDisjointSet<'TVertex>
Type parameters: 'TVertex, 'TEdge
ComputePredecessorCost(...)
Signature: (predecessors:IDictionary<'TVertex,'TEdge> * edgeCosts:IDictionary<'TEdge,float> * target:'TVertex) -> float
Type parameters: 'TVertex, 'TEdge

Given a edge cost map, computes the predecessor cost.

ComputeTransitiveClosure(...)
Signature: (visitedGraph:BidirectionalGraph<'TVertex,'TEdge> * createEdge:Func<'TVertex,'TVertex,'TEdge>) -> BidirectionalGraph<'TVertex,'TEdge>
Type parameters: 'TVertex, 'TEdge
ComputeTransitiveReduction(visitedGraph)
Signature: visitedGraph:BidirectionalGraph<'TVertex,'TEdge> -> BidirectionalGraph<'TVertex,'TEdge>
Type parameters: 'TVertex, 'TEdge
CondensateEdges(...)
Signature: (visitedGraph:IBidirectionalGraph<'TVertex,'TEdge> * vertexPredicate:VertexPredicate<'TVertex>) -> IMutableBidirectionalGraph<'TVertex,MergedEdge<'TVertex,'TEdge>>
Type parameters: 'TVertex, 'TEdge
CondensateStronglyConnected(g)
Signature: g:IVertexAndEdgeListGraph<'TVertex,'TEdge> -> IMutableBidirectionalGraph<'TGraph,CondensedEdge<'TVertex,'TEdge,'TGraph>>
Type parameters: 'TVertex, 'TEdge, 'TGraph

Condensates the strongly connected components of a directed graph

CondensateWeaklyConnected(g)
Signature: g:IVertexAndEdgeListGraph<'TVertex,'TEdge> -> IMutableBidirectionalGraph<'TGraph,CondensedEdge<'TVertex,'TEdge,'TGraph>>
Type parameters: 'TVertex, 'TEdge, 'TGraph

Condensates the weakly connected components of a graph

ConnectedComponents(g, components)
Signature: (g:IUndirectedGraph<'TVertex,'TEdge> * components:IDictionary<'TVertex,int>) -> int
Type parameters: 'TVertex, 'TEdge

Computes the connected components of a graph

GetEdgeIdentity(graph)
Signature: graph:IEdgeSet<'TVertex,'TEdge> -> EdgeIdentity<'TVertex,'TEdge>
Type parameters: 'TVertex, 'TEdge

Gets the edge identity.

GetIndexer(dictionary)
Signature: dictionary:Dictionary<'TKey,'TValue> -> Func<'TKey,'TValue>
Type parameters: 'TKey, 'TValue

Returns the method that implement the access indexer.

GetVertexIdentity(graph)
Signature: graph:IVertexSet<'TVertex> -> VertexIdentity<'TVertex>
Type parameters: 'TVertex

Gets the vertex identity.

IncrementalConnectedComponents(g)
Signature: g:IMutableVertexAndEdgeSet<'TVertex,'TEdge> -> Func<KeyValuePair<int,IDictionary<'TVertex,int>>>
Type parameters: 'TVertex, 'TEdge

Computes the incremental connected components for a growing graph (edge added only). Each call to the delegate re-computes the component dictionary. The returned dictionary is shared accross multiple calls of the method.

IsDirectedAcyclicGraph(g)
Signature: g:IVertexListGraph<'TVertex,'TEdge> -> bool
Type parameters: 'TVertex, 'TEdge

Gets a value indicating whether the graph is acyclic

IsolatedVertices(visitedGraph)
Signature: visitedGraph:IBidirectionalGraph<'TVertex,'TEdge> -> IEnumerable<'TVertex>
Type parameters: 'TVertex, 'TEdge

Gets the list of isolated vertices (no incoming or outcoming vertices)

MaximumFlowEdmondsKarp(...)
Signature: (visitedGraph:IMutableVertexAndEdgeListGraph<'TVertex,'TEdge> * edgeCapacities:Func<'TEdge,float> * source:'TVertex * sink:'TVertex * flowPredecessors:byref<TryFunc<'TVertex,'TEdge>> * edgeFactory:EdgeFactory<'TVertex,'TEdge>) -> float
Type parameters: 'TVertex, 'TEdge

Computes the Edmonds-Karp maximums flow for a graph with positive capacities and flows.

MinimumSpanningTreeKruskal(...)
Signature: (visitedGraph:IUndirectedGraph<'TVertex,'TEdge> * weights:Func<'TEdge,float>) -> IEnumerable<'TEdge>
Type parameters: 'TVertex, 'TEdge

Computes the minimum spanning tree using Kruskal's algorithm.

MinimumSpanningTreePrim(...)
Signature: (visitedGraph:IUndirectedGraph<'TVertex,'TEdge> * weights:Func<'TEdge,float>) -> IEnumerable<'TEdge>
Type parameters: 'TVertex, 'TEdge

Computes the minimum spanning tree using Prim's algorithm. Prim's algorithm is simply implemented by calling Dijkstra shortest path.

OddVertices(g)
Signature: g:IVertexAndEdgeListGraph<'TVertex,'TEdge> -> List<'TVertex>
Type parameters: 'TVertex, 'TEdge

Create a collection of odd vertices

OfflineLeastCommonAncestorTarjan(...)
Signature: (visitedGraph:IVertexListGraph<'TVertex,'TEdge> * root:'TVertex * pairs:IEnumerable<SEquatableEdge<'TVertex>>) -> TryFunc<SEquatableEdge<'TVertex>,'TVertex>
Type parameters: 'TVertex, 'TEdge

Computes the offline least common ancestor between pairs of vertices in a rooted tree using Tarjan algorithm.

RankedShortestPathHoffmanPavley(...)
Signature: (visitedGraph:IBidirectionalGraph<'TVertex,'TEdge> * edgeWeights:Func<'TEdge,float> * source:'TVertex * target:'TVertex * pathCount:int) -> IEnumerable<IEnumerable<'TEdge>>
Type parameters: 'TVertex, 'TEdge

Computes the k-shortest path from using Hoffman-Pavley algorithm.

Roots(visitedGraph)
Signature: visitedGraph:IBidirectionalGraph<'TVertex,'TEdge> -> IEnumerable<'TVertex>
Type parameters: 'TVertex, 'TEdge

Gets the list of root vertices

Roots(visitedGraph)
Signature: visitedGraph:IVertexListGraph<'TVertex,'TEdge> -> IEnumerable<'TVertex>
Type parameters: 'TVertex, 'TEdge

Gets the list of roots

ShortestPathsAStar(...)
Signature: (visitedGraph:IVertexAndEdgeListGraph<'TVertex,'TEdge> * edgeWeights:Func<'TEdge,float> * costHeuristic:Func<'TVertex,float> * source:'TVertex) -> TryFunc<'TVertex,IEnumerable<'TEdge>>
Type parameters: 'TVertex, 'TEdge
ShortestPathsBellmanFord(...)
Signature: (visitedGraph:IVertexAndEdgeListGraph<'TVertex,'TEdge> * edgeWeights:Func<'TEdge,float> * source:'TVertex) -> TryFunc<'TVertex,IEnumerable<'TEdge>>
Type parameters: 'TVertex, 'TEdge
ShortestPathsDag(...)
Signature: (visitedGraph:IVertexAndEdgeListGraph<'TVertex,'TEdge> * edgeWeights:Func<'TEdge,float> * source:'TVertex) -> TryFunc<'TVertex,IEnumerable<'TEdge>>
Type parameters: 'TVertex, 'TEdge
ShortestPathsDijkstra(...)
Signature: (visitedGraph:IUndirectedGraph<'TVertex,'TEdge> * edgeWeights:Func<'TEdge,float> * source:'TVertex) -> TryFunc<'TVertex,IEnumerable<'TEdge>>
Type parameters: 'TVertex, 'TEdge
ShortestPathsDijkstra(...)
Signature: (visitedGraph:IVertexAndEdgeListGraph<'TVertex,'TEdge> * edgeWeights:Func<'TEdge,float> * source:'TVertex) -> TryFunc<'TVertex,IEnumerable<'TEdge>>
Type parameters: 'TVertex, 'TEdge
Sinks(visitedGraph)
Signature: visitedGraph:IVertexListGraph<'TVertex,'TEdge> -> IEnumerable<'TVertex>
Type parameters: 'TVertex, 'TEdge

Gets the list of sink vertices

SourceFirstBidirectionalTopologicalSort(...)
Signature: (visitedGraph:IBidirectionalGraph<'TVertex,'TEdge> * direction:TopologicalSortDirection) -> IEnumerable<'TVertex>
Type parameters: 'TVertex, 'TEdge
SourceFirstBidirectionalTopologicalSort(...)
Signature: visitedGraph:IBidirectionalGraph<'TVertex,'TEdge> -> IEnumerable<'TVertex>
Type parameters: 'TVertex, 'TEdge
SourceFirstBidirectionalTopologicalSort(...)
Signature: (visitedGraph:IBidirectionalGraph<'TVertex,'TEdge> * vertices:IList<'TVertex> * direction:TopologicalSortDirection) -> unit
Type parameters: 'TVertex, 'TEdge
SourceFirstBidirectionalTopologicalSort(...)
Signature: (visitedGraph:IBidirectionalGraph<'TVertex,'TEdge> * vertices:IList<'TVertex>) -> unit
Type parameters: 'TVertex, 'TEdge
SourceFirstTopologicalSort(visitedGraph)
Signature: visitedGraph:IVertexAndEdgeListGraph<'TVertex,'TEdge> -> IEnumerable<'TVertex>
Type parameters: 'TVertex, 'TEdge
SourceFirstTopologicalSort(...)
Signature: (visitedGraph:IVertexAndEdgeListGraph<'TVertex,'TEdge> * vertices:IList<'TVertex>) -> unit
Type parameters: 'TVertex, 'TEdge
StronglyConnectedComponents(...)
Signature: (g:IVertexListGraph<'TVertex,'TEdge> * components:byref<IDictionary<'TVertex,int>>) -> int
Type parameters: 'TVertex, 'TEdge

Computes the strongly connected components of a graph

TopologicalSort(visitedGraph)
Signature: visitedGraph:IUndirectedGraph<'TVertex,'TEdge> -> IEnumerable<'TVertex>
Type parameters: 'TVertex, 'TEdge

Creates a topological sort of a undirected acyclic graph.

TopologicalSort(visitedGraph, vertices)
Signature: (visitedGraph:IUndirectedGraph<'TVertex,'TEdge> * vertices:IList<'TVertex>) -> unit
Type parameters: 'TVertex, 'TEdge

Creates a topological sort of a undirected acyclic graph.

TopologicalSort(visitedGraph)
Signature: visitedGraph:IVertexListGraph<'TVertex,'TEdge> -> IEnumerable<'TVertex>
Type parameters: 'TVertex, 'TEdge

Creates a topological sort of a directed acyclic graph.

TopologicalSort(visitedGraph, vertices)
Signature: (visitedGraph:IVertexListGraph<'TVertex,'TEdge> * vertices:IList<'TVertex>) -> unit
Type parameters: 'TVertex, 'TEdge

Creates a topological sort of a directed acyclic graph.

TreeBreadthFirstSearch(...)
Signature: (visitedGraph:IVertexListGraph<'TVertex,'TEdge> * root:'TVertex) -> TryFunc<'TVertex,IEnumerable<'TEdge>>
Type parameters: 'TVertex, 'TEdge
TreeCyclePoppingRandom(...)
Signature: (visitedGraph:IVertexListGraph<'TVertex,'TEdge> * root:'TVertex) -> TryFunc<'TVertex,IEnumerable<'TEdge>>
Type parameters: 'TVertex, 'TEdge
TreeCyclePoppingRandom(...)
Signature: (visitedGraph:IVertexListGraph<'TVertex,'TEdge> * root:'TVertex * edgeChain:IMarkovEdgeChain<'TVertex,'TEdge>) -> TryFunc<'TVertex,IEnumerable<'TEdge>>
Type parameters: 'TVertex, 'TEdge
TreeDepthFirstSearch(visitedGraph, root)
Signature: (visitedGraph:IVertexListGraph<'TVertex,'TEdge> * root:'TVertex) -> TryFunc<'TVertex,IEnumerable<'TEdge>>
Type parameters: 'TVertex, 'TEdge

Computes a depth first tree.

WeaklyConnectedComponents(g, components)
Signature: (g:IVertexListGraph<'TVertex,'TEdge> * components:IDictionary<'TVertex,int>) -> int
Type parameters: 'TVertex, 'TEdge

Computes the weakly connected components of a graph

Fork me on GitHub