Answered step by step
Verified Expert Solution
Question
1 Approved Answer
The following code solves the TSP with no subtours, using an idea that is somewhat similar to the MTZ constraints. ( a ) Explain how
The following code solves the TSP with no subtours, using an idea
that is somewhat similar to the MTZ constraints.
a Explain how the code ensures there are no subtours in the
solution.
b What is the code in arcs, in :
doing? Why?
c Run this code using the gurobi solver for different numbers
of cities using the data provided in LNPdat.txt but
only consider a small number of cities. Do the results look
reasonable?
Note that this code will produce an 'error', which is that some
invalid subscripts are discarded. AMPL is just removing the
diagonal data which are not required for this code, but it
is not a problem because AMPL will still compute a solution.
It is possible to remove the diagonals but they are required
for other code, so I've left them in
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started