Skip to content
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

Add new algorithm for cycle detection #2

Open
clue opened this issue Jan 22, 2015 · 1 comment
Open

Add new algorithm for cycle detection #2

clue opened this issue Jan 22, 2015 · 1 comment

Comments

@clue
Copy link
Member

clue commented Jan 22, 2015

Originally reported by @clue in graphp/graph#9:

We should provide an algorithm for cycle detection that works for both directed and undirected (and mixed) graphs.

Consider basing it on TopologicalSort.

Besides merely detecting cycles, it would be nice to also return Cycle instances, similar to how DetectNegativeCycle works.

http://en.wikipedia.org/wiki/Cycle_%28graph_theory%29#Cycle_detection

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants