3. Resultados y discusión
3.4. Efecto del método de síntesis
We now turn towards Algorithm 6 again. The task is to efficiently check the fea- sibility of all neighbors of the incumbent solution with respect to the 2-opt*neigh-
borhood. In the end, we are interested in a feasible neighboring solution that is evaluated best. In the following, we describe the feasibility and gain evaluation of a single move.
LetR0 andR00 be two different vehicle routes. Suppose we take a first part from
R0and a second part from R00, precisely we take the first x customers fromR0 and the last y customers from R00 in order to create a new vehicle route R000. Without loss of generality, we assume that both x and y are not 0. We use the short notation c0 := R0[x] and c00 := R00[|R00| −y+1]to denote the customers that we want to connect. Let drivec0,c00 be the driving time between them.
To find out whether R000 is feasible or not, we compare the labels −→Lserved c0 and ←− Lserved c00 . If −→ dlservedc0 +drivec0,c00+ ←−
dlservedc00 exceeds the total driving time limit limitDlong,
R000is infeasible. So we only continue if this is not the case. Then, the next step is to do the following for every index pair(j, k), where j is an index between 1 and x and k is an index between 1 and y. For a given index pair(j, k), we first compute the number h#j,kof due breaks en route:
h#j,k := l(−→dsservedc0,j +drivec0,c00+
←−
dsservedc00,k )/limitDshort m
−1
For instance, if−→dsservedc0,j +drivec0,c00 +
←−
dsservedc00,k ≤ limitDshort, then no break en route is
6.4. Conclusion and Outlook 125
with respect to the index pair(j, k)as the minimum of−→Tserved c0,j (t) +
←−
Tserved
c00,k (t0) + (t0− t)over all t and t0with t+drivec0,c00 +h#
j,k·break≤t0. The travel time functions may
be undefined for some t but we treat ⊥ just like ∞ here. For a given t, the point in time t0 is quickly determined as the earliest point in time that is not earlier than t+drivec0,c00+h#
j,k·break and for which ←−
Tservedc00,k (t0)is defined.
After we have calculated the minimum travel time ofR000 with respect to every index pair(j, k), the (overall) minimum travel time ofR000is the minimum over all j from 1 to x and all k from 1 to y. If it is undefined, thenR000 is infeasible. If not, we finally check whether the minimum travel time of R000 exceeds the maximum allowed travel time limitTlongor not.
Let the input of a checking routine be two labels−→Lserved c0 and
←− Lserved
c00 , let size(L) denote the size of the labelL, that is, the number of pieces of information contai- ned therein, and let nodes(L) denote the length of the contained sequence of tu- ples (corresponds to x or y here). Then the time it takes to evaluate a move is in O(size(−→Lserved c0 ) ·nodes( ←− Lserved c00 ) +size( ←− Lserved c00 ) ·nodes( −→ Lserved c0 )). We conjecture – but do not prove – that the size of a label is polynomial in the number of customers in the route and the number of their time windows. Note that the scheduling problem at hand is a subproblem of the problem treated in chapter 4, which was proven to be solvable in polynomial time.
Checking a neighboring solution means to do the above for two new links. That is, we do so not only for(c0, c00)but also for(R0[x+1],R00[|R00| −y]), unless x = |R0|
or y = |R00|. In order to evaluate the gain of the move, we sum up the minimum travel times of the two output routes and subtract the minimum travel times of the input routes. In the special case x = |R0| and y = |R00|, the number of routes in the solution is decreased by one. Recall that minimizing the number of routes in the solution is the primary optimization goal.
6.4
Conclusion and Outlook
As the VRTDSP with multiple time windows is a highly complex problem, we have focused on local search based algorithms to solve it. We have shown how to pro- pagate travel time information forward and backward. When such information is pre-computed, the concatenation of two partial routes can be evaluated efficiently. 2-opt*is an example of a neighborhood where this technique is particularly useful.
However, bidirectional labeling can also be advantageous for other neighborhoods, such as the insert or the swap neighborhood in which one customer is moved from one route to another or two customers are exchanged between their routes, respecti- vely. Our approach works for any setting of the break parameters (for instance, we could allow 10 hours of driving between two long breaks instead of only 9 hours) and with the general break policy that allows breaks en route at any time, unlike the approach of Schiffer et al. (2017). We conjecture that it takes polynomial time (in the number of customers and the number of time windows) to find the best move in the 2-opt*neighborhood.
For the sake of completeness, we have presented a very simple local search based algorithm to solve the VRTDSP. But our approach for the route evaluation could as well be integrated into the far more sophisticated solution framework of Vidal et al. (2014) by implementing the Eval2 function. At PTV, we have incorporated the presented ideas into the move evaluation of the vehicle routing service of PTV
126 Chapter 6. Vehicle Routing and Truck Driver Scheduling
xServer. Here, we have even implemented an enhanced variant that works with two types of breaks under the no-long-break-en-route policy (see section 5.6).
In the European Union, there is a relaxing rule that allows to take a break in two parts. In this chapter, we have ignored this rule, even though an extension of the presented approach to the ruleset{drive until driven, first-second-split}is not overly difficult (see section 3.4).
We have proposed an exact scheduling method that always finds a feasible sche- dule if one exists and that returns the minimum travel time. However, the overall problem, the VRTDSP, is typically not solved to proven optimality in practice. The- refore, one direction for future research is to assess the pros and cons of a heuristic scheduling approach that no longer guarantees optimality of the subproblem. As long as the returned solution is feasible, it would suffice to have a method that does not always find a feasible solution if one exists and does not necessarily output the minimum travel time if it finds one. In particular, if the second optimization crite- rion was not the minimum total travel time but the minimum total distance, then the adverse effects of the non-optimality may be acceptable and outweighed by a shorter run-time.
Minimum Service Cost Objective We have considered a constraint on the maxi-
mum travel time of each vehicle route and the total travel time of all routes as se- condary minimization goal. This is common both in theory and in practice. But sometimes, there are other cost drivers that should also be taken into account. To this end, let us suppose that the length of the planning horizon is at most limitTlong.
In this scenario, we do not need to keep track of the minimum travel time accumu- lated since the last long break. Instead, we could focus a little more on actual costs.
So far, we have only considered hard time window constraints. Ibaraki et al. (2005) propose general time windows as a generalization of hard and even soft time windows. This means we are given a time-dependent service cost function that maps a time t to the cost that a service entails when it starts at time t. Hard time windows are a special case in which the costs are either 0 or infinite. With such a service cost function, we can assign a cost value between 0 and ∞ to a service that begins rather late or early. Even priorities of time windows can be expressed. In practice, this is very useful when perishable groceries need to be delivered. Let us take a delivery to a supermarket or a (fast food) restaurant as an example. The groceries need to be accepted and handled by the staff of the supermarket or the restaurant. Hence, the service cost of the delivery may be higher the more crowded the store or restaurant is and the busier the staff is with other things at that time.
In our algorithm, we could store the accumulated service cost since the end of the last long break instead of the accumulated travel time since then. With such a function, we could optimize the service level over all customers. Hashimoto, Ya- giura, and Ibaraki (2008) even regard a time-dependent driving time function and a time-dependent driving cost function for every pair of customers in addition to the time-dependent service costs. Time-dependent driving costs could also be in- tegrated into our approach – but only as long as the driving times remain time- independent.
127
Chapter 7
Truck Driver Routing on
Time-Dependent Road Networks
We study the problem of computing time-dependent shortest routes for truck dri- vers. In contrast to conventional route planning, truck drivers have to obey go- vernment regulations that impose limits on non-stop driving times. Therefore, route planners must plan break periods in advance and select suitable parking lots. To en- sure that maximum driving times are not exceeded, predictable congestion due to, e.g., peak hours should also be taken into account. Therefore, we introduce the truck driver routing problem in time-dependent road networks. It turns out that the combination of time-dependent driving times with constraints imposed by drivers’ working hours requires computation of multiple time-dependent profiles for optimal solutions. Although conceptually simple, profile search is expensive. We greatly re- duce (empirical) running times by calculating bounds on arrival and departure times during additional search phases to only query partial profiles and only to a fraction of the parking lots. Carefully integrating this approach with a one-to-many extension of time-dependent contraction hierarchies makes our approach practical. For even faster queries, we also propose a heuristic variant that works very well in practice. Excellent performance of our algorithms is demonstrated on a recent real-world in- stance of Germany that is much harder than time-dependent instances considered in previous works.
Note This chapter has been published before. Apart from a few minor changes, it is an exact quote of the paper by Kleff et al. (2017). As such, it is self-contained and does not require the knowledge of previous chapters.
7.1
Introduction
In many countries of the world, truck drivers are legally obligated to take breaks on a regular basis to obviate drivers’ fatigue and hence increase road safety. For in- stance, Regulation (EC) No. 561/2006 of the European Union (European Parliament and Council of the European Union, 2006) demands a break of at least 45 minutes af- ter at most 4.5 hours of driving. And according to the hours-of-service regulation in the United States (Federal Motor Carrier Safety Administration, 2011), a 30-minutes- break is mandatory after at most eight hours have elapsed. Truck drivers must park their vehicle at a suitable location before taking such a “lunch break”. Due to the size of their trucks, the drivers are severely limited compared to car drivers when in se- arch of a parking space. For assistance in finding appropriate and available parking
128 Chapter 7. Truck Driver Routing on Time-Dependent Road Networks
lots, truck drivers use mobile apps like Truck Parking Europe1 that maintain data-
bases of parking lots and display nearby lots to users. In this work, we investigate the following optimization problem: En route from one customer to another, when and where should the driver take a break (if at all) to conform to the provisions on breaks and arrive at the destination earliest possible?
We only consider one drive from a source to a destination. In general, a truck driver may visit multiple customers per day. In this case, the customers’ time win- dows also have to be regarded. Moreover, if a trip takes more than one day, not only lunch breaks have to be scheduled but also longer rest breaks for the driver to sleep. The problem of scheduling breaks in order to comply with regulations while also taking customer time windows into account is known as the truck driver scheduling problem (Goel, 2010). However, the locations of the parking lots remain disregarded in this setting. In this work, we take a major first step towards combining time- dependent route planning and truck driver scheduling. We determine not only when but also where to take a break.
We consider time-dependent driving times to model predictable congestion. In this scenario, it might be beneficial to not depart from source right away, or to pro- long a break, or to wait at a parking lot for a time that is too short to count as break. As an example of short-term waiting, imagine the following: At the time of arrival at a parking lot, the driving time to the destination would be two minutes longer than the remaining allowed driving time. Luckily, the driver just has to wait ten minutes for the congestion to disperse and for the driving time to drop by these two minutes. In contrast to the European Union, short-term waiting does not pay off in the United States because the lunch break becomes mandatory after eight hours have elapsed, and not after a certain accumulated driving time. In the following, we focus on the EU regulation.
Time-dependency makes the problem particularly challenging, and the question arises whether it can be solved efficiently in practice. We are interested both in op- timal and in heuristic approaches. There are a couple of parameters to reduce the run-time, and we seek to shed light on their impact on the solution quality. For our experimental analysis, it is sufficient to assume that the driver stops at only one parking lot (if at all). For a planning horizon of one day, this is no substantial limita- tion in practice as a daily driving time of 9h (US: 11h) should not be exceeded, even though it may be extended to 10h twice a week. For the sake of completeness, we discuss the implications regarding multiple stops.
Related Work Route planning algorithms have received a large amount of atten-
tion in recent years, resulting in a multitude of speedup techniques (Bast et al., 2016; Sommer, 2014). In the time-dependent scenario, there are driving time functions asso- ciated with the edges. These map the time of the day to a driving time (Cooke and Halsey, 1966). Dijkstra’s algorithm (Dijkstra, 1959; Dantzig, 1963) can be generali- zed (Dreyfus, 1969) to answer earliest arrival (EA) queries. However, profile queries asking for the driving time function between two vertices are not feasible for large road networks (Delling and Wagner, 2009). The reason is that profiles may have su- perpolynomial complexity (Foschini, Hershberger, and Suri, 2014), and maintaining them for all vertices makes Dijkstra’s algorithm impractical.
Several classic speedup techniques have been generalized to the time-dependent scenario (Baum et al., 2016; Delling, 2011; Delling and Nannicini, 2012), typically focusing on fast EA queries. Efficient EA and profile queries at continental scale