Exclude specific vehicles from handling specific shipments?

Hi,

I have the following requirement:
Lets assume that i already have a set of shipments and a set vehicles. The route have already been created and all jobs are being serviced. New shipments came in, and they need to be handled by the same vehicles. The problem is that some of the drivers may refuse to handle these shipments.

The solution i thought about is mapped in the following example:
vehicle 1 --Skills–> a,b
vehicle 2 --Skills–> a,b
vehicle 3 --Skills–> a,b
Job 1 --Skills–> a,b
Job 2 --Skills–> a,b

Then a new batch of jobs comes in. I will then adjust skills like follows:
vehicle 1 --Skills–> a,b
vehicle 2 --Skills–> a,b
vehicle 3 --Skills–> a
Job 1 --Skills–> a,b
Job 2 --Skills–> a,b
Job 3 --Skills–> b
Job 4 --Skills–> b

My questions are:

  • Will this solution work ?
  • Is there a better way to solve this problem ?

Thanks.

Hi @rdbrid,

One issue with your approach is that no job can be assigned to vehicle 3, because the skill constraint is in an “AND” fashion. What you can do instead is to add a skill c to vehicles 1 and 2, and set it for jobs 3 and 4.

A more sophisticated way is to use hard route constraint to disallow certain jobs to be assigned to certain vehicles. Actually, it is exactly what is covered by the example of hard route constraint in jsprit’s Walkthrough Constraints page.

Best regards,
He