0

I am fetching TimeMatrix(N*N) and Distance matrix from google API ,so how to add that in Optaplanner VRP solver.What is the Default vehicle Speed optaplanner is using for routing? Can I change that speed? This Answer explains How to pass actual distance Matrix to the solver,like that can I pass actual Time matrix to solver.Please Help..

Community
  • 1
  • 1
  • http://stackoverflow.com/questions/21455751/using-real-distances-between-points-in-optaplanner?rq=1 plz check this – Maheshwar Ligade Nov 08 '16 at 11:50
  • @MaheshwarLigade The question you provided is for adding distance matrix , but I have both distance and Time matrix.So how can I pass both to the problem.BTW thanks. – Rahul Kumar Nov 08 '16 at 12:11

1 Answers1

1

Adjust the Vehicle Routing example model so a RoadLocation has a separate distance matrix for distance and for time. Then put up a soft constraint for both of them, each with it's own weight. Then you have a weighted function of distance and time.

Geoffrey De Smet
  • 26,223
  • 11
  • 73
  • 120
  • Thanks for your answer. If I add a time matrix map in RoadLocation where do I add soft constraint .Do I need to change drl config file for this. – Rahul Kumar Nov 11 '16 at 07:39