Routing solver doesn't seems to respect time windows #4135
Unanswered
waelbb
asked this question in
Routing (and legacy CP) questions
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello, I have a vrp problem where each node correspond to a category (A, B or C), I duplicated the node from the category C. The thing is that I don't want 2 duplicated node to be include in the same route so what I did is that I added time windows. Let's say that I have 40 vehicle with 15 capacity (each visited node has a capacity of 1 it is just to limit the number of visited node per vehicle to 15), I divided all my vehicle to 2 start and end location. So I have start node 0 and end node 1 with 20 vehicles and start node 2 and end node 3 with 20 vehicles. I tried to set up time windows for my start and end location this way :
Those start and end node are dummy location so they have a 0 seconds distance to all the other nodes. Here is how my time_window matrix is setup :
[[28800, 28800],
[80000, 80000],
[115200, 115200],
[166400, 166400],
[[0, 86400], []],
[[], [0, 86400]],
[[0, 86400], []],
[[0, 86400], [0, 86400]]
For the visited nodes if the nodes is not a duplicated node is will be available from [28800,80000] and [115200,166400]. If it is a duplicated node one will be available during the first part [28800,80000] and the duplicated one from [115200,166400].
Unfortunately in the end I have duplicated node in the same route while it should be impossible cause vehicle either start from the first start and end node which means they should be back at 80000 or form the second meaning they can only start at 115200.
Could you help me solve this please ?
Here is my code so you can better understand :
Beta Was this translation helpful? Give feedback.
All reactions