optaplanner - VRP but with no depot

风格不统一 提交于 2020-01-25 05:18:04

问题


i'm working with the Multiple Vehicles Route Problem. I'm trying Optaplanner and looks good and promising.

I'm using the CVRP-32customers example, but I need to remove the "depots".

I just need to optimize a route for some salesman, where they start is not an issue to me. I just need the best 10 routes to visit my 100 customers, does not matter where they start.

I looked at this SO Question, but could not take anything from it to solve my problem.

Can this be achieved with Optaplanner? Is there an alternative (hopefully free...)?

Thanks in advance.

Best regards, Federico.


回答1:


I think your problem absolutely could be solved using Optaplanner. You have a good start by using VRP example. Now, the first thing you need to do is of course alter the domain model class to fit your need.

  1. The first class you should alter would be Vehicle class, as you said, you want to remove the depot because you don't need it in your case. So instead of having depot property inside the vehicle class, you could change it to location instead.
  2. The second thing you should take care was how do you want your route to be? If it is a closed route which mean the start location was also the end of location, then you don't need to make any modification since the VRP example was a closed route. But if you desire a open route which mean the end location of your vehicle is not the start location, then you might want to alter the "distanceFromLastCustomerToDepot" rule. How you alter it, it really depends on you business process.

If you want to discuss more, feel free to join the optaplanner forum. You could find me there using the same nickname (Wizard). Hope this help you, kind regards.



来源:https://stackoverflow.com/questions/47702893/optaplanner-vrp-but-with-no-depot

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!