Skip to main content

My model is infeasible. Can someone please help me?



1 comment

  • Lennart Lahrs
    Gurobi Staff Gurobi Staff

    Hi Jordi,

    I was able to remove the infeasibility by relaxing the below equality constraints to larger or equal to constraints.

    >= 1, name="VisitOnceFrom_{}".format(i))
    >= 1, name="VisitOnceTo_{}".format(j))

    Before, it was forbidden for multiple vehicles to visit a specific client. I can think of two cases how this resulted in infeasibility. One is that if the demand of one client exceeded a vehicle type's capacity, it would render your model infeasible because multiple visits to one client were forbidden. The second is that each vehicle is forced to leave the depot, but the number of vehicles is larger than the number of clients; hence, some clients had to be visited by more than one vehicle – which was not allowed.

    I hope this information is helpful, please let me know if otherwise.

    Best regards,


Please sign in to leave a comment.