Computes Dijkstra's shortest path
Constructor | Description |
|
|
Static member | Description |
Full Usage:
Dijkstra.compute (starting, getEdgeWeight, graph)
Parameters:
'NodeKey
getEdgeWeight : 'EdgeData -> float
graph : DiGraph<'NodeKey, 'a, 'EdgeData>
Returns: ('NodeKey * float)[]
|
|
Full Usage:
Dijkstra.compute (starting, graph)
Parameters:
'NodeKey
graph : AdjGraph<'NodeKey, 'NodeData, 'EdgeData>
Returns: Dictionary<'NodeKey, float>
|
|
Full Usage:
Dijkstra.compute (starting, graph)
Parameters:
'NodeKey
graph : FGraph<'NodeKey, 'NodeData, 'EdgeData>
Returns: Dictionary<'NodeKey, float>
|
|
Full Usage:
Dijkstra.computeBetween (origin, destination, graph)
Parameters:
'NodeKey
destination : 'NodeKey
graph : DiGraph<'NodeKey, 'NodeData, float>
Returns: 'a
|
|
Full Usage:
Dijkstra.computeBetween (origin, destination, graph)
Parameters:
'NodeKey
destination : 'NodeKey
graph : FGraph<'NodeKey, 'NodeData, float>
Returns: 'a
|
|
Full Usage:
Dijkstra.computeWithEdgeData (starting, graph)
Parameters:
'NodeKey
graph : AdjGraph<'NodeKey, 'NodeData, float>
Returns: Dictionary<'NodeKey, float>
|
|
Full Usage:
Dijkstra.computeWithEdgeData (starting, graph)
Parameters:
'NodeKey
graph : FGraph<'NodeKey, 'NodeData, float>
Returns: Dictionary<'NodeKey, float>
|
|
Full Usage:
Dijkstra.computeWithEdgeDataBy (starting, getEdgeWeight, graph)
Parameters:
'NodeKey
getEdgeWeight : 'EdgeData -> float
graph : AdjGraph<'NodeKey, 'NodeData, 'EdgeData>
Returns: Dictionary<'NodeKey, float>
|
|
Full Usage:
Dijkstra.computeWithEdgeDataBy (starting, getEdgeWeight, graph)
Parameters:
'NodeKey
getEdgeWeight : 'EdgeData -> float
graph : FGraph<'NodeKey, 'NodeData, 'EdgeData>
Returns: Dictionary<'NodeKey, float>
|
|
Full Usage:
Dijkstra.ofAdjGraph starting getEdgeWeight graph
Parameters:
'NodeKey
getEdgeWeight : 'EdgeData -> float
graph : AdjGraph<'NodeKey, 'NodeData, 'EdgeData>
Returns: Dictionary<'NodeKey, float>
|
|
Full Usage:
Dijkstra.ofDiGraph source getEdgeWeight graph
Parameters:
'NodeKey
-
Calculate the shortest paths from this node.
getEdgeWeight : 'EdgeData -> float
graph : DiGraph<'NodeKey, 'a, 'EdgeData>
-
The graph for which to compute the shortest path.
Returns: ('NodeKey * float)[]
Tuples of target node and distance.
|
If there isn't a path between two edges, the distance is set to `infinity`.
|
Full Usage:
Dijkstra.ofDiGraphAllPairs getEdgeWeight graph
Parameters:
'EdgeData -> float
graph : DiGraph<'NodeKey, 'a, 'EdgeData>
-
The graph for which to compute the shortest paths.
Returns: 'NodeKey[] * float[][]
The ordered array of nodes and 2D Array of distances where each
row and column index corresponds to a node's index in the nodes array.
|
If there isn't a path between two edges, the distance is set to `infinity`.
|
Full Usage:
Dijkstra.ofDiGraphAllPairsWithPath getEdgeWeight graph
Parameters:
'EdgeData -> float
graph : DiGraph<'NodeKey, 'a, 'EdgeData>
-
The graph for which to compute the shortest path.
Returns: ('NodeKey * 'NodeKey * float * 'NodeKey[] option)[][]
Array of tuples of source NodeKey, target NodeKey, distance, and path option.
|
If there isn't a path between two edges, the distance is set to `infinity`. Path only contains intermediate steps.
|
Full Usage:
Dijkstra.ofDiGraphBetween getEdgeWeight graph origin destination
Parameters:
'EdgeData -> float
graph : DiGraph<'NodeKey, 'NodeData, 'EdgeData>
-
The graph to be analysed
origin : 'NodeKey
-
The starting node of the path
destination : 'NodeKey
-
The finishing node of the path
Returns: float option
A float of the distance
|
|
Full Usage:
Dijkstra.ofDiGraphWithPath source getEdgeWeight graph
Parameters:
'NodeKey
-
Calculate the shortest paths from this node.
getEdgeWeight : 'EdgeData -> float
graph : DiGraph<'NodeKey, 'a, 'EdgeData>
-
The graph for which to compute the shortest path.
Returns: ('NodeKey * 'NodeKey * float * 'NodeKey[] option)[]
Array of tuples of source NodeKey, target NodeKey, distance, and path option.
|
If there isn't a path between two edges, the distance is set to `infinity`. Path only contains intermediate steps.
|
Full Usage:
Dijkstra.ofFGraph starting getEdgeWeight graph
Parameters:
'NodeKey
getEdgeWeight : 'EdgeData -> float
graph : FGraph<'NodeKey, 'NodeData, 'EdgeData>
Returns: Dictionary<'NodeKey, float>
|
|
Full Usage:
Dijkstra.ofUndirected source getEdgeWeight graph
Parameters:
'NodeKey
-
Calculate the shortest paths from this node.
getEdgeWeight : 'EdgeData -> float
graph : UndirectedGraph<'NodeKey, 'NodeData, 'EdgeData>
-
The graph for which to compute the shortest path.
Returns: ('NodeKey * float)[]
Tuples of target node and distance.
|
If there isn't a path between two edges, the distance is set to `infinity`.
|
Full Usage:
Dijkstra.ofUndirectedAllPairs getEdgeWeight graph
Parameters:
'EdgeData -> float
graph : UndirectedGraph<'NodeKey, 'NodeData, 'EdgeData>
-
The graph for which to compute the shortest paths.
Returns: 'NodeKey[] * float[][]
The ordered array of nodes and 2D Array of distances where each
row and column index corresponds to a node's index in the nodes array.
|
If there isn't a path between two edges, the distance is set to `infinity`.
|
Full Usage:
Dijkstra.ofUndirectedAllPairsWithPath getEdgeWeight graph
Parameters:
'EdgeData -> float
graph : UndirectedGraph<'NodeKey, 'NodeData, 'EdgeData>
-
The graph for which to compute the shortest path.
Returns: ('NodeKey * 'NodeKey * float * 'NodeKey[] option)[][]
Array of tuples of source NodeKey, target NodeKey, distance, and path option.
|
If there isn't a path between two edges, the distance is set to `infinity`. Path only contains intermediate steps.
|
Full Usage:
Dijkstra.ofUndirectedFGraphIncludingPath starting getEdgeWeight graph
Parameters:
'NodeKey
getEdgeWeight : 'EdgeData -> float
graph : AdjGraph<'NodeKey, 'NodeData, 'EdgeData>
Returns: Dictionary<'NodeKey, ('NodeKey * float)>
|
|
Full Usage:
Dijkstra.ofUndirectedWithPath source getEdgeWeight graph
Parameters:
'NodeKey
-
Calculate the shortest paths from this node.
getEdgeWeight : 'EdgeData -> float
graph : UndirectedGraph<'NodeKey, 'NodeData, 'EdgeData>
-
The graph for which to compute the shortest path.
Returns: ('NodeKey * 'NodeKey * float * 'NodeKey[] option)[]
Array of tuples of source NodeKey, target NodeKey, distance, and path option.
|
If there isn't a path between two edges, the distance is set to `infinity`. Path only contains intermediate steps.
|