
thanks Robert for answering me.
Hope you can help me complete my model. I am implementing an upgrade of the maximal covering location problem, in which it is possible to reduce the length of the edges, this has a certain cost and there is a pre-established budget. However, an error appears in the resolution phase: Error at _cmdno 3 executing "solve" command
(file MCLB.run, line 11, offset 103):
error processing constraint constraint6 ['I', 'I']: can't convert 'I' to a number.
this is the complete problem:
I am attaching the .mod and .dat files.
thanks to the availability,
Best regards
On Fri, Jun 24, 2022 at 1:08 AM UTC, AMPL Google Group <am...@googlegroups.com> wrote:
There is an extra V in the indexing of the constraint. It should be just {i in V, j in V, k in V diff {i,j}: i<j}. Also you can only define (h,s) once in an indexing set. For the first sum, you could use
{(h,s) in Gout[k]: (h,s) not in Gin[i]}
or equivalently
{(h,s) in Gout[k] diff Gin[i]}
The indexing for the second sum is written similarly.
--
Robert Fourer
am...@googlegroups.com