Support for Multiple delivery location for a customer(OR Constraint)

Hello Community,
I have provided multiple delivery location to customer.
Some customers are not bothered about delivery location. Customer provides a choice of delivering to home or office. Algorithm has to figure out best location to deliver with minimal cost.
Can jsprit take OR constraint in delivering it to customer?

Please let me know the feasibility of it.

Thanks in advance.


This is not possible yet. But since we managed to consider multiple time windows, it should not be a bigger problem to make multiple locations working. I assume that the implementation is conceptuelly similar. Could you open a feature request here:


Hi Stefan,

We are also facing this problem of multiple options to deliver the orders. Without this feature currently present in Jspirit, I thought of solving this problem in this way.
Suppose we have to deliver 5 Orders, say o1, o2, o3, o4, o5. Further consider that o1 can be delivered to anyone of n1 alternatives. Similarly o2,o3,o4 and o5 can be delivered to any one of n2, n3, n3 and n5 alternatives respectively.
Now to solve this problem we can divide it into n1n2n3n4n5 different VRP problem with only one location for an order. Take minimum of all these to find solution of original problem.
Its obvious that this solution is very naive and computationally expensive. Would you please suggest us any other way to solve this problem.


Sounds expensive and impossible to solve this way for many jobs and alternative locations! A combinatorial problem on top of a combinatorial problem :smile:. Probably you need your own heuristic to search only for promising solutions. Alternatively, you can use Branch&Bound or similar.

Hi Stefan,

We are thinking to add this functionality of multiple delivery location to the jspirit. Would you please give us some lead or startpoint. As you mentioned this problem is very similar to multiple time window problem, but if you could tell us little more about it that how you solved it then it’d be a great help.

Thanks and regards