Adding Breaks to Pickup and Delivery Solution #3929
Unanswered
remeshx
asked this question in
Routing (and legacy CP) questions
Replies: 1 comment
-
Break don't know you have a capacity/load dimension. If you only have a capacity of 1, you can set the SlackVar to any pickup point to 0 so solver won't be able to add a break after a pickup since the SlackVar (i.e. waiting time) is zero. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Version: v9.5
Language: Python
I am new to OR-Tools and have successfully created a solution for pickup and delivery problems with time windows and breaks using the following code:
However, although the breaks are correctly placed between the trips, they do not consider the pickup and delivery constraints. In other words, when a vehicle picks up a passenger, the break should not be allowed while the passenger is onboard. Unfortunately, the solution currently only schedules breaks when passengers have been picked up but not yet dropped off.
is that expected behavior?
How can one enforce the solver to take into account the pickup and drop-off constraints for breaks and only schedule a break when the vehicle's capacity is at its maximum value (i.e., when it does not have any passengers onboard)?"
Beta Was this translation helpful? Give feedback.
All reactions