Algorithm Design
Algorithm Design
Algorithm Design
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
528<br />
Chapter 8 NP and Computational Intractability<br />
designated node r ~ V and a designated set of "target nodes" T __ V - {r}.<br />
Each node v has a switching time sv, which is a positive integer.<br />
At time 0, the node r generates a message that it would like ev~ node<br />
in T to receive. To accomplish this, we want to find a scheme whereby r<br />
tells some of its neighbors (in sequence), who in turn tell some of their<br />
neighbors, and so on, until every node in T has received the message. More<br />
formally, a broadcast scheme is defined as follows. Node r may send a<br />
copy of the message to one of its neighbors at time 0; this neighbor will<br />
receive the message at time 1. In genera!, at time t >_ 0, any node u that<br />
has already received the message may send a copy of the message to<br />
one of its neighbors, provided it has not sent a copy of the message in<br />
any of the time steps t - su + 1, t - su + 2 ..... t - 1. (This reflects the role<br />
of the switching time; v needs a pause of su - 1 steps between successive<br />
sendings of the message. Note that if sv = 1, then no restriction is imposed<br />
41.<br />
by this.)<br />
The completion time of the broadcast scheme is the ~u_m time t<br />
by which all nodes in T have received the message. The Broadcast Time<br />
Problem is the following: Given the input described above, and a bound<br />
b, is there a broadcast scheme with completion time at most b?<br />
42.<br />
Prove that Broadcast Time is NP-complete.<br />
Example. Suppose we have a directed graph G = (V, E), with V =<br />
{r, a, b, c}; edges (r, a), (a, b), (r, c); the set T = {b, c}; and switching time<br />
sv = 2 for each v ~ V. Then a broadcast scheme with minimum completion<br />
time would be as follows: r sends the message to a at time 0; a sends<br />
the message to b at time 1; r sends the message to c at time 2; and the<br />
scheme completes at time 3 when c receives the message. (Note that a can<br />
send the message as soon as it receives it at time 1, since this is its first<br />
sending of the message; but r cannot send the message at time 1 since<br />
sr = 2 and it sent the message at time 0.)<br />
Given a directed graph G, a cycle cover is a set of node-disjoint cycles<br />
so that each node of G belongs to a cycle. The Cycle Cover Problem asks<br />
whether a given directed graph has a cycle cover.<br />
(a) Show that the Cycle Cover Problem can be solved in pol~ rnomial time.<br />
(b)<br />
(Hint: Use Bipartite Matching.)<br />
Suppose we require each cycle to have at most three edges. Show that<br />
determining whether a graph G has such a cycle cover is NP-complete.<br />
Suppose you’re consulting for a company in northern New Jersey that<br />
designs communication networks, and they come to you with the follow-<br />
Notes and Further Reading<br />
ing problem. They’re studying a specific n-node communication network,<br />
modeled as a directed graph G = (V, E). For reasons of fault tolerance, they<br />
want to divide up G into as many virtual "domains" as possible: A domain<br />
in G is a set X of nodes, of size at least 2, so that for each pair of nodes<br />
u, v ~ X there are directed paths from u to v and v to a that are contained<br />
entirely in X.<br />
Show that the following Domain Decomposition Problem is NP-complete.<br />
Given a directed graph G = (V, E) and a number k, can V be partitioned<br />
into at least k sets, each of which is a domain?<br />
Notes and Further Reading<br />
In the notes to Chapter 2, we described some of the early work on formalizing<br />
computational efficiency using polynomial time; NP-completeness evolved<br />
out of this work and grew into its central role in computer science following<br />
the papers of Cook (1971), Levin (1973), and Karp (1972). Edmonds (1965)<br />
is credited with drawing particular attention to the class of problems in<br />
?,f~P ~ co-~f~P--those with "good characterizations." His paper also contains<br />
the explicit conjecture that the Traveling Salesman Problem cannot be solved<br />
in polynomial time, thereby prefiguring the P ~ NP question. Sipser (1992) is<br />
a useful guide to all of this historical context.<br />
The book by Garey and Johnson (1979) provides extensive material on NPcompleteness<br />
and concludes with a very useful catalog of known NP-complete<br />
problems. While this catalog, necessarily, only covers what was known at the<br />
time of the book’s publication, it is still a very useful reference when one<br />
encounters a new problem that looks like it might be NP-complete. In the<br />
meantime, the space of known NP-complete problems has continued to expand<br />
dramatically; as Christos Papadimitriou said in a lecture, "Roughly 6,000<br />
papers every year contain an NP-completeness result. That means another<br />
NP-complete problem has been discovered since lunch." (His lecture was at<br />
2:00 in the afternoon.)<br />
One can interpret NP-completeness as saying that each individual NPcomplete<br />
problem contains the entire complexity of NP hidden inside it. A<br />
concrete reflection of this is the fact that several of the Ni~-complete problems<br />
we discuss here are the subject of entire books: the Traveling Salesman is the<br />
subject of Lawler et al. (1985); Graph Coloring is the subject of Jensen and Toft<br />
(1995); and the Knapsack Problem is the subject of Marte!lo and Toth (1990).<br />
NP-completeness results for scheduling problems are discussed in the survey<br />
by Lawler et al. (1993).<br />
529