Electric Vehicle Routing Problem with Charging Time and Variable Travel Time

An electric vehicle routing problem with charging time and variable travel time is developed to address some operational issues such as range limitation and charging demand. The model is solved by using genetic algorithm to obtain the routes, the vehicle departure time at the depot, and the charging plan. Meanwhile, a dynamic Dijkstra algorithm is applied to find the shortest path between any two adjacent nodes along the routes. To prevent the depletion of all battery power and ensure safe operation in transit, electric vehicles with insufficient battery power can be repeatedly recharged at charging stations.The fluctuations in travel time are implemented to reflect a dynamic traffic environment. In conclusion, a large and realistic case study with a road network in the Beijing urban area is conducted to evaluate the model performance and the solution technology and analyze the results.


Introduction
With energy crisis and environmental pollution problem, petroleum use and energy diversity have gained global interest and raised public concern in many countries.In [1], transportation section has occupied 30% greenhouse gas (GHG) in the United States.Therefore, the construction of efficient, intensive, and low-carbon transportation systems has become a controversial topic.Two major approaches to sustainable transportation are being considered: renewable energy technologies and efficient transportation operations.As one way of developing the renewable energy technologies, alternative fuel vehicles (AFVs), such as hybrid vehicles (HVs), plugin hybrid electric vehicles (PHEVs), and electric vehicles (EVs), have been manufactured to reduce vehicle emissions.Reference [2] introduces the transition challenges of AFVs in transportation systems from the viewpoints of consumer choice, market growth, vehicle performance improvement, and fuelling infrastructure.EVs that are totally powered by onboard batteries have advantages over traditional vehicles in zero energy emissions and environment protection.Reference [3] focuses on development opportunities, technological problems, cost-effectiveness, and policy support to introduce EVs and forecast future EV adoption trajectory within 10 years.With the increasing improvements in battery technologies and charging station construction, EVs are gaining popularity and associated with many fields of transportation.
Recently, logistics is searching for a new technological innovation to surpass the traditional distribution mode and improve operational inefficiency.The combination of logistics and EVs is consistent with the objective requirements of sustainable transportation.In Beijing, under the leadership of the government, 70 logistics EVs coming from four logistics companies are applied in several distribution areas such as express delivery and supermarket delivery.The related problems such as the vehicle routing problem (VRP) are being focused on.VRP, in which the multiple routes for a fleet of vehicles are determined for a set of customers to minimize the object value, is a classical problem among many distribution problems.The combination of EVs and VRP is a new extended VRP and is called the electric vehicle routing problem (EVRP).Reference [4] considers some comprehensive constraints, such as time window, range constraint, charging stations, and cargo weight, to propose an EVRP model.However, the model merely considers static traffic.The varying traffic conditions in a real road network may cause battery power to be completely depleted while in transit.Reference [5] concentrates on the limited range of AFVs and the lack of refuelling stations to develop a green VRP model with the objective of minimizing the total distance.Reference [6] simultaneously combines the charging station location problem with the EVRP to minimize the total costs, including travel cost, charging cost, and location cost.In [7], because of the limited range, EVs can be recharged at special sites in transit and a charging EVRP model is given.Finally, the average tour length is estimated.
In the EVRP, several subproblems such as the route planning problem and the shortest path problem sometimes need to be solved.Reference [8] uses the minimum time as the object to develop three different types of traffic network equilibrium models in terms of charging time and energy consumption.The results prove that the entire traffic network can achieve balance in the end and provide the optimal routing selection.The paper integrates dynamic traffic with routing choices for EVs.In [9], EVs are assumed to have a significant amount of charging demand.To obtain a minimumcost path, a dynamic program method is applied to develop the model, which is solved by two algorithms.Reference [10] regards energy consumption as the link cost and applies the classic Dijkstra algorithm to obtain the shortest path in a large network.Because the recuperate energy of EVs during the deceleration phases or travel downhill produces link costs less than zero, Johnson potential technology is employed to transform negative energy caused by deceleration or braking.Similarly, [11] also considers energy consumption as the link cost to propose an optimal EV routing model with the least energy consumption.The model is solved by A * algorithm; the results are incorporated into a vehicle navigation system.Considering the uncertain characteristics of traffic time, [12] presents an energy model and uses a combination of robust optimization, A * algorithm, and Lagrangian relaxation to obtain the EV shortest path.Reference [13] considers the reachable range and location problem to give EV aid routes in four cases.In [14], the shortest path problem with a different number of battery recharge stations for EVs is explored.
In contrast to these previous papers, this paper primarily considers distribution features, EV features, and dynamic traffic environment to investigate the EVRP.Detailed descriptions are as follows.
(1) As one of the major obstacles in EV development, the limited range must be considered.An effective route must satisfy the condition that the vehicle has adequate range to arrive at each node.Range anxiety, which causes the drivers to fear that the battery power will be depleted before the vehicle reaches the node, attaches significance to the range constraint.From the perspective of the limited range, the problem is an extension of the distance-constrained VRP (DCVRP) that is proposed by [15].The DCVRP requires that the total distance travelled by the vehicle is less than or equal to the maximum possible distance.Different advanced algorithms exist to solve the DCVRP models that are developed by different objective functions.For example, [16] considers two possible objective functions (total distance and the number of vehicles) to model the DCVRP and analyzes the relationship between two obtained optimal solutions.Reference [17] solves the DCVRP based on two approximation algorithms.Reference [18] uses the improved branch-and-bound method in the DCVRP and achieves suitable performance for large instances (maximum of 1000 customers).
(2) Charging demand is a unique characteristic for EVs so as to be worthy of consideration.The distribution area in a large urban city is relatively large.When the range cannot satisfy the distance demand of completing the trip, the vehicle needs to be recharged at charging stations in transit.Due to the time lost during recharging, the route may make some changes.Therefore, the two subproblems (how the charging stations are assigned and when the vehicles recharge) will be addressed.An optimal charging plan constitutes a part of the results.
(3) One of the ideas in the paper is the dynamic traffic environment.The majority of the previous EVRP research focuses on the static traffic environment, in which travel time is regarded as a constant factor.However, in a real road network, the traffic environment is dynamic in real time.If the results from the model with the static traffic environment are applied to a real road network, some circumstances, such as excess cost, serve delay, vehicle accidents, unsuitable charging stations, and nonoptimal paths, may be attributed to the large difference.To avoid unnecessary losses and consumptions, this paper concentrates on the dynamic traffic environment and considers travel time as a variable factor.The fluctuations in travel time can be implemented to well reflect the dynamic traffic environment in the developed model and results.The EVRP with variable travel time is not studied at present.However, the VRP with variable travel time has been investigated since 1990.The VRP with variable travel time is generally referred to as a dynamic network VRP or time-dependent VRP (TD-VRP).In the early period, numerous papers (refer to [19][20][21][22][23][24]) attempt to connect the dynamic features of traffic with the VRP and present the related models.However, a major weakness of these papers is that the proposed models cannot satisfy the first-in-first-out (FIFO) property.Considering that the travel time between two nodes is dependent on the travel speed, which is divided into many cases in one day, [25] proposes the TD-VRP model, which is verified to conform with the FIFO property.With the rapid development of intelligent transportation systems (ITSs), massive data can be collected and processed in real time.Some papers (refer to [26][27][28][29][30]) develop the subsequent models.
(4) Vehicle capacity is a basic consideration in the VRP or variants.
(5) There is a strict requirement for time window so that all customers can be served in time.The charging time in transit influences the time window.In this paper, a soft time window, which has a certain penalty cost due to early or late arrivals by customers, is considered.(6) The costs are even more significant from the viewpoint of logistics companies.Therefore, the objective of the model is to minimize the total costs, including travel cost, charging cost, penalty cost, and vehicle fixed cost.
Based on these above considerations, the paper presents an electric vehicle routing problem with charging time and variable travel time (EVRP-CTVTT) to fulfil customer demands, ensure operation safety, and reduce costs.This paper is organized as follows: Section 2 describes the problem and introduces charging time, travel time calculation, and dynamic Dijkstra algorithm.The model is formulated as a mixed-integer linear program in Section 3. Section 4 briefly introduces solution technology.Section 5 presents experimental data, results, and analysis.Additional conclusions and future research are presented in Section 6.

Problem Description
Assume that there are 20 available logistics EVs to deliver many cargoes from the single depot to the customers.The requirement that all the used vehicles must depart from the depot to perform delivery and return to the depot is applied.During mid-tour, these vehicles are not allowed to return to the depot.To prevent the depletion of the whole battery power, EVs with the insufficient battery power can be recharged at charging stations many times in transit.
An optimal vehicle operation scheme which includes the routes, the vehicle departure time at the depot, the charging plan, and the shortest paths is obtained to fulfil customer demand, ensure operation safety, and reduce costs.The routes and the vehicle departure time at the depot answer the following two questions: how customers are visited and when the used vehicles depart from the depot, respectively.The charging plan is to solve the problem of how and when the used vehicles with charging demand are recharged.The shortest paths are to guide the vehicles how to drive in a large road network.
Similarly, the vehicle on route 2 leaves the depot at 15:10 and is recharged at node C5.On route 3, the vehicle has the sufficient battery power for the entire trip so as to not have need of travelling to any charging station.Because the entire road network including massive intersection information is not given in Figure 1, the shortest paths are not constructed.A realistic study case and the corresponding complete results are presented in Section 5.
The EVRP-CTVTT model has two main considerations: charging demand and dynamic traffic environment.Therefore, we carefully introduce these two in Sections 2.1 and 2.2.In addition, a dynamic Dijkstra algorithm introduced in Section 2.3 is proposed to solve the shortest path problem.

Charging Demand. In general, the logistics company with
EVs has charging spots at the depot.EVs can be charged during idle periods (e.g., night time).So when leaving depot, EVs have the full battery power.However, sometimes the trips are too long so that EVs have insufficient battery power to complete the entire trips in transit.Then EVs can go to the public charging stations which provide a better choice for the running EVs to replenish the battery power.According to the Society of Automotive Engineers (SAE), three charging levels exist, as listed in Table 1.Level 1 is suitable for overnight at home and workplace.Level 2 facilities are typically installed at private and public facilities.Level 3, which is also referred to as fast charging, is high-voltage and high-current charging implementation.
Currently, the majority of the public charging stations in Beijing provide fast charging, which can rapidly complete the charging process in 1 h.The real recharged battery power is not considered; that is, regardless of the battery power when an EV arrives at a charging station, the charging time is regarded as a constant value (assume 30 min).When recharging is undertaken, the batteries are filled to capacity.In addition, the queue is not considered; that is, EVs are certainly recharged whenever possible.

Dynamic Traffic Environment.
The complexity traffic conditions may spend more travel time so that there is an impediment on customer serve timeliness and vehicle accessibility.The implementation, such as fluctuations in travel time, is an efficient method for reflecting the dynamic traffic environment in a real road network.Therefore, the variable travel time is introduced to restore the real driving environment of EVs.The effective and comprehensive calculation of the travel time is significant.
The travel time calculation proposed by Ichoua 2003 [25], where the adjustment of the travel speed is considered and the FIFO property is certified is applied in this paper.One day is subdivided into many time periods.The travel speed is not assumed to be constant and changes when a vehicle crosses the boundary between two consecutive time periods.The acceleration time or deceleration time determined by the two different travel speeds in the boundary is short and should be disregarded.In other words, the changing travel speed is considered to be a step function (refer to Figure 2).The travel time is the sum of the travel time and different traffic speeds.
For example, there are many time periods   ,  = 1, 2, . . ., .A vehicle leaves the starting node of link  at time period   and travels at the traffic speed V    until the vehicle arrives at the node located at the boundary   and  +1 .The vehicle travels at the traffic speed V  +1  until the vehicle arrives at the node located at the boundary  +1 and  +2 .Finally, the vehicle arrives at the end node of link  at time period   .Figure 3 shows the travel distance and the travel time of the vehicle travelling over link .Based on the process, the travel time from node  to node  is where     is the travel distance of the vehicle that travels over link  at time period   and   is the length of link .

Dynamic Dijkstra Algorithm.
There are massive intersections in a real road network.It is unrealistic that the vehicles drive by the straight line between two nodes.Therefore, how to find out the shortest paths between two any adjacent nodes along the routes is a problem in the EVRP-CTVTT model.The routes, the vehicle departure time at the depot, and the charging plan are obtained from the EVRP-CTVTT model which is present in Section 3. The shortest path (SP) problem in this paper is addressed alone and its solution is used in the EVRP-CTVTT model.SP is to obtain a path with minimal cost in a directed and complete graph.The most common method of solving SP is the classical Dijkstra algorithm [31] which is a method to fix a single node as the source node, obtain the shortest paths from the source to all other nodes in the graph, and produce a shortest path tree.In the classical Dijkstra algorithm, link weight is always regarded as distance (constant value).
However, when travelling in the multivariate traffic conditions, the vehicles spend more time.The majority of the drivers are more concerned with time instead of distance.Therefore, travel time instead of distance is considered as link weight.Due to the dynamic traffic, the travel time of each link is not always constant and changes in real time.Then, the link weight is caused to be dynamic.To solve the SP with variable travel time, we refer to the construction and theory of the classical Dijkstra algorithm and make some improvements over the classical Dijkstra algorithm to propose a dynamic Dijkstra algorithm, where the travel time between any two nodes in the graph needs to be again computed so that the link weight is updated in real time when one node chooses the next connected node.According to the travel time calculation in Section 2.2, the time period of the vehicle arriving at the starting node of the current link must be known.However, there may be several upstream links for the current link.When the current link is transferred from different upstream links, there is different arrival time at the starting node of the current link.So the time period of the vehicle arriving at the starting node of the current link must be on-line recorded in combination with the time periods of the current link to compute the travel time of the current link.
Based on the ideas of the dynamic Dijkstra algorithm, the pseudocode of the dynamic Dijkstra algorithm (Pseudocode 1) is described as follows: graph is the road network;  is the origin;  is the destination;  is the sequence of the shortest path from  to ; cost(, V) represents the link weight of link (, V).The vehicle arrives at node  at time [].

Model Formulation
Based on the problem description and considerations, the EVRP-CTVTT model is formulated as the following mixedinteger linear program.The involved variables in the model are defined as follows: where Subject to Equation ( 3) minimizes the total costs, which consist of the vehicle fixed cost, the travel cost, the penalty cost, and the charging cost.In (4), the used vehicles spend the vehicle fixed cost.The travel cost shown in ( 5) is proportional to the travel time.Equation ( 6) describes the expense to use charging stations.Because the customers may be served early or late, the penalty cost is charged in (7).
Equations ( 8) and ( 9) ensure that each customer is visited by only one vehicle.Equation (10) presents the flow conservation, in which the number of arrivals must equal the number of departures at any customer or charging station.Equations ( 11) and ( 12) require all the vehicles to leave from the start depot and return to the end depot.Because only one depot exists, the start depot and the end depot are located at the same node ( =   ).No running vehicles pass any node, with the exception of the start depot and the end depot.
Equation ( 13) is the expression of the residual range.The vehicle drives based on the shortest path solved in Section 2.3.The range constraint that the residual range of any vehicle at any node must be larger than zero is proposed in (14).Equation (15) states that each vehicle has 100% charge when leaving the start depot.
Equation (16) states that the vehicles deliver many loads to the customers.Equation (17) ensures that the loading weight of each vehicle does not exceed the vehicle load capacity.In (18), the vehicle departure time at the current node equals the sum of the vehicle departure time at the last node, the travel time between the last node and the current node, and the charging time.The travel time is obtained by the travel time calculation ((1)-( 2)).Equations ( 19)- (20) ensure that all the vehicles perform delivery within the vehicle operation time period.
Equation ( 21) requires all the vehicles to only visit the charging stations to be recharged.Equations ( 22) and (23) ensure that   and   are 0-1 decision variables.

Model Solution Technology
The VRPs and variants are an NP-hard problem.The heuristic algorithms can achieve better performance in computation time and solution quality for the VRPs and variants.As one of the heuristic algorithms, genetic algorithm (GA) is easy to program and has faster computation time.Moreover, the GA has been widely applied in the complex VRPs or variants implemented especially in large and realistic road networks and can obtain acceptable better solution.Therefore, considering the complexity of the proposed model and the road network, the GA is regarded as the model solution technology in the paper.
In the GA, a set number of individuals with genes are processed by selection and multiplication operators to produce new individuals.The individuals with better fitness will obtain more opportunities to survive.To achieve variety among the individuals, crossover and mutation are applied in the GA procedure.The procedure of the GA is shown as follows.
Step 1. Apply encoded mode to produce initial population () (|()| = ); then  = 0. Step 4. Every two individuals in 1() form a pair to be applied in a crossover.Each individual is required to satisfy all constraints.If not, the pair is in vain; run the crossover again.1() is updated.
Step 5.Each individual in 1() is applied in a mutation.Each individual is required to satisfy all constraints.If not, the individual is in vain; run the mutation again.1() is updated.
Step 6. 1() and the elite individuals are combined to form a new population (), where  =  + 1.
Step 7. If  < , return to Step 3. Otherwise, stop running and output the individual with the highest fitness value in ().
Step 8. Decode the individual to achieve the optimal solution.
The GA parameters (number of individuals, number of generations, number of elite individuals, crossover rate, and mutation rate) may have an impact on the solution values.The three parameters (number of individuals, number of generations, and number of elite individuals) are determined by many experiments with different parameters.And the two parameters (crossover rate and mutation rate) are chosen in their reasonable values ranges.All parameters in the GA are listed in Table 2.
The two decision variables   (routes) and   (charging plan) can be obtained from the individual.The encoded mode in which the decision variables are expressed by the individual is the premise of the GA.We adopt the mode where the individual includes all visited nodes.For example, there are one depot,  customers,  charging stations, and  vehicles.The procedure of the encoded mode is as follows: (1) The serial numbers of  customers and  charging stations are successively arranged as 1, . . ., ,  + 1, . . ., .
(2) After it is disordered, the string of numbers is defined as .(3) Sequentially define the serial numbers as  + 1,  + 2, . . .,  + 2 at the start depots and the end depots.
(4) The first position and last position of  are inserted by the numbers  + 1 and  + 2, respectively.
The inserted  forms one individual.The individual is divided into many segments by the numbers from  + 1 to  + 2.Each segment can be converted to one route.However, some routes are considered ineffective because they do not visit any customers.
A simple example is shown in Figure 4 to explain the encoded mode.Three vehicles, one charging station, and nine customers are available.Based on the procedure of the encoded mode, an individual is formed.Some findings can be achieved by decoding the individual: route 1 visits customers 5, 2, and 1; route 2 is ineffective; route 3 visits customers 4, 9, 6, 3, 7, and 8; and route 3 is recharged prior to returning to the depot.
In addition to the two decision variables (  and   ), the remaining decision variable   indicates that the vehicle departure time at the depot is solved alone.The paper applies exhaustive method.The set of the available departure times is composed of the time at ten minute intervals between the earliest operation time and the latest operation time (e.g., 06:00, 06:10,. ..,20:50, 21:00).Each effective route orderly matches with one available departure time to compute the object value.For the minimal object value, the available departure time is considered as the vehicle departure time at the depot.

Large Realistic Case Study
A large and realistic case study is conducted to reflect the performance of the proposed model and the solution technology.All experiments were run on a desktop with an Intel Core i5-5200U CPU, 16 GB of RAM, and a 64bit operating system.Several types of experimental data are determined as follows.

Experimental Data
5.1.1.Road Network.The models are applied to a discrete representation of a large and realistic road network in the Beijing urban area (within the fifth ring).The entire road network of the Beijing urban area is too complex to be simplified.Considering travel speed data source, model complexity, and solution effectiveness, the paper primarily selects all expressways and the majority of arterial roads to construct a large and realistic road network.After creation, the road network is composed of 222 nodes and 943 links.The nodes and links represent the road intersections and road segments, respectively.

Facilities Data.
Three types of facilities exist: depot, customer, and charging station.Only one depot is located at the centre of the road network.The locations of 50 customers which will be served next day and 20 charging stations are randomly distributed at nodes of the road network.The freight weight is randomly assigned to each customer from eight weight grades (10 kg, 20 kg, 30 kg, 40 kg, 50 kg, 60 kg, 70 kg, and 80 kg).Similarly, the time window of each customer is also randomly produced every hour between 8:00 and 19:00.Figure 5 presents the comprehensive road network loading facilities data.

Travel Speed Data.
To calculate the travel time in the EVRP-CTVTT model, the travel speed must be determined.The microwave sensor installed on a section of an expressway collected the traffic speed data every 2 min on one day.Because the travel speed data is from the reality and the collection interval is very short (2 min), the real traffic environment can be effectively restored.Figure 6 shows the travel speed data during the vehicle operation time period.

Constant Variable Value Determination.
Currently, EVs for logistics in Beijing are primarily electric vans manufactured by the Beijing Motor Company.According to the logistics EV technology specification, the vehicle load capacity and the maximum driving range are 1000 kg and 120 km, respectively.The per-unit vehicle fixed cost   considers driver wage, upkeep, vehicle idle cost, and vehicle insurance cost.The per-unit travel cost   is based on time utilization and operation efficiency.According to the advices from the logistics company, we set the two parameters to 100 yuan and 1 yuan/min, respectively.The per-unit charging cost   is determined by the electricity prices and charging service fee.In Beijing, the average industrial electricity price is 0.8 yuan/kWh [32].At present, no unified standard approach is available for the charging service fee.For convenient calculations, the per-unit charging cost is valued to be 30 yuan: 21.6 yuan (cost with 100% charge) plus 8.4 yuan (charging service fee).The charging time   is set to 30 min according to Section 2.1.The constant variables are summarized in Table 3.

Results and Analysis.
Based on the foregoing experimental data, the EVRP-CTVTT model is solved by the GA.ten times.The computational time the algorithm takes in each experiment is not very different.The average computational time is about 3 h.Consider that the model and the realistic road network are overly complex.In addition, the result is obtained the day before the result is performed in reality.Therefore, the computational time the algorithm takes is acceptable.The model object (optimal object value) is regarded as the experimental index to be compared.The experiment with the least optimal object value will be analyzed in details.The compared result in Table 4 indicates that Experiment 1 has the best solution performance.
The algorithm iteration process of Experiment 1 (Figure 7) shows that the GA can quickly guarantee convergence and improve computational effort.Moreover, the results, including the routes, the vehicle departure times at the depot, and the charging plan, are presented as follows.The vehicle running information including vehicle departure time, travel distance, and order of the visited nodes is shown in Table 5.Table 6 summarizes all the details costs.
As requested, seven vehicles are dispatched.The travel distance of route 1 exceeds the maximum driving range (120 km).Due to the limited range, the vehicle on route 1 is required to be recharged at charging station 2 in transit.Moreover, the charging time delays the time for serving customers and produces a larger penalty cost for route 1.
As the most important factor to influence the routes and charging plan, the residual range of each vehicle arriving at any visited node needs to be analyzed in detail (refer to Figure 8).It indicates that the obtained optimal solution satisfies the range constraint that the residual range of a vehicle at any visited node must exceed zero.For route 1, because the vehicle is fully recharged at charging station 2, the residual range for customer 22 which is the first visited node after the vehicle is recharged distinctly increases.
Besides the routes, the vehicle departure times at the depot, and the charging plan, the results about the shortest path problem must be present.We also depict the shortest paths along the routes in the road network.According to Figure 9, the running track of each route can be clearly shown.The corresponding vehicles visit the customers or charging stations in an orderly manner.

Conclusions
At present, the increasing EVs are employed in different transport areas such as logistics.To better address the problem of how the vehicle operation scheme is planned when EVs are regarded as the transport mode to visit the  customers in a real road network, this paper comprehensively considers the distribution features (time window and weight constraint), the EV characteristics (limited range and charging demand), and the dynamic traffic environment to develop the EVRP-CTVTT model with the minimal total costs.An optimal vehicle operation scheme, which simultaneously consisted of the routes, the vehicle departure time at the depot, the charging plan, and the shortest paths, is achieved.Due to the limited range, EVs are sometimes recharged at charging stations many times while in transit to ensure that the trip is completed.The best method for optimally assigning charging stations for EVs with charging demand is also discussed in the paper.
In reality, traffic is constantly changing.Different from the majority of the related papers, this paper focuses on the dynamic traffic environment.To implement the dynamicity of traffic, the fluctuations in travel time are introduced in the developing model.The changing travel speed every 2 min for one day is applied to compute the travel time.Based on the changing travel speed, a dynamic Dijkstra algorithm making some improvements over the classic Dijkstra algorithm is proposed to solve the shortest path between any two adjacent nodes along the routes.
A large and realistic case study with the road network in the Beijing urban area, with 50 customers and 20 charging stations, is presented.The GA is applied to solve the EVRP-CTVTT model and obtain several results, including the routes, the vehicle departure time at the depot, and the charging plan.The results indicate that the GA yields acceptable performance on computational time, convergence, and solution quality.
From the results, we conclude that the EVRP-CTVTT model and dynamic Dijkstra algorithm completely satisfy customer demand while reducing cost, preventing depletion of all battery power while in transit, and ensuring safe operation.In addition, the results provide an optimal vehicle scheme for the logistics company with EV operation.
Although the paper first considers charging time and variable travel time to solve the EVRP, several aspects remain unaddressed: (i) Even if we apply the real traffic speed data, sometimes there is randomness in the travel speed because of several traffic accidents.Therefore, the more complex expressions of the travel speed will be focused on.
(ii) The charging station locations, which may impact the charging plan, are fixed.The related research association route problem and location problem will be investigated in the future.
(iii) The optimal solution is extremely influenced by the per-unit cost parameters.This paper directly provides values based on operation experience.Our future work will include a sensitivity analysis for these parameters.

Figure 1 :
Figure 1: An example of a simple operation scheme.
is defined: insert  at the beginning of   ← V[] End while insert  at the beginning of  Pseudocode 1: Pseudocode of dynamic Dijkstra algorithm.

𝐶 0 :
total costs (yuan)   : fixed vehicle cost of vehicle  (yuan)   : travel time cost of vehicle  (yuan)   : charging cost of vehicle  (yuan)   : penalty cost of vehicle  (yuan)   : per-unit fixed vehicle cost (yuan/one vehicle)   : per-unit travel time cost (yuan/min)   : per-unit charging cost (yuan/one time)   : per-unit early arrival penalty cost (yuan/min)   : per-unit delay arrival penalty cost (yuan/min) : a set of charging stations : start depot   : end depot : a set of customers :  ∪  ∪  ∪   : a set of the available vehicles   : residual range of vehicle  at node  (km)   : travel distance of the shortest path from node  to node  (km)  max : maximum driving range (km)   : loading weight of vehicle  departing from start depot (kg)   : freight weight of node  (kg)  max : vehicle load capacity (kg)   : travel time of vehicle  travelling from node  to node  (min)   : departure time of vehicle  at node   early  : earliest vehicle operation time  delay   : latest vehicle operation time  early  : earliest arrival time at node   delay  : latest arrival time at node    : charging time (min)   : whether there is a charging station at node , {1,  ∈ ; 0, else} Mathematical Problems in Engineering Decision Variables   : {1, vehicle  travels from node  to node ; 0, otherwise}   : {1, vehicle  is recharged at node ; 0, otherwise}   : departure time of vehicle  at the depot The model formulation is shown as follows:

Figure 4 :
Figure 4: A simple example of the encoded mode (black, red, and green numbers represent depot, customer, and charging station, resp.).

Figure 5 :
Figure 5: Comprehensive road network loading facilities data (the number represents the serial number of customer or charging station).

Figure 9 :
Figure 9: The shortest paths along the routes.

Table 2 :
Algorithm parameter values.Step 2. Compute fitness for each individual in ().

Table 4 :
Optimal object values of ten experiments.

Table 5 :
Vehicle running information.

Table 6 :
All the details costs.