Modeling and Evolutionary Optimization for Multi-objective Vehicle Routing Problem with Real-time Traffic Conditions

The study of the vehicle routing problem (VRP) is of outstanding significance for reducing logistics costs. Currently, there is little VRP considering real-time traffic conditions. In this paper, we propose a more realistic and challenging multi-objective VRP containing real-time traffic conditions. Besides, we also offer an adaptive local search algorithm combined with a dynamic constrained multi-objective evolutionary framework. In the algorithm, we design eight local search operators and select them adaptively to optimize the initial solutions. Experimental results show that our algorithm can obtain an excellent solution that satisfies the constraints of the vehicle routing problem with real-time traffic conditions.


INTRODUCTION
In 2017, China's total social logistics expenditure accounted for 14.6% of GDP. Every 1% diminution in the total logistics expenses in GDP will reduce hundreds of billions of costs. And with the rapid development of the logistics industry, the vehicle routing problem (VRP) has attracted more and more attention.
Due to different application scenarios, many variations of VRP appeared, such as capacitated VRP (CVRP) [1], VRP with time windows (VRPTW) [2], and so on. But, in the actual distribution process, the dynamic change of traffic conditions is one of the main challenges for planning vehicle routes since traffic conditions directly affect the driving time of vehicles on the road network, thus causing many emergencies. If a vehicle arrives at a delivery location later than the customer's specified latest time, customer satisfaction is significantly reduced. Existing studies that considered traffic factors simply used a random function or periodic random function to generate traffic conditions [3]. However, the traffic factors generated by the stochastic method are far from the traffic conditions in the actual road network since the traffic flow between the road sections is interrelated. In order to make the VRP model closer to the actual engineering situation, this paper proposes an unprecedented VRP that combines the road network topology and the multi-objective VRPTW with a soft time window (MOVRPRTC). The road network data in this model come from the road traffic network of Guanggu in Wuhan, and the order data come from the real online shopping order data after desensitization.
Heuristic algorithms are the only feasible ways to solve practical VRP since exact algorithms could not solve complex VRP in an acceptable time [4]. The heuristic search algorithms applied in VRP mainly focus on genetic algorithm [5,6], ant colony optimization [7], adaptive large neighborhood search [8,9]. Through the investigation of these methods, we found one disadvantage that almost no algorithm adopts any specific mechanisms to handle constraint conditions, i.e., they directly discard infeasible solutions during iterations. In this case, the algorithm can only search in the feasible region, and its exploration ability will be extremely limited. However, there may be better quality solutions in the space outside the feasible region. If we keep these solutions, some operations can be carried out to pull them back to the feasible region and meanwhile keep their quality. To address this disadvantage, we convert the two objectives in MOVRPRTC into constraints first and then make use of a dynamic constrained multi-objective optimization algorithm framework (DCMOEA) [10] to handle constraints. It turns out this method greatly enhances the selection pressure in the multi-objective optimization.
There are three contributions to this paper. Firstly, realistic databased vehicle routing problem considering road network Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request  constraints and real-time traffic conditions is constructed, which can be used as test cases for future researchers. Secondly, the dynamic constraint multi-objective optimization framework is applied to the combinatorial optimization problem, which provides a new idea of constraint treatment in the combinatorial optimization problem. Thirdly, several productive local optimizers with adaptive selection schemes are designed, which proved to be very effective in solving our proposed MOVRPRTC.
The remaining sections of this paper are organized as follows. Section 2 describes the modeling method of MOVRPRTC, including the road network topology construction and the vehicle routing problem formulation. Section 3 introduces our proposed optimization algorithm for MOVRPRTC, including the application of dynamic constrained multi-objective evolutionary algorithm framework in VRP and the adaptive local search mechanism. Experimental results are shown in Section 4. Finally, the conclusion is given in Section 5.

MODELING OF MOVRPRTC 2.1 Construction of Road Network
In MOVRPRTC, routes can only exist on real roads of the traffic network. The first crucial step of road network construction is to determine the connection between coordinate points in the road. Take the junction shown in Figure 1 as an example. The junction is represented by four coordinate points 4, 5, 8, and 9, which are shared by four roads. Point 4 has two precursor points, i.e., point 1 and 5, and two successor points, i.e., point 3 ad 8. After determining all the connections, the entire topology will be completed.

Figure 1. Topology of road junction.
Another critical step of road network construction is to determine the weight variance of each edge with the variance of time. The structure of the road network in a specific area remains almost unchanged in the short term, and most people's daily activities are regular, the traffic conditions vary nearly periodically. So, we can use the traffic trend of any specific day to model the traffic trend. However, considering the difference between the workday and weekend, it is more reasonable to model the traffic trend from the data of a week. In addition, due to some weather anomalies or some other unexpected reasons, the traffic trend may be different on the same day in a different week. So finally, we collected the traffic conditions of the expressway in the Guanggu area within three weeks and used BP neural network to model the traffic trend. Figure 2 shows the traffic trend of a section of the road within 24 hours.

Figure 2. Traffic conditions within 24 hours of a road.
All the data for the construction of the road network come from the Amap traffic status API [11].

Formulation of MOVRPRTC
MOVRPRTC is described as follows: in road network topology where K represents the number of vehicles used. f is the sum of the delay time of all vehicles. 3 f is the sum of the waiting time of all vehicles, which is used to measure the delivery efficiency. All objectives need to be minimized.

OPTIMIZATION ALGORITHM FOR MOVRPRTC
To address MOVRPRTC, we use the dynamic constraint multiobjective genetic algorithm framework to deal with the constraints, NSGA-II [12] for multi-objective selection, and our newly proposed adaptive local search algorithm to optimize candidate solutions.

Multi-objective Optimization
Multi-objective optimization is the process of simultaneously optimize two or more conflicting objectives. A multi-objective problem can be written as follows:

Framework of ALSDCMOEA
The dynamic constraint multi-objective genetic algorithm framework has three characteristics for MOVRPRTC: 1) a constraint optimization problem equivalent converted into a dynamic constraint multi-objective optimization problem with two types of objectives: a) original objective; b) constraint-violation objective. 2) using the idea of simulated annealing, gradually reducing the constraint boundary aims to handle the constraint difficulty.
Inspired by DCMOEA, 2 f and 3 f in MOVRPRTC can be converted into constraints. Then the problem can be converted into VRPRTC:

Solution Initialization
Before introducing the initialization method, we need to explain the encoding of the solution first. Since MOVRPRTC contains the road network, a solution should include not only the serving sequence of customers but also the detailed traveling sequence of coordinate points of each vehicle. Figure 3 shows an example, where sequence A indicates the serving sequence of the customers, sequence B indicates the traveling sequence of the coordinate points, gray dots between the depot and the customer 1 indicates the point in the road network that the vehicle needs to travel from the depot to the customer 1. The optimization algorithm only operates sequence A to reallocate customers for vehicles and change their serving sequences. Sequence B is only used for evaluation.

Figure 3. Solution representation.
To get the initialization solution, we use the agglomerative hierarchical clustering (AHC) algorithm to group customers into several clusters, one of which represents the customers served by one vehicle. The advantage of using AHC is that the number of vehicles required can be adaptively adjusted according to the demand of customers.

Adaptive Local Search for MOVRPRTC
The fundamental tasks of solving MOVRPRTC are the allocation of vehicles for customers and the sequencing of customer servings. In order to address these two tasks, we design eight local search operators and use an adaptive framework to help the algorithm jump out of the local optima. The eight operators showed as below: LS1: Randomly choose two different customers from a random vehicle, and swap their serving orders; LS2: Randomly choose two different customers from a random vehicle, and reverse the serving sequence between these two customers (the length of the sequence shall not exceed 3); LS3: Randomly choose one vehicle and randomly intercept a sequence from it, then insert the sequence into another randomly selected vehicle. Then the entire serving sequence of the inserted vehicle should be re-sorted by nearest neighbor search; LS4: Find two customers with the maximum wait time and with the maximum delay time, respectively. Insert the customer with the maximum delay time at the position right before the customer with the maximum wait time; LS5: Randomly select a customer from a random vehicle, and insert it at a random location in another randomly selected vehicle; LS6: Repeat LS5 several times (no more than 4 times); LS7: Find the customer with the maximum traveling time, and insert it at the position right before the customer who has the maximum waiting time; LS8: Find the customer with the maximum traveling time and insert it at a random location.
LS1 and LS2 are designed for changing the serving sequence, and the other operators are designed for changing the allocation of customers. After the local search is operated on a solution, the solution's path will be reconstructed by a specific function. The main content of this function is the A* algorithm, which can get the shortest route for every vehicle according to the real-time traffic conditions.
The pseudo-code of ALS is shown in Algorithm 2. The subtlety part is the adaptive mechanism. At the beginning of the algorithm, each operator has the same weight, and then it will be adjusted according to the performance of the offspring generated by the operator in each iteration. If a better solution is generated, the corresponding operator's score will be incremented by 1. In each iteration, the operators will be selected by the roulette. If the best solution remains unchanged for specific iterations, the algorithm will be considered as being converged. At this time, the scores of all operators are reset to 1, and then the algorithm continues until the termination condition is reached.

EXPERIMENT
The following experiments are run on a PC equipped with Core-i7 3.4 GHz and 16 GB of RAM. All algorithms are implemented in C++. Problem parameter settings: The opening time of the depot is from 8:00 to 24:00. The vehicle type is the same one, with a maximum capacity of 3 tons. The number of customers is 100. Algorithm parameter setting: The population size is 100, which means that the number of new solutions generated in each iteration is 100. The maximum number of iterations is 10000.

Performance of Optimization Methods
In order to prove the effectiveness of the adaptive scheme for local search operators, we compare our original algorithm with a modified version without the adaptive scheme. Their operators are the same, except that the modified version randomly selects one of eight operators in each iteration. As shown in Figure 4, the original version is superior to the modified version in terms of the wait time and delay time, and meanwhile not inferior to the modified version in terms of the total length. Aiming to illustrate the full effect of ALSDCMOEA more intuitively, we compare the best solution of the initial solutions with the best one of the final solutions. The best solution is defined as the solution with the minimum sum of three objectives. Their objectives are shown in Table 1.

CONCLUSION
This paper proposed a multi-objective vehicle routing problem with real-time traffic conditions. The traffic condition data and customer demand data in the model all come from real-world data.
In order to address this problem, this paper also proposed an adaptive local search algorithm based on a dynamic constrained multi-objective evolutionary algorithm framework. Experimental results show that ALSDCMOEA can effectively solve MOVRPRTC.
The scale of MOVRPRTC used in this paper is small, and we can increase it in many ways, including extending the coverage of the map, increase the number of customers, increase the density of the road network, etc.. As for the algorithm proposed in this paper, we need to conduct more experiments to prove the effectiveness of the DCMOEA. In addition, to further improve the performance of ALSDCMOEA, some other multi-objective optimization algorithms should also be attempted to use, such as MOEA/D.