Infeasible problem with time limit, num_vehicles=1 and drop_penalty
mdubil15 opened this issue · 4 comments
Hello, here is the graph and the issue related. Thanks for your help ;)
With this graph (20 nodes all related to each other and to the source and sink, service_time on each node, and cost=time on each edge) ,
prob = VehicleRoutingProblem(graphe_l, num_vehicles = 1, drop_penalty=100, duration = 420)
prob.solve()
gives the exception "problem infeasible" though it should show the best routing that one vehicle can operate in less than 420 time units ?
Hi @mdubil15 ! Thanks for reaching out :)
I am able to reproduce the error. This is very strange. It seems to be related to the solver. The error that is thrown is different if I use CPLEX (prob.solve(solver="cplex")
), and the error differs if I change the solving parameters withing cplex: I get 'optimal with unscaled infeasibilities'
.
This needs a little investigation. I think the problem comes from the combination of imposing a unique vehicle, and allowing dropping nodes. This creates artificial variables behind the curtains, with high coefficients. Will get back to you as soon as I can!
I am investigating and am pretty sure this is a scaling issue.
The concept of using both options num_vehicles=1
and drop_penalty=100
is perfectly valid. In fact, one of the unit tests tests this (and does not fail):
Lines 296 to 303 in 96cc550
In the next release, the code will work without having to add fictitious demand. Closing for now.