Find a topological ordering for the graph in Figure 9.81.
Read moreTextbook Solutions for Data Structures and Algorithm Analysis in Java
Question
Assume that the Hamiltonian cycle problem is NP-complete for undirectedgraphs.a. Prove that the Hamiltonian cycle problem is NP-complete for directed graphs.b. Prove that the unweighted simple longest-path problem is NP-complete fordirected graphs.
Solution
The first step in solving 9 problem number 55 trying to solve the problem we have to refer to the textbook question: Assume that the Hamiltonian cycle problem is NP-complete for undirectedgraphs.a. Prove that the Hamiltonian cycle problem is NP-complete for directed graphs.b. Prove that the unweighted simple longest-path problem is NP-complete fordirected graphs.
From the textbook chapter Graph Algorithms you will find a few key concepts needed to solve this.
Visible to paid subscribers only
Step 3 of 7)Visible to paid subscribers only
full solution