Picking vehicle path optimization method and system based on CPS architecture

By using an adaptive large neighborhood search algorithm under the CPS architecture, vehicle data is perceived in real time and the path is dynamically optimized, which solves the problems of high computational complexity and weak response to sudden events in existing technologies, and achieves efficient and flexible vehicle path optimization.

CN121235583APending Publication Date: 2025-12-30STATE GRID SHANGHAI MUNICIPAL ELECTRIC POWER CO +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511176571.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-08-21
Publication Date
2025-12-30

AI Technical Summary

Technical Problem

Existing technologies have high computational complexity in vehicle routing optimization, are difficult to adapt to dynamically changing transportation environments, have weak response capabilities to emergencies, are highly dependent on data, have limited generalization capabilities, and are difficult to adapt to diverse needs across regions and industries.

Method used

An adaptive large neighborhood search algorithm based on CPS architecture is adopted, which combines the perception layer, decision layer and application layer to perceive vehicle data in real time. The adaptive large neighborhood search algorithm is used for iterative solution, and removal and repair operators are introduced to dynamically adjust path optimization. The simulated annealing algorithm is used to optimize operator weights to achieve fast response and global optimal solution.

Benefits of technology

It enables real-time perception and dynamic optimization of the logistics and transportation process, improves the efficiency and flexibility of route optimization, reduces delays and empty runs, enhances the ability to respond to emergencies, and improves the system's adaptability and security.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121235583A_ABST
    Figure CN121235583A_ABST
Patent Text Reader

Abstract

The invention relates to a goods taking vehicle path optimization method and system based on a CPS architecture, and the method comprises the steps: constructing the CPS architecture for vehicle path optimization, and carrying out the real-time sensing of the data of a goods taking vehicle in a logistics transportation process; the method comprises the following steps: obtaining goods taking quantity demands and positions of all clients and a usable vehicle set, and forming a to-be-solved vehicle path problem optimization model by constructing an objective function for minimizing vehicle driving cost and vehicle use cost and corresponding constraint conditions; and carrying out iterative solution on the vehicle path problem optimization model by adopting a self-adaptive large neighborhood search algorithm to obtain a final planned path, introducing a removal operator and a repair operator in the solution process, calculating a corresponding operator score, forming a new solution, and judging whether the new solution is a new optimal solution or not. Compared with the prior art, the method has the advantages that real-time sensing and dynamic optimization of the whole logistics transportation process are realized, emergencies are responded in time, and the path optimization efficiency is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of vehicle routing optimization technology, and in particular to a method and system for optimizing the routing of pickup vehicles based on a CPS architecture. Background Technology

[0002] In research on the vehicle routing problem with pickup (PVRP), the development of existing technologies has evolved from static models to dynamic optimization, and from single algorithms to a fusion of multiple technologies. Early research mainly relied on exact algorithms such as mixed integer linear programming (MILP) to solve for the optimal path through mathematical modeling. However, as the problem size increases (e.g., the number of customer nodes, vehicle types, and constraints increase), the computational complexity of exact algorithms grows exponentially, resulting in excessively long solution times and making it difficult to meet the needs of real-time decision-making. For example, in scenarios involving hundreds of customers and multiple warehouses, MILP may take several hours or even longer to solve, failing to adapt to dynamically changing transportation environments.

[0003] To address this challenge, researchers have gradually turned to heuristic and metaheuristic algorithms (such as genetic algorithms, ant colony optimization, and simulated annealing). These methods generate near-optimal solutions within a reasonable timeframe through random search and local optimization strategies. While these algorithms demonstrate high computational efficiency in large-scale problems, their limitations are also significant: on the one hand, they are prone to getting trapped in local optima, making it difficult to guarantee global optimality; on the other hand, the adjustment of algorithm parameters is highly dependent on experience, lacking generality. Furthermore, many models are based on idealized assumptions (such as constant traffic conditions and fixed customer demand), ignoring dynamic factors in actual operation (such as sudden traffic congestion, temporary order changes, and weather changes), leading to deviations between optimization results and real-world scenarios.

[0004] In terms of technology integration, big data analytics and machine learning have been introduced to enhance the predictive power and adaptability of models. For example, by training predictive models with historical traffic data, future road conditions can be predicted in advance and route planning can be optimized; reinforcement learning can be used to dynamically adjust delivery strategies, enabling the system to evolve autonomously in complex environments. However, these technologies still have the following shortcomings:

[0005] First, it is highly dependent on data. If the quality of the input data is not high (such as sensor failure or missing data), the model's performance will be greatly reduced.

[0006] Second, the model has limited generalization ability and is difficult to adapt to diverse needs across regions and industries.

[0007] Third, the system has a weak ability to respond to emergencies. For example, in the event of a traffic accident or extreme weather, the system may not be able to quickly generate alternative solutions, leading to delays. Summary of the Invention

[0008] The purpose of this invention is to overcome the shortcomings of the existing technology by providing a method and system for optimizing the route of pickup vehicles based on a CPS architecture, so as to realize real-time perception and dynamic optimization of the entire logistics transportation process, timely response to emergencies, and efficient route optimization.

[0009] The objective of this invention can be achieved through the following technical solutions:

[0010] A method for optimizing the route of pickup vehicles based on CPS architecture includes the following steps: constructing a CPS architecture for vehicle route optimization and real-time sensing of data during the logistics transportation process of pickup vehicles;

[0011] Obtain the pickup volume requirements and locations of each customer, as well as the set of available vehicles and the driving range and load constraints of each vehicle. By constructing an objective function that minimizes vehicle driving costs and vehicle usage costs, along with the corresponding constraints, an optimization model for the vehicle routing problem to be solved is formed.

[0012] An adaptive large neighborhood search algorithm is used to iteratively solve the vehicle routing problem optimization model to obtain the final planned path. During the iterative solution process, a removal operator and a repair operator are introduced, and the corresponding operator scores are calculated to form a new solution and determine whether it is the new optimal solution. The removal operator is used to remove some nodes in the current path, and the repair operator is used to insert the removed nodes into the damaged path.

[0013] Furthermore, the adaptive large neighborhood search algorithm introduces an iterative solution process for the removal and repair operators, which includes:

[0014] For the current solution, a removal operator and a repair operator are selected sequentially using the roulette wheel method and applied to the current solution. First, the removal operator is executed to remove nodes in the current path, and then the repair operator is executed to insert the removed nodes into the damaged path. A new solution is then recalculated.

[0015] If the objective function cost of the new solution is lower than that of the current solution, then the current solution is assigned the new solution; if the objective function cost of the new solution is lower than that of the optimal solution, then the optimal solution is assigned the new solution; otherwise, the current solution is assigned the new solution according to a preset probability formula.

[0016] Furthermore, the adaptive large neighborhood search algorithm includes a reaction factor to dynamically adjust the weights of the removal and repair operators. During the iterative optimization process, the removal and repair operators are scored, thereby updating their weights. The corresponding calculation expression is:

[0017] New weight = Original weight × b + (1-b) × (Score / Number of uses)

[0018] In the formula, b is the reaction factor.

[0019] Furthermore, the process of assigning scores to the removal and repair operators is as follows:

[0020] If the new solution is better than the current solution, the corresponding removal and repair operator scores will increase by 6 points; if the current solution is assigned the new solution by probability, the corresponding removal and repair operator scores will increase by 3 points.

[0021] Furthermore, the calculation expression for the probability formula is as follows:

[0022] p = exp(-(cost(S)) new )-cost(S cur )) / T)

[0023] In the formula, p is the probability, and cost(S) is the cost of probability. new ) represents the cost of the new solution, cost(S) cur Let T be the cost of the current solution;

[0024] The temperature T is updated using the simulated annealing algorithm. If the temperature T is updated using the simulated annealing algorithm, the current solution will be assigned the new solution, and the scores of the corresponding removal and repair operators will be increased by 2 points.

[0025] Furthermore, the removal operator includes a random removal operator and a worst-case removal operator. The random removal operator is used to randomly delete some nodes from the current solution. The worst-case removal operator is used to delete the nodes with the highest removal cost from the current solution. The removal cost is the difference between the cost before and after the node removal.

[0026] The repair operator includes a random insertion operator and a greedy insertion operator. The random insertion operator is used to randomly insert the deleted node into the damaged path, and the greedy insertion operator is used to insert the deleted node in the position where the insertion cost increases the least. The insertion cost is the difference between the cost before and after the node is inserted.

[0027] Furthermore, the objective function of the vehicle routing problem optimization model is expressed as follows:

[0028]

[0029] In the formula, c and c 0 These represent the unit mileage cost and the unit vehicle usage cost, respectively, two variables. This indicates that the value is 0 if vehicle k passes through arc (i,j)∈A, otherwise it is 0; the binary variable u k=1 indicates that vehicle k is in use, otherwise it is 0; r ij Let K represent the distance a vehicle travels from point i to point j, K be the set of vehicles, and A be the set of all arcs.

[0030] Furthermore, the constraints of the vehicle routing problem optimization model include:

[0031]

[0032]

[0033] In the formula, This indicates that each vehicle departs from and returns from the same warehouse, if This indicates that vehicle k is not in use; For the demand point flow conservation constraint, The maximum route length constraint is L, and the travel distance of each vehicle is a continuous variable. Indicates that vehicle k leaves point i∈N o The load capacity, Q, is the load capacity constraint for each vehicle, d i The quantity of goods picked up at the demand point is 0, and n+1 corresponds to the same warehouse, representing the start and end points of the path.

[0034] Furthermore, the CPS architecture includes a perception layer, a decision layer, and an application layer. The perception layer is used to collect vehicle data and adjust the vehicle routing problem optimization model in real time. The decision layer is used to clean and analyze the collected vehicle data. The application layer is used to provide a visual monitoring interface, navigation, and task allocation.

[0035] The present invention also provides a pickup vehicle route optimization system based on CPS architecture, including a memory and a processor. The memory stores a computer program, and the processor calls the computer program to execute the steps of the method described above.

[0036] Compared with the prior art, the present invention has the following advantages:

[0037] (1) On the one hand, this invention uses CPS technology to realize real-time perception and dynamic optimization of the entire logistics transportation process. This enables the system to acquire key data such as vehicle location, cargo status, traffic flow and weather changes in real time, and to quickly analyze them through edge computing or cloud platforms, thereby dynamically adjusting delivery routes and task allocation, reducing empty runs and delays;

[0038] On the other hand, in the process of optimizing the route of the pickup vehicle, two removal operators and two repair operators were designed for the adaptive large neighborhood search algorithm. The operators can be selected adaptively, which increases the directionality of the optimization and improves the optimization efficiency.

[0039] (2) The present invention sets reaction factors for two removal operators and two repair operators, dynamically adjusts the weights of the destruction and repair operators, assigns scores to the destruction and repair operators according to the assignment process of the new solution, and smoothly updates the weights based on the scores and reaction factors, thereby accelerating the calculation of the optimal solution and improving the convergence speed of the algorithm. Attached Figure Description

[0040] Figure 1 This is a flowchart illustrating a method for optimizing the route of a pickup vehicle based on a CPS architecture, as provided in an embodiment of the present invention.

[0041] Figure 2 This is a schematic diagram of a CPS architecture provided in an embodiment of the present invention. Detailed Implementation

[0042] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. The components of the embodiments of the present invention described and shown in the accompanying drawings can generally be arranged and designed in various different configurations.

[0043] Therefore, the following detailed description of the embodiments of the invention provided in the accompanying drawings is not intended to limit the scope of the claimed invention, but merely to illustrate selected embodiments of the invention. All other embodiments obtained by those skilled in the art based on the embodiments of the invention without inventive effort are within the scope of protection of the invention.

[0044] It should be noted that similar labels and letters in the following figures indicate similar items. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures.

[0045] Example 1

[0046] like Figure 1 As shown, this embodiment provides a method for optimizing the route of pickup vehicles based on a CPS architecture, including the following steps:

[0047] S1: Build a CPS architecture for vehicle route optimization and perceive data in real time during the logistics transportation process of pickup vehicles.

[0048] S2: Obtain the pickup volume requirements and locations of each customer, as well as the set of available vehicles and the driving range and load constraints of each vehicle. By constructing an objective function that minimizes vehicle driving costs and vehicle usage costs, along with the corresponding constraints, an optimization model for the vehicle routing problem to be solved is formed.

[0049] S3: An adaptive large neighborhood search algorithm is used to iteratively solve the vehicle routing problem optimization model to obtain the final planned path. During the iterative solution process, a removal operator and a repair operator are introduced, and the corresponding operator scores are calculated to form a new solution and determine whether it is the new optimal solution. The removal operator is used to remove some nodes in the current path, and the repair operator is used to insert the removed nodes into the damaged path.

[0050] In step S1, such as Figure 2 As shown, the CPS architecture includes a perception layer, a decision layer, and an application layer. The perception layer is used for vehicle data collection, the decision layer is used for cleaning and analyzing the collected vehicle data, and the application layer is used to provide a visual monitoring interface, navigation, and task allocation. It achieves comprehensive perception, intelligent analysis, and dynamic optimization of transport vehicles, multiple warehouse nodes, and logistics processes, providing new technical support for optimizing pickup vehicle routes.

[0051] The specific descriptions of each functional layer are as follows:

[0052] 1.1 Perception Layer: Enables end-to-end data acquisition and status awareness.

[0053] The perception layer is the foundation of the entire system, responsible for real-time monitoring of physical entities such as pickup vehicles, storage facilities, loading and unloading equipment, cargo status, and the external environment. By deploying GPS positioning modules, onboard sensors (such as engine status, tire pressure, and fuel consumption), and cargo status monitoring devices (temperature, humidity, and vibration detection) on transport vehicles, comprehensive control over vehicle operation and cargo safety is achieved. Inventory monitoring sensors, shelf load detectors, and environmental temperature and humidity sensors are installed in the warehouse to ensure dynamic visibility of storage resources. Simultaneously, motion recognition and operation recording modules are installed on loading and unloading equipment (such as forklifts and conveyor belts) to improve operational efficiency and safety. All collected data is transmitted to edge computing nodes via high-speed communication networks such as 5G and Wi-Fi 6, providing raw data for subsequent processing.

[0054] Edge computing nodes are deployed close to the data source, such as in-vehicle terminals or local servers in warehouses. Their main function is to perform preliminary cleaning, anomaly detection, and feature extraction on raw data. For example, when the system detects an abnormal engine temperature in a pickup truck, the edge node can immediately trigger an early warning mechanism and notify the control center, while simultaneously uploading key data to the decision-making level for further analysis. This mechanism not only improves the system's response speed but also effectively reduces the computing pressure on the cloud.

[0055] 1.2 Decision-making level: Integrating big data and intelligent algorithms to achieve dynamic path optimization.

[0056] As the core of the system, the decision-making layer undertakes the key tasks of data analysis, model building, and intelligent decision-making. First, the big data processing unit integrates, cleans, and models multi-source heterogeneous data from edge nodes, extracting potential patterns using clustering analysis and association rule mining to provide data support for route planning. Based on this, machine learning and deep reinforcement learning algorithms are combined to construct route optimization models suitable for different scenarios, such as a pickup route optimization model considering dynamic traffic conditions, a multi-warehouse collaborative scheduling model, and a priority route planning model under time window constraints.

[0057] As data accumulates during system operation, the model develops online learning capabilities, continuously updating parameters to adapt to new business needs and environmental changes. For example, the system can predict road congestion for a future period based on historical traffic flow data and adjust pickup order and driving routes accordingly. Furthermore, in response to emergencies (such as traffic accidents or severe weather), the system can quickly generate alternative route plans and push them to driver terminals, significantly improving emergency response capabilities.

[0058] 1.3 Application Layer: User-facing, providing visual services and intelligent interactive experiences.

[0059] The application layer directly targets various user groups, including logistics managers, delivery drivers, warehouse operators, and customer terminals, providing rich functional support and service interfaces. Managers can view key indicators such as vehicle location, pickup progress, and warehouse inventory in real time through the cloud platform, assisting in resource allocation and strategy formulation; drivers receive specific pickup tasks, navigation routes, and temporary change instructions, supporting functions such as voice prompts and electronic signatures, improving operational convenience and accuracy; customer terminals can check order status and estimated arrival time, and participate in delivery confirmation, enhancing user experience and satisfaction.

[0060] In addition, the system incorporates blockchain technology to store key data such as order information, handover records, and payment settlements on the blockchain during the pickup process, ensuring data immutability and full traceability, thereby enhancing the transparency and trustworthiness of logistics services. The control center, as the system's central hub, is responsible for coordinating the operation of all aspects, monitoring the overall delivery network status in real time, promptly identifying and handling abnormal events, and ensuring the system's stable operation.

[0061] In summary, the CPS-based pickup vehicle route optimization system constructs a closed-loop system integrating real-time perception, intelligent analysis, and efficient execution through close collaboration between the perception layer, decision-making layer, and application layer. This system not only addresses the shortcomings of traditional route optimization methods in dynamic response, multi-objective collaboration, and adaptability to complex environments, but also achieves precise planning, flexible adjustment, and green sustainable development of pickup routes in the logistics field by deeply integrating cutting-edge technologies such as the Internet of Things, artificial intelligence, and blockchain. This provides a solid technical foundation and practical path for the evolution of modern logistics systems towards intelligence and collaboration.

[0062] The adoption of CPS technology in PVRP research offers significant advantages and improvements. Firstly, CPS achieves real-time perception and dynamic optimization of the entire logistics and transportation process by deeply integrating technologies such as the Internet of Things (IoT), sensor networks, cloud computing, and artificial intelligence (AI). This enables the system to acquire key data in real time, such as vehicle location, cargo status, traffic flow, and weather changes, and to perform rapid analysis through edge computing or cloud platforms. This allows for dynamic adjustments to delivery routes and task allocation, reducing empty runs and delays. For example, in dynamic environments, CPS, combined with big data analytics and machine learning algorithms (such as deep reinforcement learning), can predict future traffic trends and changes in customer demand, generating more forward-looking route planning solutions.

[0063] Secondly, CPS significantly enhances the system's flexibility and responsiveness. In the face of unexpected events, such as traffic accidents, sudden severe weather, or temporary changes in customer orders, CPS can use tools like the Gaode Map API and ArcGIS to simulate optimal pickup routes under different demand distribution conditions and adjust pickup plans in real time. This improves the system's adaptability and emergency response capabilities, reduces delivery delays, and ensures service quality. This instant response mechanism not only enhances the system's flexibility but also ensures efficient operation in complex and ever-changing real-world environments.

[0064] Furthermore, CPS plays a crucial role in enhancing safety. The system can detect driver behavior (such as fatigue or speeding) in real time through onboard sensors and remote monitoring systems, issuing timely alerts. It can also track cargo status (such as temperature, humidity, and vibration), ensuring the safe transport of high-value or perishable goods, making it particularly suitable for industries with high environmental requirements, such as pharmaceuticals and fresh produce. This intelligent monitoring and early warning function further reduces transportation risks and ensures cargo safety.

[0065] Furthermore, CPS facilitates collaborative work across all links of the supply chain. It makes information sharing between different warehouses and between warehouses and distribution centers more convenient, helping to strengthen cooperation and form an efficient supply chain network. For example, by establishing enterprise alliances and sharing warehousing and transportation resources, profits can be increased while risks are diversified, enhancing the resilience and stability of the entire supply chain. This seamless cross-departmental information exchange not only improves resource utilization and service efficiency but also provides a solid foundation for joint scheduling, reducing overall operating costs.

[0066] Finally, CPS supports comprehensive cost optimization. In addition to direct transportation costs (such as fuel consumption and labor costs), CPS also considers indirect cost factors such as inventory management and customer service, achieving overall cost minimization. For example, adjusting pickup routes based on real-time traffic data to avoid congested areas not only saves time and fuel but also reduces customer dissatisfaction and potential losses caused by delays. Furthermore, through in-depth analysis of historical data, CPS can identify potential optimization opportunities and propose more economical and reasonable solutions.

[0067] In step S2, the specific process of constructing the vehicle routing problem optimization model includes:

[0068] The Vehicle Routing Problem with Pickup (PVRP) involves a group of identical vehicles departing from a distribution center to serve a defined set of customers and returning to the distribution center after completing their service. The pickup quantity for each customer is known. Vehicles follow planned routes, picking up goods from customers and returning them to the distribution center according to their pickup requests. Each customer is visited only once by one vehicle. The goal is to determine the optimal routes and number of vehicles used, within constraints such as vehicle loading capacity and travel distance, to meet the pickup needs of all customers with the lowest possible mileage.

[0069] Specifically, the following construction process is included:

[0070] Set configuration: Let K be the set of vehicles available at the warehouse (k∈K), and N be the set of demand points (customers). c (N c ={1,2,…,n}). Using N o ={0}∪N c and N e =N c ∪{n+1} represents the starting and ending points of the arc, A(A={(i,j)|i∈N) o ,j∈N e ,i≠j) represents the set of all arcs.

[0071] Parameter settings: Use r ijLet c and c represent the distance the vehicle travels from point i to point j. 0 Let L represent the unit mileage cost and unit vehicle usage cost, respectively. L is the mileage constraint for each vehicle, Q is the load constraint for each vehicle, and d is the load factor constraint. i (d i <0) represents the quantity of goods picked up at the demand point (customer point). 0 and n+1 correspond to the same warehouse, representing the start and end points of the path.

[0072] Variable setting: binary variable This indicates that the value is 0 if vehicle k passes through arc (i,j)∈A, otherwise it is 0. The binary variable u... k =1 indicates that vehicle k is in use. (Continuous variable) Indicates that vehicle k leaves point i∈N o Load capacity.

[0073] The optimization model for the vehicle routing problem is as follows:

[0074] Objective function:

[0075]

[0076] In the formula, c and c 0 These represent the unit mileage cost and the unit vehicle usage cost, respectively, two variables. This indicates that the value is 0 if vehicle k passes through arc (i,j)∈A, otherwise it is 0; the binary variable u k =1 indicates that vehicle k is in use, otherwise it is 0; r ij Let K represent the distance a vehicle travels from point i to point j, K be the set of vehicles, and A be the set of all arcs.

[0077] Constraints:

[0078]

[0079] In the formula, This indicates that each vehicle departs from and returns from the same warehouse, if This indicates that vehicle k is not in use; For the demand point flow conservation constraint, The maximum route length constraint is L, and the travel distance of each vehicle is a continuous variable. Indicates that vehicle k leaves point i∈N o The load capacity, Q, is the load capacity constraint for each vehicle, d i The quantity of goods picked up at the demand point is 0, and n+1 corresponds to the same warehouse, representing the start and end points of the path.

[0080] Equation (1) represents minimizing the total cost, including vehicle operating costs and vehicle usage costs; constraint (2) indicates that each vehicle departs from and returns from the same warehouse. If This indicates that vehicle k is not in use; constraint (3) is the demand point flow conservation constraint; constraint (4) is the maximum route length constraint; constraint (5) indicates that the vehicle leaves the warehouse empty; constraint (6) indicates the change in load capacity of each vehicle leaving each demand point; constraint (7) indicates that the load capacity of each vehicle arriving at the warehouse does not exceed the maximum capacity limit; constraint (8) indicates that each demand point is served only once; constraint (9) indicates that if a vehicle serves a customer, it is used. Equations (10) and (11) define the range of values ​​for the variables.

[0081] In step S3, the iterative solution process of the adaptive large neighborhood search algorithm, which introduces the removal operator and the repair operator, includes:

[0082] For the current solution, a removal operator and a repair operator are selected sequentially using the roulette wheel method and applied to the current solution. First, the removal operator is executed to remove nodes in the current path, and then the repair operator is executed to insert the removed nodes into the damaged path. A new solution is then recalculated.

[0083] If the objective function cost of the new solution is lower than that of the current solution, then the current solution is assigned the new solution; if the objective function cost of the new solution is lower than that of the optimal solution, then the optimal solution is assigned the new solution; otherwise, the current solution is assigned the new solution according to a preset probability formula.

[0084] The adaptive large neighborhood search algorithm includes a reaction factor to dynamically adjust the weights of the removal and repair operators. During iterative optimization, the removal and repair operators are scored, thereby updating their weights. The corresponding calculation expression is:

[0085] New weight = Original weight × b + (1-b) × (Score / Number of uses)

[0086] In the formula, b is the reaction factor.

[0087] The process of assigning scores to the removal and repair operators is as follows:

[0088] If the new solution is better than the current solution, the corresponding removal and repair operator scores will increase by 6 points; if the current solution is assigned the new solution by probability, the corresponding removal and repair operator scores will increase by 3 points.

[0089] The formula for calculating probability is:

[0090] p = exp(-(cost(S)) new )-cost(S cur )) / T)

[0091] In the formula, p is the probability, and cost(S) is the cost of probability. new ) represents the cost of the new solution, cost(S) curLet T be the cost of the current solution;

[0092] The temperature T is updated using the simulated annealing algorithm. If the temperature T is updated using the simulated annealing algorithm, the current solution will be assigned the new solution, and the scores of the corresponding removal and repair operators will be increased by 2 points.

[0093] The removal operators include the random removal operator and the worst-case removal operator. The random removal operator is used to randomly delete some nodes from the current solution; the worst-case removal operator is used to delete the nodes with the highest removal cost from the current solution. The removal cost is the difference between the cost before and after the node removal.

[0094] Repair operators include random insertion operators and greedy insertion operators. Random insertion operators are used to randomly insert deleted nodes into the damaged path, while greedy insertion operators are used to insert deleted nodes in the position where the insertion cost increases the least. The insertion cost is the difference between the cost before and after the node is inserted.

[0095] The solution process of the above-mentioned overall adaptive large neighborhood search algorithm includes:

[0096] Step 1. Initialization: Initial solution S initial =[0], number of vehicles k=1;

[0097] Current access point c = 0; load capacity w = 0; travel distance L = 0

[0098] Step 2. Repeat the following steps until all customers have been visited.

[0099] Step 2a.v ← The point closest to the currently visited point c

[0100] Step 2b. If vehicle k can reach the warehouse after visiting v and the vehicle load constraint is met.

[0101] Step 2b(i).S initial ←S initial ∪{v}, update the current access point c, load capacity w, and travel distance L.

[0102] Step 2c. Otherwise, S←S∪{0}; number of vehicles k+=1; current access point c=0; load capacity w=0; mileage L=0, return to step 2a.

[0103] Step 3. Initialization: Current temperature T ← T0, current solution S cur ←S initial Optimal solution S best ←S initial Taboo list (taboo_list = [])

[0104] Step 4. If T <T f :

[0105] Step 4a. Loop Iter times.

[0106] Step 4a(i). For S cur First, based on the operator performance, a removal operator and a repair operator are selected sequentially using a roulette wheel algorithm and applied to the current solution. Through a "destroy first, then repair" procedure, a new solution S is formed. new and S new Add to taboo_list

[0107] Step 4a(iii) If cost(S) new ) <cost(S cur ), S cur =S new Update operator fraction step 4a(iii-1) if cost(S) new ) <cost(S best ), S best =S new Update the operator fraction;

[0108] Step 4a(iv) Otherwise, if with probability p = exp(-(cost(S) new )-cost(S cur )) / T) accepts the new solution, S cur =S new Update operator fractions

[0109] Step 4a(v) Otherwise, update the operator fraction.

[0110] Step 4b. Update temperature T = β·T, and release the taboo list taboo_list

[0111] Step 5. Return the optimal solution S best

[0112] Two removal operators and two repair operators are designed for the adaptive large neighborhood search algorithm. The removal operators include random removal and worst-case removal. Random removal involves randomly deleting 10% of the client points from the current solution; worst-case removal involves deleting the 10% of points with the highest removal cost, where the removal cost is the difference between the cost before and after removal. The repair operators include random insertion and greedy insertion. Random insertion involves randomly inserting the deleted points into the broken path, increasing the randomness of the solution search; greedy insertion involves inserting the deleted points into the position with the least cost increase, where the insertion cost is the difference between the cost before and after insertion. Furthermore, an adaptive selection operator is considered to increase the directionality of the optimization and improve its efficiency.

[0113] This embodiment delivers goods to seven customer locations in Shanghai using a single warehouse. It uses the Adaptive Large Neighborhood Search (ALNS) algorithm to solve the PVRP problem with mileage constraints, load constraints, and demand flow constraints, with the goal of minimizing the sum of total travel distance and vehicle fixed costs.

[0114] Specifically, the calculation process includes the following:

[0115] 1.1) Basic Data Structure Modeling

[0116] Node entity modeling: A set of customer nodes is constructed by reading files, containing 7 customer nodes (numbered 1-7) and 1 distribution center (number 0). Entity attributes include 2D coordinate data (x, y) and node demand values, stored in a list structure for fast indexing and access. The coordinate data is stored precisely as floating-point numbers, and the demand values ​​are also stored as floating-point numbers to support continuous quantity processing.

[0117] Distance matrix calculation: Constructing the total node distance matrix based on the Euclidean distance formula: O(n) implementation using NumPy matrices 2 The time complexity calculation ensures global shared access to distance data. A symmetric storage strategy is used for the matrix to optimize memory usage.

[0118] 1.2) Constraint Data Preprocessing

[0119] Load constraint handling: Set the maximum vehicle load Q = 100, and implement dynamic load monitoring through a demand accumulation verification mechanism. In the preprocessing stage, the customer demand value is stored in the demand list. During path generation, the cumulative load is calculated in real time. When the cumulative value exceeds Q, path splitting is triggered.

[0120] Mileage constraint enhancement: The maximum mileage for a single path is preset to L = 300, and all distance data is pre-generated during the distance matrix calculation stage. During path feasibility checks, the hard constraint is verified by accumulating the distances of each segment of the current path and comparing them with the L value.

[0121] 1.3) Special Data Processing

[0122] Path structure normalization: The `calsubr` function was developed to convert one-dimensional path sequences into multi-dimensional sub-paths, automatically inserting warehouse nodes (0) as path start and end identifiers. The `multizero` function was used to eliminate consecutive zero nodes, ensuring the validity of the path structure.

[0123] Initial solution generation: A greedy algorithm is used to construct an initial feasible solution, and the nearest neighbor selection strategy is implemented through the next_short function. In the preprocessing stage, warehouse nodes (number 0) are excluded to generate a customer candidate set, ensuring that path construction starts from the warehouse nodes.

[0124] This preprocessing system transforms raw geographic data into standardized input that meets the requirements of the ALNS algorithm through matrix calculation, dynamic verification, and structural standardization, providing a reliable data foundation for subsequent damage-repair operators.

[0125] 2) Algorithm parameter settings

[0126] This code implements a vehicle routing optimization algorithm based on Adaptive Large Neighborhood Search (ALNS), addressing the PVRP problem with mileage constraints, load constraints, and demand flow constraints, with the objective of minimizing the total cost (mileage cost + fixed cost). The following is an analysis of the parameter configuration and optimization logic:

[0127] 2.1) Algorithm control parameters

[0128] The initial temperature T = 100 and the cooling coefficient a = 0.97 are used to simulate the annealing acceptance criterion, which controls the probability of the algorithm accepting inferior solutions during the iteration process. The initial high temperature allows for extensive search, and gradually converges to a local optimum as the temperature decreases.

[0129] The response factor b = 0.7 is used to dynamically adjust the weights of the damage and repair operators. The larger the value, the greater the influence of historical performance on the current weight, and the slower the weight update speed.

[0130] 2.2) Disruption and Repair Operator Weight Mechanism

[0131] The initial weights wDestroy = [1,1] and wRepair = [1,1] correspond to two types of destruction (random destruction, maximum cost destruction) and two types of repair (random insertion, greedy insertion) operators, respectively.

[0132] Weight update depends on the scoring mechanism: if the new solution is better than the current solution, the score of the destruction / repair operator increases by 6 points; if the inferior solution is accepted, it increases by 3 points; if the solution is accepted through simulated annealing, it increases by 2 points.

[0133] Finally, the weights are updated smoothly using the response factor b, with the formula: New weight = Original weight × b + (1-b) × (Score / Number of uses)

[0134] 2.3) Problem Constraint Parameters

[0135] Load constraint Q = 100: Maximum load capacity of a single vehicle.

[0136] Mileage constraint L = 300: Maximum travel distance of a single vehicle.

[0137] Fixed cost = 30: The fixed cost of using each vehicle. The total fixed cost corresponding to the number of vehicles needs to be added to the objective function.

[0138] 3) Optimization Results

[0139] 3.1) Initial solution generation

[0140] The initial path is constructed using the nearest neighbor heuristic algorithm (greconstr function). The objective function value is calculated using calcost, which includes the sum of the total path distance and the vehicle's fixed cost. The quality of the initial solution directly affects the algorithm's convergence speed.

[0141] 3.2) ALNS Iteration Process

[0142] Destruction phase: Randomly remove 4 nodes (randomDestroy) or remove the 3 highest cost nodes in the current path (max3Destroy). After removal, the path continuity needs to be checked (deempty and multizero functions).

[0143] Repair phase: Randomly or greedily insert (minimize insertion cost) the removed node, and verify the constraints after each insertion (feacheckf and feachecks functions).

[0144] Acceptance criterion: The simulated annealing mechanism is used to determine whether to accept a new solution, thus avoiding getting trapped in local optima.

[0145] 3.3) Result Output

[0146] The final output is the optimal solution path and its total cost. Verifying the feasibility of the solution requires ensuring that:

[0147] The mileage of all sub-paths is less than or equal to L, and the load is less than or equal to Q.

[0148] The distribution center (node ​​0) separates the sub-paths in the path, and the demand flow constraint dynamically adjusts the load through the demand array.

[0149] 4) Result Verification

[0150] The specific implementation paths are displayed using Amap (Gaode Maps). All optimized paths meet the objective of minimizing the sum of total travel distance and vehicle fixed costs, with loads not exceeding Q=100 and mileage not exceeding L=300, satisfying the preset constraints. The current example has integrated with the Amap API to obtain real-time traffic information.

[0151] Example 2

[0152] This embodiment provides a pickup vehicle route optimization system based on CPS architecture, including a memory and a processor. The memory stores a computer program, and the processor calls the computer program to execute the steps of the method as described in Embodiment 1.

[0153] The program code used to implement the methods of the present invention can be written in any combination of one or more programming languages. This program code can be provided to a processor or controller of a general-purpose computer, special-purpose computer, or other programmable data processing device, such that when executed by the processor or controller, the program code causes the functions / operations specified in the flowcharts and / or block diagrams to be implemented. The program code can be executed entirely on the machine, partially on the machine, as a standalone software package partially on the machine and partially on a remote machine, or entirely on a remote machine or server.

[0154] The preferred embodiments of the present invention have been described in detail above. It should be understood that those skilled in the art can make numerous modifications and variations based on the concept of the present invention without creative effort. Therefore, all technical solutions that can be obtained by those skilled in the art based on the concept of the present invention through logical analysis, reasoning, or limited experimentation on the basis of existing technology should be within the scope of protection defined by the claims.

Claims

1. A method for optimizing the route of a pick-up vehicle based on a CPS architecture, characterized in that, The method comprises the following steps: constructing a CPS architecture for vehicle path optimization to realize real-time sensing of data of a pickup vehicle in a logistics transportation process; obtaining pickup quantity demands and positions of various customers, a set of available vehicles and driving course constraints and load constraints of each vehicle, constructing an objective function of minimizing vehicle driving cost and vehicle use cost and corresponding constraint conditions to form a vehicle path problem optimization model to be solved; iteratively solving the vehicle path problem optimization model by using an adaptive large neighborhood search algorithm to obtain a final planning path, introducing a removal operator and a repair operator in the iterative solving process, calculating corresponding operator scores, forming a new solution and judging whether the new solution is a new optimal solution; the removal operator is used to remove part of nodes in the current path, and the repair operator is used to insert the removed nodes into the damaged path.

2. The CPS architecture based vehicle routing optimization method according to claim 1, wherein, The iterative solving process of the adaptive large neighborhood search algorithm introducing the removal operator and the repair operator comprises: for a current solution, a removal operator and a repair operator are selected in turn by using a roulette method, applied to the current solution, the removal operator is used to remove nodes in the current path, and then the repair operator is used to insert the removed nodes into the damaged path, and a new solution is recalculated; if the objective function cost value of the new solution is lower than that of the current solution, the current solution is assigned to the new solution; if the objective function cost value of the new solution is lower than that of the optimal solution, the optimal solution is assigned to the new solution; otherwise, the current solution is assigned to the new solution with a preset probability formula.

3. The CPS architecture based vehicle routing optimization method of claim 2, wherein, The adaptive large neighborhood search algorithm is provided with a reaction factor for dynamically adjusting the weights of the removal operator and the repair operator, and the removal operator and the repair operator are scored in the iterative optimization process, so that the weights of the removal operator and the repair operator are updated, and the corresponding calculation expression is: New weight = original weight * b + (1-b) * (score / use frequency) In the formula, b is the reaction factor.

4. The CPS architecture based vehicle routing optimization method of claim 3, wherein, The process of scoring the removal operator and the repair operator is specifically: if the new solution is better than the current solution, the scores of the corresponding removal operator and repair operator are increased by 6 points; if the current solution is assigned to the new solution by the probability, the scores of the corresponding removal operator and repair operator are increased by 3 points.

5. The CPS architecture based vehicle routing optimization method of claim 4, wherein, The calculation expression of the probability formula is: p = exp(-(cost(S new )-cost(S cur )) / T) where p is a probability, cost(S new ) is the cost of the new solution, cost(S cur ) is the cost of the current solution, and T is a temperature; If the temperature T is updated by using the simulated annealing algorithm, and the current solution is assigned to the new solution, the scores of the corresponding removal operator and repair operator are increased by 2 points.

6. The CPS architecture based vehicle routing optimization method of claim 1, wherein, The removal operator comprises a random removal operator and a worst removal operator, the random removal operator is used to randomly delete part of nodes from the current solution, and the worst removal operator is used to delete part of nodes with the largest removal cost from the current solution, the removal cost being the difference between the costs before and after node removal; The repair operator comprises a random insertion operator and a greedy insertion operator, the random insertion operator is used to randomly insert the deleted nodes into the damaged path, and the greedy insertion operator is used to insert the deleted nodes into the position with the least increase in insertion cost, the insertion cost being the difference between the costs before and after node insertion.

7. The CPS architecture based vehicle routing optimization method of claim 1, wherein, The expression of the objective function of the vehicle path problem optimization model is: where c and c 0 respectively represent the vehicle unit mileage cost and the unit vehicle usage cost, binary variable denotes the cost of vehicle k when it travels on arc (i, j) e A, otherwise 0; binary variable u k = 1 if vehicle k is used, otherwise 0; r ij denotes the travel distance of vehicle from point i to point j, K is the vehicle set, and A is the set of all arcs.

8. The CPS architecture based vehicle routing optimization method of claim 7, wherein, The constraint condition of the vehicle path problem optimization model comprises: where, denotes that each vehicle departs and returns from the same depot, and if denotes that vehicle k is not used; is the demand point flow conservation constraint, is the route maximum length constraint, L is the driving distance constraint for each vehicle, and the continuous variable denotes the load of vehicle k leaving point i∈N o , Q is the load constraint for each vehicle, d i is the pickup quantity of demand points, 0 and n+1 correspond to the same depot, and denotes the start and end points of the path.

9. The CPS architecture based vehicle routing optimization method of claim 1, wherein, The CPS architecture comprises a perception layer, a decision layer and an application layer, the perception layer is used for collecting vehicle data, and is used for adjusting the vehicle path problem optimization model in real time, the decision layer is used for cleaning and analyzing the collected vehicle data, and the application layer is used for providing a visual monitoring interface, navigation and task allocation.

10. A CPS architecture based pick-up vehicle path optimization system characterized in that, A computer program product comprises a memory and a processor, the memory stores a computer program, and the processor calls the computer program to execute the steps of the method in any one of claims 1-9.