-
Notifications
You must be signed in to change notification settings - Fork 325
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Floyd-Warshall #377
Floyd-Warshall #377
Conversation
I don't know why rustfmt check is failing. |
(Coming from the Reddit post about prepona.) I tried running |
Hi! The rustfmt errors in master where fixed in 56feb0b. They should be fixed if you rebase. |
Hi! I'll do it today. Thanks for your help. |
put BoundedMeasure trait alongside Measure trait implement BoundedMeasure trait for all numerical types. add unit test for floyd_warshall algorithm move floyd warshall tests into tests/floyd_wrashall.rs replace panic with Result return type handle overflow and underflow more elegantly add quickcheck for floyd_warshall algorithm add documentation for floyd_warshall algorithm add link to wikipedia for floyd_warshall algorithm use std types instead of primitives update test and doc update tests again! Update src/floyd_warshall.rs Co-authored-by: Lukas Abfalterer <labfalterer@gmail.com> Update src/algo/mod.rs Co-authored-by: Lukas Abfalterer <labfalterer@gmail.com> apply cargo fmt
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks nice, thanks!
It's a pity that it cannot be used with StableGraph (due to the compactness trait), but changing the index iteration to iterating over node indices would probably kill the efficiency.
Do you thing you could add a benchmark for this?
This can be merged as-is either way :)
Sure. I'll add it till the end of this week. |
* implement floyd_warshall algorithm and expose it via algo module put BoundedMeasure trait alongside Measure trait implement BoundedMeasure trait for all numerical types. add unit test for floyd_warshall algorithm move floyd warshall tests into tests/floyd_wrashall.rs replace panic with Result return type handle overflow and underflow more elegantly add quickcheck for floyd_warshall algorithm add documentation for floyd_warshall algorithm add link to wikipedia for floyd_warshall algorithm use std types instead of primitives update test and doc update tests again! Update src/floyd_warshall.rs Co-authored-by: Lukas Abfalterer <labfalterer@gmail.com> Update src/algo/mod.rs Co-authored-by: Lukas Abfalterer <labfalterer@gmail.com> apply cargo fmt * add benchmark for floyd warshall algorithm * apply cargo fmt
* implement floyd_warshall algorithm and expose it via algo module put BoundedMeasure trait alongside Measure trait implement BoundedMeasure trait for all numerical types. add unit test for floyd_warshall algorithm move floyd warshall tests into tests/floyd_wrashall.rs replace panic with Result return type handle overflow and underflow more elegantly add quickcheck for floyd_warshall algorithm add documentation for floyd_warshall algorithm add link to wikipedia for floyd_warshall algorithm use std types instead of primitives update test and doc update tests again! Update src/floyd_warshall.rs Co-authored-by: Lukas Abfalterer <labfalterer@gmail.com> Update src/algo/mod.rs Co-authored-by: Lukas Abfalterer <labfalterer@gmail.com> apply cargo fmt * add benchmark for floyd warshall algorithm * apply cargo fmt
Implements floyd_warshall algorithm