0% found this document useful (0 votes)
27 views12 pages

6.4 TSP Using Branch and Bound

Uploaded by

yatinrana10143
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
27 views12 pages

6.4 TSP Using Branch and Bound

Uploaded by

yatinrana10143
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 12

Department of Computer Science and Engineering (CSE)

UNIVERSITY INSTITUTE OF
ENGINEERING
COMPUTER SCIENCE ENGINEERING
Bachelor of Engineering
Design and Analysis of
Algorithms(CST-311/ITT-311)

Topic: Traveling Salesman Problem using


Branch And Bound
DISCOVER . LEARN . EMPOWER

University Institute of Engineering (UIE)


Department of Computer Science and Engineering (CSE)

Learning Objectives & Outcomes


Objective:
• To understand the concept Traveling Salesman Problem
using Branch And Bound

Outcome:
• Student will understand
 Traveling Salesman Problem using Branch And Bound

University Institute of Engineering (UIE)


Department of Computer Science and Engineering (CSE)

Traveling Salesman Problem using Branch And Bound

Problem Definition:
•TSP includes a salesperson who has to visit a number of
cities during a tour & the condition is to visit all the cities
exactly once and return back to the same city where the
person started.

University Institute of Engineering (UIE)


Department of Computer Science and Engineering (CSE)

Basic steps followed

Let G=(V,E) be a directed graph defining an instance of the


TSP.

1. This graph is first represented by a cost matrix where


cij= the cost of edge if there is a path between vertex i and
vertex j
cij=∞ if there is no path

2. Convert cost matrix into reduced matrix i.e. every row


and column should contain at least one zero entry.

University Institute of Engineering (UIE)


Department of Computer Science and Engineering (CSE)

Basic steps followed (Contd.)

3. Cost of the reduced matrix is the sum of elements that are


subtracted from rows and columns of cost matrix to
make it reduced.

4. Make the state space tree for reduced cost matrix.

5. To find the next E-node, find the least cost valued node by
calculating the reduced cost matrix with every node.

University Institute of Engineering (UIE)


Department of Computer Science and Engineering (CSE)

Basic steps followed (Contd.)


6. If <i,j> edge is to be included, then there are 3 conditions
to accomplish this task.

a) Change all entries in row i and column j of A to ∞.

b) Set A[j,1] =∞.

c) Reduce all rows and columns in resulting matrix


except for rows and columns containing ∞.

University Institute of Engineering (UIE)


Department of Computer Science and Engineering (CSE)

Basic steps followed (Contd.)

7. Calculate the cost of the matrix where cost = L + cost(i,j) +


r
Where L = cost of original reduced cost matrix & r = New
reduced cost matrix.

8. Repeat the above steps for all the nodes until all the
nodes are generated and we get a path.

University Institute of Engineering (UIE)


Department of Computer Science and Engineering (CSE)

Similarity between Branch and Bound and


Backtracking
• Both the problems use state space tree to solve the
problem.

• Both use BFS and DFS techniques.

University Institute of Engineering (UIE)


Department of Computer Science and Engineering (CSE)

Dissimilarity between Branch and Bound and


Backtracking
• It provides only one solution.

• We cannot do revert back i.e. backtracking.

• Does not limit us to any particular way of traversing the tree.

• For every node a lower and upper bound is calculated.

• At every stage the bound is calculated by the partial solution


calculated in the previous stage.

• It gets better performance than backtracking.

University Institute of Engineering (UIE)


Department of Computer Science and Engineering (CSE)

REFERENCES
Text books:
•Cormen, Leiserson, Rivest, Stein, “Introduction to Algorithms”, Prentice Hall of
India, 3rd edition 2012. problem, Graph coloring.

University Institute of Engineering (UIE)


Department of Computer Science and Engineering (CSE)

Summary

Branch and Bound:

•Travelling salesperson problem

University Institute of Engineering (UIE)


THANK YOU

University Institute of Engineering (UIE)

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy