Question: Suppose that we wish to maintain the transitive closure of a directed graph G = (V, E) as we insert edges into E. That is,

Suppose that we wish to maintain the transitive closure of a directed graph G = (V, E) as we insert edges into E. That is, after each edge has been inserted, we want to update the transitive closure of the edges inserted so far. Assume that the graph G has no edges initially and that the transitive closure is to be represented as a Boolean matrix.
a. Show how the transitive closure G* = (V, E*) of a graph G = (V, E) can be updated in O (V2) time when a new edge is added to G.

Step by Step Solution

3.42 Rating (165 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

a Let T be the V V matrix representing the transitive closure such that Ti j is 1 if there is a path from i to j and 0 if not Initialize I when there ... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Document Format (1 attachment)

Word file Icon

C-S-A (151).docx

120 KBs Word File

Students Have Also Explored These Related Algorithms Questions!