Page 1 of 1

Weird result when planning multi-day one-way with overnight

Posted: Fri Jan 14, 2022 4:01 pm
by Oliver Meyer
Hi,

we recently observed a strange behaviour of xTour Internet when doing tour optimization using "planOvernightTours", specifically multi-day one-way tours with overnight stays.

We have a request where about 50 TransportOrders are to be planned, with an available time frame of 5 days.
The time restriction on the driver is every day 08:00 - 17:00; the time restrictions on the transport orders are every day 00:00 - 23:59.
Overnight stays are allowed for every day.

When we plan the tour as a roundtrip (i.e. start depot = end depot), all the transport orders are scheduled as expected.

However when we plan the tour with exactly the same transport orders and all the same restrictions EXCEPT that the tour is planned as a one-way trip (i.e. start depot is not end depot), the result is that only the first 9 or so transport orders are planned (all on one day; which day it is appears to be random), while the rest of the week will be unused and all the other transport orders marked as unscheduled.

The use case of a multi-day one-way tour with overnight stays is rare for the users of our application, so we don't know for how long this has been that way without being noticed. But I'm pretty sure this used to work differently some time in the past.

Can you please elaborate why xTour behaves that way?
I can send you the request as XML if needed.

Thanks in advance & greetings

Oliver Meyer
Nagarro ES GmbH

Re: Weird result when planning multi-day one-way with overni

Posted: Fri Jan 14, 2022 4:28 pm
by Bernd Welter
Indeed: it is needed ;-)
Send it to me 1:1.

At least if the following hint doesn't answer the question:

If you set "startDepot != endDepot" with planBasicTours this also means that we determine a single tour.
If you also set "toursMustFitIntoSingleOperatingInterval" we have no other choice but to use only a single day.

Best regards,
Bernd

Re: Weird result when planning multi-day one-way with overni

Posted: Mon Jan 17, 2022 7:40 am
by Oliver Meyer
Hi Bernd,

please find the sample request attached.

Greetings
Oliver Meyer

Re: Weird result when planning multi-day one-way with overni

Posted: Mon Jan 17, 2022 11:19 am
by Bernd Welter
Hello Oliver,

from what I see in your request: costPerUnplannedCustomer=0.0
So if it doesn't matter whether youi visit a customer or not it is always cheaper to skip them ;-)

By setting this cost factor to 100.0 I get the orders scheduled.

Best regards,
Bernd

PS: you also set the costPerOvernightStay=0.00 and maximumNumberOfAllowedOvernightStays=4 (plus positive pattern).
This means that yopui will always stay in a hotel. Is that your desired behaviour?

Re: Weird result when planning multi-day one-way with overni

Posted: Tue Jan 18, 2022 3:46 pm
by Oliver Meyer
Hi Bernd,

thanks for the hint, that seems to fix the problem!

We'll test if and how it also affects the results in other scenarios.

costPerOvernightStay=0.0 is actually what we want, since the users can enable/disable overnight stay for every day in our UI. If they enable it, the hotel stay should also be done in any case.

Best wishes,
Oliver