A method and device for path planning of vehicles with different types and multiple cabins based on multi-strategy iterative local search
By optimizing the routing of multi-cabin vehicles with different vehicle types through a multi-strategy iterative local search method, the problems of difficult initial solution generation and low quality were solved, achieving efficient and stable route optimization and vehicle type allocation, thereby improving transportation efficiency and cost-effectiveness.
Patent Information
- Application Number
- CN202411933796.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-25
- Publication Date
- 2025-10-28
- Estimated Expiration
- 2044-12-25
AI Technical Summary
Existing algorithms struggle to generate initial solutions and produce poor-quality solutions when solving the routing problem for multi-compartment vehicles of different models, especially when dealing with large-scale problems.
A multi-strategy iterative local search approach is adopted, including the cheapest insertion method, the load adjustment strategy LAS, local search, fixed random number perturbation, and the vehicle type optimization strategy VOS. By optimizing path planning through multiple strategies, a high-quality global optimal solution is generated.
It improves the quality of initial solution generation and optimization efficiency, ensures the flexibility and stability of route planning, avoids getting trapped in local optima, optimizes vehicle type allocation, and improves transportation efficiency and cost-effectiveness.
Smart Images

Figure CN119721389B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of vehicle routing technology, and in particular to a method and apparatus for routing multi-cabin vehicles of different models based on multi-strategy iterative local search. Background Technology
[0002] In recent years, with the continuous development of logistics and the increasing complexity of modern supply chains in China, people's demands for the diversity of transported goods, and even the entire transportation industry, are constantly rising. The use of traditional, single-compartment transport vehicles is gradually failing to meet the growing and diversified needs of various industries. If ordinary single-compartment vehicles are still used for delivery, only one type of item can be transported at a time, severely impacting transportation efficiency and costs. Therefore, the widespread use of multi-compartment vehicles of various models in the transportation industry can significantly improve the flexibility and efficiency of the transportation process, reduce the risks associated with mixing different goods, enhance transportation safety, and optimize high transportation costs.
[0003] The Multi-Compartment Vehicle Routing Problem (MCVRP) is an NP-hard problem and a variant of the Vehicle Routing Problem (VRP). Unlike traditional VRP where each vehicle can only deliver one type of goods, in the MCVRP, each vehicle has multiple independent compartments and can simultaneously deliver multiple mutually exclusive goods to achieve efficiency, timeliness, and economy. The Multi-Compartment Vehicle Routing Problem with Different Vehicle Models adds the attribute of different vehicle models to the MCVRP problem, combining the two for research. Traditional solutions to the Multi-Compartment Vehicle Routing Problem with Different Vehicle Models often have limitations: for example, while exact algorithms perform well for small-scale problems, the MCVRP problem is NP-hard, and the introduction of multiple vehicle models makes the solution more complex. Therefore, for large-scale problems, using exact algorithms is not only ineffective but also lacks time efficiency. Therefore, expanding the research attributes of the Multi-Compartment Vehicle Routing Problem with Different Vehicle Models, constructing a problem model, and designing efficient and high-quality algorithms become particularly important.
[0004] Iterative Local Search (ITS) is a metaheuristic optimization algorithm that aims to find better solutions by repeatedly applying local searches and escaping local optima. ITS not only avoids getting trapped in local optima through perturbations but also boasts high efficiency in solving problems. Combined with flexible multi-strategy adjustments and wide applicability, ITS offers advantages in handling multi-vehicle, multi-cabin route planning problems. Summary of the Invention
[0005] This invention addresses the problems of existing algorithms in generating initial solutions and achieving poor solution quality when solving the multi-compartment vehicle routing problem of different vehicle models. It proposes a method and apparatus for multi-compartment vehicle routing based on multi-strategy iterative local search.
[0006] On one hand, the present invention provides a method for multi-cabin vehicle path planning of different vehicle models based on multi-strategy iterative local search, including:
[0007] Step 1: Obtain vehicle information and node information, and establish a path cost minimization formula; the node information includes customer nodes and depot nodes; the vehicle information includes vehicle model information and the total number of all vehicle models.
[0008] Step 2: Based on the vehicle and node information, use the cheapest insertion method to obtain the initial path solution C_sol. The cheapest insertion method refers to first generating a first part of the path based on the customer nodes with the largest demand, removing these nodes from the node information, and then randomly selecting some customer nodes from the remaining node information to generate a second part of the path. The first part of the path and the second part of the path form the initial path, and the remaining customer nodes are inserted into the initial path to obtain the initial solution. The number of initial paths is equal to the total number of all vehicle models.
[0009] Step 3: Improve and optimize the initial solution C_sol using the loading adjustment strategy LAS, and output the improved solution a; the loading adjustment strategy LAS is used to improve the loading rate of smaller vehicle types on the path and optimize the loading space of larger vehicle types;
[0010] Step 4: Adjust the improved solution a using a local search strategy to obtain the best solution B_sol;
[0011] Step 5: Based on the best solution B_sol, adjust it by perturbing with a fixed number of random numbers to obtain a new best solution;
[0012] Step 6: Based on the above best solution B_sol and the new best solution, calculate the path load percentage variance and path cost. If the path load percentage variance and path cost meet the preset acceptance strategy, then accept the new best solution and execute Step 7; otherwise, return to Step 4 and repeat the execution.
[0013] Step 7: Determine if the iteration stopping condition is met. If the iteration stopping condition is met, proceed to step 8; otherwise, return to step 4 and repeat the process.
[0014] Step 8: Optimize the new best solution using the vehicle type optimization strategy (VOS) to obtain the global optimal solution A_sol; the vehicle type optimization strategy (VOS) is used to optimize the relationship between the path load and the maximum capacity of the corresponding vehicle type in the new best solution.
[0015] Furthermore, in step 1,
[0016] The path cost minimization formula is:
[0017]
[0018] Where F represents the path cost of the corresponding solution; V represents node information; M represents the set of vehicle types used, M = {1, 2, ..., m}; x ijm Let x represent a binary decision variable. ijm =1 indicates that there exists a vehicle of type m traveling from node i to node j; otherwise, x = 1. ijm =0; d ij c represents the path distance from node i to node j; m This represents the unit transportation cost for vehicle model m.
[0019] Furthermore, step 1 also includes setting the required parameters, which include setting the maximum number of iterations T, the neighborhood size NR, the perturbation parameter S, the number of perturbations NP, and the number of times the acceptance strategy has no boost C.
[0020] Furthermore, in step 2, obtaining the initial solution C_sol of the path using the cheapest insertion method specifically includes:
[0021] The total number N of all car models in the vehicle model set is counted, and then selected sequentially from the node information set V according to the demand. Each customer node generates The first part of the path is selected, and the customer nodes in this part are removed from the set V of node information; then, the remaining customer nodes in the set V are randomly selected. Each customer node generates There are N initial paths, which are the second part of the path. The customer nodes of this part are removed from the set of node information V. A total of N initial paths are generated, and the vehicle models with the maximum loading capacity exceeding the current demand are assigned to the initial paths. Based on the N initial paths, under the constraint of satisfying the maximum capacity, the remaining customer nodes in the set of node information V are inserted into the vehicle that minimizes the path cost. If there are customer nodes that cannot be inserted into the initial path, the solution is abandoned and a new initial solution is generated.
[0022] Furthermore, in step 3, the loading adjustment strategy LAS specifically includes:
[0023] Obtain the set M = {1, 2, ..., m} of all vehicle types used in the current solution. Then, iterate through all non-minimum vehicle types in descending order to obtain the set Fr = {R1, R2, ..., Rn} of all paths using vehicle type r. i}, where r∈M and r≠1; let the current vehicle model be r=m;
[0024] For each path Ri in Fr, traverse the customer nodes on its path, and insert the customer nodes into the path using a smaller vehicle type t, where t < r, without violating the capacity limit and without increasing the total path cost;
[0025] After all paths in Fr have been traversed, traverse the next vehicle type r - 1; determine whether r - 1 is greater than 1. If so, continue to traverse vehicle type r - 1; otherwise, end the adjustment; set the iteration count T to 1 and the non - improvement count C to 0.
[0026] Further, in step 5, the fixed - random - number perturbation specifically includes:
[0027] Each time of perturbation, randomly select one path from N paths, randomly select a customer node in the selected path as a reference, remove b customer nodes within its neighborhood range NR, and temporarily store them in an array;
[0028] Insert the customer nodes temporarily stored in the array into the path in a random order;
[0029] Determine whether the path cost of the new solution obtained after the current perturbation is less than that of the best solution before the current perturbation. If it is less, use the new solution as the new best solution for the next perturbation; otherwise, use the best solution before the current perturbation for the next perturbation;
[0030] Until the perturbation count NP reaches the preset count, end the perturbation and output the finally obtained new best solution.
[0031] Further, in step 6, the calculation expression for the variance of the path loading percentage is:
[0032]
[0033] where n represents the number of paths corresponding to the solution x, n ≤ N; P i represents the loading rate of the vehicle corresponding to path R i The loading rate is the ratio of the load on the vehicle corresponding to path R i to the maximum capacity of this vehicle type, and Z represents the average loading rate of all vehicles on all paths P1, P2... P n
[0034] Further, in step 6, the preset acceptance strategy is defined as:
[0035]
[0036] where S c represents the best solution B_sol, S n represents the new best solution, F(x) represents the path cost, and f(x) represents the variance of the path loading percentage;
[0037] If the new best solution has a lower path cost, then accept the new best solution, increment the iteration count T by 1, and reset the number of times the strategy has no improvement, C, to 0. If the path cost of the new best solution remains unchanged or increases, but its path load percentage variance decreases, then also accept the new best solution, increment the iteration count T by 1, and reset the number of times the strategy has no improvement, C, to 0. Otherwise, do not accept the new best solution, and increment the number of times the strategy has no improvement, C, by 1.
[0038] Correspondingly, in step 7, the iteration stopping condition includes determining whether the iteration number T and the number of no-boosts C have both reached the preset value. If they have, then proceed to step 8; otherwise, return to step 4 and repeat the process.
[0039] Furthermore, in step 8, the vehicle model optimization strategy (VOS) specifically includes:
[0040] Obtain the set of vehicle types M = {1, 2, ..., m} used by the current best solution, and traverse from vehicle type 1 to vehicle type m in ascending order; set the current vehicle type as i, and obtain the set of paths f that use vehicle type i. i ={R1,R2,...,R i} and the set F of all paths whose loading capacity does not exceed the maximum capacity of vehicle model i. I ={R1,R2,...,R I};
[0041] When the number of paths corresponding to vehicle model i is less than the number of paths whose loading capacity does not exceed the maximum capacity of vehicle model i, for set F I Path R1 to Path R I Sort the paths in descending order according to their path length, and then assign vehicle type i to each path in order. After assigning vehicle type i, move on to the next vehicle type i+1. Check if i is less than or equal to m. If so, continue to traverse the next vehicle type i+1. Otherwise, end the adjustment.
[0042] On the other hand, the present invention provides a multi-strategy iterative local search-based path planning device for multi-cabin vehicles of different models, comprising:
[0043] Data acquisition module: used to acquire vehicle information and node information, and establish a path cost minimization formula. The node information includes customer nodes and depot nodes; the vehicle information includes vehicle model information and the total number of all vehicle models.
[0044] Initial Result Module: This module is used to obtain the initial path solution C_sol based on vehicle and node information using the cheapest insertion method. The cheapest insertion method involves first generating a first part of the path based on customer nodes with high demand, removing these nodes from the node information, and then randomly selecting some customer nodes from the remaining node information to generate a second part of the path. The first and second parts of the path form the initial path, and the remaining customer nodes are inserted into the initial path to obtain the initial solution. The number of initial paths is equal to the total number of all vehicle models.
[0045] Loading Adjustment Module: Used to improve and optimize the initial solution C_sol through the loading adjustment strategy LAS, and output the improved solution a; the loading adjustment strategy LAS is used to improve the loading rate of smaller vehicle types on the path and optimize the loading space of larger vehicle types;
[0046] Local search module: used to adjust the improved solution a using a local search strategy to obtain the best solution B_sol;
[0047] Perturbation module: Used to adjust the solution based on the best solution B_sol by perturbing it with a fixed number of random numbers to obtain a new best solution;
[0048] The first judgment module is used to calculate the variance of the path load percentage and the path cost based on the best solution B_sol and the new best solution. If the variance of the path load percentage and the path cost meet the preset acceptance strategy, the new best solution is accepted and the process proceeds to the second judgment module; otherwise, the process returns to the local search module and repeats the operation.
[0049] The second judgment module is used to determine whether the iteration stop condition is met. If the iteration stop condition is met, the module will enter the vehicle model optimization module; otherwise, the module will return to the local search module to repeat the operation.
[0050] Vehicle Model Optimization Module: This module is used to optimize the new best solution using the Vehicle Model Optimization Strategy (VOS) to obtain the globally optimal solution A_sol. The Vehicle Model Optimization Strategy (VOS) is used to optimize the relationship between the path load and the maximum capacity of the corresponding vehicle model in the new best solution.
[0051] Compared with existing technologies, the present invention has the following advantages:
[0052] (1) The multi-strategy iterative local search method for multi-cabin vehicle routing based on different vehicle models provided by this invention constructs an initial solution using an initial solution construction method based on the lowest cost insertion method. This paper ensures the feasibility of generating a solution by prioritizing a certain number of customer points with high demand, and further guarantees the quality of the solution by selecting the position with the lowest insertion cost when inserting nodes, thus solving the problems of difficulty in generating initial solutions and low quality.
[0053] (2) In the process of adjusting the initial solution, this invention designs a variety of strategies. Among them, the loading adjustment strategy is designed to adjust the loading of different vehicle types between paths, thereby increasing the loading of smaller vehicle types to create more optimization space for larger vehicle types, with the aim of providing more optimization possibilities for local search. In order to enhance the stability of the solution and avoid the solution from getting trapped in local optima, this invention designs a path loading percentage variance acceptance strategy. This acceptance strategy tends to accept solutions with better results and more stable loading rates between vehicles based on different acceptance criteria.
[0054] (3) This invention uses a vehicle model optimization strategy to allocate vehicle models in descending order of path length, so that relatively longer paths are assigned to vehicles with lower path costs. By optimizing the final best solution through this strategy, the vehicle model allocation is ensured to be the optimal solution under the current circumstances, thereby improving the quality of vehicle model allocation. Attached Figure Description
[0055] Figure 1 This is a flowchart illustrating a multi-strategy iterative local search method for multi-compartment vehicle routing of different vehicle models, provided for the implementation of this invention. Detailed Implementation
[0056] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of the embodiments of this invention will be clearly described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without creative effort are within the scope of protection of this invention.
[0057] like Figure 1 As shown, this embodiment of the invention provides a method for multi-cabin vehicle path planning of different vehicle models based on multi-strategy iterative local search, including:
[0058] S101: Obtain vehicle information and node information, and establish a path cost minimization formula; the node information includes customer nodes and station nodes; the vehicle information includes vehicle model information and the total number of all vehicle models.
[0059] Specifically, it also includes preset required parameters, which include setting the maximum number of iterations T, the neighborhood size NR, the perturbation parameter S, the number of perturbations NP, and the number of times the acceptance strategy has no boost C.
[0060] Specifically, the path cost minimization formula is:
[0061]
[0062] Where F represents the path cost of the corresponding solution; V represents node information; M represents the set of vehicle types used, M = {1, 2, ..., m}; x ijm Let x represent a binary decision variable. ijm =1 indicates that there exists a vehicle of type m traveling from node i to node j; otherwise, x = 1. ijm =0; d ij c represents the path distance from node i to node j; m This represents the unit transportation cost for vehicle model m.
[0063] S102: Based on vehicle information and node information, use the cheapest insertion method to obtain the initial path solution C_sol; the cheapest insertion method refers to first generating a first part of the path based on the customer nodes with larger demand, removing these nodes from the node information, and then randomly selecting some customer nodes from the remaining node information to generate a second part of the path; the first part of the path and the second part of the path form the initial path, and inserting the other remaining customer nodes into the initial path to obtain the initial solution; the number of the initial paths is equal to the total number of all vehicle models.
[0064] Specifically, the total number N of all models in the model set is counted, and models are selected sequentially from set V according to their demand. Find the customer node with the highest demand and insert it into the path to generate... A 0-i-0 path is generated, and then a random path is selected from V. Each customer node is inserted into the path, generating... There are N 0-i-0 paths. After generating a total of N paths, remove these N nodes from V and assign vehicle models whose maximum loading capacity exceeds the current demand to these paths. Finally, sort the remaining customer nodes in set V in descending order of demand, and use this as the insertion order to insert the remaining nodes into the vehicle with the lowest path cost without violating the maximum capacity constraint. Update the paths and remove nodes from V simultaneously. If a node cannot find a place to insert, it means that a feasible solution has not been generated. In this case, discard the generated path solution and repeat the step to generate new paths until all customer nodes are inserted into the initially generated N paths.
[0065] As can be seen, the embodiments of the present invention generate initial solutions using the lowest-cost insertion method, solving the problems of difficulty and low quality in generating initial solutions for multi-compartment vehicle routing problems with different vehicle models. The lowest-cost insertion method can effectively avoid generating the same initial solution in different experiments, ensuring the diversity of initial solutions.
[0066] S103: The initial solution C_sol is improved and optimized by the loading adjustment strategy LAS, and the improved solution a is output; the loading adjustment strategy LAS is used to improve the loading rate of smaller vehicle types on the path and optimize the loading space of larger vehicle types;
[0067] Specifically, obtain the set \(M = \{1, 2, \ldots, m\}\) of all vehicle types used for the current solution, and traverse all non - minimum vehicle types in descending order; set the current vehicle type as \(r = m\); when traversing any vehicle type \(r\), obtain the set \(F_r=\{R_1, R_2, \ldots, R\}\) of all paths using vehicle type \(r\), where \(r\in M\) and \(r\neq1\). For each path \(R_i\) in \(F_r\), traverse all nodes on its path, and try to insert the nodes into the path belonging to a smaller vehicle type \(t(t < r)\) without violating the capacity limit and without increasing the total path cost. When all paths in \(F_r\) have been traversed, it means that vehicle type \(r\) has been traversed, and it is necessary to switch to the next vehicle type \(r - 1\). Judge whether \(r - 1\) is greater than 1 at this time. If it is, continue to traverse the next vehicle type \(r - 1\), otherwise end the adjustment. After executing the loading volume adjustment strategy, set the iteration number \(T\) to 1 and the non - improvement number \(C\) to 0. i Specifically, through the loading volume adjustment strategy LAS, larger vehicle types have more free loading space, increasing the flexibility of subsequent local search adjustment and providing more possibilities for subsequent operator optimization.
[0068] Specifically, through the loading volume adjustment strategy LAS, larger vehicle types have more free loading space, increasing the flexibility of subsequent local search adjustment and providing more possibilities for subsequent operator optimization.
[0069] S104: Adjust the improved solution \(a\) through the local search strategy to obtain the best solution \(B\_sol\).
[0070] Specifically, during the local search process, four neighborhood operators, namely one - point move, two - point swap, 2 - Opt, and Or - Opt, are used in sequence to find the best solution within the neighborhood, and no terminal nodes are involved in the operations of these four operators.
[0071] Specifically, the specific descriptions of the above local search operators are as follows:
[0072] One - point move: Select a non - terminal node on the path, remove it from its original position, and then select a position on the same path or another path to insert it;
[0073] Two - point swap: Select two non - terminal nodes on the same path or different paths, swap their positions and then insert them;
[0074] 2 - Opt: Select two non - intersecting edges in the path and disconnect them. After disconnection, reverse one of the path segments and then reconnect these paths;
[0075] Or - Opt: Select a path segment of a specified length from the path and move it to another position on the same path or another path.
[0076] S105: Based on the best solution \(B\_sol\), make adjustments through fixed random number perturbations to obtain a new best solution.
[0077] Specifically, the number of perturbations is set to NP. During each perturbation, a random node in the random path is selected, and using this node as a reference, b customer nodes within its neighborhood range NR are removed. The number of customer nodes removed, b, is determined by the perturbation parameter S and the total number of customer nodes. The b removed customer nodes are temporarily stored in an array. Subsequently, the b customer nodes temporarily stored in the array are inserted into the path in a random order.
[0078] Determine whether the path cost of the new solution obtained after the current perturbation is reduced compared with the best solution before the current perturbation. If it is reduced, use the new solution as the new best solution for the next perturbation. Otherwise, use the best solution before the current perturbation for the next perturbation. Continue until the number of perturbations NP reaches the preset number, then end the perturbation and output the new best solution obtained.
[0079] Specifically, setting a fixed random number perturbation is to prevent the solution from getting trapped in a local optimum.
[0080] S106: Based on the above best solution B_sol and the new best solution, calculate the path load percentage variance and path cost. If the path load percentage variance and path cost meet the preset acceptance policy, accept the new best solution and execute S107; otherwise, return to S104 and repeat the execution.
[0081] Specifically, the expression for calculating the variance of the path load percentage is as follows:
[0082]
[0083] Where n represents the number of paths corresponding to solution x, n≤N; P i Representing path R i The loading rate corresponding to the vehicle, wherein the loading rate is path R i Z represents the ratio of the load on the corresponding vehicle to the maximum capacity of that vehicle model. n The average load factor of all vehicles.
[0084] The default acceptance strategy is defined as follows:
[0085]
[0086] Among them, S c The best solution is represented by B_sol, S. n Let F(x) represent the new best solution, F(x) represent the path cost, and f(x) represent the variance of the path load percentage.
[0087] In this strategy, if the cost of the new best solution path is better than that of the best solution B_sol, then the new best solution is accepted, the best solution B_sol is updated, the iteration count T is incremented by 1, the number of no-improvement iterations C is reset to zero, and the process jumps to S107. If the cost of the new best solution path is not better than that of the best solution B_sol, but the variance of the path load percentage (i.e., f(x)) is better than that of the best solution B_sol, then the new best solution is still accepted, the best solution B_sol is updated, the iteration count T is incremented by 1, the number of no-improvement iterations C is reset to 0, and the process jumps to S107. If the variance of the new best solution path load percentage is not better than that of the best solution B_sol, then the number of no-improvement iterations C is incremented by 1, and the process jumps to S104 to repeat the process.
[0088] S107: Determine whether the iteration stopping condition is met. If the iteration stopping condition is met, proceed to step 8; otherwise, return to step 4 and repeat the execution.
[0089] Correspondingly, the iteration stopping conditions include determining whether the iteration number T and the number of no-boosts C have both reached the preset values. If they have, then execute S108; otherwise, return to S104 and repeat the execution.
[0090] Specifically, reaching the maximum number of iterations indicates that a sufficient number of iterations have been performed. Reaching the maximum number of iterations without improvement indicates that the potential for improvement in the solution is already limited.
[0091] It is important to note that the vehicle load changes after the random number perturbation adjustment, resulting in a change in the corresponding loading rate and a different variance of the calculated path loading percentage. Calculating the variance of the path loading percentage and using the acceptance strategy are to avoid the obtained solution getting trapped in local optima, while ensuring that the distribution of nodes within the path of the newly obtained solution is more balanced and the loading rate is more stable.
[0092] S108: The new best solution B_sol is optimized by the vehicle type optimization strategy VOS to obtain the global optimal solution A_sol; the vehicle type optimization strategy VOS is used to optimize the relationship between the path load and the maximum capacity of the corresponding vehicle type in the new best solution.
[0093] Specifically, to avoid assigning relatively long paths to higher-cost vehicle types, which could result in a situation where the final solution is the minimum-cost solution, a vehicle type optimization strategy, VOS, is used.
[0094] Specifically, we obtain the set of vehicle types M = {1, 2, ..., m} used by the current best solution, and traverse it from vehicle type 1 to vehicle type m in ascending order. We set the current vehicle type i = 1; then we obtain the set of paths using vehicle type i as f. i ={R1,R2,...,R i Then, obtain the set of all paths whose loading capacity does not exceed the maximum capacity of vehicle model i as F. I ={R1,R2,...,R IWhen the number of paths corresponding to vehicle model i is less than the number of paths whose loading capacity does not exceed the maximum capacity of vehicle model i, for set F... I Based on path length, paths R1 to R... I Sort the data in descending order, and then assign vehicle type i to each part of the path in sequence. After assigning vehicle type i, move on to the next vehicle type i+1. Check if i is less than or equal to m; if so, continue iterating to the next vehicle type i+1; otherwise, end the adjustment.
[0095] Based on the above embodiments, the present invention also provides a multi-car path planning device for different vehicle models and multi-compartment vehicles based on multi-strategy iterative local search, comprising:
[0096] Data acquisition module: used to acquire vehicle information and node information, and establish a path cost minimization formula. The node information includes customer nodes and depot nodes; the vehicle information includes vehicle model information and the total number of all vehicle models.
[0097] Initial Result Module: This module is used to obtain the initial path solution C_sol based on vehicle and node information using the cheapest insertion method. The cheapest insertion method involves first generating a first part of the path based on customer nodes with high demand, removing these nodes from the node information, and then randomly selecting some customer nodes from the remaining node information to generate a second part of the path. The first and second parts of the path form the initial path, and the remaining customer nodes are inserted into the initial path to obtain the initial solution. The number of initial paths is equal to the total number of all vehicle models.
[0098] Loading Adjustment Module: Used to improve and optimize the initial solution C_sol through the loading adjustment strategy LAS, and output the improved solution a; the loading adjustment strategy LAS is used to improve the loading rate of smaller vehicle types on the path and optimize the loading space of larger vehicle types;
[0099] Local search module: used to adjust the improved solution a using a local search strategy to obtain the best solution B_sol;
[0100] Perturbation module: Used to adjust the solution based on the best solution B_sol by perturbing it with a fixed number of random numbers to obtain a new best solution;
[0101] The first judgment module is used to calculate the variance of the path load percentage and the path cost based on the best solution B_sol and the new best solution. If the variance of the path load percentage and the path cost meet the preset acceptance strategy, the new best solution is accepted and the process proceeds to the second judgment module; otherwise, the process returns to the local search module and repeats the operation.
[0102] The second judgment module is used to determine whether the iteration stop condition is met. If the iteration stop condition is met, the module will enter the vehicle model optimization module; otherwise, the module will return to the local search module to repeat the operation.
[0103] Vehicle Model Optimization Module: This module is used to optimize the new best solution using the Vehicle Model Optimization Strategy (VOS) to obtain the globally optimal solution A_sol. The Vehicle Model Optimization Strategy (VOS) is used to optimize the relationship between the path load and the maximum capacity of the corresponding vehicle model in the new best solution.
[0104] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method for multi-carriage, multi-vehicle path planning based on multi-strategy iterative local search, characterized in that, Including: Step 1: Obtain vehicle information and node information, and establish a path cost minimization relationship; the node information includes customer nodes and depot nodes; the vehicle information includes vehicle type information in use and total number information of all vehicle types; it also includes preset required parameters, and the preset required parameters include setting a maximum number of iterations T, neighborhood size NR, perturbation parameter S, number of perturbation times NP, and number of non-improvement times C for the acceptance strategy; Among them, the path cost minimization relationship is: Where F represents the path cost of the corresponding solution; V represents the set of node information; M represents the set of vehicle types used, M = {1, 2, ..., m}; x ijm Let x represent a binary decision variable. ijm =1 indicates that there exists a vehicle of type m traveling from node i to node j; otherwise, x = 1. ijm =0; d ij c represents the path distance from node i to node j; m This represents the unit transportation cost of vehicle model m; Step 2: According to the vehicle information and node information, use the cheapest insertion method to obtain an initial path solution C_sol; the cheapest insertion method means first generating a first part of the path based on customer nodes with larger demand, removing these nodes from the node information, and then randomly selecting some customer nodes from the remaining node information to generate a second part of the path; the first part of the path and the second part of the path form an initial path, and inserting other remaining customer nodes into the initial path to obtain an initial solution; the number of the initial paths is equal to the total number of all vehicle types; Step 3: Improve and optimize the initial solution C_sol through a load adjustment strategy LAS, and output an improved solution a; the load adjustment strategy LAS is used to increase the load of small vehicle types on the path and optimize the loading space of large vehicle types; Step 4: Adjust the improved solution a through a local search strategy to obtain the best solution B_sol; Step 5: Based on the best solution B_sol, make adjustments through fixed random number perturbation to obtain a new best solution; Step 6: Based on the above best solution B_sol and the new best solution, calculate the path load percentage variance and path cost. If the path load percentage variance and path cost meet the preset acceptance strategy, accept the new best solution and execute Step 7; otherwise, return to Step 4 and repeat; Among them, the calculation expression of the path load percentage variance is: Where n represents the number of paths corresponding to solution x, n≤N; P i Representing path R i The loading rate corresponding to the vehicle, wherein the loading rate is path R i Z represents the ratio of the load on the corresponding vehicle to the maximum capacity of that vehicle model. n The average load factor of all vehicles; Step 7: Determine whether the iteration stop condition is met. If the iteration stop condition is met, execute Step 8; otherwise, return to Step 4 and repeat; Step 8: Optimize the new best solution through a vehicle type optimization strategy VOS to obtain a global optimal solution A_sol; the vehicle type optimization strategy VOS is used to optimize the relationship between the path load and the maximum capacity of the corresponding vehicle type in the new best solution.
2. The method for multi-carriage, multi-vehicle path planning based on multi-strategy iterative local search according to claim 1, characterized in that, In Step 2, the specific process of obtaining the path initial solution C_sol by using the cheapest insertion method includes: The total number N of all car models in the vehicle model set is counted, and then selected sequentially from the node information set V according to the demand. Each customer node generates The first part of the path is selected, and the customer nodes in this part are removed from the set V of node information; then, the remaining customer nodes in the set V are randomly selected. Each customer node generates There are N initial paths, which are the second part of the path. The customer nodes of this part are removed from the set of node information V. A total of N initial paths are generated, and the vehicle models with the maximum loading capacity exceeding the current demand are assigned to the initial paths. Based on the N initial paths, under the constraint of satisfying the maximum capacity, the remaining customer nodes in the set of node information V are inserted into the vehicle that minimizes the path cost. If there are customer nodes that cannot be inserted into the initial path, the solution is abandoned and regenerated.
3. The method for multi-carriage path planning of different vehicle models based on multi-strategy iterative local search according to claim 1, characterized in that, In Step 3, the specific content of the load adjustment strategy LAS includes: Obtain the set M = {1, 2, ..., m} of all vehicle types used in the current solution. Then, iterate through all non-minimum vehicle types in descending order to obtain the set Fr = {R1, R2, ..., Rn} of all paths using vehicle type r. i }, where r∈M and r≠1; let the current vehicle model be r=m; For each path Ri in Fr, traverse the customer nodes on its path, and insert the customer nodes into the path of the vehicle type t that is smaller (where t < r) without violating the capacity limit and without increasing the total path cost; After all the paths in Fr have been traversed, traverse the next vehicle type r - 1; determine whether r - 1 is greater than 1. If it is, continue to traverse the vehicle type r - 1; otherwise, end the adjustment; set the iteration number T to increase by 1 and the non-improvement number C to 0.
4. The method for multi-carriage path planning of different vehicle models based on multi-strategy iterative local search according to claim 1, characterized in that, In Step 5, the fixed random number perturbation specifically includes: During each perturbation, a path is randomly selected from N paths, and a customer node is randomly selected from the selected path as a reference. b customer nodes within its neighborhood range NR are removed and temporarily stored in an array. Insert the customer nodes temporarily stored in the array back into the path in a random order; Determine whether the path cost has decreased after the new solution obtained after the current perturbation is compared with the best solution before the current perturbation. If it has decreased, use the new solution as the new best solution for the next perturbation; otherwise, use the best solution before the current perturbation for the next perturbation. The perturbation continues until the number of perturbations, NP, reaches the preset number, at which point the perturbation ends and the newly obtained best solution is output.
5. The method for multi-carriage path planning of different vehicle models based on multi-strategy iterative local search according to claim 1, characterized in that, In step 6, The preset acceptance strategy is defined as follows: Among them, S c The best solution is represented by B_sol, S. n Let F(x) represent the new best solution, F(x) represent the path cost, and f(x) represent the variance of the path load percentage. If the new best solution has a lower path cost, accept the new best solution, increment the iteration count T by 1, and reset the number of iterations C that do not improve the strategy to 0. If the path cost of the new best solution remains unchanged or increases, but its path load percentage variance decreases, also accept the new best solution, increment the iteration count T by 1, and reset the number of iterations C that do not improve the strategy to 0. In other cases, do not accept the new best solution, and increment the number of iterations C that do not improve the strategy by 1. Correspondingly, in step 7, the iteration stopping condition includes determining whether the iteration number T and the number of no-boosts C have both reached the preset value. If they have, then proceed to step 8; otherwise, return to step 4 and repeat the process.
6. The method for multi-carriage path planning of different vehicle models based on multi-strategy iterative local search according to claim 1, characterized in that, In step 8, the vehicle model optimization strategy (VOS) specifically includes: Obtain the set of vehicle types M = {1, 2, ..., m} used by the current best solution, and traverse from vehicle type 1 to vehicle type m in ascending order; set the current vehicle type as i, and obtain the set of paths f that use vehicle type i. i ={R1,R2,...,R i } and the set F of all paths whose loading capacity does not exceed the maximum capacity of vehicle model i. I ={R1,R2,...,R I }; When the number of paths corresponding to vehicle model i is less than the number of paths whose loading capacity does not exceed the maximum capacity of vehicle model i, for set F I Path R1 to Path R I Sort the paths in descending order according to their path length, and then assign vehicle type i to each path in sequence. After assigning vehicle type i, move on to the next vehicle type i+1. Check if i is less than or equal to m. If so, continue to traverse the next vehicle type i+1. Otherwise, end the adjustment.
7. A multi-strategy iterative local search-based path planning device for multi-cabin vehicles of different models, characterized in that, include: Data acquisition module: used to acquire vehicle information and node information, and establish a path cost minimization relationship. The node information includes customer nodes and depot nodes; the vehicle information includes vehicle model information and total number of all vehicle models; it also includes preset required parameters, which include setting the maximum number of iterations T, neighborhood size NR, perturbation parameter S, perturbation count NP, and the number of times the acceptance strategy has no improvement C. The path cost minimization formula is as follows: Where F represents the path cost of the corresponding solution; V represents the set of node information; M represents the set of vehicle types used, M = {1, 2, ..., m}; x ijm Let x represent a binary decision variable. ijm =1 indicates that there exists a vehicle of type m traveling from node i to node j; otherwise, x = 1. ijm =0; d ij c represents the path distance from node i to node j; m This represents the unit transportation cost of vehicle model m; Initial Result Module: This module is used to obtain the initial path solution C_sol based on vehicle and node information using the cheapest insertion method. The cheapest insertion method involves first generating a first part of the path based on customer nodes with high demand, removing these nodes from the node information, and then randomly selecting some customer nodes from the remaining node information to generate a second part of the path. The first and second parts of the path form the initial path, and the remaining customer nodes are inserted into the initial path to obtain the initial solution. The number of initial paths is equal to the total number of all vehicle models. Loading Adjustment Module: Used to improve and optimize the initial solution C_sol through the loading adjustment strategy LAS, and output the improved solution a; the loading adjustment strategy LAS is used to improve the loading rate of smaller vehicle types on the path and optimize the loading space of larger vehicle types; Local search module: used to adjust the improved solution a using a local search strategy to obtain the best solution B_sol; Perturbation module: Used to adjust the solution based on the best solution B_sol by perturbing it with a fixed number of random numbers to obtain a new best solution; The first judgment module is used to calculate the variance of the path load percentage and the path cost based on the best solution B_sol and the new best solution. If the variance of the path load percentage and the path cost meet the preset acceptance strategy, the new best solution is accepted and the process proceeds to the second judgment module; otherwise, the process returns to the local search module and repeats the operation. The expression for calculating the variance of the path load percentage is as follows: Where n represents the number of paths corresponding to solution x, n≤N; P i Representing path R i The loading rate corresponding to the vehicle, wherein the loading rate is path R i Z represents the ratio of the load on the corresponding vehicle to the maximum capacity of that vehicle model. n The average load factor of all vehicles; The second judgment module is used to determine whether the iteration stop condition is met. If the iteration stop condition is met, the module will enter the vehicle model optimization module; otherwise, the module will return to the local search module to repeat the operation. Vehicle Model Optimization Module: This module is used to optimize the new best solution using the Vehicle Model Optimization Strategy (VOS) to obtain the globally optimal solution A_sol. The Vehicle Model Optimization Strategy (VOS) is used to optimize the relationship between the path load and the maximum capacity of the corresponding vehicle model in the new best solution.
Citation Information
Patent Citations
Distribution optimization method for continuous multi-time replenishment of gas station in push-type distribution mode
CN116843259A
Vehicle scheduling path optimization method and device
CN118886582A