A logistics transport vehicle route planning recommendation processing method and system

CN122529596APending Publication Date: 2026-08-07GUIZHOU BUSINESS SCHOOL
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
GUIZHOU BUSINESS SCHOOL
Filing Date
2026-07-09
Publication Date
2026-08-07

AI Technical Summary

Technical Problem

然而,现有聚类方法大多仅考虑任务的空间距离特征,忽略了时间窗口这一重要约束条件,导致聚类结果与实际可行的配送方案存在较大偏差

Benefits of technology

[0049] This invention employs a modularity-optimized segmentation method based on spatiotemporal transfer costs, simultaneously considering the spatial distance and time window characteristics of transportation tasks for clustering, making the clustering results more consistent with actual delivery patterns. Cluster centers are determined by calculating the peak density gradient in the time-space coordinate system, fully utilizing the clustering characteristics of tasks in the time dimension and reducing the additional travel distance of vehicles. Global matching optimization using a fitness matrix achieves optimal allocation of vehicles and task clusters, avoiding the problem of uneven utilization of vehicle resources. Transportation tasks are mapped to state nodes carrying time and capacity markers, and a directed state graph is constructed, making the handling of time window constraints and capacity constraints more intuitive and efficient, reducing the computational complexity of the algorithm. The overall scheme meets real-time requirements while ensuring solution quality, improving the adaptability and robustness of the algorithm.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122529596A_ABST
    Figure CN122529596A_ABST
Patent Text Reader

Abstract

The application discloses a logistics transport vehicle route planning recommendation processing method and system, and relates to the technical field of intelligent logistics optimization, and comprises the following steps: acquiring a transport task set and a vehicle resource set; constructing a task association network based on a space-time transfer cost and performing module degree optimization segmentation to obtain a task cluster set; projecting the task cluster to a time-space coordinate system and extracting a cluster center through a density gradient peak value; constructing an adaptation degree matrix according to the matching degree of a vehicle arrival time and a task time window, and performing global matching optimization to obtain a binding scheme of the vehicle and the task cluster; mapping the task to a state node carrying a time and a capacity label, constructing a directed state graph, searching a minimum cost path satisfying a constraint, and outputting a task access order. The application comprehensively considers space-time characteristics, and improves the route planning efficiency and accuracy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of intelligent logistics optimization technology, specifically to a method and system for route planning and recommendation of logistics transportation vehicles. Background Technology

[0002] In real-world logistics and distribution scenarios, transportation tasks typically exhibit multi-dimensional characteristics such as time window constraints and cargo capacity requirements, while vehicle resources are limited by factors like capacity constraints and initial location distribution. How to rationally allocate transportation tasks to vehicles and plan optimal routes for each vehicle that satisfy various constraints is a core problem that urgently needs to be solved in the logistics and transportation field.

[0003] Traditional vehicle routing methods primarily employ heuristic or exact algorithms. Heuristic algorithms, such as genetic algorithms and ant colony algorithms, can obtain feasible solutions within a reasonable timeframe, but often struggle to guarantee solution quality and are prone to getting trapped in local optima when faced with large-scale task sets. Exact algorithms, such as branch and bound and dynamic programming, can obtain optimal solutions, but their computational complexity increases exponentially with task size, making them unsuitable for real-time requirements in practical applications.

[0004] In recent years, some studies have attempted to introduce clustering methods to pre-group transportation tasks and then plan routes separately for each group. However, most existing clustering methods only consider the spatial distance characteristics of tasks, ignoring the important constraint of the time window, leading to significant deviations between the clustering results and practically feasible delivery solutions. In the vehicle-task cluster matching stage, existing methods often employ greedy strategies or simple proximity allocation principles, lacking a global optimization perspective and easily causing uneven utilization of vehicle resources. In the route planning stage, existing methods typically use stepwise adjustments or penalty functions when dealing with capacity constraints and time window constraints, which not only increases the number of iterations but may also cause the final path to deviate from the globally optimal solution.

[0005] In summary, existing logistics transportation vehicle route planning technologies have significant shortcomings in areas such as spatiotemporal feature modeling of task clustering, global matching optimization of vehicle and task clusters, and constraint handling mechanisms for path planning, making it difficult to meet real-time requirements while ensuring solution quality. Summary of the Invention

[0006] The purpose of this invention is to provide a method and system for route planning and recommendation of logistics transportation vehicles, aiming to solve at least one of the technical problems existing in the prior art.

[0007] The technical solution of this invention is: a method for recommending routes for logistics transportation vehicles, comprising the following steps:

[0008] Obtain a set of transportation tasks containing location information and time windows, and a set of vehicle resources containing capacity information and location information;

[0009] A task association network is constructed based on the spatiotemporal transfer cost between transportation tasks, and a task cluster set is obtained by performing modularity optimization segmentation on the task association network.

[0010] For each task cluster in the task cluster set, the transportation tasks within the task cluster are projected onto the time-space coordinate system, the density gradient of the projected point set in the time axis direction is calculated, and the spatial position corresponding to the peak of the density gradient is extracted as the cluster center.

[0011] Calculate the arrival time of each vehicle in the vehicle resource set to the cluster center, construct an adaptation matrix based on the matching degree between the arrival time of each vehicle and the time window of each transportation task in the corresponding task cluster, and perform global matching optimization based on the adaptation matrix to obtain the binding scheme between vehicles and task clusters.

[0012] Based on the binding scheme, transportation tasks within a task cluster are mapped to state nodes carrying time and capacity markers. A directed state graph is constructed through marker propagation between state nodes. The minimum cost path that satisfies the time window constraint and capacity constraint is searched on the directed state graph. The transportation task access order corresponding to the minimum cost path is output as the vehicle route planning recommendation result.

[0013] Based on the spatiotemporal transfer cost between transportation tasks, a task association network is constructed. Modularity optimization segmentation is performed on this network to obtain a set of task clusters, including:

[0014] Calculate the spatial distance and time window interval between each transportation task in the transportation task set. Based on the time window interval, weight the spatial distance to obtain the spatiotemporal transfer cost between transportation tasks. Construct a task association network with transportation tasks as nodes and spatiotemporal transfer cost as connection weight.

[0015] Each node in the task association network is initialized as an independent cluster, and the ratio of the sum of the connection weights within each cluster to the sum of the connection weights of the entire task association network is calculated as the cluster density.

[0016] The time span covered by the time window of the transportation task within each cluster is calculated as the cluster temporal dispersion. The cluster compactness and cluster temporal dispersion are combined to construct a modularity quality index.

[0017] Iteratively select the cluster that maximizes the improvement in modularity quality index, merge it, and update the modularity quality index until merging all clusters fails to improve the modularity quality index. Output the transportation task nodes contained in each cluster as a task cluster set.

[0018] For each task cluster in the task cluster set, the transportation tasks within the task cluster are projected onto a time-space coordinate system. The density gradient of the projected point set along the time axis is calculated, and the spatial location corresponding to the peak of the density gradient is extracted as the cluster center, including:

[0019] For each task cluster in the task cluster set, extract the start time and location information of the time window of each transportation task in the task cluster. Construct a time-space coordinate system with the start time of the time window as the time axis and the location information as the spatial axis. Map each transportation task in the task cluster to the projection point in the time-space coordinate system to obtain the projection point set.

[0020] Based on the distribution range of the projection point set on the time axis, the time axis is divided into multiple equal-width time periods, and the number of projection points in each time period is counted as the time period density.

[0021] The density gradient along the time axis is obtained by calculating the ratio of the density difference between adjacent time periods to the width of the time period, and the maximum value of the density gradient is extracted as the density gradient peak.

[0022] Extract each projection point within the time period corresponding to the density gradient peak, calculate the time deviation between the start time of the time window of each projection point and the center time of the time period corresponding to the density gradient peak, perform attenuation weighting on the position information of each projection point based on the time deviation, and find the geometric center. The spatial position of the geometric center is taken as the cluster center.

[0023] Calculate the arrival time of each vehicle in the vehicle resource set to the cluster center. Construct a fit matrix based on the matching degree between the arrival time of each vehicle and the time window of each transportation task within the corresponding task cluster. Perform global matching optimization based on the fit matrix to obtain the vehicle-task cluster binding scheme, including:

[0024] For each vehicle in the vehicle resource set, obtain the spatial distance between the vehicle's current position coordinates and the cluster center of each task cluster in the task cluster set, and calculate the arrival time of each vehicle in the vehicle resource set to the cluster center by combining the vehicle's driving speed.

[0025] For each vehicle and each task cluster, the start time of the time window of each transportation task within the task cluster is extracted, the absolute value of the time deviation between the arrival time of each vehicle and the start time of each time window is calculated, and the absolute value of the time deviation of each transportation task within the task cluster is weighted and summed according to the weight of the goods in the transportation task to obtain the degree of matching between the arrival time of each vehicle and the time window of each transportation task within the corresponding task cluster.

[0026] A fit matrix is ​​constructed using each vehicle in the vehicle resource set as the row index, each task cluster in the task cluster set as the column index, and the matching degree as the element value.

[0027] Global matching optimization is performed based on the fitness matrix. The matrix element with the smallest value is iteratively selected from the fitness matrix to establish the corresponding vehicle and task cluster binding relationship. The row corresponding to the bound vehicle and the column corresponding to the task cluster are removed from the fitness matrix. The selection and removal operations are repeated until all vehicles or all task clusters are bound to obtain the vehicle and task cluster binding scheme.

[0028] Based on the binding scheme, transportation tasks within a task cluster are mapped to state nodes carrying time and capacity markers. A directed state graph is constructed through marker propagation between state nodes, including:

[0029] Extract the time window and cargo demand of each transportation task within the task cluster, encapsulate the time window as a time stamp and the cargo demand as a capacity stamp, and map each transportation task as a state node carrying the time stamp and capacity stamp.

[0030] Calculate the spatial distance between state nodes. Determine whether the state node can be reached within the time mark range of the subsequent state node based on the time mark of the preceding state node. If it can be reached, establish a directed connection edge from the preceding state node to the subsequent state node. Add the capacity mark of the preceding state node and the capacity mark of the subsequent state node as the capacity propagation mark of the directed connection edge.

[0031] Traverse all state node pairs within the task cluster and establish directed connections, forming a directed state graph by connecting the state nodes and the directed connections.

[0032] Search for the minimum cost path that satisfies both time window and capacity constraints on the directed state graph, and output the order of transportation tasks accessing the minimum cost path as the vehicle route planning recommendation result, including:

[0033] Perform path search on the directed state graph, calculate the arrival time of each state node in the search path and the cumulative value of the capacity propagation mark of each directed connection edge along the path direction, perform relaxation adjustment on state nodes whose arrival time exceeds the state node time mark range or whose capacity propagation mark cumulative value exceeds the vehicle capacity limit, and record the time deviation and capacity overload, and generate candidate paths with relaxation marks.

[0034] The time deviation and capacity overload are weighted together to form the constraint violation penalty cost, which is then weighted and summed with the spatial distance cost to obtain the path evaluation value. The candidate path with the smallest path evaluation value is selected to continue the search and obtain the initial path.

[0035] Backtrack the state nodes with relaxation markers in the initial path, calculate the time window matching degree and capacity surplus between the transportation task and the adjacent state nodes based on the time deviation and capacity overload, reallocate the transportation task to the adjacent state node with the highest matching degree and the capacity surplus, and update the capacity propagation marker to obtain the reconstructed path that satisfies the time window constraint and capacity constraint.

[0036] The reconstruction path with the lowest spatial distance cost is selected as the minimum cost path, and the order of transportation task access corresponding to the minimum cost path is output as the vehicle route planning recommendation result.

[0037] For state nodes whose arrival time exceeds the state node time stamp range or whose capacity propagation stamp accumulation value exceeds the vehicle capacity limit, relaxation adjustment is performed and the time deviation and capacity overload are recorded. Candidate paths carrying relaxation stamps are generated, including:

[0038] For a state node whose arrival time exceeds the time mark range of the state node, calculate the time difference between the arrival time and the start or end time of the time mark as the time deviation, and expand the time mark range of the state node in the direction of the arrival time according to the time deviation to obtain the expanded time mark range.

[0039] For state nodes where the accumulated value of capacity propagation markers exceeds the vehicle capacity limit, the difference between the accumulated value of capacity propagation markers and the vehicle capacity limit is calculated as the capacity overload. The cargo demand of the transportation task corresponding to the state node is split according to the capacity overload, and the split cargo demand is marked as the demand to be reallocated.

[0040] The expanded time stamp range and the demand to be reallocated are encapsulated into a relaxation tag and bound to the state node to generate candidate paths carrying the relaxation tag.

[0041] This invention provides a logistics transportation vehicle route planning and recommendation system, the system comprising:

[0042] The data acquisition module is used to acquire a set of transportation tasks containing location information and time windows, as well as a set of vehicle resources containing capacity information and location information;

[0043] The task clustering module is used to construct a task association network based on the spatiotemporal transfer cost between transportation tasks, and to perform modular degree optimization segmentation on the task association network to obtain a set of task clusters.

[0044] The cluster center extraction module is used to project the transportation tasks within each task cluster into a time-space coordinate system, calculate the density gradient of the projected point set along the time axis, and extract the spatial location corresponding to the peak value of the density gradient as the cluster center.

[0045] The vehicle matching module is used to calculate the arrival time of each vehicle in the vehicle resource set to the cluster center. It constructs a fit matrix based on the matching degree between the arrival time of each vehicle and the time window of each transportation task in the corresponding task cluster. Based on the fit matrix, it performs global matching optimization to obtain the binding scheme between vehicles and task clusters.

[0046] The route planning module maps transportation tasks within a task cluster to state nodes carrying time and capacity markers according to the binding scheme. It constructs a directed state graph through marker propagation between state nodes, searches the directed state graph for the minimum cost path that satisfies the time window constraint and the capacity constraint, and outputs the transportation task access order corresponding to the minimum cost path as the vehicle route planning recommendation result.

[0047] One technical solution provided in this embodiment of the invention is an electronic device, including: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps in any of the aforementioned methods.

[0048] One technical solution provided in this embodiment of the invention is a computer-readable storage medium storing computer program instructions, which, when executed by a processor, implement the steps in any of the aforementioned methods.

[0049] This invention employs a modularity-optimized segmentation method based on spatiotemporal transfer costs, simultaneously considering the spatial distance and time window characteristics of transportation tasks for clustering, making the clustering results more consistent with actual delivery patterns. Cluster centers are determined by calculating the peak density gradient in the time-space coordinate system, fully utilizing the clustering characteristics of tasks in the time dimension and reducing the additional travel distance of vehicles. Global matching optimization using a fitness matrix achieves optimal allocation of vehicles and task clusters, avoiding the problem of uneven utilization of vehicle resources. Transportation tasks are mapped to state nodes carrying time and capacity markers, and a directed state graph is constructed, making the handling of time window constraints and capacity constraints more intuitive and efficient, reducing the computational complexity of the algorithm. The overall scheme meets real-time requirements while ensuring solution quality, improving the adaptability and robustness of the algorithm. Attached Figure Description

[0050] Figure 1 A flowchart of a logistics transportation vehicle route planning and recommendation method provided in an embodiment of the present invention;

[0051] Figure 2 This is a schematic diagram of the structure of a logistics transportation vehicle route planning and recommendation processing system according to an embodiment of the present invention. Detailed Implementation

[0052] like Figure 1 As shown, Figure 1A flowchart of a logistics transportation vehicle route planning and recommendation method provided in an embodiment of the present invention is included, the method comprising the following steps:

[0053] Step 101: Obtain a set of transportation tasks containing location information and time windows, and a set of vehicle resources containing capacity information and location information.

[0054] Step 102: Construct a task association network based on the spatiotemporal transfer cost between transportation tasks, and perform modularity optimization segmentation on the task association network to obtain a task cluster set.

[0055] In some embodiments of the present invention, step 102 may specifically include the following sub-steps:

[0056] Sub-step 1021: Calculate the spatial distance and time window interval between each transportation task in the transportation task set. Based on the time window interval, weight the spatial distance to obtain the spatiotemporal transfer cost between transportation tasks. Construct a task association network with transportation tasks as nodes and spatiotemporal transfer cost as connection weight.

[0057] Sub-step 1022: Initialize each node in the task association network as an independent cluster, and calculate the ratio of the sum of connection weights within each cluster to the sum of all connection weights in the task association network as the cluster density.

[0058] Sub-step 1023: Calculate the time span covered by the time window of the transportation task within each cluster as the cluster time dispersion, and combine the cluster compactness and the cluster time dispersion to construct the modularity quality index.

[0059] Sub-step 1024: Iteratively select the cluster that maximizes the improvement of the modularity quality index, merge and update the modularity quality index, until merging all clusters fails to improve the modularity quality index, and output the transportation task nodes contained in each cluster as a task cluster set.

[0060] Obtain a set of transportation tasks containing location information and time windows, and a set of vehicle resources containing capacity information and location information. Each transportation task includes the latitude and longitude coordinates of the pickup point and delivery point, the earliest available pickup time, and the latest required delivery time. Vehicle resources include the latitude and longitude coordinates of the vehicle's parking location and the vehicle's maximum load capacity.

[0061] Calculate the spatial distance between each transportation task in the transportation task set. For any two transportation tasks, extract the latitude and longitude coordinates of the delivery point of the first transportation task and the pickup point of the second transportation task, and calculate the actual road distance between the two points using the spherical distance formula. Perform this distance calculation on every pair of transportation tasks in the transportation task set to form a spatial distance matrix between tasks.

[0062] Calculate the time window interval between transportation tasks. Extract the latest delivery time of the first transportation task and the earliest pickup time of the second transportation task; the time difference between the two is the time window interval. If the first transportation task must be delivered before 2 PM on the same day, and the second transportation task can be picked up as early as 3 PM on the same day, the time window interval is 1 hour. If the earliest pickup time of the second transportation task is earlier than the latest delivery time of the first transportation task, the time window interval is recorded as 0.

[0063] The product of spatial distance and time window interval is used as the spatiotemporal transfer cost. When the spatial distance is 25 kilometers and the time window interval is 2 hours, the spatiotemporal transfer cost is 50. The larger the time window interval, the worse the connection between the two tasks. By multiplying, the influence of spatial distance is amplified, which significantly increases the transfer cost between task pairs that are difficult to connect in time.

[0064] A task association network is constructed by treating transportation tasks as nodes and spatiotemporal transfer costs as connection weights. Each transportation task corresponds to a node in the network, and there is an edge between any two nodes, with the weight of the edge being the spatiotemporal transfer cost between the corresponding tasks. The smaller the transfer cost, the smaller the connection weight between task pairs, indicating that these two tasks are more suitable to be executed sequentially by the same vehicle.

[0065] Initialize each node in the task association network as an independent cluster. Each transportation task node forms a separate cluster, and the number of clusters equals the total number of transportation tasks. Calculate the sum of connection weights within each cluster. Since each cluster initially contains only one node, there are no connections within the cluster, so the sum of connection weights within each cluster is 0. Calculate the sum of connection weights of all edges in the task association network, and use the ratio of the sum of connection weights within each cluster to the sum of all connection weights as the cluster density. Initially, the cluster density of all clusters is 0.

[0066] The time span covered by the time window of each transportation task within a cluster is calculated as the cluster's time dispersion. The minimum of the earliest pickup times and the maximum of the latest delivery times for all transportation tasks within a cluster are extracted; the difference between these two values ​​is the cluster's time dispersion. For example, if a cluster contains three transportation tasks with earliest pickup times of 8:00, 9:00, and 10:00, and latest delivery times of 12:00, 14:00, and 13:00, the cluster's time dispersion is 14:00 - 8:00 = 6 hours. Initially, each cluster contains only one task, and the cluster's time dispersion equals the task's latest delivery time minus its earliest pickup time.

[0067] A modularity quality index is constructed by combining intra-cluster compactness and cluster temporal dispersion. The modularity quality index is defined as follows: Where Q represents the modularity quality index, k represents the total number of current clusters, and W cW represents the sum of the connection weights of all edges within the c-th cluster. total T represents the sum of the connection weights of all edges in the task-associated network. c This represents the temporal dispersion of the c-th cluster, with α being the balance coefficient and a value of 0.01. This index comprehensively reflects the degree of correlation between tasks within the cluster and the concentration of their temporal distribution.

[0068] Iterate through all possible cluster pair combinations, calculate the new modularity quality index value after merging each pair, and select the cluster pair that maximizes the increase in modularity quality index for merging. When merging two clusters, the new cluster contains all nodes from the original two clusters, and the sum of connection weights and temporal dispersion within the new cluster are recalculated. After updating the modularity quality index, continue searching for the next optimal cluster pair to merge.

[0069] Determine if merging any of the possible clusters fails to improve the modularity quality index. Stop the iteration process when the modularity quality index of any two merged clusters is no higher than that before the merge. The resulting cluster partition is the optimal task cluster set. Output the transportation task nodes contained in each cluster as the task cluster set for subsequent vehicle route planning.

[0070] This invention characterizes the connection between tasks by measuring the spatiotemporal transfer cost, and automatically aggregates transportation tasks with strong spatiotemporal correlation into task clusters using a modularity optimization method. This takes into account the dual impact of spatial distance and time constraints, avoids the subjectivity and inefficiency of manual division, provides a reasonable task grouping basis for vehicle route planning, and improves the utilization efficiency of vehicle resources and the overall quality of transportation scheduling.

[0071] Step 103: For each task cluster in the task cluster set, project the transportation tasks within the task cluster onto the time-space coordinate system, calculate the density gradient of the projection point set in the time axis direction, and extract the spatial location corresponding to the peak value of the density gradient as the cluster center.

[0072] In some embodiments of the present invention, step 103 may specifically include the following sub-steps:

[0073] Sub-step 1031: For each task cluster in the task cluster set, extract the start time and location information of the time window of each transportation task in the task cluster. Construct a time-space coordinate system with the start time of the time window as the time axis and the location information as the space axis. Map each transportation task in the task cluster to the projection point in the time-space coordinate system to obtain the projection point set.

[0074] Sub-step 1032: Divide the time axis into multiple equal-width time periods according to the distribution range of the projection point set on the time axis, and count the number of projection points in each time period as the time period density.

[0075] Sub-step 1033: Calculate the ratio of the time interval density difference between adjacent time intervals to the time interval width to obtain the density gradient in the time axis direction, and extract the maximum value of the density gradient as the density gradient peak.

[0076] Sub-step 1034: Extract each projection point within the time period corresponding to the density gradient peak, calculate the time deviation between the start time of the time window of each projection point and the center time of the time period corresponding to the density gradient peak, perform attenuation weighting on the position information of each projection point based on the time deviation and find the geometric center, and take the spatial position of the geometric center as the cluster center.

[0077] For each task cluster in the task cluster set, the start time of the time window and location information of each transportation task within the task cluster are extracted. The start time of the time window is the earliest available pickup time for the transportation task, and the location information includes the latitude and longitude coordinates of the pickup point. A time-space coordinate system is constructed with the start time of the time window as the time axis and the location information as the spatial axis. The time axis uses 24-hour numerical representation, and the spatial axis uses a two-dimensional plane coordinate system, with the horizontal axis representing longitude and the vertical axis representing latitude.

[0078] The projected point set is obtained by mapping each transportation task within a task cluster to a projection point in a time-space coordinate system. If a task cluster contains 5 transportation tasks with their earliest pickup times of 8:00, 9:00, 10:00, 11:00, and 12:00, and their corresponding pickup point longitudes of 116.2°, 116.3°, 116.4°, 116.3°, and 116.5°, and latitudes of 39.8°, 39.9°, 40.0°, 39.9°, and 40.1°, then 5 projection points are formed in the time-space coordinate system. The time coordinate of each projection point corresponds to its earliest pickup time, and the spatial coordinate corresponds to the latitude and longitude of its pickup point.

[0079] The time axis is divided into multiple equal-width time periods based on the distribution range of the projected point set on the time axis. The minimum and maximum time coordinate values ​​of all projected points in the projected point set are obtained; the difference between these two values ​​represents the time distribution range. This time distribution range is then divided into several equal time periods, each with an equal width. For example, if the time distribution range of the projected point set is 4 hours (8:00 to 12:00), it is divided into four time periods, each with a width of 1 hour, corresponding to 8:00 to 9:00, 9:00 to 10:00, 10:00 to 11:00, and 11:00 to 12:00 respectively.

[0080] The number of projection points within each time period is counted as the time period density. All projection points in the projection point set are traversed, and each projection point's time coordinate value is determined to fall within a specific time period. The projection point count for that time period is incremented by 1. When the time period from 8:00 to 9:00 contains 1 projection point, the time period from 9:00 to 10:00 contains 2 projection points, the time period from 10:00 to 11:00 contains 1 projection point, and the time period from 11:00 to 12:00 contains 1 projection point, the time period densities are 1, 2, 1, and 1, respectively.

[0081] The density gradient along the time axis is obtained by calculating the ratio of the density difference between adjacent time periods to the time period width. For any two adjacent time periods, the density gradient at that location is obtained by subtracting the density of the previous time period from the density of the later time period and dividing the difference by the time period width. The density gradient values ​​calculated between all adjacent time periods are iterated through, and the maximum gradient value is selected as the density gradient peak. The location corresponding to the density gradient peak represents the region where the density of the projection point increases the fastest along the time axis, and this region contains a large number of transportation tasks with similar time windows.

[0082] Identify the adjacent time periods corresponding to the density gradient peak, and select the time period with the higher density as the time period corresponding to the density gradient peak. Obtain the start and end times of this time period, and filter all projection points in the projection point set whose time coordinate values ​​fall within this time period range. When the density gradient peak is 1 and corresponds to the time period from 9:00 to 10:00, extract two projection points within this time period.

[0083] Calculate the time deviation between the start time of the time window for each projection point and the center time of the time interval corresponding to the density gradient peak. The center time of the time interval corresponding to the density gradient peak is the average of the start and end times of that time interval. The time deviation is the absolute value of the difference between the projection point's time coordinate value and the center time. When the center time of the time interval is 9.5, and the time coordinate of a projection point is 9, then the time deviation of that projection point is 0.5h.

[0084] The positional information of each projection point is attenuated and weighted based on the time deviation, and the geometric center is then determined. The formula for calculating the weight of the projection point is as follows: , where w y Let represent the weight of the y-th projection point, e be the base of the natural logarithm ≈ 2.718, and τ y The time deviation of the y-th projection point is represented by β, which is an attenuation coefficient of 0.5. Projection points with larger time deviations have smaller weights, indicating a smaller contribution to the cluster center's location. The longitude coordinates of the cluster center are obtained by summing the products of the longitude coordinates of all projection points and their corresponding weights, and then dividing by the total weights. The latitude coordinates are calculated using the same method, and the combination of these two coordinates forms the spatial location of the cluster center.

[0085] This invention uses a time-space coordinate system to uniformly express the temporal and spatial attributes of transportation tasks. It uses density gradients to identify the clustering characteristics of tasks in the time dimension and uses time deviation as a weighting factor to calculate the cluster center position. This makes the cluster center reflect both the spatial distribution center of the tasks and the concentration trend of the task time window, providing a reference positioning point that takes into account both temporal and spatial characteristics for subsequent vehicle scheduling and route planning, thereby improving the pertinence of vehicle resource allocation and the rationality of route planning.

[0086] Step 104: Calculate the arrival time of each vehicle in the vehicle resource set to the cluster center. Construct an adaptation matrix based on the matching degree between the arrival time of each vehicle and the time window of each transportation task in the corresponding task cluster. Perform global matching optimization based on the adaptation matrix to obtain the binding scheme between vehicles and task clusters.

[0087] In some embodiments of the present invention, step 104 may specifically include the following sub-steps:

[0088] Sub-step 1041: For each vehicle in the vehicle resource set, obtain the spatial distance between the current position coordinates of the vehicle and the cluster center of each task cluster in the task cluster set, and calculate the arrival time of each vehicle in the vehicle resource set to the cluster center in combination with the vehicle's driving speed.

[0089] Sub-step 1042: For each vehicle and each task cluster, extract the start time of the time window of each transportation task within the task cluster, calculate the absolute value of the time deviation between the arrival time of each vehicle and the start time of each time window, and sum the absolute values ​​of the time deviation of each transportation task within the task cluster according to the weight of the goods in the transportation task to obtain the degree of matching between the arrival time of each vehicle and the time window of each transportation task within the corresponding task cluster.

[0090] Sub-step 1043: Construct a fit matrix using each vehicle in the vehicle resource set as the row index, each task cluster in the task cluster set as the column index, and the matching degree as the element value.

[0091] Sub-step 1044: Perform global matching optimization based on the fitness matrix. Iteratively select the matrix element with the smallest element value from the fitness matrix to establish the corresponding vehicle and task cluster binding relationship. Remove the corresponding row of the bound vehicle and the corresponding column of the task cluster from the fitness matrix. Repeat the selection and removal operation until all vehicles or all task clusters are bound to obtain the vehicle and task cluster binding scheme.

[0092] For each vehicle in the vehicle resource set, the spatial distance between the vehicle's current location coordinates and the cluster center of each task cluster in the task cluster set is obtained. The vehicle's current location coordinates are obtained in real time through onboard positioning equipment, including longitude and latitude information. The spatial location of the cluster center has been determined in the previous steps, also including longitude and latitude coordinates. The straight-line distance between the vehicle's current location and the cluster center is calculated using the Euclidean distance formula between two points. When the vehicle's current location has a longitude of 116.1 degrees and a latitude of 39.7 degrees, and the cluster center of a certain task cluster has a longitude of 116.4 degrees and a latitude of 40.0 degrees, the difference in longitude and latitude is converted into an actual distance, yielding a spatial distance of approximately 42 km between the two points.

[0093] The arrival time of each vehicle in the vehicle resource set to the cluster center is calculated based on its travel speed. Vehicle speed can be extracted from historical travel data (average speed) or a predetermined speed set according to road type. Dividing the spatial distance by the vehicle speed gives the time required for the vehicle to travel from its current location to the cluster center. When the spatial distance is 42 km and the average vehicle speed is 50 km / h, the required time is 42 / 50 = 0.84 h, or 50 min. Adding the required time to the current time gives the estimated arrival time of the vehicle to the cluster center. If the current time is 8:00, the vehicle's arrival time to the cluster center is 8:50.

[0094] For each vehicle and each task cluster, the start time of the time window for each transportation task within the task cluster is extracted. The start time of the time window is the earliest pickup time for the transportation task, reflecting the earliest time point at which the vehicle is allowed to start service for that transportation task. When a task cluster contains 3 transportation tasks with start times of 9:00, 10:00, and 11:00 respectively, these 3 times are extracted for subsequent matching degree calculation.

[0095] Calculate the absolute value of the time deviation between the arrival time of each vehicle and the start time of each time window. The time deviation is the vehicle arrival time minus the start time of the time window, and the absolute value is taken to eliminate positive and negative differences. When the vehicle arrival time is 8:50 (8.83), and the start time of a transportation task time window is 9:00, then the absolute value of the time deviation is 9 - 8.83 = 0.17h. The smaller the absolute value of the time deviation, the higher the degree of matching between the vehicle arrival time and the task time window, and the more timely the vehicles can respond to transportation needs.

[0096] The absolute values ​​of the time deviations for each transportation task within a task cluster are weighted and summed according to the cargo weight of the transportation task to obtain the degree of matching between the arrival time of each vehicle and the time window of each transportation task within the corresponding task cluster. The formula for calculating the degree of matching is: , of which M ij n represents the matching degree between the i-th vehicle and the j-th task cluster. jt represents the number of transportation tasks within the j-th task cluster. i Let s represent the arrival time of the i-th vehicle. jz b represents the start time of the time window for the z-th transportation task within the j-th task cluster. jz This represents the weight of the goods in the z-th transportation task within the j-th task cluster. If a task cluster contains 3 transportation tasks with weights of 2t, 3t, and 1t respectively, and their corresponding time window start times are 9:00, 10:00, and 11:00 respectively, and a vehicle arrives at 8:83, then the formula is (0.17×2) + (1.17×3) + (2.17×1) = 0.34 + 3.51 + 2.17 = 6.02. A smaller matching degree value indicates a better overall match between the vehicle's arrival time and the time window of the transportation tasks within the task cluster, prioritizing urgent tasks with larger cargo weights.

[0097] A fit matrix is ​​constructed using each vehicle in the vehicle resource set as a row index, each task cluster in the task cluster set as a column index, and the matching degree as the element value. When the vehicle resource set contains 4 vehicles and the task cluster set contains 3 task clusters, the fit matrix is ​​a 4x3 matrix. The element value in the i-th row and j-th column of the matrix represents the matching degree between the i-th vehicle and the j-th task cluster. The fit matrix is ​​constructed by iterating through all combinations of vehicles and task clusters, calculating the matching degree of each combination, and filling the corresponding position in the matrix.

[0098] Global matching optimization is performed based on the fitness matrix. The process involves traversing all elements in the fitness matrix, finding the element with the smallest value (the row index of which represents a vehicle, and the column index representing a task cluster), and establishing a binding relationship between the vehicle and the task cluster. The row corresponding to the bound vehicle is then removed from the fitness matrix, along with the column corresponding to the bound task cluster, resulting in a smaller matrix. The process of finding the smallest element in the new matrix, establishing a new binding relationship, and deleting the corresponding row and column is repeated. This process continues until all rows or columns in the fitness matrix are completely deleted, indicating that either all vehicles are bound to task clusters or all task clusters are bound to vehicles, thus obtaining the vehicle-task cluster binding scheme.

[0099] This invention constructs a fitness matrix that reflects the spatiotemporal matching relationship between vehicles and task clusters by calculating the deviation between vehicle arrival time and task time window and combining it with cargo weight for weighted evaluation. It adopts an iterative optimization method to achieve the global optimal binding between vehicles and task clusters, so that vehicle resources can prioritize responding to time-sensitive and large-volume transportation needs, reduce vehicle idle time and task waiting time, and improve vehicle utilization efficiency and transportation service timeliness.

[0100] Step 105: Based on the binding scheme, the transportation tasks within the task cluster are mapped to state nodes carrying time and capacity tags. A directed state graph is constructed through tag propagation between state nodes. The minimum cost path that satisfies the time window constraint and capacity constraint is searched on the directed state graph. The transportation task access order corresponding to the minimum cost path is output as the vehicle route planning recommendation result.

[0101] In some embodiments of the present invention, step 105, which maps transportation tasks within a task cluster to state nodes carrying time and capacity markers according to a binding scheme, and constructs a directed state graph through marker propagation between state nodes, may specifically include the following sub-steps:

[0102] Sub-step 1051: Extract the time window and cargo demand of each transportation task in the task cluster, encapsulate the time window as a time marker, encapsulate the cargo demand as a capacity marker, and map each transportation task as a state node carrying the time marker and capacity marker.

[0103] Sub-step 1052: Calculate the spatial distance between state nodes. Determine whether the state node can be reached within the time mark range of the subsequent state node based on the time mark of the preceding state node. If it can be reached, establish a directed connection edge from the preceding state node to the subsequent state node. Add the capacity mark of the preceding state node and the capacity mark of the subsequent state node as the capacity propagation mark of the directed connection edge.

[0104] Sub-step 1053: Traverse all state node pairs within the task cluster and establish directed connection edges, forming a directed state graph by connecting the state nodes and directed connection edges.

[0105] Extract the time window and cargo demand for each transportation task within a task cluster. The time window comprises the earliest and latest service times, defining the time range within which vehicles can begin providing service for that transportation task. Cargo demand represents the weight or volume of cargo that needs to be transported for that task. If a task cluster contains four transportation tasks with time windows of 9:00-11:00, 10:00-12:00, 11:00-13:00, and 12:00-14:00, corresponding to cargo demands of 2t, 3t, 1t, and 2t respectively, extract the time window and cargo demand information for each task.

[0106] The time window is encapsulated as a timestamp, which is stored as a pair of values ​​representing the earliest and latest service times, forming the time constraint boundary of the transportation task. The time window from 9:00 to 11:00 is encapsulated as timestamps 9 and 11, and the time window from 10:00 to 12:00 is encapsulated as timestamps 10 and 12. By encapsulating the time windows with timestamps, the time window constraints are transformed into comparable numerical ranges.

[0107] The cargo demand is encapsulated as a capacity tag, which is stored in numerical form, reflecting the extent to which the transportation task occupies the vehicle's load capacity. A cargo demand of 2 tons is encapsulated as capacity tag 2, and a cargo demand of 3 tons is encapsulated as capacity tag 3. The value of the capacity tag directly corresponds to the tonnage of cargo that the transportation task needs to carry.

[0108] Each transportation task is mapped to a state node carrying a time stamp and a capacity stamp. A state node is generated for each transportation task, carrying both its time stamp and capacity stamp. The state node also contains the location coordinates of the transportation task, used for subsequent calculations of the spatial distance between nodes. When four transportation tasks are mapped to four state nodes, each state node contains three types of attribute information: time stamp, capacity stamp, and location coordinates, fully describing the time constraints, capacity requirements, and spatial location of the transportation task.

[0109] For any two state nodes, their respective position coordinates are extracted, and the straight-line distance between the two coordinates is calculated using the Euclidean distance formula. The spatial distance between state node A and state node B is 20km, and the spatial distance between state node B and state node C is 15km. The calculated spatial distances are used to determine whether the vehicle can complete the journey between the nodes within the time window constraint.

[0110] The earliest service time of the preceding state node is selected as the time when the vehicle departs from that node. The spatial distance between nodes is divided by the vehicle's speed to obtain the travel time. The two are added together to obtain the estimated time for the vehicle to reach the subsequent state node.

[0111] Determine if the estimated time falls within the time window of the subsequent state node. If the current state node's time is marked as 9:00 to 11:00, the distance between nodes is 20km, and the vehicle speed is 50km / h, the travel time is 20 / 50 = 0.4h, or 24min. The estimated time for the vehicle to arrive at the subsequent node is 9:24. If the subsequent state node's time is marked as 10:00 to 12:00, the estimated time of 9:24 is earlier than the earliest service time of 10:00, but it can arrive before the time window closes. The vehicle needs to wait at the subsequent node until 10:00 before starting service, and is therefore considered to be able to arrive. If the subsequent state node's time is marked as 9:00 to 9:20, the estimated time of 9:24 is later than the latest service time of 9:20, and is therefore considered to be unable to arrive within the time window.

[0112] When it is determined that a vehicle can reach a subsequent node from a preceding node within the time window constraint, a directed edge is established from the preceding state node to the subsequent state node. This directed edge indicates that the vehicle can complete its service at the preceding node and then travel to the subsequent node to provide service within the time window constraint. The directed edge carries edge weight information, which is the spatial distance between nodes, reflecting the travel cost from the preceding node to the subsequent node. For example, a directed edge is established from state node A to state node B, with an edge weight of 20km.

[0113] The capacity markers of the preceding and subsequent state nodes are summed to form the capacity propagation marker for the directed connection edge.

[0114] When the capacity of the preceding node is marked as 2t and the capacity of the subsequent node is marked as 3t, the capacity propagation mark of the directed connection edge is: 2+3=5t. The capacity propagation mark represents the total amount of cargo carried by the vehicle when it travels along the directed connection edge and reaches the subsequent node. It is used to determine whether the vehicle is overloaded and to ensure that the total cargo carried by the vehicle throughout the entire path does not exceed the vehicle's maximum load limit.

[0115] For each pair of state nodes within a task cluster, the spatial distance is calculated, temporal reachability is determined, directed edges are established, and capacity propagation markers are set using the aforementioned method. When the task cluster contains 4 state nodes, theoretically, 12 pairs of node combinations need to be determined, i.e., combinations where each node acts as a predecessor node and is followed by 3 other nodes. For each pair of node combinations that meet the temporal reachability condition, a directed edge is established. State node A can reach both state nodes B and C, so two directed edges are established; state node B can only reach state node D, so one directed edge is established. Some node pairs may not be able to establish a connection due to time window mismatch, and some node pairs may establish unidirectional connections instead of bidirectional connections.

[0116] A directed state graph is formed by combining state nodes and directed edges. The directed state graph uses state nodes as vertices and directed edges as edges to form a network structure. Each node in the graph carries a time stamp and a capacity stamp, and each edge carries an edge weight and a capacity propagation stamp. When four state nodes are combined with six directed edges, a directed state graph with four vertices and six edges is formed. The directed state graph fully depicts the reachability and cost relationships between transportation tasks within a task cluster under time and capacity constraints, providing a structured search space for subsequent pathfinding.

[0117] This invention encapsulates transportation task constraints into an operable data structure through the encapsulation of time and capacity markers. State node mapping enables a structured expression of task attributes, the establishment of directed edges characterizes the spatiotemporal reachability relationships between nodes, and capacity propagation markers enable dynamic tracking of load constraints. The construction of the directed state graph provides a complete search space for subsequent path searching, improving the accuracy and feasibility of route planning.

[0118] In step 105, searching for the minimum-cost path that satisfies both the time window and capacity constraints on the directed state graph, and outputting the transportation task access order corresponding to the minimum-cost path as the vehicle route planning recommendation result, also includes:

[0119] Perform path search on the directed state graph, calculate the arrival time of each state node in the search path and the cumulative value of the capacity propagation mark of each directed connection edge along the path direction, perform relaxation adjustment on state nodes whose arrival time exceeds the state node time mark range or whose capacity propagation mark cumulative value exceeds the vehicle capacity limit, and record the time deviation and capacity overload, and generate candidate paths with relaxation marks.

[0120] The time deviation and capacity overload are weighted together to form the constraint violation penalty cost, which is then weighted and summed with the spatial distance cost to obtain the path evaluation value. The candidate path with the smallest path evaluation value is selected to continue the search and obtain the initial path.

[0121] Backtrack the state nodes with relaxation markers in the initial path, calculate the time window matching degree and capacity surplus between the transportation task and the adjacent state nodes based on the time deviation and capacity overload, reallocate the transportation task to the adjacent state node with the highest matching degree and the capacity surplus, and update the capacity propagation marker to obtain the reconstructed path that satisfies the time window constraint and capacity constraint.

[0122] The reconstruction path with the lowest spatial distance cost is selected as the minimum cost path, and the order of transportation task access corresponding to the minimum cost path is output as the vehicle route planning recommendation result.

[0123] Perform a path search on the directed state graph. Starting from the initial state node, visit subsequent state nodes along the directed edges to form a path. During the path search, track the vehicle's arrival time and cumulative cargo load at each state node. Select state node A as the starting node, and the vehicle visits state nodes B, C, and D sequentially along the directed edges to form a search path containing four state nodes.

[0124] The vehicle departs from the preceding state node. The travel time is calculated based on the spatial distance between nodes and the vehicle's speed. The arrival time at the current node is obtained by adding the service completion time of the preceding node to the travel time. The vehicle's service time at state node A is 9:00. The distance from state node A to state node B is 20km. The vehicle speed is 50km / h, the travel time is 24 minutes, and the vehicle arrives at state node B at 9:24. After staying at state node B for 30 minutes, the vehicle departs at 9:54. The distance to state node C is 15km, the travel time is 18 minutes, and the vehicle arrives at state node C at 10:12.

[0125] As the vehicle visits each state node along the path, the cumulative cargo load increases with the number of nodes visited. The vehicle starts with an initial cargo load of 0t from the starting node. Upon reaching state node A, the cargo load increases by 2t from that node's capacity marker, bringing the cumulative cargo load to 2t. The vehicle continues to state node B, where the cargo load increases by 3t from that node's capacity marker, bringing the cumulative cargo load to 5t. The vehicle continues to state node C, where the cargo load increases by 1t from that node's capacity marker, bringing the cumulative cargo load to 6t.

[0126] The calculated arrival time is compared with the timestamp of the status node to check if the arrival time falls within the time window. Status node B's timestamp is from 10:00 to 12:00. The vehicle's arrival time of 9:24 is earlier than the earliest service time of 10:00, so the arrival time is determined to be within the timestamp range, but waiting is required. Status node D's timestamp is from 9:00 to 9:30. The vehicle's arrival time of 10:30 is later than the latest service time of 9:30, so the arrival time is determined to be outside the timestamp range, and the time deviation is recorded as 60 minutes.

[0127] The calculated cumulative load is compared with the vehicle's maximum load limit. The vehicle's maximum load is 5 tons. When the cumulative load reaches 6 tons, it exceeds the vehicle's capacity limit by 1 ton, and is therefore deemed overloaded. The overload amount is recorded as 1 ton.

[0128] For state nodes that exceed constraints, relaxation adjustments are performed and relaxation flags are attached. Vehicles are allowed to access these state nodes beyond the time window or load limit, but the time deviation and capacity overload are recorded as the degree of constraint violation. The relaxation flag contains the time deviation and capacity overload information for that node. State node D carries a relaxation flag containing a time deviation of 60 minutes and a capacity overload of 0 tons, while state node C carries a relaxation flag containing a time deviation of 0 minutes and a capacity overload of 1 ton. Candidate paths carrying relaxation flags are generated, including the state node access order, arrival time of each node, cumulative cargo load, and time deviation and capacity overload information.

[0129] The time deviation and capacity overload are weighted together to form the constraint violation penalty cost, and then weighted together with the spatial distance cost to form the path evaluation value.

[0130] The path evaluation value is calculated as follows: Where E is the path evaluation value, and D is the path evaluation value. total The total spatial distance cost of the path. This represents the sum of time deviations for all state nodes along the path. Let A be the total capacity overload of all state nodes in the path, B be the weighting coefficient of spatial distance cost, and γ be the weighting coefficient of time deviation penalty. The total spatial distance cost of the candidate path is 55km, the total time deviation is 60min, and the total capacity overload is 1t. The weighting coefficients are set to 1 for spatial distance cost, 0.5 for time deviation penalty, and 10 for capacity overload penalty. The path evaluation value is 95.

[0131] For all generated candidate paths, calculate their path evaluation values. Select the candidate path with the smallest evaluation value and continue exploring other possible access paths starting from the end state node of that path. Repeat the path search, arrival time calculation, capacity accumulation, constraint judgment, relaxation adjustment, and path evaluation process. After searching all possible path combinations, obtain the initial path with the smallest path evaluation value.

[0132] Tracing back through the initial path, identify the state nodes carrying relaxation markers and those that violate the constraints. The initial path includes state nodes A, B, C, and D, where state nodes C and D carry relaxation markers.

[0133] The time window matching degree between the transportation task and adjacent state nodes is calculated based on the time deviation. The time window matching degree is calculated as follows: , of which M time For time window matching degree, T a T is the estimated time for the vehicles to arrive at the mission after being reassigned. o This represents the midpoint of the task's time window. The time window for state node D is from 9:00 to 9:30, with the midpoint at 9:15. After the transportation task for state node D is reassigned to state node B, the estimated arrival time of the vehicle from state node B is 9:40, resulting in a time window matching degree of 0.038. After the transportation task for state node D is reassigned to state node A, the estimated arrival time of the vehicle from state node A is 9:10, resulting in a time window matching degree of 0.167.

[0134] The capacity reserve between the transportation task and adjacent state nodes is calculated based on the capacity overload. The capacity reserve is the vehicle's maximum load capacity minus the cumulative load after redistribution. The vehicle's maximum load capacity is 5t. After redistributing state node C to state node B, the cumulative load on the path is 4t, and the capacity reserve is 1t. After redistributing state node C to state node A, the cumulative load on the path is 3t, and the capacity reserve is 2t.

[0135] Compare the time window matching degree and capacity surplus of each adjacent state node, and select the adjacent state node with the highest time window matching degree and a positive capacity surplus as the target for the reassignment of the transportation task. State node D is reassigned to state node A, and state node C is reassigned to state node A. Based on the new assignment position of the transportation task, recalculate the capacity propagation mark of each directed connection edge in the path, and re-accumulate the capacity propagation mark along the new path direction to obtain a reconstructed path that satisfies the time window constraint and the capacity constraint.

[0136] Calculate the total spatial distance cost for all reconstructed paths that meet the constraints, and select the reconstructed path with the minimum cost as the final path. Output the order of transportation task access corresponding to the path with the minimum cost as the vehicle route planning recommendation result, and convert the arrangement order of each state node in the path with the minimum cost into a recommended order for vehicles to access each transportation task in sequence.

[0137] This invention expands the search space coverage through a relaxation mechanism, and the penalty cost for constraint violation enables path evaluation to balance distance cost and constraint satisfaction. The transportation task reallocation mechanism optimizes and adjusts based on time window matching degree and capacity surplus, transforming constraint-violating paths into feasible paths that satisfy all constraints, thereby improving the executability and economy of route planning.

[0138] The process of performing relaxation adjustment and recording the time deviation and capacity overload for state nodes whose arrival time exceeds the state node time stamp range or whose capacity propagation stamp accumulation value exceeds the vehicle capacity limit, and generating candidate paths carrying relaxation stamps, further includes:

[0139] For a state node whose arrival time exceeds the time mark range of the state node, calculate the time difference between the arrival time and the start or end time of the time mark as the time deviation, and expand the time mark range of the state node in the direction of the arrival time according to the time deviation to obtain the expanded time mark range.

[0140] For state nodes where the accumulated value of capacity propagation markers exceeds the vehicle capacity limit, the difference between the accumulated value of capacity propagation markers and the vehicle capacity limit is calculated as the capacity overload. The cargo demand of the transportation task corresponding to the state node is split according to the capacity overload, and the split cargo demand is marked as the demand to be reallocated.

[0141] The expanded time stamp range and the demand to be reallocated are encapsulated into a relaxation tag and bound to the state node to generate candidate paths carrying the relaxation tag.

[0142] For state nodes whose arrival time exceeds the time marker range, it is necessary to calculate the time deviation and expand the time marker range. Check the vehicle's arrival time at the state node against the time window range defined by the state node's time marker to determine whether the arrival time is earlier or later than the time window's start or end time. State node E has a time marker range of 10:00 to 12:00. The vehicle arrives at 9:30, which is earlier than the time window's start time of 10:00. Calculate the time difference between the arrival time and the time marker's start time. Subtracting 10:00 from 9:30 yields a time difference of 30 minutes, which is the time deviation.

[0143] The time stamp range of the status node is expanded towards the arrival time by the time deviation. Since the arrival time is earlier than the start time of the time window, the start time of the time stamp range needs to be shifted forward. The original start time of the time stamp range was 10:00. Shifting it forward by 30 minutes, the start time of the expanded time stamp range is adjusted to 9:30, while the end time remains unchanged at 12:00. The expanded time stamp range is from 9:30 to 12:00. The time stamp range of the status node is from 14:00 to 16:00. The vehicle arrives at 16:45, which is later than the end time of the time window at 16:00. The time difference between the arrival time and the end time of the time stamp is calculated. Subtracting 16:45 from 16:00 gives a time difference of 45 minutes, which is the time deviation. Since the arrival time is later than the end time of the time window, the end time of the time stamp range needs to be shifted backward. The original time stamp range ended at 16:00. It was shifted forward by 45 minutes, and the end time of the expanded time stamp range was adjusted to 16:45. The start time remained unchanged at 14:00. The expanded time stamp range is from 14:00 to 16:45.

[0144] Obtain the accumulated capacity propagation marker value of the vehicle at this state node. This accumulated value represents the cumulative cargo load of the vehicle after visiting this node. The vehicle's maximum load capacity is 8t. After the vehicle visits state node G, the accumulated capacity propagation marker value is 10t, which exceeds the vehicle's capacity limit. Calculate the difference between the accumulated capacity propagation marker value and the vehicle's capacity limit. Subtracting 8t from 10t yields a difference of 2t, which is the capacity overload.

[0145] The cargo demand for the transportation task corresponding to each state node is broken down by capacity overload. State node G has a cargo demand of 3 tons and a capacity overload of 2 tons. The 3 tons cargo demand is divided into two parts: the first part is the cargo demand minus the capacity overload, calculated as 1 t; the second part is the capacity overload of 2 tons. The first part, 1 t, is retained in the original time and capacity markers of state node G, while the second part, 2 t, is marked as demand to be reallocated. Demand to be reallocated indicates that this portion of cargo demand cannot be carried at the current path location and needs to be reallocated to other state nodes or other vehicle paths during subsequent path adjustments.

[0146] The transport task corresponding to state node Xin has a cargo demand of 5t. After a vehicle visits this node, the cumulative value of the capacity propagation mark is 11t. The maximum load of the vehicle is 8t, and the capacity overload is 3t. The cargo demand of 5t is split into two parts: the first part, 2t, is retained in state node Xin, and the second part, 3t, is marked as the demand to be reallocated.

[0147] The expanded time stamp range is encapsulated as a component of the relaxation tag. The relaxation tag contains the original time stamp range, the expanded time stamp range, and time deviation information. The relaxation tag for state node E contains the original time stamp range of 10:00 to 12:00, the expanded time stamp range of 9:30 to 12:00, and a time deviation of 30 minutes. The expanded time stamp range is recorded in the relaxation tag for subsequent path evaluation to determine whether the state node meets the time constraints, and the time deviation is recorded for calculating the constraint violation penalty cost.

[0148] The demand to be reallocated is encapsulated as a component of the relaxation tag. The relaxation tag contains the original cargo demand, the cargo demand retained after splitting, the demand to be reallocated, and capacity overload information. The relaxation tag of state node G contains the original cargo demand of 3t, the cargo demand retained after splitting of 1t, the demand to be reallocated of 2t, and the capacity overload of 2t. The relaxation tag records the demand to be reallocated so that this portion of the cargo demand can be reallocated to a suitable location during subsequent route adjustments, and records the capacity overload to calculate the penalty cost for constraint violation.

[0149] The relaxation flags, containing the extended time stamp range and the demand to be reallocated, are bound to the corresponding state nodes. State node E's relaxation flag includes the extended time stamp range of 9:30 to 12:00 and a time deviation of 30 minutes. State node G's relaxation flag includes the demand to be reallocated of 2 tons and a capacity overload of 2 tons. Some state nodes may exceed both the time window constraint and the capacity constraint simultaneously; the relaxation flags of these state nodes include both the extended time stamp range and the demand to be reallocated. State node Ren's time stamp range is 8:00 to 9:00, the vehicle arrival time is 9:20, the time deviation is 20 minutes, and the extended time stamp range is 8:00 to 9:20. The cargo demand corresponding to state node Ren is 4 tons, the accumulated capacity propagation flag after the vehicle visits this node is 9 tons, the vehicle's maximum load is 8 tons, the capacity overload is 1 t, the cargo demand retained after splitting is 3 tons, and the demand to be reallocated is 1 t. The relaxation flag bound to the state node Ren also includes the extended time flag range of 8:00 to 9:20, the time deviation of 20 minutes, the demand to be reallocated of 1 t, and the capacity overload of 1 t.

[0150] Candidate paths carrying relaxation markers are generated. Each candidate path includes a sequence of visited state nodes and relaxation markers bound to each state node. The candidate path visits state nodes E, G, and R. State node E carries a relaxation marker containing a time deviation of 30 minutes, state node G carries a relaxation marker containing a capacity overload of 2 tons, and state node R carries a relaxation marker containing both a time deviation of 20 minutes and a capacity overload of 1 ton. The relaxation marker information of the candidate paths is used in subsequent path evaluation and adjustment processes to identify the location and degree of constraint violations by state nodes.

[0151] This invention achieves flexible handling of time window constraints through the dynamic expansion of the time stamp range, and achieves flexible adjustment of capacity constraints through the splitting of cargo demand and the marking of items to be reallocated. The encapsulation and binding mechanism of the relaxation markers stores constraint violation information in a structured manner, providing a data foundation for the calculation of penalty costs in subsequent path evaluation and the reallocation of demand in path adjustment. This improves the fault tolerance and optimization space of the path search process, and enhances the robustness and practicality of route planning.

[0152] like Figure 2 As shown, Figure 2 This is a schematic diagram of a logistics transportation vehicle route planning and recommendation processing system provided in an embodiment of the present invention. The system includes:

[0153] The data acquisition module 201 is used to acquire a set of transportation tasks containing location information and time windows, and a set of vehicle resources containing capacity information and location information;

[0154] Task clustering module 202 is used to construct a task association network based on the spatiotemporal transfer cost between transportation tasks, and to perform modular degree optimization segmentation on the task association network to obtain a set of task clusters.

[0155] The cluster center extraction module 203 is used to project the transportation tasks within the task clusters into the time-space coordinate system for each task cluster in the task cluster set, calculate the density gradient of the projection point set in the time axis direction, and extract the spatial position corresponding to the peak of the density gradient as the cluster center.

[0156] The vehicle matching module 204 is used to calculate the arrival time of each vehicle in the vehicle resource set to the cluster center, construct an adaptation matrix based on the matching degree between the arrival time of each vehicle and the time window of each transportation task in the corresponding task cluster, and perform global matching optimization based on the adaptation matrix to obtain the binding scheme between vehicles and task clusters.

[0157] The route planning module 205 is used to map transportation tasks within a task cluster into state nodes carrying time and capacity tags according to the binding scheme. A directed state graph is constructed through tag propagation between state nodes. The module searches for the minimum cost path that satisfies the time window constraint and the capacity constraint on the directed state graph. The order of transportation task access corresponding to the minimum cost path is output as the vehicle route planning recommendation result.

[0158] One technical solution provided in this embodiment of the invention is an electronic device, including: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps in any of the aforementioned methods.

[0159] One technical solution provided in this embodiment of the invention is a computer-readable storage medium storing a computer program, wherein the processor executes the computer program to implement the steps in any of the aforementioned methods.

[0160] The specific embodiments described above are preferred embodiments of the present invention and are not intended to limit the specific scope of the present invention. The scope of the present invention includes, but is not limited to, these specific embodiments. All equivalent changes made in accordance with the shape and structure of the present invention are within the protection scope of the present invention.

Claims

1. A method for route planning and recommendation of logistics transportation vehicles, characterized in that, Includes the following steps: Obtain a set of transportation tasks containing location information and time windows, and a set of vehicle resources containing capacity information and location information; A task association network is constructed based on the spatiotemporal transfer cost between transportation tasks, and a task cluster set is obtained by performing modularity optimization segmentation on the task association network. For each task cluster in the task cluster set, the transportation tasks within the task cluster are projected onto the time-space coordinate system, the density gradient of the projected point set in the time axis direction is calculated, and the spatial position corresponding to the peak of the density gradient is extracted as the cluster center. Calculate the arrival time of each vehicle in the vehicle resource set to the cluster center, construct an adaptation matrix based on the matching degree between the arrival time of each vehicle and the time window of each transportation task in the corresponding task cluster, and perform global matching optimization based on the adaptation matrix to obtain the binding scheme between vehicles and task clusters. Based on the binding scheme, transportation tasks within a task cluster are mapped to state nodes carrying time and capacity markers. A directed state graph is constructed through marker propagation between state nodes. The minimum cost path that satisfies the time window constraint and capacity constraint is searched on the directed state graph. The transportation task access order corresponding to the minimum cost path is output as the vehicle route planning recommendation result.

2. The method according to claim 1, characterized in that, Based on the spatiotemporal transfer cost between transportation tasks, a task association network is constructed. Modularity optimization segmentation is performed on this network to obtain a set of task clusters, including: Calculate the spatial distance and time window interval between each transportation task in the transportation task set. Based on the time window interval, weight the spatial distance to obtain the spatiotemporal transfer cost between transportation tasks. Construct a task association network with transportation tasks as nodes and spatiotemporal transfer cost as connection weight. Each node in the task association network is initialized as an independent cluster, and the ratio of the sum of the connection weights within each cluster to the sum of the connection weights of the entire task association network is calculated as the cluster density. The time span covered by the time window of the transportation task within each cluster is calculated as the cluster temporal dispersion. The cluster compactness and cluster temporal dispersion are combined to construct a modularity quality index. Iteratively select the cluster that maximizes the improvement in modularity quality index, merge it, and update the modularity quality index until merging all clusters fails to improve the modularity quality index. Output the transportation task nodes contained in each cluster as a task cluster set.

3. The method according to claim 1, characterized in that, For each task cluster in the task cluster set, the transportation tasks within the task cluster are projected onto a time-space coordinate system. The density gradient of the projected point set along the time axis is calculated, and the spatial location corresponding to the peak of the density gradient is extracted as the cluster center, including: For each task cluster in the task cluster set, extract the start time and location information of the time window of each transportation task in the task cluster. Construct a time-space coordinate system with the start time of the time window as the time axis and the location information as the spatial axis. Map each transportation task in the task cluster to the projection point in the time-space coordinate system to obtain the projection point set. Based on the distribution range of the projection point set on the time axis, the time axis is divided into multiple equal-width time periods, and the number of projection points in each time period is counted as the time period density. The density gradient along the time axis is obtained by calculating the ratio of the density difference between adjacent time periods to the width of the time period, and the maximum value of the density gradient is extracted as the density gradient peak. Extract each projection point within the time period corresponding to the density gradient peak, calculate the time deviation between the start time of the time window of each projection point and the center time of the time period corresponding to the density gradient peak, perform attenuation weighting on the position information of each projection point based on the time deviation, and find the geometric center. The spatial position of the geometric center is taken as the cluster center.

4. The method according to claim 1, characterized in that, Calculate the arrival time of each vehicle in the vehicle resource set to the cluster center. Construct a fit matrix based on the matching degree between the arrival time of each vehicle and the time window of each transportation task within the corresponding task cluster. Perform global matching optimization based on the fit matrix to obtain the vehicle-task cluster binding scheme, including: For each vehicle in the vehicle resource set, obtain the spatial distance between the vehicle's current position coordinates and the cluster center of each task cluster in the task cluster set, and calculate the arrival time of each vehicle in the vehicle resource set to the cluster center by combining the vehicle's driving speed. For each vehicle and each task cluster, the start time of the time window of each transportation task within the task cluster is extracted, the absolute value of the time deviation between the arrival time of each vehicle and the start time of each time window is calculated, and the absolute value of the time deviation of each transportation task within the task cluster is weighted and summed according to the weight of the goods in the transportation task to obtain the degree of matching between the arrival time of each vehicle and the time window of each transportation task within the corresponding task cluster. A fit matrix is ​​constructed using each vehicle in the vehicle resource set as the row index, each task cluster in the task cluster set as the column index, and the matching degree as the element value. Global matching optimization is performed based on the fitness matrix. The matrix element with the smallest value is iteratively selected from the fitness matrix to establish the corresponding vehicle and task cluster binding relationship. The row corresponding to the bound vehicle and the column corresponding to the task cluster are removed from the fitness matrix. The selection and removal operations are repeated until all vehicles or all task clusters are bound to obtain the vehicle and task cluster binding scheme.

5. The method according to claim 1, characterized in that, Based on the binding scheme, transportation tasks within a task cluster are mapped to state nodes carrying time and capacity markers. A directed state graph is constructed through marker propagation between state nodes, including: Extract the time window and cargo demand of each transportation task within the task cluster, encapsulate the time window as a time stamp and the cargo demand as a capacity stamp, and map each transportation task as a state node carrying the time stamp and capacity stamp. Calculate the spatial distance between state nodes. Determine whether the state node can be reached within the time mark range of the subsequent state node based on the time mark of the preceding state node. If it can be reached, establish a directed connection edge from the preceding state node to the subsequent state node. Add the capacity mark of the preceding state node and the capacity mark of the subsequent state node as the capacity propagation mark of the directed connection edge. Traverse all state node pairs within the task cluster and establish directed connections, forming a directed state graph by connecting the state nodes and the directed connections.

6. The method according to claim 5, characterized in that, Search for the minimum cost path that satisfies both time window and capacity constraints on the directed state graph, and output the order of transportation tasks accessing the minimum cost path as the vehicle route planning recommendation result, including: Perform path search on the directed state graph, calculate the arrival time of each state node in the search path and the cumulative value of the capacity propagation mark of each directed connection edge along the path direction, perform relaxation adjustment on state nodes whose arrival time exceeds the state node time mark range or whose capacity propagation mark cumulative value exceeds the vehicle capacity limit, and record the time deviation and capacity overload, and generate candidate paths with relaxation marks. The time deviation and capacity overload are weighted together to form the constraint violation penalty cost, which is then weighted and summed with the spatial distance cost to obtain the path evaluation value. The candidate path with the smallest path evaluation value is selected to continue the search and obtain the initial path. Backtrack the state nodes with relaxation markers in the initial path, calculate the time window matching degree and capacity surplus between the transportation task and the adjacent state nodes based on the time deviation and capacity overload, reallocate the transportation task to the adjacent state node with the highest matching degree and the capacity surplus, and update the capacity propagation marker to obtain the reconstructed path that satisfies the time window constraint and capacity constraint. The reconstruction path with the lowest spatial distance cost is selected as the minimum cost path, and the order of transportation task access corresponding to the minimum cost path is output as the vehicle route planning recommendation result.

7. The method according to claim 6, characterized in that, For state nodes whose arrival time exceeds the state node time stamp range or whose capacity propagation stamp accumulation value exceeds the vehicle capacity limit, relaxation adjustment is performed and the time deviation and capacity overload are recorded. Candidate paths carrying relaxation stamps are generated, including: For a state node whose arrival time exceeds the time mark range of the state node, calculate the time difference between the arrival time and the start or end time of the time mark as the time deviation, and expand the time mark range of the state node in the direction of the arrival time according to the time deviation to obtain the expanded time mark range. For state nodes where the accumulated value of capacity propagation markers exceeds the vehicle capacity limit, the difference between the accumulated value of capacity propagation markers and the vehicle capacity limit is calculated as the capacity overload. The cargo demand of the transportation task corresponding to the state node is split according to the capacity overload, and the split cargo demand is marked as the demand to be reallocated. The expanded time stamp range and the demand to be reallocated are encapsulated into a relaxation tag and bound to the state node to generate candidate paths carrying the relaxation tag.

8. A logistics transportation vehicle route planning and recommendation processing system, used to implement the method described in any one of claims 1-7, characterized in that, The system includes: The data acquisition module is used to acquire a set of transportation tasks containing location information and time windows, as well as a set of vehicle resources containing capacity information and location information; The task clustering module is used to construct a task association network based on the spatiotemporal transfer cost between transportation tasks, and to perform modular degree optimization segmentation on the task association network to obtain a set of task clusters. The cluster center extraction module is used to project the transportation tasks within each task cluster into a time-space coordinate system, calculate the density gradient of the projected point set along the time axis, and extract the spatial location corresponding to the peak value of the density gradient as the cluster center. The vehicle matching module is used to calculate the arrival time of each vehicle in the vehicle resource set to the cluster center. It constructs a fit matrix based on the matching degree between the arrival time of each vehicle and the time window of each transportation task in the corresponding task cluster. Based on the fit matrix, it performs global matching optimization to obtain the binding scheme between vehicles and task clusters. The route planning module maps transportation tasks within a task cluster to state nodes carrying time and capacity markers according to the binding scheme. It constructs a directed state graph through marker propagation between state nodes, searches the directed state graph for the minimum cost path that satisfies the time window constraint and the capacity constraint, and outputs the transportation task access order corresponding to the minimum cost path as the vehicle route planning recommendation result.

9. An electronic device, characterized in that, include: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the computer program, implements the steps of the method as described in any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer program instructions that, when executed by a processor, implement the steps of the method as described in any one of claims 1 to 7.