Apply depth-first-search to find out the spanning tree, Mathematics

Assignment Help:

Apply depth-first-search to find out the spanning tree for the subsequent graph with vertex d as the starting vertex.       

1410_Apply depth-first-search to find out the spanning tree.png

Ans: Let us begin with node'd'. Mark d as visited node. Node'd' comprises two child 'e' and 'f'. After that Visit node 'e' and mark it as visited. Select edge (d, e) and add it to spanning tree T. So, T = {(d, e)}  Now e has e has two children: c and f. Visit c, add (e, c) to T, and mark c as visited. After that visit a and after that b. Mark them visited node and add arcs (c, a) and (c, b) to T. Up to here 

T = {(d, e), (e, c), (c, a), (c, b)}

Now here c has one more child e, which is previously visited, so exit recursion and go up to e that one more unvisited child f. Visit it, mark it as visited and we add (e, f) to T.  f comprise three (3) children: d, g and h. d is visited so leave it. Visit g, and doing the basic work of marking as visited and adding the arc utilized to visit the node in T, we at last get T as 

T = {(d, e), (e, c), (c, a), (c, b), (e, f), (f, g), (g, h), (h, i), (h, k), (k, j)}


Related Discussions:- Apply depth-first-search to find out the spanning tree

Real Analysis/Advanced Calculus (Needs to be a full proof), Both need to be...

Both need to be a full page, detailed proof. Not just a few lines of proof. (1) “Every convergent sequence contains either an increasing, or a decreasing subsequence (or possibly

Division Remainders, what is the remainder when 75 is divided by 4

what is the remainder when 75 is divided by 4

How many can speak both english and russian, In a group of 1000 people, the...

In a group of 1000 people, there are 750 people will speak English and 400 people will speak Russian. How many may speak English only? How many will speak Russian? How many can spe

Probability, Question: There are 6 letters and 6 self addressed envelopes.W...

Question: There are 6 letters and 6 self addressed envelopes.What is the probability that atleast 1 is placed correctly?? Ans: If we let A be the event that letter A is in the cor

Setup the mass balance equation - linear system method, Two tanks initially...

Two tanks initially contain 100 liter liquid each. Their initial concentration are listed in the Figure below. At time zero, the input and output valves are opened simultaneously w

Directional derivatives, What are directional derivatives? Explain with two...

What are directional derivatives? Explain with two or more examples..

Word problems, A patient will receive hemodialysis for 2.5 hours. The amoun...

A patient will receive hemodialysis for 2.5 hours. The amount of fluid removed per hour is 1.4 liters. The total amount removed in liters, will be

Consecutive positive odd integers 74 what is integer value, The sum of the ...

The sum of the squares of two consecutive positive odd integers is 74. What is the value of the smaller integer? Let x = the lesser odd integer and let x + 2 = the greater odd

Find a power series representation for the function, Find a power series re...

Find a power series representation for the subsequent function and find out its interval of convergence. g (x) = 1/1+x 3 Solution What we require to do here is to rela

Ratio, find the ratio of 1:4

find the ratio of 1:4

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd