Graph Connectivity

Graph connectivity in algorithms: strongly connected components with Kosaraju's two passes, bridges and articulation points from low values, and choosing the tool.

  • 7 cards
  • 3 questions
  • About 21 min
  • Intermediate to Advanced
Share

Graph connectivity asks how a graph holds together, and the topic teaches the two algorithms for the questions a single traversal cannot answer, then how to choose among four tools. It opens on strongly connected components, the groups of a directed graph whose vertices can all reach one another, found by Kosaraju's two depth-first passes, and a gotcha shows what goes wrong when the second pass skips the reversed graph. Bridges and articulation points follow, the single edges and vertices whose failure splits an undirected graph, found from discovery times and low values and then written in Python, Java and TypeScript. A comparison sets union-find, traversal, components and bridges side by side, and an exercise finds the weak links in a delivery network.

Contents

7 cardsnot started