Module prepona::algo[][src]

Containing algorithms that can get executed on graphs and subgraphs.

Graphs and subgraphs expose some functionalities defined in the provide module. One the other end, each algorithm defined in this module require some of the functionalities defined in provide to be able to get executed. So for one algorithm to be executable on a specific graph or subgraph, it is necessary for the graphs exposed functionalities to match the requirements of the algorithm.

Structs

BellmanFord

Finds shortest path from a single source to all other vertices using bellman-ford algorithm.

Bfs

Visits graph vertices in a breath-first manner.

ConnectedComponents

Finds connected components of an undirected graph.

Dfs

Visits graph vertices in a depth-first manner.

Dijkstra

Finds shortest path from a single source to all other vertices using dijkstra algorithm.

Error

Error type returns in algo module.

Eulerian

Finds Eulerian trail and circuit.

FloydWarshall

Finds shortest path from all vertices to all the other ones using floyd-warshall algorithm.

HasCycle

Detects cycle in a graph.

Kruskal

Finds minimum spanning tree using kruskal algorithm.

TarjanSCC

Finds connected components of a directed graph.

TopologicalSort

Finds the topological sort of vertices.

VertexEdgeCut

Finds cut vertices(articulation points) and cut edges(bridges).

Enums

Color
ErrorKind

Types of errors that may happen when using one of the algorithms.

Traits

BfsListener

Trait for structures that want to listen to Bfs events.

DfsListener

Trait for structures that want to listen to Dfs events.