A GENERALIZED DECOMPOSITION ALGORITHM FOR REAL-TIME TRUCK ROUTING PROBLEMS

This paper is based on a practical project jointly conducted by a major trucking company and a renowned operations research consulting firm. It studies a large-scale, real-time truckload pickup and delivery problem. A number of cost factors are carefully measured such as loaded/empty travel distance, travel time, crew labor, equipment rental or operational cost, and revenue for completing the movements. This paper proposes a generalized decomposition algorithm that is capable of considering sophisticated business rules. The goal is to recommend executable and efficient truck routing decisions to minimize operating costs. Numerical tests are conducted with operational data from J.B.HUNT. A fleet of 5,000 trucks is considered in this experiment. The test result not only shows significant cost savings but also demonstrates computational efficiency for real-time application.


INTRODUCTION
Research on vehicle routing has seen wide applications in the transportation industry such as truck, railway, airline and pipeline, which saves on costs while covers more demands.The objective is to improve the fleet operational efficiency.This research is important within the context of increasingly automated (or computerized) systems to support decision making for the routing/scheduling routines.It can be easily extended to solving other problems that may look seemingly different, but belong to the same family of NP-completeness (Li et al., 2010(Li et al., , 2012(Li et al., and 2014)).The social economic impact of this problem cannot be overestimated.In the past century, especially during the last 60 years, numerous research efforts have been made specially to solve the trucking industry's routing problems.
The main contribution of this paper is to introduce a decomposition algorithm based on a practical project.The goal is to recommend executable and efficient truck routing decisions to minimize operating costs.Numerical tests are conducted with operational data from J.B.HUNT.The test result not only shows significant cost savings but also demonstrates computational efficiency for real-time application.
Within the company, a fleet of vehicles are to be scheduled and routed to serve a known set of loads, and each load is considered as a full truckload with an origin and a destination (OD) associated with time window constraints for pickup and delivery.There are a finite number of drivers (or, crew in general) available to be assigned.Each driver has to return home within a period of 14 days according to the company rule as well as union regulation to retain drivers (for example, maximum consecutive hours of driving).A route consists of a sequence of moves to be fulfilled by a single vehicle.A typical route needs to have a starting location the same as termination location, which makes a tour to the associated vehicle.Depending on the service type, certain vehicles or drivers may not be eligible.For example, Dedicated Contract Service is a service primarily utilizes semi-trailer trucks to transport cargo across the country; Intermodal Service partners with railways, commercial airlines or port authorities to move containers.Furthermore, once the drivers are committed to certain loads, diversion is typically not allowed with the exception from management approval.For the convenient purpose, this study does not consider diversion in the problem formulation and presentation.The primary objective is to minimize the operation cost.In addition to cost of labor, other major costs include fuel rate, travel distance, equipment rental and length of operation.Revenue from serving each load can be considered as a positive profit or negative cost whenever a load is covered or service is completed.Empty truck moves and empty driver moves (also called deadhead moves) do not generate revenue, thus are only considered costs to the company.It is expected that the developed algorithm is built into a decision making system to recommend routings automatically.

LITERATURE REVIEW
In contrast to the less-than-truckload where each vehicle carries multiple customer demands, truckload only allows a truck to serve a single customer demand each time.An example route of a vehicle starts from depot (or source), loads goods at a factory or warehouse, moves to the load destination facility, unloads the load before goes to another loading location and repeats the same truckload movement.In the end, the vehicle returns to the depot (Labadie & Prins, 2012).This is a typical vehicle routing/scheduling problem in literature.
There is a tremendous literature dealing with mathematical modeling of vehicle routing problems (VRPs), all of which imply that it is impossible to enumerate exhaustively all the possible routes for the vehicles.Earlier efforts to solving VRPs are summarized in extensive reviews as Desrochers et al. (1990) and Solomon (1987).Bramel et al. (1992Bramel et al. ( , 1994) )  with stochastic features drew more and more attention from the research community.These features included but were not limited to stochastic load distributions (Golden & Stewart, 1978;Stewart & Golden, 1983;and Bastian & Rinnooy Kan, 1992), stochastic travel time (Cook & Russell, 1978;and Berman & Simchi-Levi, 1989), or stochastic locations (Laporte et al., 1994;and Bertsimas & Howell, 1993).As the information technologies came into play, recent realtime and dynamic VRP problems became increasingly important (Yang et al., 2004) Published articles on implementation, however, are less popular compared with the counterpart on theoretical studies.When it comes to practical VRP projects, people often look for details about how algorithms are developed and implemented.This paper is originated from industry projects within a major trucking company and focuses on proven practical techniques.Implementation details are revealed so that the readers can have a better understanding of the business logic.It aims at utilizing a combined optimization method and advanced information technology to develop a real-time dispatching system.The computational time invested in searching for better decisions in terms of shorter routes and more revenue should be cautiously balanced with the needs of coming up with a decision in a timely manner.

SOLUTION APPROACH
This decision support system requires a list of components to function properly.Information is updated via continuous data feed, stored in a centralized data warehouse.Forecast module provides projections on the existing truck moves and the estimation on the future demand.Prepossessing module turns the raw data into the format that are favored by the optimizer.Optimization component is the core module that handles the mathematical formulation and sophisticated algorithm.

Information Updating
Although the information arrives all the time, it is not required to run optimizer over the entire fleet all the time.Actually, there are two types of optimization jobs.First type of job is for planning purpose and runs daily.This is normally offline and is scheduled to run overnight or at meal breaks, so that the results are immediately available to dispatchers when they start work or resume work.Second type of job is for real-time optimization.This type of job only considers a smaller set of the fleet because most vehicles are already committed to their loads/route and do not need re-optimization.This is normally triggered from managing team whenever there is a need.

Forecast Engine
Certain loads are visible before they become available for pickup.For example, the containers can be moved by trains with a projected arrival time at the pickup location.The forecast engine would gather the information from partnered carriers to make reasonable projections on the availability of their own loads.This helps the optimization engine to look beyond the current demands and make informed decision for the immediate future.Beyond the visible horizon, long term forecast is also necessary to plan ahead in terms of fleet sizing and infrastructure change at strategic level.

Preprocessing
The preprocessor needs to selectively package the raw data into the network format that the downstream optimizer requires.The basic elements in this network are link (edge) and node (vertex), which are explained in section 5. Examining the feasibility of the links can reduce the burden on the optimizer.For example, it needs to filter out an infeasible link that tries to merry a wrong type of truck to a load.Each node represents an activity such as getting a truck, load or unload.After excluding infeasible links, certain business rules will further reduce the number of links by checking the distance, time or any other resource consumed between two nodes.If certain link violates resource limit, then this link is also excluded.The ultimate goal here is to allow the optimization module find reliable routes through the network easily.

Optimization Strategy
Due to the complicated resource constraints and business rules, it is inconvenient to formulate this truck routing problem into a network flow model.The alternative approach is to apply partition or set-covering model, where the objective function minimizes the combined cost of routes being selected.
An obvious difficulty here is the attempt to explicitly enumerate all the feasible routes, which are typically required in a partition model.Given the total number of loads and available drivers/ trucks, the number of combination is extremely large and increases exponentially with the problem size.Additionally, the business rules are not easy to formulate, such as the maximum hours each driver can take in a tour.Each tour must start and end at driver's home terminal, and there are specified time windows for pickup and delivery.Here we propose a decomposition method to bypass the necessity of evaluating all possible combinations.During the iteration process, a master problem picks the best set of routes to minimize the total cost and price each load in terms of dual variables for the subproblem.The subproblem then updates the network and generates better routes for master problem to consider with.A schema that describes the entire framework of this column generation procedure is presented below in Figure 1.Here in this problem, one can assume that a column refers to a route.

MASTER PROBLEM FORMULATION
subject to: where: x j decision variable, 1 if route j is selected, 0 otherwise k the set of routes in the k-th iteration of the column generation procedure c j the cost associated with route j (operating cost -load revenue) N the set of loads The objective is to minimize the total cost to cover a known set of load demands.The revenue generated from moving a load is considered a negative cost when building the routes, and it usually causes the total route cost to be negative, otherwise the route would not be profitable.Equation ( 2) requires all the load movement to be assigned exactly once.Each load has a dual value π i associated with it, which is the shadow price the load given the current master problem.
It is important to note that during the iteration, the master problem is solved as linear programming relaxation to get dual values.The side constraints are conditional and are not formulated into the master.For example: Although the company prefers its own salaried drivers over the contracted drivers due to the lowered operating cost.DR is the total number of both.When the total number of routes being selected exceeds limit DR, it is intuitive to sort the route costs in an ascending order to pick the first DR.The uncovered loads can be either rejected or outsourced.This is to facilitate the construction of the subproblem, where all the dual values associated with Eq. ( 2) are utilized to reflect what master problem desires.

CONSTRAINED SHORTEST PATH SUBPROBLEM
Our subproblem tries to find an optimal path go through network G that does not consume more than limited resources, such as time window, duration of path, distance, etc.Because of the additional constraints applied to the path, the subproblem is therefore a Constrained Shortest Path Problem (CSPP).A path here represents a truck route in reality.

Subproblem Formulation
Minimize where x i j are the decision variables, 1 if node i is followed by node j, 0 otherwise c i j the cost to proceed from node i to node j A the set of eligible connections, link (i, j ) ∈ A π j dual associated j -th constraint (for load j ) The construction of the subproblem is essential to the usefulness of the generated routes and the overall solution time.A route is a collection of links that are connected by nodes, it is also referred as a path through network.Since it has a single objective function to generate the most profitable route, different cost elements need to be normalized within the network.For example, the overall cost on link i to j is based on the load/empty factor, distance (i, j ), the revenue of moving load j , and dual π j for load j .Given the same distance, an empty-truck move has a baseline cost and zero revenue.A loaded-truck move may double the baseline cost but gain revenue.The changing value of π j is passed from master problem to adapt to the current need.
Each route begins from the source S and ends at sink T .In most cases, the source and sink are the same physical location but have different time windows.This is due to the business rule that the driver has to return to home terminal when the route is completed.Starting from source S, each route has to connect to an artificial node where a driver is "picked up".Assigning a reasonable setup cost for such a node would encourage the model to minimize the total number of routes/drivers used.
Other resource constraints include (1) the maximum duration of each route, which is limited to 14 days; (2) the maximum combined travel distance for each route; (3) the time window for the load, which represents the earliest and latest time to pick up or deliver.In order to solve this multiple resource constrained shortest path problem with time windows, a specialized Label Setting Algorithm is applied.

The Algorithm for
is efficient if none of the labels at node k can dominate it.The path corresponding to an efficient label is defined as an efficient path.Only efficient labels and paths are kept.
Let Q k be the set of labels associated with the cost lower bound of path ending at node k ∈ V , and P k be the set of labels associated with feasible paths.The P k defines the primal function.
The primal function provides an upper bound on the cost of efficient solutions at node k.When primal and dual functions have same value for a given stage, the labels in P and Q are associated to an efficient path for the current stage.
If O = ∅, stop; [The current label(s) at the sink node T is (are) the shortest path(s)].Otherwise, find the lexicographically smallest label F(O) = min lex Step 3. (Look for a label Step 4. (Uncertainty zone).
Define the uncertainty zone for node k: Step 5. (Replacement of the label D * j , C j . (A) Calculation of the efficient labels defining the dual function: Step 2; otherwise return to Step 3. A simple graph with two resource constraints (time, distance) and cost is presented in Figure 2 and Table 1, followed by an example to show how the algorithm works.Figure 2 shows the node and link connections in the network.1(c) shows the constraint for the drivers and loads.In this example, the constraints are time window and mileage.Table 1(d) shows the resources being consumed on each link, as well as the cost on each link.Note that the actual route, which has multiple links, can be 14-days long and undertake more than just two or three loads.Where a 0 and b 0 are the beginning and ending pick-up times, and a 1 and b 1 are the minimum and maximum working miles, respectively.
Deadhead is typically discouraged because moving an empty truck comes with a cost but there is no (direct) gain in revenue.Simply speaking, driver D 0 is originally located at Philadelphia and is eligible for Load L 0 and L 2 at the beginning.Once the load is delivered, the driver may become available again at the load destination (New York or Boston, depending on the load).Preprocessor skips the ineligible connections and adds eligible connections in term of links to the network.This preprocessing is a necessary step to reduce the problem size of the subproblem.
Step 5. Replacement of (12, 0, −∞).As a result, Paths 1, 2 and 3 are non-dominated optimal and are eligible to be added into the path/route pools in the master problem.Note that in this example, labels in P and Q are always having the same sets of labels and paths because the resource constraints never get violated.In the case where certain paths exceed the resource limit, those parts are deemed as infeasible and therefore excluded at the current stage.The lower bound Q, however, would keep this infeasible label for future treatments.This technique is extremely useful when the resource on a directed link is negative.In other words, the previously infeasible path may become feasible again by adding consecutive links to it.This means that before all the paths are examined, one simply cannot determine the best or even most feasible paths.

THE SCHEME OF BRANCH AND BOUND (B&B)
Commercial software CPLEX is used to solve the master problem (linear programming relaxation).The optimal solution is generally non-integer (fractional).The B&B scheme is thus invoked and embedded into the column generation process to obtain an integer solution.The following are the details for the implementation (refer to the flow chart).If there is any existing feasible solution can be extracted from the current truck operating plan, then it should be utilized as the initial solution to speed up the search process.

The Branching Strategy
It is easy to observe that if the solution is non-integer, there must exist at least a pair of consecutive load nodes t 1 , t 2 such that 0 < where T R(t 1 , t 2 ) is the set of routes in which t 2 is executed immediately after t 1 .Based on the set T R(t 1 , t 2 ), the original problem is partitioned (branched) into two subproblems: The testing shows that this strategy gives a more balanced search tree than default variable branching and generally finds an acceptable integer solution more quickly.Conceivably, this method is to branch on the relationship between two consecutive loads.It forces the link to be selected or to be eliminated in the subproblem.

How B&B Scheme is Embedded into the Column Generation Process?
When the B&B scheme is embedded into column generation process, a search tree is created.The nodes in the search tree (stored in a sorted queue) are treated one by one.If the queue is empty, the algorithm is terminated, and the optimal integer solution obtained so far is the solution we are seeking.By treating a node we mean that two branched nodes will be created from this node: -one with = 0 (left node), -and the other with = 1 (right node).
By creating a node we mean that the objective value and the solution at the node are found.
Only the node corresponding to fractional solution with objective value smaller than that of the current optimal integer solution is inserted into the queue.Once a node corresponding to an integer solution is created and its objective value is smaller than that of the current optimal integer solution, then all untreated nodes in the queue with objective value not smaller than that of the created node will be pruned off.Whenever a node a created, a set of columns (for solving the master problem) and a network (for solving the subproblem) should be updated accordingly.

Information Storage and Retrieval
For solving the master problem and the subproblem at different nodes of the search tree, the information on columns and network must conform to the node to be created.There are two ways to get the information: one is from the root node; the other is from the node to be treated (parent node).With the first one, much more memory can be saved, but more computing time is needed (repeated computing), while with the second, the situation is reversed.There is a trade-off between the memory and the computing time.In the first case, we only need to store the original network and the columns generated at root node.The search tree is a binary tree and the root node is at 0 level.We use a label consisting of ( j + 1) identifiers to represent the location of a node at j -th level: ( j, j 1 , j 2 , . . ., j j ), where the first one j is a digit (or digits) which represents the level number of the node location; the second one j 1 represents the location (left or right) of its ancestor at the first level; the third one j 2 represents the location of its ancestor at second level,. . ., and j j represents its location at j -th level.j 1 , j 2 , . . ., j j = L or R, L stands for left branch (0-branch); R stands for right branch (1-branch).For example, a node with label (3, R, R, L) means that the node is at the third level of the search tree, and its ancestors are at the first and second levels on the right location.The third-level node is at left location.In the second case, we only need to indicate where the treated node is located and then modify the columns and network of its parent node respectively to process.

The Modification of the Columns for the Master Problem
In the 0-branch, we delete all columns i for which a t 1 ,i = 1 and a t 2 ,i = 1.In the 1-branch, we delete all columns i for which a t 1 ,i = 1 and a t 2 ,i = 0, or a t 1 ,i = 0 and a t 2 ,i = 1, and the row corresponding to constraint for node t 2 due to the redundancy.Figure 3 illustrates this process.The underlying assumption is that each load can be covered only once at most.The 2nd coverage for the same load will not bring additional revenue.
In 1-branch, the dimension of the basis matrix is thus reduced by one.The modification of the columns depends on the location of the created node in the search tree and also depends on from where the information is obtained.For example, if we use the information on columns at root node and the created nodes are (3, R, R, L), then all columns at root node having a t 1 ,i = 1 and a t 2 ,i = 0, a t 1 ,i = 0 and a t 2 ,i = 1, a t 3 ,i = 1 and a t 4 ,i = 0, a t 3 ,i = 0 and a t 4 ,i = 1, a t 5 ,i = 1 and a t 6 ,i = 1 are deleted.The row corresponding to constraint for node t 6 is also deleted due to the redundancy.We assume that the branching at first, second, and third level is based on T R(t 1 , t 2 ), T R(t 3 , t 4 ), T R(t 5 , t 6 ) respectively.

Modification of the Network for the Subproblem
We must restrict the columns to be generated by the subproblem to those that are compatible with the current created node in the search tree.The structure of the network used to generate the feasible columns should be modified accordingly.In the 0-branch, the columns covering consecutively nodes t 1 and t 2 are forbidden.As a reminder, there are the columns having t 2 executed immediately after t 1 .In the network we split the middle node M, where the link corresponding to t 1 terminates and the link corresponding to t 2 starts, into two nodes M 1 and M 2 ; all links originally terminated at M are now moved to M 1 , and all links originally started from M are moved to M 2 .The resource constraints on M 1 and M 2 remain the same as M. In the 1-branch, we force any route covering t 1 to also cover t 2 immediately.In the network, the two links corresponding to t 1 and t 2 are condensed into one link, and all the links originally terminated at the middle node of the previous two links are deleted.Figure 4 shows this modification.The cost and resource consumption for the condensed link are: (a) the cost of the newly created link equals to cost(t 1 )

TESTING RESULTS AND REMARKS
To prove the capability of the prototyped routing optimizer, we select top 10 US cities with the largest populations and set Dallas as home based depot (as shown in Table 2 and Figure 5).From these 10 cities we can have 45 non-directional city pairs sorted in an alphabet order on the origin city and destination city (as shown in Table 3).
For each pair, we call a random number between 0 and 1, if this number is less than 0.5, set a direction from origin to destination (ex.Houston to San Diego); otherwise set an opposite direction from destination to origin (ex.San Diego to Houston), where Dallas is a home base depot that every driver must return back to Dallas within 7000 miles (approximately equivalent to 2 weeks).One of the performance measurements is Load Factor (LF).For each truck driver route, LF is the total loaded miles divide by total miles (loaded miles + empty miles) traveled starting from and returning to the depot: Dallas.100 random generated data sets have been tested between current existing algorithm and our new column-generation based algorithm to compare both number of drivers used and Load Factor (LF) to complete each set of 45 loads crossing those 10 cities. Table 4 gives the details on each test case.The average run time is very stable and is within a few minutes for the tested problem size.Table 5 shows the overall performance.
Our sample testing indicates that our new column-generation based solution method will reduce about 16% of drivers and improve the Load Factor (LF) by about 9%.
The company also conducted an on-site experiment with real production data.About 3,500 externally contracted drivers, who were mainly independent business operators, and 1,500 corporate salaried drivers were considered in the problem for dispatching.Again, corporate drivers normally cost less than external contracts.About 15,000 loads are required to be covered.The   decision variable is defined as a route, which is the combination of drivers, the loads and sequence of covering the loads.Without any of the preprocessing to eliminate routes, the number of decision variables is 2.5 × 10 20 if the maximum of four loads are allowed in a single route.This number increases to 3.8 × 10 24 if five loads are allowed in a single route.The prototype successfully considered all the major business criteria and constraints to have problem solved within 20 minutes on the company's mainframe machine.After comparing with the company's then-current operating plan, over 10% cost saving was achieved, which amounted to millions of dollars annually.
The proposed decomposition algorithm can be easily generalized to many other industries that share similar characteristics.For example, railway, airlines and pipeline share the similar network characteristics.Resource constraints can be modeled in terms of time, materials, vehicle or line capacity, distances, volumes or even headcount.Sometimes it is difficult to consider certain requirements such as recurring maintenance constraints and sophisticated union rules, solving the problem without these rules as in the case of this study at least can serve as a benchmark for the real problem.We leave as a future potential research effort to incorporate those additional constraints into routes developed.
Powell et al. (1995) presented a survey of dynamic fleet optimizations dealing with some general issues.Later work of Powell et al. (2000) developed a practical model to consider dynamic assignment of drivers to known demands, which provided significant insights to our study problem here.Re-optimization policies are further introduced and tested in Yang, et al. (1998).The most recent reviews summarizing the state-of-art techniques are available in Laporte et al. (2013), Derigs et al. (2013), and Braekers et al. (2016).
and D * k belonging to uncertainty zone ⎫ ⎬ ⎭ (B) Calculation of the feasible paths defining the primal function:

Figure 5 -
Figure 5 -Top 10 US Cities with the Largest Populations.
presented some probabilistic analyses of earlier heuristics for the deterministic version of the problem.Later, VRPs Pesquisa Operacional, Vol.38(2), 2018

Shortest Path with Resource Constraints Let
(D * ik , C ik ) and (D * jk , C jk ) be the labels representing two different paths to node k.Then the first label dominates the latter, if and only if (D * ik , C ik ) − (D * jk , C jk ) ≥ (0, 0).The first label is smaller than the latter, i.e., (D * ik , C ik ) L < (D * jk , C jk ), if and only if (D * ik , C ik ) = (D * jk , C jk ), and the first non-null element of ((D * ik

Table 1 (
a) shows the drivers' profile.Table 1(b) shows loads' profile.Table

Table 2 -
Top 10 US Cities with the Largest Populations.

Table 4 -
Computational Results of 100 Tests.

Table 5 -
Comparison Between Existing And New Methods.