Minimize number of tours PTV xServer 2 - xTour

This forum deals with any kind of trip optimization based on xTour1, xTour2 and the Developer APIs "RouteOptimization" and "SequenceOptimization". No matter whether it is automatic planning or manual dispatching, refering to transport orders or service planning.
Attention: this does not refer to PTV Optiflow SaaS and PTV Developer RouteOptimization Optiflow.
Post Reply
jerich
Posts: 9
Joined: Tue May 14, 2019 9:55 am

Minimize number of tours PTV xServer 2 - xTour

Post by jerich »

Hi Bernd,

I have a question for the xTour endpoint of xServer 2.

1 Depot: Holzkirchen

3 Customers:

- Amstetten
1x order 4773 kg

- Esslingen
1x order 3008

- Pforzheim
48x orders 822 kg

The total quantity of the truck is defined with 24000 kg, 3 trucks are available.
Customer stops per tour is definied with max. 2.
Single trip per tour, single depot per tour as well as minimize number of tours is enabled.

I am using direct distance in this example to provide a smaller sample set.

What I am expecting is that the algorithm creates 2 trips, like this:

Tour 1:
- Amstetten 4773 kg
- Pforzheim 19227kg

Tour 2:
- Esslingen 3008 kg
- Pforzheim 20229 kg

Unfortunately, there are always 3 trips created. The first trip is a FTL with 23838 kg of Pforzheim and then two other trips.
Please see attached the json files "request1_3 vehicles.txt" and "response1.txt"


What I tried

Setting the maximum number of vehicles to 2 to force my expected behavior.
But now one order remains unplanned.

Please see attached "request2_2 vehicles.txt" and "response2.txt"


Is there something that I am missing in the request?
Attachments
request1_3 vehicles.txt
Request 1 - 3 vehicles
(10.98 KiB) Downloaded 222 times
response1.txt
Response 1
(50.78 KiB) Downloaded 259 times
request2_2 vehicles.txt
Request 2 - 2 vehicles
(10.96 KiB) Downloaded 220 times
response2.txt
Response 2
(37.98 KiB) Downloaded 237 times
User avatar
Bernd Welter
Site Admin
Posts: 2850
Joined: Mon Apr 14, 2014 10:28 am
Contact:

Re: Minimize number of tours PTV xServer 2 - xTour

Post by Bernd Welter »

Checked this with Daniela: you did run into a weakness of the heuristics:
Without an input plan the heuristics approach fails: it does not recognize that shifting some workload to an alternative vehicle would manage to create free capacities.
Without an input plan the heuristics approach fails: it does not recognize that shifting some workload to an alternative vehicle would manage to create free capacities.
with an input plan that pre-assigns the two bigger orders to the two vehicles the algorithm manages to create 2 tours with one trip each . And each trip delivers one of the bigger orders and several of the partial orders.
with an input plan that pre-assigns the two bigger orders to the two vehicles the algorithm manages to create 2 tours with one trip each . And each trip delivers one of the bigger orders and several of the partial orders.
Bernd Welter
Technical Partner Manager Developer Components
PTV Logistics - Germany

Bernd at... The Forum,LinkedIn, Youtube, StackOverflow
I like the smell of PTV Developer in the morning... :twisted:
Post Reply