I have a route optimization problem where, 1st requirement: I need to determine which is the first city/point that my route should start from. Some loads carry heavy products that should be unloaded first. 2nd requirement: I also need to determine which is the last city my route should have. Note: my vehicle has a defined depot and “return_to_depot”: true.
I’m trying to make the point that I set high priority to be the first on the route, is this possible? If not, what is the correct way to define the first city where my route starts, in addition to the warehouse coordinates?
Base code
{
"objectives": [
{
"type": "min",
"value": "completion_time"
}
],
"vehicles": [
{
"vehicle_id": "v1",
"type_id": "custom_vehicle_type",
"start_address": {
"location_id": "v1",
"lat":-27.676941,
"lon": -52.288830
},
"earliest_start": 1508839200,
"return_to_depot": true
}
],
"vehicle_types": [
{
"type_id": "custom_vehicle_type",
"profile": "car"
}
],
"services":[
{
"id": "s-1",
"address": {
"location_id": "Liberato Salzano",
"lon": -53.0748607372178,
"lat": -27.5964701638556
},
"priority": 10
},
{
"id": "s-2",
"address": {
"location_id": "Jaboticaba",
"lon": -53.2843894020471,
"lat": -27.631222386294
},
"priority": 10
},
{
"id": "s-3",
"address": {
"location_id": "Erval Seco",
"lon": -53.5095730836612,
"lat": -27.5494171265095
},
"priority": 1
}
]
}
In the example above, it doesn’t make any difference if I change the priority because the sequence of points remains the same