Already have an account? Get multiple benefits of using own account!
Login in your account..!
Remember me
Don't have an account? Create your account in less than a minutes,
Forgot password? how can I recover my password now!
Enter right registered email to receive password!
Q. Explain various graph traversal schemes and write their advantages and disadvantages.
Ans.
Graph Traversal Scheme is explained below
In many troubles we wish to investigate the total vertices in a graph in some systematic order. In graph we frequently do not have any one vertex singled out as special and therefore the traversal may begin at an arbitrary vertex. The two famous methods or techniques for traversing are:-
a) Depth first traversal is explained below: The breadth traversal of a graph is roughly analogous to pre-order traversal of an ordered tree. Assume that the traversal has just visited a vertex or, and let W0, W1,......Wk be the vertices near to V. Then we shall next visit W0 and keep W1.....Wk waiting. After visiting W0 we traverse all the vertices to which it is near before returning to traverse W1, W2, ........Wk.
b) Breadth first traversal: of a graph is around analogous to level by level traversal of ordered tree. If the traversal has just visited a vertex V, then it next visits all the vertices adjoining to V. Putting the vertices adjoining to these is a waiting list to be traversed after all the vertices adjoining to V have been visited. The figure below shows the order of visiting the vertices of one graph under both DFS and BFS.
DFT = 1 2 3 4 5 6 7 8 9
BFT= 1 2 9 3 5 6 4 7 8
Acyclic Graphs In a directed graph a path is said to form a cycle is there exists a path (A,B,C,.....P) such that A = P. A graph is called acyclic graph if there is no cycle in
Algorithm to Delete a given node from a doubly linked list Delete a Node from Double Linked List DELETEDBL(INFO, FORW, BACK, START, AVAIL,LOC) 1. [Delete Node] Set FOR
Linear search is not the most efficient way to search an item within a collection of items. Though, it is extremely simple to implement. Furthermore, if the array elements are arra
Illustrate Trivariate Colour Models Conventional colour models based on the tristimulus theory all contain three variables and so are called trivariate models. Let us now consi
What is an Algorithm? An algorithm is a sequence of unambiguous instructions for solving a problem, i.e., for getting a needed output for any legitimate input in a finite amoun
What is String Carrier set of the String ADT is the set of all finite sequences of characters from some alphabet, including empty sequence (the empty string). Operations on s
Explain an efficient method of storing a sparse matrix in memory. Write a module to find the transpose of the sparse matrix stored in this way. A matrix which contains number o
Explain the halting problem Given a computer program and an input to it, verify whether the program will halt on that input or continue working indefinitely on it.
What is Solid modeling Solid modeling is the most powerful of the 3-D modeling technique. It provides the user with complete information about the model. Defining an object wit
Write a program to simulate searching over a hashed file, with different assumptions for the sizeof file pages.Write a program to perform equality search operations on the hashed f
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!
whatsapp: +91-977-207-8620
Phone: +91-977-207-8620
Email: [email protected]
All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd