LPG distribution path matrix generation and scheduling method
By constructing a dynamic graph of LPG delivery, generating comprehensive non-negative edge weights, dividing candidate frontier groups, and selecting key hub nodes, the problems of high computation time for multi-source path matrix calculation and high cost of dynamic disturbance recalculation in LPG delivery scheduling are solved, and efficient path matrix generation and optimization are achieved.
Patent Information
- Application Number
- CN202611551231.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-10-08
- Publication Date
- 2026-11-27
AI Technical Summary
Existing technologies in LPG delivery scheduling suffer from high time consumption for full calculation of multi-source path matrices, high cost of full map recalculation after dynamic disturbances, disconnect between LPG hazardous materials safety constraints and path calculation process, and the difference in simulation execution cannot drive the self-optimization of path calculation parameters.
Construct a dynamic graph of LPG delivery, generate comprehensive non-negative edge weights, divide candidate frontier groups and select key hub nodes, perform finite-step edge relaxation and recursive expansion, establish a path dependency index, optimize the path matrix through digital twin simulation, and locally recalculate the matrix for incremental updates.
It improves the efficiency of multi-source path matrix generation and updating, enhances the adaptability to LPG business security constraints and dynamic execution differences, and reduces computational overhead and recalculation costs.
Smart Images

Figure CN123180882A_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the field of logistics distribution scheduling technology, specifically involving a method for generating and scheduling LPG delivery path matrices. Background Technology
[0002] Liquefied petroleum gas (LPG) delivery to homes is a crucial component of the urban gas supply system. Its dispatching process involves route planning and delivery execution among multiple stations, delivery personnel, order nodes, and transfer points. With the development of bottled LPG last-mile delivery services, the delivery system needs to complete order allocation and route arrangement under conditions of multiple orders, multiple vehicles, and multiple stations, and continuously adjust the dispatching based on information such as vehicle arrival, loading and unloading, and road traffic conditions during execution.
[0003] In existing technologies, LPG delivery scheduling systems typically employ the following technical approaches:
[0004] (1) General road network shortest path algorithms, such as Dijkstra's algorithm, A* algorithm and their accelerated variants, are mainly for single-source shortest path or point-to-point path queries. These algorithms can output one or a set of road shortest paths, but they usually do not directly calculate the multi-source path matrix required for LPG scheduling, nor do they write business safety constraints such as hazardous material risks, station service boundaries, reservation release, vehicle access restrictions, seasonal weather, traffic restrictions and safety or emergency events into the matrix elements, parameter versions and local recalculation indexes. Therefore, simply calling general shortest path algorithms is difficult to support the maintenance of real-time scheduling matrices for multiple stations, multiple gas delivery workers and multiple order batches.
[0005] (2) Traditional methods for optimizing the routes of hazardous materials vehicles or LPG delivery routes are mostly centered on the vehicle routing problem, focusing on the routes of single-batch vehicles, transportation risks, delivery costs, and time window constraints. Such solutions usually solve routes based on existing distance matrices or map interface results. When disturbances occur, they often replan the routes of single vehicles or single batches. They lack a mechanism for batch output of the path matrix for global scheduling, and also lack an incremental recalculation mechanism that binds the elements of the path matrix to candidate front groups, path backtracking pointers, and affected subgraphs.
[0006] (3) Existing liquefied gas IoT management or digital twin logistics platforms mainly focus on cylinder identification, flow tracking, order status display, vehicle location monitoring, or scenario simulation verification. Such systems can improve the level of regulatory visualization, but they usually do not solve the problem of computational efficiency in path matrix generation, nor do they form a closed loop of "path matrix generation - scheduling scheme - digital twin simulation - parameter write-back - local recalculation". Simulation results are often used for display or post-event analysis, but do not include reverse updating of edge weights, candidate frontier group division, key hub selection, and local recalculation trigger parameters.
[0007] (4) Normal logistics dynamic route replanning usually takes a route of the current vehicle or the current order as the object and re-searches point-to-point routes based on congestion, road closures or time window pressure; even if a local subgraph is used, this type of solution mainly outputs a new route for a single vehicle.
[0008] In summary, existing technologies share the following shortcomings: the full calculation of the multi-source path matrix is time-consuming, the cost of recalculating the entire map after dynamic disturbance is high, the safety constraints of LPG hazardous materials are separated from the path calculation process, and the differences in simulation execution cannot drive the self-optimization of path calculation parameters. Summary of the Invention
[0009] This application provides a method for generating and scheduling LPG delivery route matrices, aiming to solve the problems of high time consumption for full calculation of multi-source route matrices in existing technologies, high cost of full map recalculation after dynamic disturbances, disconnect between LPG hazardous materials safety constraints and route calculation process, and inability of simulation execution differences to drive the self-optimization of route calculation parameters.
[0010] A method for generating and scheduling LPG delivery route matrices, the method comprising:
[0011] Obtain LPG delivery business data and construct an LPG delivery dynamic graph based on the LPG delivery business data; the LPG delivery dynamic graph uses road nodes, station nodes, order nodes, delivery worker location nodes and candidate transfer points as vertices, and directed road edges and temporary access edges as edges;
[0012] Based on the LPG delivery business data, determine the LPG delivery business constraints, generate comprehensive non-negative edge weights for the edges in the LPG delivery dynamic graph based on the LPG delivery business constraints, and record the business constraint identifier for the edges or vertices.
[0013] Using the station nodes, gas delivery worker location nodes, or candidate transfer points in the LPG delivery dynamic map as the source points, a candidate front set is generated. The candidate front set includes vertices that have obtained path estimates but have not yet completed edge relaxation.
[0014] The candidate frontier set is divided into multiple candidate frontier groups based on different partitioning types, and a candidate frontier group identifier is assigned to each candidate frontier group.
[0015] Determine the hub evaluation index for each candidate front vertex in each candidate front group, and select key hub nodes based on the hub evaluation index;
[0016] Around the key hub node, finite-step edge relaxation and recursive expansion are performed based on the comprehensive non-negative edge weights to obtain the path estimate from the source node to the target order node;
[0017] An LPG delivery route matrix is generated based on the estimated route values, and a path dependency index is established. The path dependency index uses the identifier of the changed object determined based on the LPG delivery business data as the index key to map the corresponding set of affected source-target point matrix elements.
[0018] A delivery scheduling scheme is generated based on the LPG delivery route matrix. The delivery scheduling scheme is then input into a digital twin simulation engine to perform delivery simulation and obtain the simulation execution results.
[0019] Calculate the simulation execution difference between the simulation execution result and the delivery scheduling scheme, update at least one of the parameters involved in the generation and updating of the LPG delivery path matrix according to the simulation execution difference, and write the updated parameters into the parameter version library;
[0020] When a delivery dynamic event occurs, or the simulation execution difference exceeds a preset threshold, the path dependency index is queried based on the changed object corresponding to the delivery dynamic event or the simulation execution difference, and a matrix incremental update set is generated. Only the source-target matrix elements that are hit in the matrix incremental update set are locally recalculated, while the matrix elements that are not hit remain unchanged.
[0021] Optionally, in the above scheme, the LPG delivery business data includes road network data, station or transit warehouse data, order and reservation release data, delivery worker location and status data, gas cylinder IoT or inventory data, real-time traffic and safety or emergency event data, historical execution result data, gas cylinder IoT status and safety or emergency event data.
[0022] Optionally, in the above scheme, the constraints of the LPG delivery business include toll costs, LPG hazardous materials delivery risks, station service boundaries, order reservation release or waiting costs, cylinder status, inventory status, safety or emergency events, and historical execution deviations.
[0023] In the above scheme, optionally, generating comprehensive non-negative edge weights for the edges in the LPG delivery dynamic graph based on LPG delivery business constraints includes:
[0024]
[0025] Where T(e,t) is the estimated passage cost, R(e,t) is the LPG hazardous materials delivery risk, B(e,t) is the station service boundary or cross-regional penalty, Q(e,t) is the order reservation release or waiting cost, I(e,t) is the gas cylinder status or transit warehouse inventory constraint cost, E(e,t) is the safety or emergency event cost corresponding to road closure, leak warning, extreme weather or high temperature traffic restrictions, H(e,t) is the historical execution deviation correction term, and a1 to a7 are non-negative weight coefficients.
[0026] In the above scheme, optionally, the comprehensive non-negative edge weights further include the global road constraint cost Zroad(e,t,c):
[0027]
[0028] Where M(e,c) is the cost of adapting to the passage of delivery vehicles, P(e,t) is the cost of congestion during a given time period; K(e,t) is the cost of weather, season, traffic restrictions or control measures; L(e,t) is the cost of waiting or detouring at intersections; G(e,c) is the cost of multi-vehicle connection and coordination; C(e,c) is the cost of energy consumption or carbon emissions; m1 to m6 are non-negative weighting coefficients;
[0029] The global road constraint cost Zroad(e,t,c) is either an independent global road constraint term in the comprehensive non-negative edge weights, or it can be incorporated into the estimated toll cost T(e,t), the LPG hazardous materials delivery risk R(e,t), the safety or emergency event cost E(e,t), or the historical execution deviation correction term H(e,t) for calculation.
[0030] Optionally, in the above scheme, the division type includes at least one of site service boundary, spatial grid, road grade, order density, risk level and business constraint identifier.
[0031] Optionally, in the above scheme, determining the pivot evaluation index for each candidate front vertex in each candidate front group includes:
[0032] Based on the LPG delivery business data and LPG delivery dynamic map, determine the boundary connectivity, road grade, target order accessibility, historical route traversal frequency and risk assessment value, and read the current distance estimate from the current route search record;
[0033] The hub evaluation index is calculated using the following formula:
[0034]
[0035] Where C(v) is the boundary connectivity, G(v) is the road grade score, A(v) is the target order accessibility, F(v) is the frequency of historical path traversal, R(v) is the risk assessment value, D(v) is the cost penalty after normalization of the current distance estimate, and b1 to b6 are non-negative hub scoring parameters.
[0036] In the above scheme, optionally, the finite step edge relaxation stops when any of the following conditions are met: the number of relaxation steps reaches 2 to 8 steps, the cumulative path cost increment exceeds a preset ratio of 30% to 80%, the target order node coverage rate in the candidate frontier group reaches a preset coverage rate of 60% to 95%, the number of newly covered target orders is less than a preset revenue threshold of 1 to 5 orders, or the extended path enters an impassable or high-risk constraint area.
[0037] Optionally, in the above scheme, the LPG delivery route matrix includes matrix elements such as route distance, estimated travel time, hazardous materials risk, out-of-area penalty and accessibility marker, route backtracking pointer, candidate front group identifier, business constraint identifier and parameter version number.
[0038] In the above scheme, optionally, the change object identifier includes edge identifier, order identifier, gas cylinder identifier, inventory node identifier, site service boundary identifier, candidate frontier group identifier, business constraint identifier, and parameter version number.
[0039] Compared with the prior art, this application has at least the following beneficial effects:
[0040] This application acquires LPG delivery business data and constructs a dynamic LPG delivery graph with road nodes, station nodes, order nodes, delivery worker location nodes, and candidate transfer points as vertices and directed road edges and temporary access edges as edges. Based on LPG delivery business constraints, it generates comprehensive non-negative edge weights for the edges in the dynamic graph and records business constraint identifiers for edges or vertices, enabling business safety constraints to participate in edge weight generation during the path calculation stage. Furthermore, it generates a candidate frontier set with station nodes, delivery worker location nodes, or candidate transfer points as source points. The candidate frontier is divided into groups according to different partitioning types, and hub evaluation indicators are determined to select key hub nodes. Finite-step edge relaxation and recursive expansion are performed around the key hub nodes based on comprehensive non-negative edge weights to obtain path estimates from the source point to the target order node, generating an LPG delivery path matrix including matrix elements from multiple source points to multiple target points. This reduces the dependence on a global full expansion of the entire road network and lowers the computational overhead of generating the multi-source path matrix. Simultaneously, it establishes a path dependency index using the identifier of the changed object as the index key and mapping the set of affected source-target point matrix elements, enabling business constraints to participate in edge weight generation during the path calculation stage. Bundle identifiers and change object identifiers can directly participate in the location of matrix elements. When a delivery dynamic event occurs or the simulation execution difference exceeds the local recalculation trigger parameter, the path dependency index is queried according to the change object identifier to generate a matrix incremental update set. Local recalculation is performed only on the hit matrix elements while keeping the missing matrix elements unchanged. Moreover, the local recalculation output is the matrix incremental update set of the multi-source path matrix rather than the new driving route of a single vehicle, thereby avoiding the full recalculation of matrix elements between all source points and all target points after dynamic disturbances. By inputting the delivery scheduling scheme into the digital twin simulation engine to execute the delivery simulation, the parameters are updated according to the simulation execution difference between the simulation execution result and the delivery scheduling scheme and written to the parameter version library. At the same time, the matrix elements record the parameter version number used when they are generated, so that the path matrix generation and dynamic scheduling can be continuously corrected according to the simulation execution result. In the LPG home delivery scenario with multiple stations, multiple gas delivery workers, multiple order batches and frequent changes in road conditions, the generation and updating efficiency of the multi-source path matrix is improved, and the adaptability of the path matrix to LPG business safety constraints and dynamic execution differences is enhanced. Attached Figure Description
[0041] Figure 1 This application provides a schematic flowchart of a method for generating and scheduling LPG delivery route matrices, as an embodiment of the present application.
[0042] Figure 2 A diagram illustrating the operating environment of an LPG delivery route matrix generation and scheduling method provided in one embodiment of this application;
[0043] Figure 3 This is a structural diagram of an LPG delivery route matrix generation and scheduling system provided in one embodiment of this application;
[0044] Figure 4 This is a schematic diagram of a specific process for generating and scheduling an LPG delivery route matrix according to one embodiment of this application;
[0045] Figure 5 This application provides an embodiment of an LPG delivery dynamic diagram, a gridded road network, and a business node model diagram.
[0046] Figure 6 This application provides candidate frontier grouping, key hub node selection, and finite-step relaxation graph in one embodiment.
[0047] Figure 7 This is a schematic diagram of path matrix generation and local recalculation provided in one embodiment of this application;
[0048] Figure 8 This is a schematic diagram of the closed-loop digital twin simulation of the scheduling scheme provided in one embodiment of this application. Detailed Implementation
[0049] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments.
[0050] The following are explanations of some terms used in this application:
[0051] Front compression refers to a path matrix generation method that combines candidate front group division, key hub node selection, and finite step edge relaxation.
[0052] The candidate front set refers to the set of vertices for which path estimates have been obtained but expansion has not yet been completed.
[0053] The candidate frontier group refers to the subset of candidate frontiers after being divided according to site service boundaries, spatial grids, road grades, order density, risk levels, or business constraint identifiers.
[0054] Key pivot nodes refer to nodes within the candidate frontier group that represent the continued expansion of adjacent road subgraphs.
[0055] Path-dependent indexes refer to indexes that point from edges, orders, gas cylinders, inventory nodes, candidate frontier groups, business constraints, or parameter versions to affected matrix elements.
[0056] The matrix incremental update set refers to the sparse set of source-target matrix elements that only need to be updated after dynamic changes, while missing elements retain their original values or remain empty.
[0057] The parameter version closed loop refers to the parameter update module updating edge weights, candidate frontier group divisions, key hub selections, or locally recalculated trigger parameters based on simulation execution differences. The updated parameter content is written into the parameter version library, and the path matrix elements record the parameter version number used during generation, thus establishing a closed loop mechanism that associates the corresponding parameter records.
[0058] Comprehensive non-negative edge weight refers to the path calculation weight generated based on factors such as passage cost, risk, boundary, reservation, status, emergency or historical deviation, and is not less than zero.
[0059] In one embodiment, such as Figure 1 and Figure 3 , Figure 5 As shown, a method for generating and scheduling LPG delivery route matrices is provided, the method comprising:
[0060] Step S1: Obtain LPG delivery business data and construct an LPG delivery dynamic graph based on the LPG delivery business data; the LPG delivery dynamic graph uses road nodes, station nodes, order nodes, gas delivery worker location nodes and candidate transfer points as vertices, and directed road edges and temporary access edges as edges.
[0061] In step S1, the LPG delivery business data includes at least road network data, station or transit warehouse data, order and reservation release data, delivery worker location and status data, cylinder IoT or inventory data, real-time traffic and safety or emergency event data, historical execution result data, cylinder IoT status and safety or emergency event data. This data is obtained through the data access module.
[0062] Road network data includes road intersections, road directions, road lengths, road grades, gradients, traffic restrictions, and road connectivity. Station or transit warehouse data includes station location, service boundaries, operating hours, inventory, town-level transit stations, community forward warehouses, and candidate replenishment points. Order data includes order location, scheduled release time, affiliated station, required cylinder specifications, service duration, and order status. Delivery worker data includes current location, working status, current load, maximum carrying capacity, estimated return time, and abnormal downtime status. Cylinder IoT data includes cylinder identification, inspection validity period, remaining gas volume, pressure, inbound / outbound records, and handover location; some cylinders also provide location and time reported by positioning devices.
[0063] To integrate with existing gas dispatching platforms, the data access module can be configured with an interface adaptation unit. This unit connects to the gas order system, gas cylinder monitoring system, site inventory management system, electronic map or real-time traffic platform, and existing gas dispatching platforms via application programming interfaces (APIs), message queues, database views, batch file imports, or real-time subscriptions. It normalizes external fields into order identifiers, site identifiers, gas cylinder identifiers, delivery worker identifiers, roadside identifiers, event identifiers, timestamps, and parameter version numbers. The interface adaptation unit can also record data sources, update times, interface status, and field mapping versions, enabling subsequent path matrix elements to trace the external business data used during their generation.
[0064] In one implementation, order information, delivery worker location information, and related time records use the LPG Smart Cloud Platform as the source of business data. The data access module reads the order identifier, delivery location, order status, and their time records, and also reads the delivery worker identifier, location coordinates, and location timestamp; it establishes associations based on the order identifier or delivery worker identifier. For the same delivery worker, the latest valid location record no later than the current calculation time is selected; location records exceeding a preset valid duration are marked as pending refresh and are not used as real-time available source points before refresh. The scheduled release time, planned time, and execution time are stored separately to prevent the mixing of time records with different meanings.
[0065] Map service data can be accessed through commercial map APIs, such as Tencent Location Services' address resolution, route planning, distance or estimated travel time calculation, and real-time traffic services. The interface adaptation unit converts the coordinate system, distance unit, and time unit according to the field definitions of the accessed service, and records the query time, travel mode, origin and destination, and response status; the route distance and estimated travel time returned by the commercial map service can be used for path attribute assignment or validation.
[0066] Road network data used for road-level map search is provided by a road dataset with topological information. This dataset includes road vectors and associated topological attribute data, including road node identifiers, directed segment identifiers, start and end nodes, travel directions, and connectivity relationships. Vector data containing only map-display geometry should be supplemented with topological and travel attributes; the paths or distances between two points returned by the route planning API should not be equated with a complete road network.
[0067] Gas cylinder IoT status data can be accessed via barcode or QR code scanning terminals, vehicle-mounted terminals, or handheld delivery terminals. The interface adaptation unit converts the scanned cylinder identifier, batch scan results, handover location, scan time, and delivery worker identifier into unified gas cylinder IoT status data. It also writes statuses such as abnormal inspection validity periods, handover location deviations, abnormal cylinder replacements, or lack of scan confirmation into corresponding business constraint records, associating them with business constraint identifiers. When relevant parameters are updated, their version numbers are recorded separately. Gas cylinders equipped with positioning devices are associated with positioning data based on their cylinder identifiers. Therefore, gas cylinder scan data can directly participate in edge weight updates, path matrix reachability marking, and local recalculation triggering.
[0068] Construct a dynamic graph for LPG delivery. The dynamic graph is a directed sparse graph, with vertices including road nodes, station nodes, order nodes, delivery worker location nodes, and candidate transfer points; edges include directed road edges and temporary access edges. The bidirectional travel cost of the same road can be different; order nodes and delivery worker location nodes connect to the road network through the nearest accessible road node. Candidate transfer points refer to pre-defined locations where cylinder exchange, temporary replenishment, order merging, or service boundary handover can take place, including pre-defined cylinder exchange points, temporary parking and replenishment points, town-level transfer stations, community forward warehouses, order clustering entry points, or station service boundary intersection points.
[0069] In the specific mapping process, intersections, road segment endpoints, and other topological nodes with actual connectivity significance in the road network data are converted into road nodes, and a mapping is established using the original node identifiers. Directed edges are generated based on the start and end nodes of the road segment and the permitted traffic direction. For bidirectional road segments, edges are generated in both directions, and their lengths, road class, and traffic attributes are stored separately. For road segments that intersect in planar locations such as on or under bridges but are not actually connected, connections are not established based on geometric intersections. Other topological nodes with actual connectivity significance include:
[0070] Site nodes are generated from the location and identifier of a site or transit warehouse; order nodes are generated from the order delivery coordinates, and when an order only has an address, the coordinates are first obtained and verified through address parsing; gas delivery worker location nodes are generated from valid location records and updated over time. Candidate transit points are selected from exchange, replenishment, or handover locations configured on the platform, and their location identifiers, positions, and service attributes are saved; candidate locations calculated by order clustering or service boundaries must be matched with actual locations that can be used for handover before they can be used as transit points.
[0071] For business nodes such as stations, orders, gas delivery workers, and candidate transfer points, road nodes that meet the current vehicle and delivery passage conditions are queried within a preset access distance range. The actual entrances / exits and connection directions are checked from nearest to farthest access distance, and temporary access edges are established between the business node and the accessible road nodes. The temporary access edge stores the connection direction, access distance, estimated time, and the associated business node identifier; if no valid access point is found, it is marked as not connected, and a straight-line connection across isolation facilities is not used to replace the actual path. When the location or order location changes, the corresponding business node and its temporary access edge are updated.
[0072] Step S2: Determine LPG delivery business constraints based on LPG delivery business data, generate comprehensive non-negative edge weights for the edges in the LPG delivery dynamic graph based on the LPG delivery business constraints, and record business constraint identifiers for edges or vertices.
[0073] In step S2, LPG delivery business constraints include toll costs, LPG hazardous materials delivery risks, site service boundaries, order reservation release or waiting costs, cylinder status, inventory status, safety or emergency events, and historical execution deviations.
[0074] Based on toll costs, LPG hazardous materials delivery risks, site service boundaries, order reservation releases, cylinder status, inventory status, safety or emergency events, and historical execution deviations, a comprehensive non-negative edge weight is generated for each edge, and a business constraint identifier is recorded for each edge or vertex, specifically using the following formula:
[0075]
[0076] Where T(e,t) is the estimated passage cost, R(e,t) is the LPG hazardous materials delivery risk, B(e,t) is the station service boundary or cross-regional penalty, Q(e,t) is the order reservation release or waiting cost, I(e,t) is the gas cylinder status or transit warehouse inventory constraint cost, E(e,t) is the safety or emergency event cost corresponding to road closure, leak warning, extreme weather or high temperature traffic restrictions, H(e,t) is the historical execution deviation correction term, and a1 to a7 are non-negative weight coefficients. In this embodiment, a1+a2+a3+a4+a5+a6+a7=1; a1 to a7 can be updated according to the simulation execution difference and the constraint status corresponding to the business constraint identifier. Before the update, the parameters are read from the parameter version library through the parameter version number.
[0077] In one feasible scoring method, each cost item with comprehensive non-negative edge weights first calculates its non-negative raw value based on the corresponding original data, and then converts it to a dimensionless interval of 0 to 10. For raw values of time, bias, or distance categories, a reference upper limit greater than zero is preset. The ratio of the raw value to this upper limit is multiplied by 10, and results exceeding 10 are truncated to 10. The classification status is mapped to a score of 0 to 10 according to the parameter table. The reference upper limit, classification score, weight, and applicable scope are saved as parameter version content. Initial parameters are given by configuration and subsequently updated according to simulation differences; the version number is used to locate parameter records and is not itself cost observation data.
[0078] The estimated travel cost T(e,t) is determined based on at least one of the following from the LPG delivery business data: road network data, real-time traffic or emergency event data, and historical execution result data. Specifically, the road segment length and road grade are obtained from the road network data; traffic condition data that can be associated with the road segment is obtained from the real-time traffic or emergency event data; and historical location trajectory statistics are obtained from the historical execution result data. The travel time can be obtained by dividing the road segment length by the effective speed for that time period, and then normalized according to the upper limit of the time reference. The effective speed comes from the traffic condition data that can be associated with the road segment or the historical location trajectory statistics. If such records are missing, the preset speed corresponding to the road grade is used and the estimation source is marked. If the map interface only returns the estimated time for the entire route, it is used for the attributes or verification of the entire route and is not directly used as the time for each roadside.
[0079] The hazardous materials delivery risk R(e,t) is determined based on at least one of the following from LPG delivery business data: road network data, real-time traffic or emergency event data, and cylinder IoT or inventory data. Specifically, road attributes are obtained from road network data, risk area configurations are obtained from platform configurations, and safety or emergency event records are obtained from real-time traffic or emergency event data or the aforementioned cylinder IoT or inventory data. For example, a base score of 0 to 10 is preset for each type of risk; for risks with a geographical range and effective time period, whether a risk is hit is determined based on the spatial association between the road segment and that range and the current time period. The highest base score among the hit risks is used as the risk evaluation value for that road segment, and 0 is used for risks that are not hit. This score represents the risk penalty in route selection and is not interpreted as the probability of an accident. Clearly prohibited hazardous materials routes, road closures, and other impassable conditions are treated as hard constraints to eliminate relevant edges; limited risk premiums cannot replace prohibition constraints.
[0080] The station service boundary or cross-regional penalty B(e,t) is determined based on at least one of the station or transit warehouse data and order and reservation release data in the LPG delivery business data. Specifically, the service boundary of the station to which the current origin belongs is obtained from the station or transit warehouse data, and the target order location is obtained from the order and reservation release data. The penalty is determined by the spatial relationship between the service boundary of the station to which the current origin belongs and the road segment or target order location. Cases where cross-regional travel is allowed but penalized are assigned values according to the configuration, and cases where cross-regional travel is prohibited are marked as undeliverable.
[0081] The order reservation release or waiting cost Q(e,t) is determined based on the order and reservation release data in the LPG delivery business data. Specifically, it is determined based on the positive difference between the order reservation release time and the estimated arrival time, and normalized according to the upper limit of the waiting time reference. This cost is recorded on the service access edge of the corresponding order and is included once when the actual service enters, avoiding the repeated collection of the same order waiting cost at each roadside along the route.
[0082] The cylinder status or transit warehouse inventory constraint cost I(e,t) is determined based on at least one of the following: order and reservation release data, cylinder IoT or inventory data, and site or transit warehouse data from the LPG delivery business data. The required specifications and quantity for the order are obtained from the order and reservation release data; the valid status of the matching cylinder is obtained from the cylinder IoT or inventory data; and the available inventory of the supply node is obtained from the cylinder IoT or inventory data or the site or transit warehouse data. Values are then assigned to the business access edge of the corresponding order or replenishment node. For example, a value of 0 is assigned when inventory is sufficient and the cylinder status is normal; a preset non-negative penalty is assigned when the inventory is below the preset safety stock but the order can still be fulfilled; if the required inventory is insufficient or the cylinder status does not meet the delivery conditions, the supply selection is marked as unavailable. Missing status and normal status are marked separately; an unknown cylinder status cannot be directly considered normal.
[0083] The cost E(e,t) of a safety or emergency incident is determined based on at least one of the following: real-time traffic or emergency incident data from LPG delivery operations data, and cylinder IoT or inventory data. Specifically, the incident location, impact range, effective time, and incident level are obtained from the real-time traffic or emergency incident data or cylinder IoT or inventory data. The incident location, impact range, effective time, and incident level are associated with roadside or business nodes. Affected objects that are still allowed to pass are assigned non-negative costs according to a level table; objects that are closed or prohibited from passing are treated as hard constraints.
[0084] The historical execution deviation correction term H(e,t) is determined based on historical execution result data from LPG delivery business data. Specifically, the actual travel time for the same historical time period is obtained from the historical execution result data, compared with the corresponding estimated travel time, and the average of positive deviations exceeding the estimated time in the valid samples is taken and normalized. When only the total order time is available, the deviation is applied to the corresponding business path or order service link, and is not undecomposed and attributed to each roadside. When valid historical samples are lacking, a preset initial value is used and a sample insufficiency marker is recorded.
[0085] When the same physical road segment involves different stations, order statuses, or travel modes, its business constraint costs may differ. Therefore, each matrix generation determines the applicable edge weights and constraint records based on the current source point, travel mode, order batch, and time slice; the business context in the aforementioned edge weight tokens is stored by the current calculation task. Data such as risk areas, inventory, gas cylinder status, and station boundaries, which are not provided by the map interface, are provided by the corresponding business records or rule configurations.
[0086] In a numerical example, the estimated toll cost T for a certain road segment is 8, the hazardous materials risk R is 3, the station over-boundary penalty B is 0, the reservation waiting cost Q is 1, the gas cylinder or inventory constraint cost I is 2, the safety or emergency event cost E is 0, and the historical deviation correction H is 1; if a1 to a7 are 0.40, 0.20, 0.15, 0.05, 0.10, 0.05, and 0.05 respectively, then the edge weight... The T, R, B, Q, I, E, and H values mentioned above are normalized dimensionless values. These values are for illustrative purposes only and can be configured according to urban roads, site boundaries, security requirements, and historical execution data in actual deployments.
[0087] In other embodiments, the comprehensive non-negative edge weights can also be generated using piecewise functions, lookup table models, monotonic nonlinear correction functions, or regression models trained with historical delivery data. Regardless of the calculation method used, the output edge weights remain non-negative, and the corresponding business constraint identifiers and parameter version numbers are recorded so that the path dependency index and local recalculation modules can track their scope of influence.
[0088] Step S3: Using the station nodes, gas delivery worker location nodes, or candidate transfer points in the LPG delivery dynamic map as the source points, generate a candidate front set, which includes vertices for which path estimates have been obtained but edge relaxation has not yet been completed.
[0089] For the current source vertex, initialize its path cost estimate to 0, initialize all other vertices to positive infinity, and clear the predecessor record. Start relaxation from the traversable outgoing edges of the source vertex, adding vertices with finite estimates and still needing to expand their outgoing edges to the candidate front set. Each time a lower candidate path cost is found, simultaneously update the cost estimate and predecessor edges of the target vertex; the current distance estimate refers to the comprehensive path cost estimate maintained during this search process, and is not equivalent to the physical distance directly returned by the map interface.
[0090] Step S4: Divide the candidate frontier set into multiple candidate frontier groups based on different partitioning types, and assign a candidate frontier group identifier to each candidate frontier group.
[0091] In steps S4 and S5, as Figure 4 and Figure 6 As shown, during the path matrix generation phase, a single-source path matrix is generated using station nodes, gas delivery worker location nodes, or candidate transfer points as source points. The candidate frontier set includes vertices for which finite path estimates have been obtained but edge relaxation has not yet been completed. The candidate frontier grouping module does not perform a global complete sort of all candidate frontier vertices. Instead, it forms multiple candidate frontier groups based on station service boundaries, spatial grid groups, road level groups, risk weight reorganization, order density, and business constraint identifiers, and assigns a candidate frontier group identifier to each candidate frontier group.
[0092] For order-intensive areas, the system uses a smaller spatial grid or a higher granularity of candidate front group subdivision; for order-sparse areas, the system uses a larger spatial grid or a lower granularity of candidate front group subdivision; for areas with high hazardous material risk, the system forms a separate risk candidate front group. The purpose of this is not simply to change business priorities, but to change the organization of the path search space, allowing LPG safety constraints to directly affect the grouping, expansion, and local recalculation range of candidate fronts.
[0093] Step S5: Determine the hub evaluation index of each candidate front vertex in each candidate front group, and select key hub nodes according to the hub evaluation index.
[0094] In step S5, the boundary connectivity, road grade, target order accessibility, historical route traversal frequency and risk assessment value are determined based on LPG delivery business data and LPG delivery dynamic map, and the current distance estimate is read from the current route search record;
[0095] The critical hub node selection module selects critical hub nodes within each candidate frontier group. For example, critical hub nodes are located at the boundaries of candidate frontier groups, arterial road entrances, station service boundaries, entrances to order-intensive areas, risky detour entrances, or intersections of historically high-frequency paths. Hub scoring can be:
[0096]
[0097] Where C(v) is the boundary connectivity, G(v) is the road grade score, A(v) is the target order reachability, F(v) is the historical path traversal frequency, R(v) is the risk assessment value, D(v) is the cost penalty after normalizing the current distance estimate, and b1 to b6 are non-negative hub scoring parameters; in this embodiment, b1 to b6 can be adaptively updated based on simulation execution differences and the historical hit frequency of candidate frontier groups. Before the update, the parameters are read from the parameter version library through the parameter version number.
[0098] In one implementation of hub scoring, the boundary connectivity C(v) is obtained by counting the number of traversable outgoing edges from vertex v to other candidate front groups, and then normalized by dividing by the maximum value of that number within the current group; when the maximum value is 0, it is uniformly set to 0. The road grade score G(v) is obtained by looking up the grade field in the road network, for example, configuring the entrances of main roads, secondary roads, and branch roads suitable for the current vehicle as 1, 0.7, and 0.4 respectively; connections that are not allowed for the current vehicle to pass through are excluded first.
[0099] The reachability of a target order, A(v), can be scored using local coverage ratio as a proxy: Starting from vertex v, search along the accessible directed edges up to a preset number of hops, count the number of accessible target orders in the current batch, and then divide by the total number of target orders in that group; the denominator is 0 when it is zero. This value only represents the reachability of orders within a limited search area; it cannot be concluded that an order is unreachable in the entire road network simply because no order was found locally. The neighborhood hop count is given by configuration, and the same metric is used for the same scoring batch.
[0100] The historical path traversal frequency F(v) is determined based on the number of valid delivery trajectories passing through vertex v after road matching within a preset historical time window, and then normalized by dividing by the maximum traversal frequency within the current group; when there is no valid historical trajectory, it is set to 0 and a no-sample state is recorded. The risk assessment value R(v) can be the maximum risk score of adjacent traversable edges divided by 10. D(v) is the finite cost estimate of vertex v read from the path search record of the current source point, divided by the upper limit of the cost reference greater than zero, and truncated to the interval of 0 to 1; vertices that have not yet obtained a finite estimate value are not included in the hub candidate set for this round.
[0101] After substituting the above indicators into the hub scoring formula, a preset number of key hub nodes are selected from high to low scores; if the scores are the same, the node with the smaller current path cost estimate is selected first, and then the order is determined by the node identifier. The number, neighborhood hop count, historical window, rating table, and cost reference upper limit are all stored in the parameter version record along with the hub scoring weights.
[0102] In other embodiments, the scores of key hub nodes can also be generated using a segmented scoring table, a nonlinear correction function, or a regression model, as long as the input includes at least one of road connectivity, target order accessibility, risk assessment value, or historical path traversal frequency, and the version number of the parameters used to generate the scores is written into the candidate frontier group record.
[0103] In high-density urban scenarios, priority should be given to increasing the weight of target order accessibility and the frequency of historical route traversal, for example... In low-density scenarios such as rural areas or urban-rural fringe areas, the weights of boundary connectivity and road grade scores can be increased, for example... The above weights are preferred embodiments and do not constitute the sole limitation on the scope of protection.
[0104] Step S6: Around the key hub node, perform finite-step edge relaxation and recursive expansion based on the comprehensive non-negative edge weights to obtain the path estimate from the source node to the target order node.
[0105] In step S6, the path matrix generation module performs finite-step edge relaxation and recursive expansion on the key hub nodes. Finite-step edge relaxation stops when either of the following conditions is met: the number of relaxation steps reaches 2 to 8 steps, or the cumulative path cost increment exceeds [a certain threshold]. The preset ratio was achieved, and the target order node coverage rate within the candidate frontier group reached [a certain percentage]. The preset coverage rate, the preset revenue threshold for newly added coverage target orders is less than 1 to 5 orders, or the path is extended into inaccessible or high-risk constrained areas.
[0106] Specifically, this application employs a finite-step relaxation of 6 to 8 steps in densely populated urban order areas. When expanding from source point A to step 6, 80% of the pending orders within the candidate front group have been covered, and the cumulative path cost increment exceeds 50% of the estimated cost from the source point to the center of the candidate front group, the system stops expanding in that direction. In sparsely populated rural order areas, a finite-step relaxation of 2 to 3 steps is employed. If the number of newly covered orders falls below a preset revenue threshold for two consecutive rounds, the system postpones the expansion of that candidate front group. This reduces the expansion of irrelevant areas while ensuring the availability of the path matrix for the current scheduling batch.
[0107] The purpose of finite step edge relaxation is not to replace Dijkstra's calculation of the global exact shortest path between every pair of source and target points in the whole graph, but to quickly generate an approximate optimal path matrix that can be used for scheduling while meeting the real-time requirements of the current LPG delivery scheduling. For key matrix elements hit by the path dependency index, the system can still perform more refined recalculation in the local subgraph.
[0108] To control the approximation error caused by finite-step edge relaxation, error flags or confidence flags can be set for matrix elements. For example, the system calculates the error estimate based on the minimum estimated cost of the candidate frontier without expansion at the time of stopping, the obtained target path cost, the candidate frontier group coverage, and historical simulation deviations. When the error estimate exceeds a preset error threshold, the order priority exceeds a preset level, the target order is in an emergency state, or the same matrix element shows significant simulation execution differences in consecutive scheduling batches, the system continues to perform compensatory relaxation, increase the coverage threshold, or perform a secondary refinement search within the affected local road subgraph. The execution scope of the secondary refinement is limited to the corresponding source point, target point, critical edges recorded by the path backtracking pointer, the candidate frontier group boundary, and their preset hop count neighborhood. After refinement, the path cost, error flag, refinement flag, and new parameter version number are written back to the path matrix. This error compensation mechanism is triggered only for a small number of key matrix elements and does not change the main process of frontier compression batch generation of path matrices.
[0109] Step S7: Generate an LPG delivery path matrix based on the path estimation value and establish a path dependency index; the path dependency index uses the change object identifier determined based on the LPG delivery business data as the index key to map the corresponding set of affected source-target point matrix elements.
[0110] In step S7, the route matrix generation module outputs an LPG delivery route matrix. This matrix may include a route distance matrix, an estimated travel time matrix, a hazardous materials risk matrix, a cross-regional or reachability matrix, a route dependency index, and a set of matrix elements corresponding to locally recalculated areas. Each matrix uses the same source-destination index and is associated with the same parameter version number and the same business constraint identifier. Matrix elements can be represented as follows: , where s is the source point and o is the target order node or candidate transit point. Each matrix element stores at least the path distance and estimated travel time, hazardous material risk, cross-regional penalty, source point type, target point type, path cost, reachability marker, path backtracking pointer, candidate frontier group identifiers passed through, business constraint identifiers that triggered its generation, and parameter version number.
[0111] The attributes of matrix elements are generated along the same selected path. The source and destination point types directly inherit the type fields of the corresponding nodes; the path distance is the sum of the physical lengths of the roadside and temporary access edges along the path; the estimated travel time is the sum of the estimated travel times for each corresponding edge. Order waiting, loading / unloading, and service times are saved separately and included in the estimated completion time as needed during scheduling. Hazardous materials risks and out-of-area penalties are summarized along the route according to the additive cost caliber of this embodiment, forming path risk penalty values and out-of-area costs. The path risk penalty value is not interpreted as an accident probability.
[0112] The path cost is the cumulative value of the combined non-negative edge weights from the source point to the target point obtained in this search. Each time relaxation generates a lower candidate cost, the predecessor node and its directed edge identifier are simultaneously saved. The path edge sequence is then obtained by tracing back from the target point along the predecessor records to the source point, and this sequence is written into the path backtracking pointer and the identifiers of the candidate frontier groups traversed in the matrix element. The business constraint identifier is collected from the edges, nodes, and rule records that affect the service state of the path or target; the parameter version number is the version actually used when generating the element.
[0113] Reachability markers are generated by combining path search status and business constraints. A path is marked as reachable when a valid path is found and delivery constraints are met; if a hard constraint is explicitly violated, the corresponding reason for unavailability is recorded. Situations where the target has not yet been found due to finite-step expansion are marked as undetermined or pending recalculation, and are not directly recorded as unreachable. The path dependency index is established synchronously when matrix elements are written: path edge identifiers, associated order and business node identifiers, candidate front group identifiers, related constraint identifiers, and parameter version numbers are mapped to the source-target element respectively; after element recalculation, its invalid dependencies are deleted and new dependencies are registered. Recalculation is performed using local shortest path searches within the candidate front group, with time and scope limitations; if no results are found after timeout, the path is marked as unreachable or undergoes full recalculation according to the rules.
[0114] The path backtracking pointer can include the predecessor road node identifier, the predecessor directed edge identifier, the list of critical edge IDs, the critical hub node ID, the candidate frontier group ID, the local road subgraph ID, and the parameter version number used when generating the matrix element. During local recalculation, the system first obtains the candidate affected matrix elements through the path dependency index, then reads the path backtracking pointer of the corresponding matrix element to determine whether the changed edge, changed order, changed gas cylinder, changed inventory node, or changed business constraint falls within the historical path, critical hub neighborhood, or candidate frontier group of the matrix element; only when the above records are matched is the matrix element added to the matrix incremental update set.
[0115] The accessibility marker is used to distinguish between normal accessibility, inaccessibility due to hazardous materials restrictions, temporary inaccessibility due to station location being outside designated areas, temporary inaccessibility due to insufficient inventory, and temporary unavailability due to unreleased reservations. If the matrix elements in the attached diagram are... In the form of , the numerator represents the path distance or total path cost, and the denominator represents the estimated travel time; if the matrix elements are This indicates that there is no available path between the current source and target points; if the matrix elements are... This indicates that the person is temporarily not participating in the current dispatch batch due to reasons such as restrictions on the use of dangerous goods, unreleased reservations, service boundaries, or insufficient inventory.
[0116] Path-dependent indexes are used to record the dependencies between matrix elements and changing objects. For example, a path-dependent index may be stored using a hash table, inverted index, or key-value map, with keys such as edge identifier, order identifier, gas cylinder identifier, inventory node identifier, site service boundary identifier, candidate frontier group identifier, business constraint identifier, or parameter version number, and values such as the set of affected source-target matrix elements. For instance, edge identifier E23 could represent... Figure 7 The systematic number of any directed edge in the system can point to an index item. The index entry for parameter version V17 can point to all matrix elements generated using the risk weights of that version. This index allows the system to directly locate matrix cells from events, rather than retracing all source and target points.
[0117] In one implementation, when the same gas delivery worker serves multiple orders consecutively in a single delivery and returns to the station after the last order, the order node can also serve as a source or intermediate point, generating matrix elements between order nodes and between order nodes and station nodes within a preset nearest neighbor range. The preset nearest neighbor range can be determined by a spatial grid, station service boundary, preset hop count, or the number of nearest neighbor orders. Non-nearest order node pairs do not generate matrix elements, keeping the matrix sparse. The aforementioned matrix elements use the same comprehensive non-negative edge weights, business constraint identifiers, and parameter version numbers as the matrix elements between station nodes or gas delivery worker location nodes and order nodes, and are also registered in the path dependency index. When the changing object changes, only the matched inter-order matrix elements are recalculated based on the path dependency index. The scheduling optimization module can determine the order set for a single delivery based on the gas delivery worker's maximum carrying capacity and read the aforementioned matrix elements to generate the order access order.
[0118] When the edge weight corresponding to the changed object increases or the edge is prohibited, the affected matrix element is hit according to the path edge identifier recorded in the path dependency index. When the edge weight decreases, the closure is lifted, the inventory is restored, or the restricted period ends, the matrix element that has not passed through the edge may also obtain a better path. The system takes the changed edge as the center, determines the set of matrix elements that may benefit according to the preset hop count neighborhood, candidate front group identifier, or spatial grid, marks them as pending review, and recalculates them in batches according to order priority and computing power status. Elements that are not reviewed in time are overwritten by the corresponding candidate front group when the version lag threshold is triggered.
[0119] Step S8: Generate a delivery scheduling scheme based on the LPG delivery path matrix, input the delivery scheduling scheme into the digital twin simulation engine to perform delivery simulation, and obtain the simulation execution results.
[0120] In step S8, the scheduling optimization module reads the LPG delivery path matrix and generates a scheduling scheme. The scheduling scheme includes order attribution, delivery worker batch, order access order, candidate paths, candidate transfer points, and exception handling strategies. The scheduling optimization module can employ adaptive large neighborhood search, genetic algorithm, tabu search, mixed integer programming, greedy insertion, or rule-constrained optimization, but its path cost input comes from the LPG delivery path matrix generated by this invention.
[0121] like Figure 8 As shown, the digital twin simulation module feeds the scheduling plan back into the digital twin simulation engine, executing the delivery simulation according to the order state machine and the gas delivery worker state machine. The order state machine includes states such as pending release, received at the station, dispatched, in delivery, completed, timed out, out of area, and abnormal handover. The gas delivery worker state machine includes states such as idle, loading, in delivery, returning to the station, lunch break, off-duty, off-duty due to malfunction, and abnormal shutdown. The simulation engine obtains the simulation execution results based on the path matrix, order release time, gas delivery worker's working hours, loading time, service time, gas cylinder handover status, and the progress status of safety or emergency events.
[0122] Step S9: Calculate the simulation execution difference between the simulation execution result and the delivery scheduling scheme, update at least one of the parameters involved in the generation and updating of the LPG delivery path matrix according to the simulation execution difference, and write the updated parameters into the parameter version library.
[0123] In step S9, the parameter update module calculates the plan-execution discrepancies and writes back the parameters. Simulation execution discrepancies include differences in estimated travel time, actual completion time, cross-regional travel, timeout, gas delivery worker load, manual reassignment, gas cylinder handover location, and handling of safety or emergency events. Parameter updates can use a weighted moving average.
[0124] .
[0125] Where Theta_new represents the updated parameters, Theta_old represents the original parameters, Theta_obs represents the observed parameters obtained based on the simulation execution differences, and Lambda represents the learning coefficient between 0 and 1. Lambda can be determined based on the volatility of the simulation execution differences within a preset time window, peak order periods, or emergency situations. When volatility increases or an emergency situation occurs, Lambda is reduced to increase the weight of the observed parameters. The system can also use gradient updates or reinforcement learning to update hub scoring parameters, but regardless of the method used, the update objects are limited to comprehensive edge weights, candidate frontier group division, hub selection, and local recalculation trigger parameters. The parameter update module writes each update to the parameter version library. The parameter version record includes parameter type, applicable edge or candidate frontier group, applicable business constraint identifier, effective time, version number, previous version number, and effective range. The same parameter record sequence simultaneously stores an incrementing update sequence number, and the parameter version number can be generated from this update sequence number. For example, when the update sequence number increases from 17 to 18, the parameter version number changes from V17 to V18, and subsequent path matrix elements record the parameter version number read during their generation.
[0126] In one example, the digital twin simulation module outputs the simulation execution difference every 10 minutes or for each scheduling batch. It can also adaptively adjust the time window based on current order peaks and troughs; for example, during peak periods, the output is shortened to every 3 minutes, and during off-peak periods, it is extended to every 30 minutes. When the difference between the estimated travel time and the simulated travel time within a candidate frontier group exceeds 20%, or when the proportion of timed-out orders exceeds a preset proportion, the parameter update module converts this difference into Theta_obs, updates the corresponding edge weights, candidate frontier group partitioning parameters, hub scoring parameters, or local recalculation trigger thresholds, writes the updated parameter content to the parameter version library, and assigns a new parameter version number.
[0127] To address safety constraints in the LPG industry, the parameter update module can also generate an LPG risk calibration factor S_lpg. S_lpg is obtained by normalizing one or more of the following: gas leak warning, high-temperature restrictions, abnormal cylinder inspection, cylinder handover location deviation, cross-regional delivery, hazardous materials prohibited access, abnormal parking, user safety complaints, or manual reassignment records. When S_lpg exceeds a preset safety threshold, the system increases the hazardous materials risk weight, safety or emergency event cost, site service boundary penalty, or local recalculation trigger sensitivity, reduces Lambda to increase the weight of the latest observed parameters, and expands the local recalculation range around the corresponding candidate frontier group or safety or emergency event. When S_lpg is below a preset stability threshold and simulation errors converge in multiple consecutive scheduling batches, the system increases Lambda to enhance parameter stability and prevent edge weights from frequently fluctuating due to single abnormal fluctuations. This rule binds the adaptive parameter tuning object to LPG safety or emergency events, cylinder handover, and site service boundaries, rather than ordinary time-sensitive parameter tuning in general logistics.
[0128] To prevent continuous parameter updates from causing matrix elements to use old parameters for extended periods, a version lag threshold can be set. For the same parameter record sequence, the update sequence number is obtained by looking up the current parameter version number and the parameter version number of the matrix element record. The difference between the two non-negative sequence numbers represents the number of parameter updates that the matrix element has lagged behind. When the number exceeds the preset version lag threshold, or the number of consecutive local recalculation failures exceeds the preset number, the system triggers a full recalculation of the corresponding candidate frontier group, site service boundary, or local computing area. This threshold compares the number of updates, not the version number strings; when multiple parameter record sequences are involved, they are compared separately. After a full recalculation is triggered, the system freezes the scheduling and reading state of the old version matrix elements, regenerates the candidate frontier group, key hub nodes, path matrix elements, and path dependency indexes based on the parameter content corresponding to the current parameter version; the new matrix replaces the old version matrix elements after passing a consistency check, and the mapping relationship between the old and new versions is written to the parameter version library.
[0129] When temporary road closures, gas leak warnings, gas delivery worker malfunctions, vehicle or electric delivery tool failures, extreme rainstorms, high-temperature traffic restrictions, or sudden large-volume orders occur, the digital twin simulation engine enters emergency mode. In emergency mode, the system expands the local recalculation subgraph, for example, from one-hop nodes around the changed edge to three-hop nodes around it, temporarily increasing the risk weight of hazardous materials. It outputs an incremental update set of the matrix and a set of affected orders through path dependency indexing, prioritizing matching with the nearest available gas delivery worker or a transfer point with sufficient inventory, and generating an emergency delivery plan. This emergency branch directly links path matrix updates with LPG safety management.
[0130] Step S10: When a delivery dynamic event occurs, or the simulation execution difference exceeds a preset threshold, query the path dependency index according to the changed object corresponding to the delivery dynamic event or the simulation execution difference, generate a matrix incremental update set, perform local recalculation only on the source-target matrix elements that are hit in the matrix incremental update set, and keep the matrix elements that are not hit unchanged.
[0131] In step S10, the local recalculation module handles dynamic changes. When an order is released, the gas delivery worker's location changes, road edge weights change, station service boundaries change, gas cylinder status changes, a safety or emergency event occurs, or simulation execution differences exceed a threshold, the system queries the path dependency index based on the changed object and generates a matrix incremental update set ΔM. Then, based on the path backtracking pointer, candidate frontier group identifier, business constraint identifier, and parameter version number, the affected road subgraph is determined. Only the path matrix elements that are hit by ΔM are recalculated, while the matrix elements that are not hit by the path dependency index remain unchanged. The matrix incremental update set ΔM can be a sparse matrix or a sparse set, where most source-target point elements are empty or retain the original matrix values. Only the source-target point matrix elements that need to be updated, the values before and after the update, and the corresponding parameter version numbers are saved. The affected road subgraph can be jointly determined by the changed edge, road nodes within a preset number of hops adjacent to the edge, changed order nodes or gas cylinder nodes, changed station service boundaries, and historical path records that pass through the changed edge or changed candidate frontier group.
[0132] If temporary construction on a road segment increases the estimated travel time, the system queries the path dependency index using the edge identifier of that road segment to obtain the source-target point matrix elements. Only the matrix elements between affected stations, affected gas delivery workers, and affected orders are updated. If a community's forward warehouse has insufficient inventory, the system updates the inventory constraint cost I(e,t) of the relevant candidate transfer points and generates a new inventory parameter version number. Only the matrix elements passing through that transfer point, inventory node, or its candidate frontier group are updated. If a gas cylinder's inspection expiration date is abnormal, the system increases the risk or handover constraint cost of the relevant order and only updates the matrix elements related to that order, the gas cylinder identifier, or the corresponding business constraint identifier.
[0133] The output of the aforementioned partial recalculation is an incremental update set of the multi-source path matrix, not a new route for a single vehicle. The scheduling optimization module then reads the updated matrix elements and regenerates the scheduling scheme for the affected order set; unaffected orders and unaffected matrix elements continue to use the original matrix results.
[0134] In other variant embodiments, the path-dependent index can be implemented using an inverted index, hash table, bitmap index, sparse matrix index, or graph database edge relation index; the matrix incremental update set can be organized by a single source-target matrix element, by batches of matrix elements within the same candidate frontier group, by matrix sub-blocks within the same site service boundary, or by a set of matrix elements under the same business constraint identifier. Delivery dynamic events can originate from real-time traffic interfaces on electronic maps, site manual reassignment records, abnormal gas cylinder scanning, inventory changes, road closure notifications, changes in gas delivery worker terminal location, or differences in digital twin simulation. Local recalculation can be deployed and executed in a collaborative architecture of a central server, site-side servers, edge computing nodes, or gas delivery worker terminals. As long as it locates the affected matrix elements according to the path-dependent index and keeps the missed matrix elements unchanged, it belongs to an alternative implementation of the local update concept of this invention.
[0135] The above implementation method organizes multi-source path search by grouping candidate frontiers and expanding key hubs, locates matrix elements affected by dynamic changes through path dependency indexing, and updates parameters used in subsequent calculations through simulation to perform differential updates. Matrix elements store business constraint identifiers and parameter version numbers, ensuring that local recalculation results remain associated with their applicable business constraints and parameter records.
[0136] In one embodiment, in a scenario where two-wheeled, three-wheeled, small delivery vehicles or emergency support vehicles are used in collaboration with LPG delivery on urban, suburban, and rural roads in China, the edge weight generation module (103) can also generate the global road constraint cost Zroad(e,t,c):
[0137]
[0138] Wherein, M(e,c) is the adaptation cost of delivery vehicle passage, used to express the impact of non-motorized vehicle lanes, auxiliary roads, narrow alleys, mixed traffic sections of motorized and non-motorized vehicles, sections where three-wheeled vehicles are prohibited, and sections where overpasses or tunnels are impassable on different vehicles; P(e,t) is the congestion cost during morning and evening rush hours, school commuting, morning markets, and evening rush hours in commercial areas; K(e,t) is the cost of high temperatures in summer, icing in winter, rain and snow accumulation, low visibility, restrictions on dangerous goods, temporary construction, traffic police control, or major event closures; L(e,t) is the cost of waiting at intersections, difficulty turning left, U-turns, difficulty passing other vehicles, or detours on dead-end roads; G(e,c) is the cost of multi-vehicle connection, load swapping, emergency replacement, or replenishment coordination, used to express the connection constraints when small delivery vehicles undertake replenishment from stations to transfer points, and two-wheeled or three-wheeled delivery vehicles undertake last-mile delivery to homes; C(e,c) is the fuel cost, electricity consumption cost, or carbon emission cost; m1 to m6 are non-negative weighting coefficients. Zroad(e,t,c) can be used as an independent global road constraint term in the comprehensive non-negative edge weights, or it can be incorporated into the estimated toll cost T(e,t), hazardous materials delivery risk R(e,t), safety or emergency event cost E(e,t), or historical execution deviation H(e,t) for calculation.
[0139] When the aforementioned global road constraint costs change, the system writes the changed road constraint identifiers, vehicle type identifiers, vehicle connection identifiers, time period identifiers, weather or season identifiers, traffic restriction identifiers, energy consumption or carbon emission constraint identifiers, and corresponding parameter version numbers into the path matrix elements and path dependency index. Therefore, changes in morning / evening rush hour switching, summer high-temperature warnings, rain / snow weather, tricycle restrictions, temporary traffic control, narrow alleyway restrictions, vehicle type switching, or low-carbon operation constraints do not require a full recalculation between all source points and all orders. Instead, the path dependency index locates the source-target point matrix elements that pass through relevant edges, relevant candidate front groups, relevant vehicle types, or relevant energy consumption constraints, and recalculates within the corresponding local road subgraph. The digital twin simulation module can also write back m1 to m6 or corresponding basic weights based on the actual travel time of gas delivery workers, detour times, manual reassignment records, timeout records, and fuel or electricity consumption records, allowing the aforementioned road constraint costs to be adaptively updated according to the local road operating status. The aforementioned multi-vehicle collaboration and energy consumption and carbon emission costs are optional constraints in the LPG delivery scenario, and do not change the core process of multi-source path matrix generation, path dependency indexing and local recalculation in this invention.
[0140] LPG hazardous materials delivery risks can be determined by time restrictions around schools or hospitals, densely populated residential areas, narrow alleys in old residential areas, blocked fire lanes, hazardous materials restrictions during high-temperature periods, road congestion, abnormal parking, historical complaints, historical timeouts, or hazardous materials prohibited sections of road. When there are abnormal gas cylinder inspection expiration dates, insufficient inventory, increased priority for low-volume orders, or deviations in gas cylinder handover locations, the system updates the gas cylinder status cost I(e,t), hazardous materials risk R(e,t), or order target priority.
[0141] In one embodiment, in a mixed urban-rural LPG delivery scenario, a three-tiered supply network is formed by central stations, town-level transit stations, and community forward warehouses. Urban areas have denser order volumes, so the system uses a smaller spatial grid, more key hub nodes, and a shorter local recalculation cycle; rural areas have more dispersed orders, so the system uses a larger spatial grid, fewer key hub nodes, and a longer recalculation cycle. When forward warehouse inventory is insufficient, the system increases the inventory constraint cost of related paths at that transit point, and the scheduling optimization module prioritizes matching transit points or central stations with sufficient inventory.
[0142] For multi-site deployments in large cities, the system can be configured with edge computing nodes or site-side computing nodes. Each edge node generates local path matrices, path dependency indexes, and parameter version records in parallel according to administrative regions, site service boundaries, or candidate frontier groups. The central server aggregates the local matrices, matrix incremental update sets, and parameter update results, and can perform global matrix synchronization hourly, per scheduling batch, or per security or emergency event trigger. High-frequency update areas use short-cycle local recalculation, while low-frequency update areas use long-cycle local recalculation, thereby reducing the pressure on the central server. In the case of multi-vehicle collaborative delivery, the central server can retain the path matrices or cost matrices corresponding to different vehicle types. Edge nodes only update the matrix elements corresponding to the vehicle types and energy consumption and carbon emission constraints that are hit in their own area, while the missing elements remain unchanged.
[0143] When edge nodes synchronize incremental update sets of the matrix to the central server, they can perform anonymization, encrypted transmission, or access control on order locations, gas delivery worker trajectories, gas cylinder identifiers, and user identifiers. For example, edge nodes only upload matrix element coordinates, candidate front group identifiers, business constraint identifiers, parameter version numbers, and necessary statistics; data involving personal addresses, gas delivery worker trajectories, or gas cylinder identifiers in plaintext can be retained at the site, or hashed, segmented, anonymized, and encrypted before synchronization. This data processing method does not change the path matrix generation logic but improves data security when deployed across regions and multiple sites.
[0144] When extreme weather, concentrated order placement, or large-scale road closures cause the number of local recalculation requests to exceed the computing power threshold of the server or edge nodes, the system can enter a computing power circuit breaker state. Under the computing power circuit breaker state, the system sorts the incremental update set of the matrix according to order priority, security risk level, site service boundary, and expected timeout, prioritizing the recalculation of high-risk or high-priority matrix elements; low-priority matrix elements can temporarily use historical path matrices, call static backup matrices, or be delayed until the next scheduling batch update. After the circuit breaker is lifted, the system replenishes the unupdated matrix elements according to the parameter version number to avoid sudden concurrent recalculations affecting core delivery scheduling.
[0145] In one embodiment used to verify computational efficiency and path estimation error, an LPG delivery simulation road network with 12,100 road nodes and 47,960 directed edges is constructed. Four station source points, 12 gas delivery worker source points, and 620 order points are set, with orders clustered according to station service boundaries. A baseline scheme is used, performing full-graph Dijkstra's algorithm on each of the 16 source points and extracting order path costs. A scheme employing candidate front group partitioning, key hub priority expansion, finite-step relaxation, target set boundary stopping, path dependency indexing, and matrix incremental updates is used as the scheme to be verified. For example, the target set coverage threshold is set to 90%. During verification, the processor model, operating system, runtime environment, algorithm parameters, and random seed are recorded for comparison under identical conditions.
[0146] In the initial path matrix generation scenario, input instances can be generated using random seeds 42, 7, and 123 respectively. For each instance, the two schemes mentioned above are executed under the same road network, source point set, target point set, and edge weight conditions. The matrix generation time, number of nodes visited, number of determined matrix elements, and target set coverage are recorded for each scheme. The number of nodes visited is accumulated based on the number of node expansions in each source point search, with repeated expansions included in the count. The coverage rate uses the source-target point set pre-determined for the current verification task as the denominator, clearly distinguishing between matrix elements within and across the site service boundary. For matrix elements where both schemes obtain valid paths and the baseline path cost is greater than zero, the relative error is calculated by dividing the absolute value of the difference between the two path costs by the baseline path cost, and the average and maximum values are summarized. When the baseline path cost is zero, the absolute error is recorded separately. Elements that do not obtain valid paths are counted separately and are not included in the mean error of the determined paths.
[0147] In scenarios where road weight changes trigger dynamic recalculation, road edges associated with path dependency indexes can be selected to improve safety or emergency event costs. The baseline solution recalculates the path matrix corresponding to the 16 source points; the solution to be verified queries the path dependency index, locates the incremental update set of the matrix, and performs local recalculation on the hit source-target point elements. The recalculation time, number of node visits, number of affected source points, number of matrix elements actually updated, and path cost error of the updated matrix elements relative to the baseline result are recorded for both solutions. It is verified that the missing matrix elements remain unchanged, and the backtracking path, business constraint identifier, and parameter version number of the recalculated elements are consistent.
[0148] The above verifications compare the computational overhead of initial matrix generation and dynamic matrix update, and evaluate the impact of finite-step expansion by considering coverage and path cost errors. The reduction in time consumption can be calculated by dividing the difference between the baseline solution's time consumption and the solution to be verified by the baseline solution's time consumption; the reduction in the number of access nodes is calculated using the same caliber. Before comparison, the fixed timing range and stopping conditions are used, and the warm-up and repetitive run settings are recorded. The overhead of supplementary calculations, secondary refinements, and full completion for cross-site service boundary orders is recorded separately and included in the total overhead required to complete the same target set.
[0149] This invention establishes a closed loop for path matrix generation and dynamic scheduling in LPG delivery scenarios through LPG delivery dynamic graphs, business edge weights, candidate frontier group partitioning, finite-step relaxation of key hub nodes, path matrix dependency identification, path dependency indexing, matrix incremental update set, digital twin simulation of scheduling schemes, and parameter version write-back. This closed loop improves the efficiency of multi-source path matrix generation and ensures that path results are continuously updated based on LPG safety constraints, cylinder IoT status, and simulation execution differences.
[0150] This invention can be deployed in LPG delivery scheduling cloud platforms, site-side servers, edge computing nodes, vehicle-mounted or handheld delivery terminals, and computing devices connected to gas cylinder IoT monitoring systems, order systems, and digital twin simulation systems to generate and maintain LPG delivery route matrices and support dynamic scheduling, enabling manufacturing and use in the industry.
[0151] The core improvements of this invention include at least the following three aspects.
[0152] First, a frontier compression path matrix generation strategy is proposed. By dividing candidate frontier groups and relaxing key hubs in finite steps, the global path search range is reduced, thereby reducing the computational cost of generating multi-source path matrices.
[0153] Second, a path-dependent index and matrix incremental update mechanism are designed to map dynamic events to the affected source-target matrix elements, replacing the full matrix recalculation after perturbation.
[0154] Third, construct a parameter adaptive closed loop driven by the differences in digital twin simulation, and update the edge weights, candidate frontier group division, key hub selection and local recalculation trigger parameters in reverse by the differences in delivery simulation execution.
[0155] Furthermore, candidate frontier group identifiers and business constraint identifiers are written into the matrix elements during the path matrix generation stage, enabling the path dependency index to locate affected matrix elements when dynamic changes occur. Based on the differences in the digital twin simulation, the comprehensive non-negative edge weights, candidate frontier group partitioning parameters, hub scoring parameters, and local recalculation thresholds are updated. The updated parameter content is saved as a new parameter version and associated with the parameter version number, allowing subsequent path matrix generation to utilize the results of the previous simulation. Thus, the frontier compressed matrix generation, incremental update of the path dependency index, and digital twin parameter closure work together to achieve multi-source matrix generation, local incremental recalculation, and virtual-real self-optimization within the same source-target matrix structure.
[0156] Compared with existing technologies, this invention has at least the following beneficial effects: Addressing the problem of high time consumption in full path matrix calculation, it reduces global sorting and full-map expansion through candidate front group partitioning, key hub nodes, and finite-step relaxation, concentrating path calculation on road subgraphs that affect the current LPG scheduling batch; addressing the problem of high cost of full-map recalculation after dynamic disturbances, path matrix elements store path backtracking pointers, candidate front group identifiers, business constraint identifiers, and parameter version numbers, and quickly form a matrix incremental update set through path dependency indexing, unlike ordinary dynamic path schemes that only replan single-vehicle routes; addressing the problem of the separation between LPG safety constraints and path calculation, it treats LPG hazardous material risks, cylinder status, inventory status, station boundaries, reserved release, vehicle passage, and safety or emergency events as technical constraints in the path matrix generation process, rather than simply overlaying business rules at the scheduling backend; addressing the problem of no closed loop between simulation and path calculation, it forms a closed loop of path matrix generation, scheduling optimization, simulation verification, and parameter updates through digital twin simulation differential write-back of edge weights, candidate front group partitioning, hubs, and recalculated parameters. This solution can reduce server computing power consumption, adapt to lightweight deployment on the site side or edge nodes, and help reduce the risks of illegal passage of dangerous goods, cross-regional delivery, and order timeouts.
[0157] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
Claims
1. A method for generating and scheduling LPG delivery route matrices, characterized in that, The method includes: Obtain LPG delivery business data and construct an LPG delivery dynamic graph based on the LPG delivery business data; the LPG delivery dynamic graph uses road nodes, station nodes, order nodes, delivery worker location nodes and candidate transfer points as vertices, and directed road edges and temporary access edges as edges; Based on the LPG delivery business data, determine the LPG delivery business constraints, generate comprehensive non-negative edge weights for the edges in the LPG delivery dynamic graph based on the LPG delivery business constraints, and record the business constraint identifier for the edges or vertices. Using the station nodes, gas delivery worker location nodes, or candidate transfer points in the LPG delivery dynamic map as the source points, a candidate front set is generated. The candidate front set includes vertices that have obtained path estimates but have not yet completed edge relaxation. The candidate frontier set is divided into multiple candidate frontier groups based on different partitioning types, and a candidate frontier group identifier is assigned to each candidate frontier group. Determine the hub evaluation index for each candidate front vertex in each candidate front group, and select key hub nodes based on the hub evaluation index; Around the key hub node, finite-step edge relaxation and recursive expansion are performed based on the comprehensive non-negative edge weights to obtain the path estimate from the source node to the target order node; An LPG delivery route matrix is generated based on the estimated route values, and a path dependency index is established. The path dependency index uses the identifier of the changed object determined based on the LPG delivery business data as the index key to map the corresponding set of affected source-target point matrix elements. A delivery scheduling scheme is generated based on the LPG delivery route matrix. The delivery scheduling scheme is then input into a digital twin simulation engine to perform delivery simulation and obtain the simulation execution results. Calculate the simulation execution difference between the simulation execution result and the delivery scheduling scheme, update at least one of the parameters involved in the generation and updating of the LPG delivery path matrix according to the simulation execution difference, and write the updated parameters into the parameter version library; When a delivery dynamic event occurs, or the simulation execution difference exceeds a preset threshold, the path dependency index is queried based on the changed object corresponding to the delivery dynamic event or the simulation execution difference, and a matrix incremental update set is generated. Only the source-target matrix elements that are hit in the matrix incremental update set are locally recalculated, while the matrix elements that are not hit remain unchanged.
2. The method for generating and scheduling LPG delivery route matrices according to claim 1, characterized in that, The LPG delivery business data includes road network data, station or transit warehouse data, order and reservation release data, delivery worker location and status data, gas cylinder IoT or inventory data, real-time traffic and safety or emergency event data, historical execution result data, gas cylinder IoT status and safety or emergency event data.
3. The method for generating and scheduling LPG delivery route matrices according to claim 1, characterized in that, The constraints on LPG delivery operations include toll costs, LPG hazardous materials delivery risks, site service boundaries, order reservation release or waiting costs, cylinder status, inventory status, safety or emergency events, and historical execution deviations.
4. The method for generating and scheduling LPG delivery route matrices according to claim 3, characterized in that, Based on the constraints of the LPG delivery business, the comprehensive non-negative edge weights generated for the edges in the LPG delivery dynamic graph include: Where T(e,t) is the estimated passage cost, R(e,t) is the LPG hazardous materials delivery risk, B(e,t) is the station service boundary or cross-regional penalty, Q(e,t) is the order reservation release or waiting cost, I(e,t) is the gas cylinder status or transit warehouse inventory constraint cost, E(e,t) is the safety or emergency event cost corresponding to road closure, leak warning, extreme weather or high temperature traffic restrictions, H(e,t) is the historical execution deviation correction term, and a1 to a7 are non-negative weight coefficients.
5. The method for generating and scheduling LPG delivery route matrices according to claim 4, characterized in that, The comprehensive non-negative edge weights also include the global road constraint cost Zroad(e,t,c): Where M(e,c) is the cost of adapting to the passage of delivery vehicles, P(e,t) is the cost of congestion during a given time period; K(e,t) is the cost of weather, season, traffic restrictions or control measures; L(e,t) is the cost of waiting or detouring at intersections; G(e,c) is the cost of multi-vehicle connection and coordination; C(e,c) is the cost of energy consumption or carbon emissions; m1 to m6 are non-negative weighting coefficients; The global road constraint cost Zroad(e,t,c) is either an independent global road constraint term in the comprehensive non-negative edge weights, or it can be incorporated into the estimated toll cost T(e,t), the LPG hazardous materials delivery risk R(e,t), the safety or emergency event cost E(e,t), or the historical execution deviation correction term H(e,t) for calculation.
6. The method for generating and scheduling LPG delivery route matrices according to claim 1, characterized in that, The classification types include at least one of the following: site service boundary, spatial grid, road grade, order density, risk level, and business constraint identifier.
7. The method for generating and scheduling LPG delivery route matrices according to claim 1, characterized in that, The pivot evaluation metrics for each candidate front vertex in each candidate front group include: Based on the LPG delivery business data and LPG delivery dynamic map, determine the boundary connectivity, road grade, target order accessibility, historical route traversal frequency and risk assessment value, and read the current distance estimate from the current route search record; The hub evaluation index is calculated using the following formula: Where C(v) is the boundary connectivity, G(v) is the road grade score, A(v) is the target order accessibility, F(v) is the frequency of historical path traversal, R(v) is the risk assessment value, D(v) is the cost penalty after normalization of the current distance estimate, and b1 to b6 are non-negative hub scoring parameters.
8. The method for generating and scheduling LPG delivery route matrices according to claim 1, characterized in that, The finite-step edge relaxation stops when any of the following conditions are met: the number of relaxation steps reaches 2 to 8 steps, the cumulative path cost increment exceeds a preset ratio of 30% to 80%, the target order node coverage rate within the candidate frontier group reaches a preset coverage rate of 60% to 95%, the number of newly covered target orders is less than a preset revenue threshold of 1 to 5 orders, or the extended path enters an impassable or high-risk constraint area.
9. The method for generating and scheduling LPG delivery route matrices according to claim 1, characterized in that, The LPG delivery route matrix includes the following matrix elements: route distance, estimated travel time, hazardous materials risk, out-of-area penalty and accessibility marker, route backtracking pointer, candidate front group identifier, business constraint identifier and parameter version number.
10. The method for generating and scheduling LPG delivery route matrices according to claim 1, characterized in that, The changed object identifiers include edge identifier, order identifier, gas cylinder identifier, inventory node identifier, site service boundary identifier, candidate frontier group identifier, business constraint identifier, and parameter version number.
