Discrete Mathematics with Graph Theory (Classic Version) (3rd Edition) (Pearson Modern Classics for Advanced Mathematics Series)
Discrete Mathematics with Graph Theory (Classic Version) (3rd Edition) (Pearson Modern Classics for Advanced Mathematics Series)
3rd Edition
ISBN: 9780134689555
Author: Edgar Goodaire, Michael Parmenter
Publisher: PEARSON
Question
Book Icon
Chapter 12.5, Problem 7E

(a)

To determine

Change the depth-first search algorithm so that it can count the number of connected components of a graph.

(b)

To determine

To prove: The number of components also, give the labels that the search assign to the vertices.

If the table shows the adjacencies in a graph with vertices v1,v2,......v13 without drawing the graph apply depth-first search and use the method discovered in part (a).

1 2 3 4 5 6 7 8 9 10 11 12 13
1 0 1 0 0 0 1 0 0 0 0 1 0 0
2 1 0 0 0 0 0 0 0 0 0 1 0 0
3 0 0 0 0 0 0 0 1 0 0 0 0 1
4 0 0 0 0 1 0 1 0 0 0 0 1 0
5 0 0 0 1 0 0 0 0 0 1 0 0 0
6 1 0 0 0 0 0 0 0 0 0 1 0 0
7 0 0 0 1 0 0 0 0 1 1 0 0 0
8 0 0 1 0 0 0 0 0 0 0 0 0 1
9 0 0 0 0 0 0 1 0 0 0 0 1 0
10 0 0 0 0 1 0 1 0 0 0 0 0 0
11 1 1 0 0 0 1 0 0 0 0 0 0 0
12 0 0 0 1 0 0 0 0 1 0 0 0 0
13 0 0 1 0 0 0 0 1 0 0 0 0 0

Blurred answer
Students have asked these similar questions
find the mximum possible order of S5
For the Graph G1 in Figure, starting with the matching M={av,bw} and a maximum matching using the bipartite matching algorithm). Show each step, and provide a certificate of optimality (obtained from the algorithm).
Use the high-level version of Dijkstra's algorithm to find the shortest paths from the vertex v4 to all the other vertices of the graph below. Show the actions step by step. Assume that each undirected edge represents two directed edges with the same weight.

Chapter 12 Solutions

Discrete Mathematics with Graph Theory (Classic Version) (3rd Edition) (Pearson Modern Classics for Advanced Mathematics Series)

Ch. 12.1 - Prob. 1ECh. 12.1 - Prob. 2ECh. 12.1 - Prob. 3ECh. 12.1 - Prob. 4ECh. 12.1 - Prob. 5ECh. 12.1 - Prob. 6ECh. 12.1 - Prob. 7ECh. 12.1 - Prob. 8ECh. 12.1 - 9. The vertices in the graph represent town; the...Ch. 12.1 - Prob. 11ECh. 12.1 - 12. [BB] suppose and are two paths from a vertex...Ch. 12.1 - Prob. 13ECh. 12.1 - Prob. 14ECh. 12.1 - Prob. 15ECh. 12.1 - Prob. 16ECh. 12.1 - 17. [BB] Recall that a graph is acyclic if it has...Ch. 12.1 - Prob. 18ECh. 12.1 - Prob. 19ECh. 12.1 - Prob. 20ECh. 12.1 - Prob. 21ECh. 12.1 - Prob. 22ECh. 12.1 - The answers to exercises marked [BB] can be found...Ch. 12.1 - Prob. 24ECh. 12.1 - Prob. 25ECh. 12.1 - A forest is a graph every component of which is a...Ch. 12.1 - Prob. 27ECh. 12.2 - Prob. 1TFQCh. 12.2 - Prob. 2TFQCh. 12.2 - Prob. 3TFQCh. 12.2 - Prob. 4TFQCh. 12.2 - Prob. 5TFQCh. 12.2 - Prob. 6TFQCh. 12.2 - Prob. 7TFQCh. 12.2 - Prob. 8TFQCh. 12.2 - Prob. 9TFQCh. 12.2 - Prob. 1ECh. 12.2 - Prob. 2ECh. 12.2 - Prob. 3ECh. 12.2 - Prob. 4ECh. 12.2 - Prob. 5ECh. 12.2 - Prob. 6ECh. 12.2 - Prob. 7ECh. 12.2 - Prob. 8ECh. 12.2 - Prob. 9ECh. 12.2 - Prob. 10ECh. 12.2 - Prob. 11ECh. 12.2 - Prob. 12ECh. 12.2 - Prob. 13ECh. 12.2 - Prob. 14ECh. 12.2 - Prob. 15ECh. 12.2 - Prob. 16ECh. 12.2 - Prob. 17ECh. 12.3 - If Kruskal’s algorithm is applied to after one...Ch. 12.3 - 2. If Kruskal’s algorithm is applied to we might...Ch. 12.3 - 3. If Kruskal’s algorithm is applied to we might...Ch. 12.3 - If Prim’s algorithm is applied to after one...Ch. 12.3 - If Prims algorithm is applied to we might end up...Ch. 12.3 - If Prims algorithm is applied to we might end up...Ch. 12.3 - Prob. 7TFQCh. 12.3 - Prob. 8TFQCh. 12.3 - Prob. 9TFQCh. 12.3 - Prob. 10TFQCh. 12.3 - Prob. 1ECh. 12.3 - Prob. 2ECh. 12.3 - Prob. 3ECh. 12.3 - Prob. 4ECh. 12.3 - The answers to exercises marked [BB] can be found...Ch. 12.3 - Prob. 6ECh. 12.3 - Prob. 7ECh. 12.3 - Prob. 8ECh. 12.3 - Prob. 9ECh. 12.3 - Prob. 10ECh. 12.3 - Prob. 11ECh. 12.3 - In our discussion of the complexity of Kruskals...Ch. 12.3 - Prob. 13ECh. 12.3 - Prob. 14ECh. 12.3 - Prob. 15ECh. 12.3 - Prob. 16ECh. 12.3 - Prob. 17ECh. 12.3 - Prob. 18ECh. 12.4 - The digraph pictured by is a cyclic.Ch. 12.4 - Prob. 2TFQCh. 12.4 - Prob. 3TFQCh. 12.4 - Prob. 4TFQCh. 12.4 - Prob. 5TFQCh. 12.4 - Prob. 6TFQCh. 12.4 - Prob. 7TFQCh. 12.4 - Prob. 8TFQCh. 12.4 - Prob. 9TFQCh. 12.4 - Prob. 10TFQCh. 12.4 - Prob. 1ECh. 12.4 - Prob. 2ECh. 12.4 - Prob. 3ECh. 12.4 - Prob. 4ECh. 12.4 - 5. The algorithm described in the proof of...Ch. 12.4 - How many shortest path algorithms can you name?...Ch. 12.4 - Prob. 7ECh. 12.4 - Prob. 8ECh. 12.4 - Prob. 10ECh. 12.4 - Prob. 11ECh. 12.4 - Prob. 12ECh. 12.4 - [BB] Explain how Bellmans algorithm can be...Ch. 12.4 - Prob. 14ECh. 12.5 - Prob. 1TFQCh. 12.5 - Depth-first search has assigned labels 1 and 2 as...Ch. 12.5 - Depth-first search has assigned labels 1 and 2 as...Ch. 12.5 - Prob. 4TFQCh. 12.5 - Prob. 5TFQCh. 12.5 - Prob. 6TFQCh. 12.5 - Prob. 7TFQCh. 12.5 - Prob. 8TFQCh. 12.5 - 9. Breadth-first search (see exercise 10) has...Ch. 12.5 - Prob. 10TFQCh. 12.5 - Prob. 1ECh. 12.5 - Prob. 2ECh. 12.5 - Prob. 3ECh. 12.5 - 4. (a) [BB] Let v be a vertex in a graph G that is...Ch. 12.5 - Prob. 5ECh. 12.5 - Prob. 6ECh. 12.5 - Prob. 7ECh. 12.5 - Prob. 8ECh. 12.5 - Prob. 9ECh. 12.5 - Prob. 10ECh. 12.5 - [BB; (a)] Apply a breath-first search to each of...Ch. 12.5 - Prob. 12ECh. 12.5 - Prob. 13ECh. 12.5 - Prob. 14ECh. 12.6 - Prob. 1TFQCh. 12.6 - Prob. 2TFQCh. 12.6 - Prob. 3TFQCh. 12.6 - Prob. 4TFQCh. 12.6 - Prob. 5TFQCh. 12.6 - Prob. 6TFQCh. 12.6 - Prob. 7TFQCh. 12.6 - Prob. 8TFQCh. 12.6 - Prob. 9TFQCh. 12.6 - Prob. 10TFQCh. 12.6 - Prob. 1ECh. 12.6 - Prob. 2ECh. 12.6 - Prob. 3ECh. 12.6 - Prob. 4ECh. 12.6 - Prob. 5ECh. 12.6 - Prob. 6ECh. 12.6 - Prob. 7ECh. 12.6 - Prob. 8ECh. 12.6 - Prob. 9ECh. 12.6 - Prob. 10ECh. 12.6 - Prob. 11ECh. 12.6 - Prob. 12ECh. 12.6 - Prob. 13ECh. 12.6 - Prob. 14ECh. 12.6 - Prob. 15ECh. 12 - Prob. 1RECh. 12 - Prob. 2RECh. 12 - Prob. 3RECh. 12 - Prob. 4RECh. 12 - 5. (a) Let G be a graph with the property that...Ch. 12 - Prob. 6RECh. 12 - Prob. 7RECh. 12 - Prob. 8RECh. 12 - Prob. 9RECh. 12 - Prob. 10RECh. 12 - Prob. 11RECh. 12 - Prob. 12RECh. 12 - Prob. 13RECh. 12 - Prob. 14RECh. 12 - Prob. 15RECh. 12 - Prob. 16RECh. 12 - Prob. 17RECh. 12 - Prob. 18RECh. 12 - In each of the following graphs, a depth-first...Ch. 12 - Prob. 20RECh. 12 - Prob. 21RECh. 12 - Prob. 22RECh. 12 - Prob. 23RECh. 12 - Prob. 24RECh. 12 - Prob. 25RECh. 12 - Prob. 26RE
Knowledge Booster
Background pattern image
Similar questions
Recommended textbooks for you
Text book image
Linear Algebra: A Modern Introduction
Algebra
ISBN:9781285463247
Author:David Poole
Publisher:Cengage Learning