I’m working on a VRP problem with optaplanner where not every customer needs to be visited. I know that genuine variable can be configured as nullable in optaplanner. So I wonder what should I do on chained variables like customers ?
Asked
Active
Viewed 75 times
1 Answers
0
This is a limitation of chained variables to at least the current version 7.18. We have ideas on how to support this in a future version some day.
The common workaround is to create a "dummy vehicle" and adjust all constraints to ignore visits of the dummy vehicle, so they don't affect the score. Any visit assigned to the dummy vehicle is basically unassigned.

Geoffrey De Smet
- 26,223
- 11
- 73
- 120
-
Thank you very much, Geoffrey. I’ll try. – Xiaomeng Feb 11 '19 at 23:36