Overview of Graph Theory concepts and algorithms
Graph theory focuses on the relationship between vertices and edges. Graphs are categorized by direction (Directed Graphs, such as DAGs, and Undirected Graphs) and by weight (Weighted Graphs, used in network flow, and Unweighted Graphs).
Key algorithmic categories include:
- Traversal: DFS and BFS, which form the basis for topological sorting and connected component analysis.
- Shortest Path: Dijkstra (for graphs without negative edges), Bellman-Ford (includes negative edge detection), and Floyd-Warshall (for all-pairs shortest paths).
- Minimum Spanning Tree (MST): Prim's and Kruskal's algorithms, typically used for network cabling/layout problems.
- Connectivity: Tarjan's algorithm for Strongly Connected Components (SCC) and algorithms for Biconnected Components (identifying articulation points and bridges).
- Advanced Topics: Network Flow (Max-Flow Min-Cut Theorem), Bipartite Matching (Hungarian algorithm), and Eulerian Circuits (Hierholzer's algorithm).