Page 1 of 1

How to Make a overnight stay depending on distance to home

Posted: Wed Nov 16, 2016 2:52 pm
by frank.essenberger
Hello everybody,

in our current project we would like to model the following behavior: Depending on a critical distance to the home location, the driver should return to his home depot or make a overnight stay. Is such a thing possible?

Regards
Frank Essenberger

Re: How to Make a overnight stay depending on distance to ho

Posted: Wed Nov 16, 2016 2:56 pm
by Bernd Welter
Hello Frank,

I just saw that your requirement has already been described in an older posting:
http://xserver.ptvgroup.com/forum/viewt ... =108&p=274

There is no direct distance related parameter but of course the relation between the vehicles costs (per distance, per time) and the overnight stay (costs per hotel night) are balanced and we return the cheapest solution that matches the constraints such as
  • maximum number of overnight stays
  • overnight patterns
Does this answer the question?
Best regards Bernd

Re: How to Make a overnight stay depending on distance to ho

Posted: Thu Nov 17, 2016 8:28 am
by frank.essenberger
Yes this answers the question. Just to put this also in the Java API context I am using. We have on the one site the car object:

Vehicle-> VehicleCosts->costsPerKm, fixedCosts...

and on the other site the planning parameters object passed to planOvernightTour method:

OvernightParams->costPerUnplannedCustomer, costPerOvernightStay

Internally, the optimal (cheapest) solution is found be comparing the costs for driving home each night or taking a hotel.

Re: How to Make a overnight stay depending on distance to ho

Posted: Thu Nov 17, 2016 9:49 am
by Bernd Welter
Yes - we consider the various cost relevant properties of the vehicle plus the overnight params.