Skip to content

Commit

Permalink
Merge e7a7cfc into 4724646
Browse files Browse the repository at this point in the history
  • Loading branch information
IvanIsCoding committed May 5, 2022
2 parents 4724646 + e7a7cfc commit 031445b
Show file tree
Hide file tree
Showing 11 changed files with 1,451 additions and 3 deletions.
1 change: 1 addition & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 9 additions & 0 deletions docs/source/api.rst
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,10 @@ Shortest Paths
retworkx.dijkstra_shortest_path_lengths
retworkx.all_pairs_dijkstra_shortest_paths
retworkx.all_pairs_dijkstra_path_lengths
retworkx.bellman_ford_shortest_paths
retworkx.bellman_ford_shortest_path_lengths
retworkx.negative_edge_cycle
retworkx.find_negative_cycle
retworkx.distance_matrix
retworkx.floyd_warshall
retworkx.floyd_warshall_numpy
Expand Down Expand Up @@ -273,6 +277,8 @@ the functions from the explicitly typed based on the data type.
retworkx.digraph_all_pairs_dijkstra_shortest_paths
retworkx.digraph_dijkstra_shortest_path_lengths
retworkx.digraph_all_pairs_dijkstra_path_lengths
retworkx.digraph_bellman_ford_shortest_path_lengths
retworkx.digraph_bellman_ford_shortest_path_lengths
retworkx.digraph_k_shortest_path_lengths
retworkx.digraph_dfs_edges
retworkx.digraph_dfs_search
Expand Down Expand Up @@ -323,6 +329,8 @@ typed API based on the data type.
retworkx.graph_all_pairs_dijkstra_shortest_paths
retworkx.graph_k_shortest_path_lengths
retworkx.graph_all_pairs_dijkstra_path_lengths
retworkx.graph_bellman_ford_shortest_path_lengths
retworkx.graph_bellman_ford_shortest_path_lengths
retworkx.graph_dfs_edges
retworkx.graph_dfs_search
retworkx.graph_transitivity
Expand Down Expand Up @@ -353,6 +361,7 @@ Exceptions
retworkx.DAGWouldCycle
retworkx.NoEdgeBetweenNodes
retworkx.DAGHasCycle
retworkx.NegativeCycle
retworkx.NoSuitableNeighbors
retworkx.NoPathFound
retworkx.NullGraph
Expand Down
11 changes: 11 additions & 0 deletions releasenotes/notes/bellman-ford-ebeb580222000f56.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
features:
- |
Added new functions to compute negative cycles and the shortest path
in graphs with negative edge weights using the Bellman-Ford
algorithm with the SPFA heuristic:
* :func:`retworkx.find_negative_cycle`
* :func:`retworkx.bellman_ford_path_lengths`
* :func:`retworkx.bellman_ford_shortest_paths`
* :func:`retworkx.edge_negative_cycle`
1 change: 1 addition & 0 deletions retworkx-core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ keywords = ["graph"]

[dependencies]
ahash = { version = "0.7.6", default-features = false }
fixedbitset = "0.4.1"
petgraph = "0.6.0"
rayon = "1.5"

Expand Down

0 comments on commit 031445b

Please sign in to comment.