midhilesh elavazhagan
midhilesh elavazhagan

Reputation: 91

How to minimize cost per km along with route distance in vehicle routing problem using ortools?

I have given the information about the cost per km for each vehicle. My objective is to minimize the distance along with the cost by choosing optimal vehicles. I am using google or-tools where the objective function is to minimize the total distance. Is there any way to incorporate the cost per km information and minimize that along with total distance using google or-tools in python language?

Please help me to solve this problem.

Upvotes: 1

Views: 576

Answers (1)

Mizux
Mizux

Reputation: 9301

Create a "cost" matrix for each vehicle type and use it instead of using a distance matrix ?

Upvotes: 2

Related Questions