8000 Algorithms to implement · Issue #33 · dominikbraun/graph · GitHub
[go: up one dir, main page]

Skip to content
  • Algorithms to implement #33

    Open
    Open

    Description

    @dominikbraun

    This is an umbrella issue for various algorithms that might or should be implemented mid- to long-term.


    Clustering

    • Transitivity

    Connectivity

    • Is connected
    • Strongly connected components
    • Weakly connected components
    • Condensation

    Cycles

    DAGs

    • Topological sort
    • Transitive reduction
    • Transitive closure

    Eulerian

    • Eulerian circuit
    • Eulerian path

    Paths

    • Dijkstra
    • A*
    • All simple paths between two vertices

    Traversal

    • DFS
    • BFS
    • DFS tree
    • BFS tree

    Trees

    • Minimum spanning tree
    • Maximum spanning tree

    Isomorphism & Comparisons

    Sets

    • Union-find

    These algorithms along with their tests should live in a file named after their category, e.g. DFS is located in traversal.go and tested in traversal_test.go. They should accept a Graph[K comparable, T any] instance and vertex values (T) or vertex hashes (K) where appropriate.

    Activity

    1. pinned this issue on Sep 1, 2022
    2. pangeran-bottor commented on Sep 8, 2022

      @pangeran-bottor
      Contributor

      Hi @dominikbraun,

      I'm interested in working on some of these tasks and planning to start with the Simple cycles one.
      I want to confirm the specific functionality of this method. For example, is it to find all simple cycles from the given graph?

    3. dominikbraun commented on Sep 8, 2022

      @dominikbraun
      OwnerAuthor

      Hi @pangeran-bottor, thanks for you interest! I've opened issue #39 to describe the function and discuss it.

    4. purpleidea commented on Sep 12, 2022

      @purpleidea

      Fantastic. Would love to see graph isomorphism here. I don't think any golang graph library supports it, and this would be a great win. I document some info about this here: purpleidea/mgmt#199 HTH and thank you!

    5. dominikbraun commented on Sep 15, 2022

      @dominikbraun
      OwnerAuthor

      @purpleidea I've opened issue #47 for graph isomorphism.

    6. nathancoleman commented on Nov 5, 2022

      @nathancoleman

      @dominikbraun I've implemented Nearest Neighbor Graph and Farthest Neighbor Graph for my own purposes and was curious if it was something you'd be interested in as a contribution here.

      The interesting part for me was that I sometimes want to calculate this graph using the AdjacencyMap() and other times using the PredecessorMap() depending on which node is my frame of reference in a directed graph. If you're interested in this contribution, what sort of interface would you expect? For my own use case, I have split these into NearestAdjacentGraph() and NearestPredecessorGraph()

    7. dominikbraun commented on Nov 5, 2022

      @dominikbraun
      OwnerAuthor

      @nathancoleman Thanks for your suggestion, a contribution regarding NNGs and FNGs would definitely be welcome!

      I'm not into NNGs though, so it is hard for me to judge and reason about an appropriate API. If I understand you correctly, the distinction between AdjacencyMap and PredecessorMap would be inherent to the problem and isn't due to a flawed API design of this library - in that case, NearestAdjacentGraph and NearestPredecessorGraph would be fine for me.

    8. zoonage commented on Apr 22, 2024

      @zoonage

      Could we get a topological generations algorithm as well please? Example from networkx

    9. miparnisari commented on Apr 24, 2025

      @miparnisari

      I would also add to this list network algorithms 😄

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

    Metadata

    Metadata

    Assignees

    No one assigned

      Labels

      enhancementNew feature or requesthelp wantedExtra attention is needed

      Projects

      No projects

        Milestone

        No milestone

        Relationships

        None yet

        Development

        No branches or pull requests

        Issue actions

        0