| # | required problems | topic |
|---|---|---|
| 1 | Suppose you are given a graph in which each vertex
has a cost. The cost of a path from v to w
is the sum of the costs of the interior vertices along the path
(the costs of v and w are not included in the sum).
Design an algorithm to solve the all-pairs shortest path problem on this type of graph. | shortest path alg |
| 2 | CLR Exercise 25.2-1 on page 634 | Floyd-Warshall all-pair shortest path alg |
| # | suggested problems | topic | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| 3 | Baase Exercise 7.32 on page 381 | articulation points | |||||||||
| 4 | Baase Exercise 7.48 on pages 384 | graph alg - bipartite | |||||||||
| 5 | CLR Exercise 24.2-4 on page 595 | graph alg - count paths on DAG | |||||||||
| 6 | [Manber Exercise 10.23a on pp. 339-340] The transitive closure A* of an n × n matrix A is defined as follows: (Assume that multiplication is performed according to the Boolean rules.) |
transitive closure | |||||||||
| 7 | Consider a DAG with n vertices, labeled by the integers
1 through n. Call this graph G.
There is an edge from vertex x to vertex y
if and only if x > 2y.
|
transitive closure | |||||||||
| 8 | We are given a directed graph G on n
vertices.
Give an algorithm to fill in the entries of an
n × n matrix M such that
Hint: This problem can be solved by dynamic programming. Let C[i, j, k] be the length of the longest path from i to j, using no intermediate vertex numbered higher than k. Obtain a recurrence and boundary conditions for C[i, j, k]. Allow for the possibility that the graph may have some self loops, i.e., edges from a vertex to itself. |
all pairs paths | |||||||||