0 ratings0% found this document useful (0 votes) 93 views22 pagesD1 Ch3
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content,
claim it here.
Available Formats
Download as PDF or read online on Scribd
ACCT VAM RES UNL: EL) Crary
1 For each network, complete the table of least distances,
Table of least
istances
4 68 C DE
“al- 7 5
Bi/7 - 3
c 3 8 RB
D 8-4
E Ro4 -
‘Table of least distances
4 8 C DE F
— 10 BOIS
WS 3
- 3
BG - 25
Is 3 -
BoC DE
0 9 W WT
10 3 0 ne)
93 pb 8
0 2 19 2» 10
" 8 8 8
10 0 8 10
20 lo 18 10ease) Lee CR ee EUS)
2 a Describe the difference between the practical and the
classical travelling salesman problems.
b For the network given on the right, find, by inspection,
the solution of:
the practical travelling salesman problem
ii the classical travelling salesman problem.
State the route used in each case, starting from A
© 3 a Find, by inspection, the solution of the practical
travelling salesman problem for this network, starting
from P. State the route used.
b Explain why the choice of start point does not affect
the minimum distance travelled
¢ Explain why it isnt possible to find a solution to the
classical travelling salesman problem for this network.
4 Construct a complete network in which the solutions to the
classical and practical travelling salesman problems are different
Ep ya iar ne aioe wate mies
recone _ | pebih nal exe ora) compere!
=.
©) Using a minimum spanning tree method to find an upper bound
= You can use a minimum spanning tree method to find an upper bound for the practical
travelling salesman problem by following these steps:
1. Find the minimum spanning tree for the network (using GED sou are seeking s
Prim’s algorithm or Kruskal’s algorithm). This guarantees that minimum route. There is
each vertex is included. therefore a logic in trying,
to.use, as a starting point,
the minimum spanning
tree, which you know how
3 Finally, try to find ‘shortcuts’. (Make use of some of the tofind
non-included ares that enable you to not repeat some of the
minimum spanning tree.)
2, Double this minimum connector (in effect you keep on retracing
your steps) so that completing the cycle is guaranteed.ACCT AMe ess Uae Crary
‘The initial upper bound found by doubling each arc on a minimum spanning tree is shown below.
4 8
c B
2
FP ©
Minimum spanning tree Initial upper bound
This visits each vertex and returns to the starting vertex.
* An initial upper bound is found by finding the weight of the minimum spanning tree for the
network and doubling it. Notice that this is a solution to the practical travelling salesman
problem, but is not a
ex
a Use Kruskal’s algorithm to find a minimum
spanning tree for the network on the right,
b Hence find an initial upper bound for the
travelling salesman problem.
‘@ Using Krustal’s algorithm:
Putting the ares In order:
AC, AD. CE, BE. CD, DE, DF, BD, FG, AB, EG
Include AC, AD, CE, BF, reject CD, reject DE,
include DF, reject BD, include FG. Tr e.
The weight of the minimum spanning tree
=3+344+54748=30
b The intial upper bound is 2 x 30 = 60,
rTase) Sa ERIN Rye eU es)
‘The table of least distances for a network is given below. Find an initial upper bound for the
travelling salesman problem for this network.
Starting at A:
Order of arc inclusion: AB, BD, AC, DE
1¢ weight of the minimum spanning tree
48413414246
92.
The initial upper bound is 2 x 4%
The initial upper bound found in the previous two examples is not very good, since you repeat each
arc in the minimum spanning tree.
You can improve the initial upper bound by looking for shortcuts.ACCT VAM RES UNL: EL) Crary
EXED cise suns
Starting from the initial upper bound found in Example 4, use a shortcut to reduce the upper
bound to below 70.
Use CEUI6) instead of repeating CA(13), ABII), BDI) and
DE(\4), this saves 13 + 148 4 14 — 18 = 28
This gives the following route:
Improved upper bound is now 48414416 +13 = 64
Example @) DED vecision-zaaning
The table shows the distances, in kilometres, between eight cities. A politician has to visit each city,
starting and finishing at 4. She wishes to minimise the total distance travelled,
a Find a minimum spanning tree for this network
b Hence find an upper bound for this problem.
© Use shortcuts to reduce this upper bound to a value below 1300 kilometres.ase) Sa ERIN Rye eU es)
2 Using Prim’ algorithm
1 203
1 l
c
a
a |@ - wi 402 155 193 319 165
c|@ a - 456 200 246 373 20
p |se2 402 456 - 413 220 @ 209
£ |@® 155 200 413 - 204 266 131
F | 172 193 246 220 204 - 44 @®
G |299 s19 373 195 266 @ - 160
n/a 165 216 70 10 -
Onder of are selection: AB, | HE. FG, GD
2047
a
we OT OE
© Looking at the tree,
ely shortcuts are AD and BC
AD caves 120 + 131 + 70 + 144 + 155 — 382 = 236 kilometres
BC saves 47 +84 — 121
0 kilometres
362 &
This leaves the following tour
apa? Youcan check your
te Eee
121 answer by comparing
0 131 70. 14a 185 your intial upper bound,
ch 64 ‘the savings from your
; shortcuts, and your
Tour ABCAEHFGDA ee
Tour length = 47 + 121+ 84 + 120+ 131+ 70+ 144 + 155 +362
= 1254 kilometresACCT VAM RES UNL: EL) Crary
Selecting shortcuts
In Example 6 there are many other shortcuts that could be tried.
Three such shortcuts are shown below.
+ BD saves 265 kilometres, so this shortcut alone would have been sufficient.
Tour ABDGFHEACA, length 1237 kilometres
+ CB+ AF + FD saves 238 kilometres.
Tour ABCAEHFGDFA, length 1264 kilometres
+ CDalone saves 248 kilometres.
Tour ABAEHFGDCA, length 1256 kilometres
Of these, the best upper bound is 1237 kilometres since this is the smallest.
= Aim to make the upper bound as low as possible to reduce the interval in
which the optimal solution is contained.
EXITED vecision-naxns
14 4
4 Find a minimum spanning tree for the network above and hence find
an initial upper bound for the travelling salesman problem,
b Usea shorteut to find a better upper bound.
© State the route given by your improved upper bound and state its length.
ryase) Lee CR ee EUS)
© 2 A construction worker needs to service five sets of traflic lights located at A, B, C, D and E.
The table shows the distance, in kilometres, between the lights. She will start and finish at A
and wishes to minimise her total travelling distance.
a Find a minimum spanning tree for the network, (4 marks)
b Hence find an initial upper bound for the length of the worker's route. (1 mark)
€ Use shorteuts to reduce the upper bound to a value below 65 kilometres. G marks)
4_ State the route given by your improved upper bound and state its length. (2 marks)
© 3 a Use Kruskal’s algorithm to find a minimum
spanning tree for the network shown on the
right, and hence find an initial upper bound for
the travelling salesman problem. (Smarks)
b Use shorteuts to reduce the upper bound to
below 240. marks)
€ State the route given by your improved upper
bound and state its length, (2 marks)
EDD start with the edge of minimum
weight, BF. + Decision 1 Section 3.1
© 4 The table shows the times, in minutes, taken to travel between a veterinary surgery S and
five farms V, W, X, Yand Z. A vet needs to visit animals at each of the farms and wishes to
‘minimise the total travel time, He will start and finish at the surgery, S.
a Use Prim’s algorithm, starting at S, to find a minimum spanning tree for the network
above and hence find an initial upper bound for the travelling salesman problem. (4 marks)
b Use the method of shortcuts to reduce the upper bound to below 200 minutes. (3 marks)
€ State the route given by your improved upper bound and state the total time
taken on this route. (2 marks)ACCT AMe ess Uae Crary
©) Using a minimum spanning tree method to find a lower bound
* You can use a minimum spanning tree method :
tr fn ower bound forthe castel problem QE s
by following these steps. robles ya are suling te
practical problem, you need to
1 Remove each vertex in turn, together with its ares. apply the algorithm toa table of
2. Find the residual minimum spanning tree (RMST) least distances,
and its length
3. Add to the RMST the ‘cost’ of reconnecting the
deleted vertex by the two shortest, distinct, ares and
note the totals.
4 The greatest of these totals is used for the lower
bound
5. Make the lower bound as high as possible to
reduce the interval in which the optimal solution is
contained.
6 You have found an optimal solution if the lower (ania
bound gives a Hamiltonian cycle, or if the lower eet fi
‘bound has the same value as the upper bound. :
FIED ctsomersneraron
‘The table of least distances for a network is shown,
‘The residual spanning tree s the
‘minimum spanning tree forthe
resulting network after removing 2
a By deleting vertex A, find a lower bound to the
travelling salesman problem for this network.
b State whether of not this lower bound represents an
optimal solution. Give a reason for your answer.
Using Prim’s algorithm starting at B, the order of arc selection
Ib BD, DE and EC