A solution algorithm for optimizing the vehicle scheduling in the secondary logistics distribution of refined oil
Through the improved taboo search algorithm and constructive heuristic algorithm, the vehicle scheduling solution in secondary logistics distribution of refined oil was optimized, and the problems of high distribution costs and low customer satisfaction in the existing technology were solved, and the goal of reducing costs and improving customer satisfaction was achieved.
Patent Information
- Application Number
- CN202211693379.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-12-28
- Publication Date
- 2025-07-01
- Estimated Expiration
- 2042-12-28
AI Technical Summary
In the secondary distribution of refined oil, it is difficult to quickly and efficiently optimize the vehicle scheduling plan in the prior art, resulting in low level of logistics informatization, high distribution costs and low customer satisfaction.
An improved taboo search algorithm is designed to solve the secondary logistics distribution scenario of refined oil based on mathematical modeling, and an initial feasible solution is generated in combination with a constructive heuristic algorithm, and iteratively optimized through the improved taboo search algorithm to obtain a higher quality vehicle scheduling solution.
It has achieved auxiliary staff decision-making, reduced vehicle delivery costs, improved customer satisfaction, and optimized logistics delivery models.
Smart Images

Figure CN116187531B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of vehicle scheduling, and particularly relates to a solution algorithm for optimizing the vehicle scheduling of the secondary logistics distribution of refined oil products. Background Art
[0002] In recent years, with the rapid development of the social economy and the application and upgrade of the Internet of Things technology, modern logistics technology has undergone major changes and breakthroughs on the basis of the traditional mode. Smart logistics, which is developing towards automation, informatization, and intelligence, is increasingly recognized and accepted by enterprises in transportation, warehousing, production, sales, etc.
[0003] At present, the petrochemical industry, as a traditional energy industry, is not only greatly impacted by the fluctuations in the crude oil and refined oil product markets, but also faces the dual pressures of economic and energy structure adjustments. In this situation, the demand for optimizing the oil supply chain is increasing day by day. As the final link of the oil supply chain, the purpose of the secondary distribution of refined oil products is to transport the refined oil products in the oil depot to each gas station by tanker trucks, so as to meet the replenishment needs of the gas stations. In the refined oil product logistics system, the cost of the secondary distribution of refined oil products accounts for as high as 60%-70% of the total logistics cost, and there is great potential for optimization. Therefore, more and more oil enterprises regard optimizing the logistics distribution mode of refined oil products as an important breakthrough point for reducing operating costs and increasing enterprise benefits.
[0004] The secondary distribution system of refined oil products mainly consists of elements such as oil depots, distribution vehicles, and gas station networks, and is uniformly managed by the distribution center. However, there are still many shortcomings in the refined oil product logistics distribution of oil enterprises. For example, the level of logistics informatization is low, and the distribution center cannot quickly respond to the site demands; most of the vehicle distribution plans are obtained based on manual experience, and the solution quality and solution efficiency are low. Coupled with the fact that the secondary distribution problem of refined oil products belongs to the vehicle routing problem in terms of classification, which is a typical NP-hard problem with a high solution complexity. Therefore, how to obtain a high-quality vehicle scheduling plan for the secondary distribution of refined oil products in a short time is an urgent problem to be solved. Summary of the Invention
[0005] In view of this, the purpose of the present invention is to provide a solution algorithm for optimizing the vehicle scheduling of the secondary logistics distribution of refined oil products. On the basis of the mathematical modeling of the secondary logistics distribution scenario of refined oil products, an improved tabu search algorithm is designed to quickly and efficiently solve the problem, so as to achieve the goals of assisting staff in decision-making, reducing vehicle distribution costs, and improving customer satisfaction.
[0006] The solution algorithm for optimizing the vehicle scheduling of the secondary logistics distribution of refined oil products described above includes the following processes.
[0007] Symbol Definition
[0008] N = {0, 1, …, |N|}: the set of nodes; where {0} represents the oil depot, i.e., the starting and ending points of the route;
[0009] N ′ = {1, …, |N|}, representing the gas stations to be delivered;
[0010] K = {1, 2, …, |K|}: the set of delivery vehicles;
[0011] P i = {1, 2, …, |P i |}: the set of demand orders for gas station i;
[0012] M k = {1, 2, …, |M k |}: the set of compartments of delivery vehicle k;
[0013] R k = {1, 2, …, |R k |}: the set of trips of delivery vehicle k;
[0014] i, j: node numbers, i, j ∈ N;
[0015] k: delivery vehicle number, k ∈ K;
[0016] p: order number, p ∈ P i ;
[0017] m: compartment number, m ∈ M k ;
[0018] r: vehicle trip number, r ∈ R k ;
[0019] Parameter definitions
[0020] d ij : the route distance (in kilometers) between node i and node j;
[0021] q ip : the demand (in kiloliters) of order p at station i;
[0022] Q km : the capacity (in kiloliters) of compartment m of vehicle k;
[0023] λ: the maximum working time (in hours) of the vehicle;
[0024] v: the driving speed (in kilometers per hour) of the vehicle;
[0025] s1: the oil loading rate (in kiloliters per minute);
[0026] s2: Oil unloading rate (kiloliters per minute);
[0027] α: Minimum loading rate of the vehicle compartment;
[0028] β: Minimum delivery rate of the order;
[0029] c1: Fixed vehicle usage cost (yuan per vehicle);
[0030] c2: Unit delivery cost of the vehicle (yuan per kilometer);
[0031] c3: Unit loss cost of the undelivered part of the order (yuan per kiloliter);
[0032] c4: Unit loss cost of the undelivered order (yuan per kiloliter);
[0033] Variable definition
[0034] x ijkr : If vehicle k passes through the route (i, j) from site i to site j, then x ijkr = 1, otherwise x ijkr = 0;
[0035] y ikpmr : If the order p at site i is loaded into the vehicle compartment m of vehicle k and delivered during trip r,
[0036] then y ikpmr = 1, otherwise y ikpmr = 0;
[0037] z ikr : Represents the order in which vehicle k visits site i during trip r;
[0038] u kr : If vehicle k makes a delivery during trip r, then u kr = 1, otherwise u kr = 0;
[0039] Objective function
[0040] The problem of secondary distribution of refined oil can be described as follows: For a single oil depot and multiple gas stations, the oil tanker loads the oil orders required by the gas stations at the oil depot, then visits the gas stations along the distribution route in sequence to complete the oil unloading task, and finally returns to the oil depot. However, due to limited vehicle resources and diverse oil orders, it is impossible to ensure that the distribution needs of all gas stations can be met. In this case, when designing the vehicle scheduling plan for secondary distribution of refined oil, not only the overall distribution cost needs to be considered, but also the degree of satisfaction of the gas station demand.
[0041] Based on the above, the objective function of the refined oil secondary distribution problem in the present invention is set as a comprehensive objective function, which mainly consists of two parts: vehicle distribution cost and order loss cost. Among them, the vehicle distribution cost reflects the cost generated during the vehicle transportation process, and the order loss cost reflects the loss cost generated due to the unmet demand of gas stations.
[0042] The vehicle distribution cost can be further divided into vehicle fixed distribution cost and vehicle variable transportation cost. The former represents the fixed cost generated by the vehicle being used, and the latter is positively correlated with the vehicle's transportation distance.
[0043] The expression of the vehicle fixed usage cost is shown in Equation (1):
[0044] c1∑ k∈K u k1 (1)
[0045] The expression of the vehicle variable transportation cost is shown in Equation (2):
[0046]
[0047] The order loss cost can be further divided into the loss cost of the undistributed part of the order and the loss cost of the undelivered order. The former represents the loss generated by the part of the order capacity that exceeds the vehicle compartment capacity and cannot be distributed, and the latter represents the loss generated by the order that cannot be distributed.
[0048] The expression of the loss cost of the undistributed part of the order is shown in Equation (3):
[0049]
[0050] The expression of the loss cost of the undelivered order is shown in Equation (4):
[0051]
[0052] The expression of the comprehensive objective function is shown in Equation (5):
[0053]
[0054] The solution objective of the designed model in the present invention is to minimize the comprehensive cost function, which considers both the overall transportation distance of the vehicle and the demand satisfaction degree of gas stations, so that the solution scheme is more in line with the actual situation of the enterprise.
[0055] Model Constraints
[0056] The refined oil secondary distribution problem is essentially a vehicle routing problem. However, due to the particularity and complexity of the oil distribution scenario, in addition to having the general characteristics of traditional VRP problems such as multiple vehicle types and multiple products, it also has the following characteristics of oil distribution:
[0057] (1) Multi-compartment vehicles: Most refined oil distribution vehicles are multi-compartment tank trucks. Each vehicle compartment corresponds to loading one order. A tank truck can load multiple refined oil orders at a time and distribute them to multiple gas stations.
[0058] (2) Compartment loading: Since refined oil is a dangerous good that is flammable and explosive, when the compartment loading is too low, the friction between the refined oil and the tank wall is likely to cause vehicle accidents, and the sloshing liquid is not conducive to the stable driving of the vehicle. Therefore, refined oil distribution needs to meet the compartment loading constraint, that is, the loading rate needs to reach above the standard.
[0059] (3) Multi-trip distribution: Due to the large order scale, tank trucks usually need to perform multiple trips of distribution tasks to meet the daily distribution plan, and the total distribution time of all trips of the tank truck cannot exceed its maximum working time.
[0060] Based on the above characteristics of the secondary distribution of refined oil, the present invention converts them into model constraints using mathematical expressions, thereby performing mathematical modeling.
[0061] For the distribution vehicle, each of its trips starts from the oil depot, returns to the oil depot after completing the distribution of the refined oil order, and then prepares for the distribution of the next trip. And the distribution vehicle can only start the next trip after completing the distribution task of the previous trip. In addition, since the problem is defined on a connected graph, each node on the graph has a flow balance constraint, that is, the number of times entering the node is equal to the number of times leaving the node. To avoid generating sub-circuits in the vehicle path plan, the present invention adopts the MTZ constraint to eliminate sub-circuits. Thus, the constraints shown in Equations (6)-(10) are obtained.
[0062]
[0063] Equation (6) indicates that the start of any trip of any vehicle starts from the oil depot;
[0064] Equation (7) indicates that the end of any trip of any vehicle returns to the oil depot;
[0065] Equation (8) indicates that for any vehicle, only after the previous trip is completed can the next trip start;
[0066] Equation (9) indicates the inflow and outflow balance constraint;
[0067] Equation (10) indicates the MTZ sub-circuit elimination constraint;
[0068] In the secondary distribution problem of refined oil, each oil product order can only be loaded on one cabin at most, and each cabin can only load one order at most. In addition, the feasibility of loading an order on a cabin is related to the actual order capacity loaded on the cabin. The ratio of the actual loading volume to the cabin capacity needs to be no less than the minimum loading rate of the cabin, and the ratio of the actual loading volume to the order capacity needs to be no less than the minimum distribution rate of the order. Therefore, the present invention defines constraints such as equations (11) to (14).
[0069]
[0070] Formula (11) indicates that any cabin in any trip of any vehicle can only carry one order at most; Formula (12) indicates that any order at any station can only be loaded into one cabin at most;
[0071] Formula (13) indicates that if an order is loaded onto a vehicle cabin, the loading rate of the vehicle cabin cannot be lower than the minimum loading rate α; Formula (14) indicates that part of the order may not be delivered, but the actual delivery rate of the order cannot be lower than the minimum delivery rate β;
[0072] For any delivery vehicle, its total delivery time cannot exceed the maximum working time. The delivery time of a vehicle in a certain trip mainly consists of three parts: the loading time of the oil order, the unloading time of the oil order, and the vehicle transportation time. The total delivery time of the vehicle is the sum of the delivery time of all trips. Therefore, the present invention defines a constraint as shown in formula (15).
[0073]
[0074] Formula (15) indicates that the total vehicle delivery time cannot exceed the maximum working time;
[0075] Formula (16) to Formula (19) are definitions of variables.
[0076] Constructive heuristic algorithm
[0077] The present invention proposes a constructive heuristic algorithm based on improved nearest neighbor insertion to quickly obtain an initial feasible solution to the secondary distribution problem of refined oil products. The feasible solution includes the distribution route plan for each vehicle to visit the gas station each trip and the loading plan for the oil product order on the vehicle cabin.
[0078] The main goal of generating the initial solution is to consider the lower delivery cost while satisfying the oil product order delivery needs of all stations as much as possible. Based on this goal, the constructive heuristic algorithm provided by the present invention adopts the solution idea of grouping first and then routing, that is, first determine the combination of gas stations to be delivered, then select the most suitable delivery vehicle for delivery according to the station combination, and generate the corresponding vehicle delivery plan.
[0079] When the loading plan of the vehicle is determined, that is, the combination of stations that the vehicle needs to visit is already known, it is very easy to solve the optimal route plan for the vehicle at this time. Since the maximum number of compartments of the vehicle does not exceed 4, the number of stations visited by the vehicle during the journey will not exceed 4 either. By traversing, the route plan that minimizes the delivery distance of the journey can be obtained quickly. However, for different combinations of stations, there can be multiple feasible loading plans for the vehicle, and the vehicle resources are limited. The division of the combination of stations and the selection of the loading plan will affect subsequent decisions, thereby affecting the quality of the overall delivery plan. In order to obtain an overall better delivery plan, the present invention makes decisions on station grouping and order loading plan selection by defining evaluation indicators such as order delivery urgency, station delivery priority, and loading plan delivery efficiency.
[0080] Symbol Definition:
[0081] N = {0, 1, …, |N|}: Node set; where {0} represents the oil depot, that is, the starting and ending points of the route;
[0082] N ′ = {1, …, |N|}, representing the gas stations to be delivered;
[0083] K = {1, 2, …, |K|}: Delivery vehicle set;
[0084] P i = {1, 2, …, |P i |}: The set of orders to be delivered at gas station i;
[0085] M k = {1, 2, …, |M k |}: The compartment set of delivery vehicle k;
[0086] R k = {1, 2, …, |R k |}: The journey set of delivery vehicle k;
[0087] L: The loading plan of the order corresponding to the compartment;
[0088] D: The set of all feasible loading plans;
[0089] S: The set of vehicle delivery plans;
[0090] i, j: Node numbers, i, j ∈ N;
[0091] k: Delivery vehicle number, k ∈ K;
[0092] p: Order number, p ∈ P i ;
[0093] m: Cabin number, m ∈ M k ;
[0094] r: Vehicle trip number, r ∈ R k ;
[0095] d ij : Route distance between node i and node j;
[0096] θ ipkmr : A status variable measuring whether the cabin m of vehicle k can meet the loading of order p at station i during trip r.
[0097] If θ ipkmr = 1, it means that the vehicle cabin can load and deliver the order. Otherwise, θ ipkmr = 0;
[0098] w1, w2, w3, w4, w5: Control parameters;
[0099] For any order p at any gas station i, the delivery urgency O ip is calculated as follows:
[0100]
[0101] Among them, by counting the number of available delivery times of all cabins that meet the order loading requirements, an evaluation of the available delivery resources for the order is obtained. If the delivery resources are fewer, it means that the delivery urgency of this order is higher, so the cabin is considered to be preferentially allocated to this order;
[0102] For the delivery priority J i of any gas station i, the calculation formula is as follows:
[0103]
[0104] Among them, d 0i represents the route distance from gas station i to the oil depot; The evaluation of the delivery priority mainly considers two aspects: the distance from the station to the oil depot and the delivery urgency of the orders belonging to this station. If the distance from the station to the oil depot is farther and the sum of the delivery urgencies of all orders at the station is greater, then the delivery priority of this station is greater.
[0105] For a feasible order loading plan L, the calculation formula of its delivery benefit is as follows:
[0106] f(L) = w4C(L) + w5U(L) (22) Among them, f(L) represents the delivery benefit of the loading plan, C(L) represents the delivery cost of this loading plan, and U(L) represents the overall order delivery urgency in this loading plan. This indicator shows that if a delivery plan has a lower delivery cost and the delivery urgency of the orders loaded in this plan is higher, then the delivery benefit of this plan is higher.
[0107] Based on the above settings, the steps of the structural heuristic algorithm proposed by the present invention are as follows:
[0108] Step 1: Initialize the set N′ of stations to be delivered, the set K of deliverable vehicles, and the set S of vehicle delivery plans;
[0109] Step 2: If the current set N′ of delivery stations is not empty, go to Step 3; otherwise, go to Step 13;
[0110] Step 3: Update the delivery urgency of all orders based on formula (20), and then calculate the delivery priority of all stations to be delivered based on formula (21). Select the station with the highest delivery priority as the seed station i, and generate the initial station combination {i};
[0111] Step 4: For the initial station combination, sequentially select vehicles from the set K of deliverable vehicles. If a vehicle has a feasible order loading plan L, add this plan to the set D of loading plans;
[0112] Step 5: Set the best loading plan L best to be empty, and set the best delivery benefit f best to be 0;
[0113] Step 6: If the current set D of loading plans is empty, go to Step 10; otherwise, go to Step 7;
[0114] Step 7: Sequentially select and remove loading plans from the set D of loading plans. If there are unassigned loading orders in the vehicle compartment in the selected loading plan, go to Step 8; otherwise, go to Step 9;
[0115] Step 8: For the selected loading plan L, obtain the station combination visited by the current vehicle according to the order information it loads. Select the best station to insert based on the nearest neighbor insertion algorithm. For the inserted station combination, determine whether there is a feasible inserted loading plan L′. If it exists, add the new loading plan L′ to the set D and go to Step 7; otherwise, go to Step 9;
[0116] Step 9: For the selected loading plan L, calculate the delivery benefit of the loading plan based on formula (22). If f(L)>f best , then update L best =L, f best =f(L), and go to Step 5;
[0117] Step 10: If L best is empty, indicating that there is no feasible delivery plan for the seed station i, go to Step 11; otherwise, go to Step 12;
[0118] Step 11: Remove the seed site i from the set N' of sites to be delivered; go to Step 2;
[0119] Step 12: According to the optimal loading plan L best , solve its corresponding optimal delivery route plan, save the loading plan and the route plan to the set S of vehicle delivery plans, and update the set N' of sites to be delivered and the set K of available delivery vehicles; go to Step 2;
[0120] Step 13: The algorithm terminates, and the final set S of vehicle delivery plans is output;
[0121] Improved Tabu Search Algorithm
[0122] In view of the characteristics of the secondary distribution problem of refined oil, the present invention proposes an improved Tabu Search Algorithm, which iteratively optimizes the initial feasible solution obtained by the construction heuristic algorithm of nearest neighbor insertion, so as to obtain a vehicle scheduling plan with higher quality, so as to achieve the goal of reducing the logistics distribution cost and improving the customer satisfaction.
[0123] The design of the Tabu Search Algorithm provided by the present invention is as follows.
[0124] Symbol Definition:
[0125] S0: Initial vehicle delivery plan for the secondary distribution of refined oil;
[0126] n: Number of gas stations;
[0127] k: Number of delivery vehicles;
[0128] S best : Current best vehicle delivery plan;
[0129] f best : Current optimal objective function value;
[0130] L: Tabu list length;
[0131] N: Candidate solution set;
[0132] M: Maximum number of iterations;
[0133] Form of solution:
[0134] The overall vehicle delivery plan can be divided into three levels of "overall - vehicle - trip". For the delivery plan of a single vehicle for a single trip, it needs to include both the order of sites visited by the vehicle in the current trip and the allocation of orders to the vehicle cabin. Therefore, the present invention defines the form of the solution as X = {ξ1, ξ2,..., ξ i ,... ξ m}, where ξ iIt is regarded as a node of the delivery plan and serves as the basic element of the solution.
[0135] ξ i What is stored is the pairing plan between the order and the vehicle compartment. For example, if ξ1 = (O1, M1), it means that order O1 is loaded onto vehicle compartment M1; in addition to storing the pairing information between the order and the vehicle compartment, the subscript i of ξ i represents the order in which the orders in this delivery plan are delivered. For example, if ξ1 = (O1, M1) and the subscript of ξ1 is 1, it means that order O1 is the first order to be delivered, thereby determining the visiting order of the gas stations.
[0136] Fitness function:
[0137] In the present invention, the fitness function is set as the comprehensive cost function corresponding to the vehicle delivery plan.
[0138] Neighborhood action:
[0139] For the vehicle delivery plan, its quality is determined by the vehicle routing plan, and its feasibility is determined by the order loading plan. In order to better explore the neighborhood space of the solution, the present invention defines three different neighborhood operators to achieve neighborhood exploration in different directions.
[0140] (1) Node swap: For two nodes in the same route or different routes, swap their positions;
[0141] (2) Relocate: Remove a node on a certain route and insert it into another position;
[0142] (3) 2-opt: Select two nodes on different routes and swap the itinerary segments after the selected nodes;
[0143] In order to improve the efficiency of neighborhood exploration, the present invention assigns weights to each neighborhood operator, defines the probability of each operator being selected based on Equation (23) in each iteration, and selects using the roulette wheel rule.
[0144]
[0145] In the formula, w i represents the weight of operator i.
[0146] Tabu object and tabu list:
[0147] From the definition of the form of the solution, it can be seen that the node ξ i is the basic element of the itinerary plan, and the transformation of the neighborhood action is also the transformation of the node. Therefore, the movement of the node is selected as the tabu object, which is essentially the removal and insertion of orders.
[0148] In order to enable the algorithm to explore the neighborhood solutions as much as possible in the early stage and mainly focus on exploring the better solutions in the later stage. Therefore, the length of the tabu list in the present invention is dynamic, and the length of the tabu list gradually increases as the number of iterations increases, which is obtained by Equation (24).
[0149]
[0150] In the formula, L0 is the initial tabu step size of the short tabu list, i is the number of iterations, rand is a random number in the interval (0, 1), and τ is a parameter set based on the problem scale to ensure that the change of the tabu step size will not be too large.
[0151] In addition, in order to prevent the algorithm from falling into repeated and ineffective iterations, after a certain number of iterations, if the optimal solution has not been improved, the tabu list can be reset or the length of the tabu list can be reduced to perform more neighborhood operations. Or, after a certain number of iterations, if the optimal solution has not been improved, the current optimal solution or better solution is set as the initial solution for re-iteration, and the tabu list is reset.
[0152] Centralization and diversification strategies:
[0153] Candidate solutions are solutions generated by the initial solution through neighborhood actions. In order to balance the local search ability and the global search ability, different candidate solutions can be generated based on different strategies and then stored in the candidate solution set. The centralization strategy is used to strengthen the further and more sufficient exploration of the neighborhood of the currently searched excellent solutions in order to find the global optimal solution. The diversification strategy is used to broaden the search area, especially the unknown area. Especially when falling into the local optimum, the search based on the diversification strategy can change the search direction and jump out of the local optimum, thus realizing global optimization.
[0154] Based on the above ideas, the present invention divides the candidate solution set into two parts. The elements in the first half are called centralization elements for centralization search; the elements in the second half are called diversification elements for diversification search. For centralization elements, they should be few and refined, and the main quality should be high, so they can be generated by the insertion method; for diversification elements, they should be many and extensive, and try to explore areas that have never been explored before, so they are generated by the random method.
[0155] Aspiration criterion:
[0156] During the iteration process, a solution better than all the solutions in the explored solution space may be obtained, and there is no reason for this solution to be tabu. The present invention adopts an aspiration criterion based on the fitness value. If there is a tabu solution in the candidate solution set that is better than the known optimal solution, this solution is de-tabued and used as the initial solution for the next iteration, and the optimal solution is updated accordingly. Otherwise, the current locally optimal solution that is not tabu is selected from the candidate solution set as the initial solution for the next iteration;
[0157] Algorithm termination criterion:
[0158] For the tabu search algorithm, the strict convergence condition, that is, traversing the state space under the condition of a sufficiently large tabu length, is obviously impractical. Therefore, an approximate convergence criterion is usually adopted when actually designing the algorithm. In the present invention, the maximum number of iterations is set to M.
[0159] The main steps of the tabu search algorithm are as follows:
[0160] Step 1: Initialize the algorithm and set parameters, including the tabu list length, candidate set length, and maximum number of iteration steps;
[0161] Step 2: Generate an initial feasible solution based on a constructive heuristic as the starting point for iterative search;
[0162] Step 3: Apply a concentration strategy and a diversification strategy respectively to generate a candidate solution set;
[0163] Step 4: According to the evaluation function, determine whether there is a solution in the current candidate solution set that satisfies the aspiration criterion. If so, select this solution as the initial solution for the next iteration; otherwise, select the current local optimal solution that is not tabu from the candidate solution set as the initial solution for the next iteration;
[0164] Step 5: Update the tabu list;
[0165] Step 6: Determine whether the algorithm meets the termination condition. If it does, output the optimal solution that appears during the iteration and terminate the algorithm; if not, use the currently selected solution as the starting point for the next iteration, and go to Step 3.
[0166] The beneficial effects of the present invention are as follows: Based on the characteristics of the refined oil secondary distribution problem, the present invention constructs a vehicle scheduling model with the lowest comprehensive cost as the objective function, and designs a constructive heuristic algorithm based on nearest neighbor insertion to quickly obtain a feasible vehicle scheduling plan as the initial feasible solution for subsequent iterations. Furthermore, based on an improved tabu search algorithm, the initial solution is iteratively optimized to obtain a vehicle scheduling plan with higher quality, thereby meeting the goals of the enterprise to reduce logistics costs and improve customer satisfaction, and promoting the construction of the enterprise's modern logistics system. Description of the Drawings
[0167] Figure 1 is the flow chart of refined oil secondary logistics distribution;
[0168] Figure 2 is the flow chart of the constructive heuristic algorithm for solving;
[0169] Figure 3 is the structure diagram of the solution to the refined oil secondary distribution problem;
[0170] Figure 4 It is the flow chart of the tabu search algorithm. Specific implementation mode
[0171] For the convenience of understanding by those skilled in the art, the present invention will be further described below in conjunction with examples and drawings. The content mentioned in the implementation mode does not limit the present invention.
[0172] A solution algorithm for optimizing the vehicle scheduling of the secondary logistics distribution of refined oil products, and its modeling process is as follows: Symbol definition
[0173] N = {0, 1, …, |N|}: Node set; where {0} represents the oil depot, that is, the starting point and ending point of the route;
[0174] N ′ = {1, …, |N|}, representing the gas stations to be distributed;
[0175] K = {1, 2, …, |K|}: Distribution vehicle set;
[0176] P i = {1, 2, …, |P i |}: Demand order set of gas station i;
[0177] M k = {1, 2, …, |M k |}: Compartment set of distribution vehicle k;
[0178] R k = {1, 2, …, |R k |}: Itinerary set of distribution vehicle k;
[0179] i, j: Node numbers, i, j ∈ N;
[0180] k: Distribution vehicle number, k ∈ K;
[0181] p: Order number, p ∈ P i ;
[0182] m: Compartment number, m ∈ M k ;
[0183] r: Vehicle itinerary number, r ∈ R k ;
[0184] Parameter definition
[0185] d ij : Route distance (km) between node i and node j;
[0186] q ip : Demand volume (kiloliters) of order p at site i;
[0187] Q km : Capacity (kiloliters) of the cabin m of vehicle k;
[0188] λ: Maximum working time (hours) of the vehicle;
[0189] v: Driving speed (km / h) of the vehicle;
[0190] s1: Loading rate of oil products (kiloliters / minute);
[0191] s2: Unloading rate of oil products (kiloliters / minute);
[0192] α: Minimum loading ratio of the cabin;
[0193] β: Minimum delivery ratio of the order;
[0194] c1: Fixed usage cost of the vehicle (yuan / vehicle);
[0195] c2: Unit delivery cost of the vehicle (yuan / km);
[0196] c3: Unit loss cost of the undelivered part of the order (yuan / kiloliter);
[0197] c4: Unit loss cost of the undelivered order (yuan / kiloliter);
[0198] Variable definition
[0199] x ijkr : If vehicle k passes through the route (i, j) from site i to site j, then x ijkr = 1, otherwise x ijkr = 0;
[0200] y ikpmr : If the order p at site i is loaded into the cabin m of vehicle k and delivered during trip r, then y ikpmr = 1, otherwise y ikpmr = 0;
[0201] z ikr : Represents the order in which vehicle k visits site i during trip r;
[0202] u kr : If vehicle k makes a delivery during trip r, then u kr = 1, otherwise u kr = 0;
[0203] The problem of secondary distribution of refined oil can be described as follows: For a single oil depot and multiple gas stations, the oil tanker loads the oil product orders required by the gas stations at the oil depot, then sequentially visits the gas stations along the distribution route to complete the oil unloading task, and finally returns to the oil depot. The logistics distribution flowchart is as Figure 1 shown.
[0204] Mathematical model
[0205] The mathematical model for the secondary logistics distribution of refined oil is as follows:
[0206]
[0207]
[0208] Formula 1 is the objective function for minimizing the comprehensive distribution cost;
[0209] Formula 2 indicates that any trip of any vehicle starts from the oil depot;
[0210] Formula 3 indicates that any trip of any vehicle ends by returning to the oil depot;
[0211] Formula 4 indicates that for any vehicle, the next trip can only start after the previous trip is completed;
[0212] Formula 5 represents the inflow - outflow balance constraint;
[0213] Formula 6 represents the MTZ sub - tour elimination constraint;
[0214] Formula 7 indicates that for any compartment in any trip of any vehicle, it can load at most one order;
[0215] Formula 8 indicates that for any order at any station, it can be loaded into at most one compartment;
[0216] Formula 9 indicates that if an order is loaded onto a compartment, the loading rate of the compartment cannot be lower than the minimum loading rate α;
[0217] Formula 10 indicates that partial non - delivery of orders is allowed, but the actual delivery rate of orders cannot be lower than the minimum delivery rate β; Formula 11 indicates that the total vehicle delivery time cannot exceed the maximum working time;
[0218] Formulas 12 - 15 are the definitions of variables.
[0219] Constructive heuristic algorithm
[0220] The algorithm flow of the constructive heuristic is as Figure 2 shown:
[0221] Step 1: Initialize the set N′ of stations to be delivered, the set K of deliverable vehicles, and the set S of vehicle delivery plans;
[0222] Step 2: If the current set N′ of delivery stations is not empty, go to Step 3; otherwise, go to Step 13;
[0223] Step 3: Update the delivery urgency of all orders based on formula (16), and then calculate the delivery priority of all stations to be delivered based on formula (17). Select the station with the highest delivery priority as the seed station i, and generate the initial station combination {i};
[0224] Step 4: For the initial station combination, sequentially select vehicles from the set K of deliverable vehicles. If a vehicle has a feasible order loading plan L, add this plan to the set D of loading plans;
[0225] Step 5: Set the best loading plan L best to be empty, and set the best delivery benefit f best to be 0;
[0226] Step 6: If the current set D of loading plans is empty, go to Step 10; otherwise, go to Step 7;
[0227] Step 7: Sequentially select and remove loading plans from the set D of loading plans. If there are unassigned loading orders in the vehicle compartment in the selected loading plan, go to Step 8; otherwise, go to Step 9;
[0228] Step 8: For the selected loading plan L, obtain the station combination visited by the current vehicle according to the order information it loads. Select the best station to insert based on the nearest neighbor insertion algorithm. For the inserted station combination, determine whether there is a feasible inserted loading plan L'. If it exists, add the new loading plan L' to the set D and go to Step 7; otherwise, go to Step 9;
[0229] Step 9: For the selected loading plan L, calculate the delivery benefit of the loading plan based on formula (18). If f(L)>f best , then update L best =L, f best =f(L), and go to Step 5;
[0230] Step 10: If L best is empty, it means there is no feasible delivery plan for the seed station i. Go to Step 11; otherwise, go to Step 12;
[0231] Step 11: Remove the seed station i from the set N' of stations to be delivered; go to Step 2;
[0232] Step 12: According to the best loading plan L best , solve its corresponding best delivery route plan, save the loading plan and the route plan to the set S of vehicle delivery plans, and update the set N' of stations to be delivered and the set K of deliverable vehicles; go to Step 2;
[0233] Step 13: The algorithm terminates, and the final vehicle delivery plan set S is output;
[0234] Symbol Definition:
[0235] N = {0, 1, …, |N|}: Node set; where {0} represents the oil depot, i.e., the starting and ending points of the route;
[0236] N ′ = {1, …, |N|}, representing the gas stations to be delivered;
[0237] K = {1, 2, …, |K|}: Delivery vehicle set;
[0238] P i = {1, 2, …, |P i |}: Set of orders to be delivered for gas station i;
[0239] M k = {1, 2, …, |M k |}: Compartment set of delivery vehicle k;
[0240] R k = {1, 2, …, |R k |}: Itinerary set of delivery vehicle k;
[0241] L: Loading plan for the compartment corresponding to the order;
[0242] D: Set of all feasible loading plans;
[0243] S: Vehicle delivery plan set;
[0244] i, j: Node numbers, i, j ∈ N;
[0245] k: Delivery vehicle number, k ∈ K;
[0246] p: Order number, p ∈ P i ;
[0247] m: Compartment number, m ∈ M k ;
[0248] r: Vehicle itinerary number, r ∈ R k ;
[0249] d ij : Route distance between node i and node j;
[0250] θ ipkmr : A state variable measuring whether the compartment m of vehicle k can satisfy the loading of order p at site i during itinerary r,
[0251] If θ ipkmr = 1, it means the vehicle compartment can load and deliver the order; otherwise, θipkmr = 0;
[0252] w1, w2, w3, w4, w5: control parameters;
[0253] For any order p of any gas station i, its delivery urgency O ip is calculated as follows:
[0254]
[0255] For the delivery priority J of any gas station i i is calculated as follows:
[0256]
[0257] For a feasible order loading plan L, the formula for its delivery benefit is as follows:
[0258] f(L) = w4C(L) + w5U(L) (18)
[0259] Improved Tabu Search Algorithm
[0260] The flow chart of the Tabu Search Algorithm is as Figure 4 shown.
[0261] Step 1: Initialize the algorithm, set parameters, including the length of the Tabu list, the length of the candidate set, and the maximum number of iteration steps;
[0262] Step 2: Generate an initial feasible solution based on a constructive heuristic as the starting point for iterative search;
[0263] Step 3: Apply the intensification strategy and the diversification strategy respectively to generate a candidate solution set;
[0264] Step 4: According to the evaluation function, determine whether there is a solution in the current candidate solution set that satisfies the aspiration criterion. If so, select this solution as the initial solution for the next iteration; otherwise, select the current local optimal solution that is not tabu in the candidate solution set as the initial solution for the next iteration;
[0265] Step 5: Update the Tabu list;
[0266] Step 6: Determine whether the algorithm meets the termination condition. If it does, output the optimal solution that appears during the iteration and terminate the algorithm; if not, use the currently selected solution as the starting point for the next iteration and go to Step 3.
[0267] Symbol Definition:
[0268] S0: Initial vehicle delivery plan for secondary refined oil delivery;
[0269] n: Number of gas stations;
[0270] k: The number of distribution vehicles;
[0271] S best : The current best vehicle distribution plan;
[0272] f best : The current optimal objective function value;
[0273] L: The length of the taboo list;
[0274] N: The candidate solution set;
[0275] M: The maximum number of iterations;
[0276] The form of the solution:
[0277] The overall vehicle distribution plan can be divided into three levels: "overall - vehicle - itinerary", as Figure 3 shown.
[0278] X = {ξ1, ξ2, …, ξ i , … ξ m} (19)
[0279] The selection of the neighborhood operator:
[0280]
[0281] The length of the taboo list:
[0282]
Claims
1. A solution algorithm for optimizing the vehicle scheduling in the secondary logistics distribution of refined oil products, characterized in that It includes the following steps: 1) Input the basic logistics plan and logistics data of the refined oil secondary logistics distribution problem; 2) Construct an objective function and a corresponding mathematical model according to the problem characteristics and solution objectives of the refined oil secondary logistics distribution; 3) Solve the refined oil secondary distribution problem based on the constructive heuristic algorithm to obtain an initial feasible solution; 4) Iteratively optimize the initial feasible solution obtained by the constructive algorithm based on the tabu search algorithm, and save and output the historical optimal solution; 5) Based on the historical optimal solution obtained by the algorithm, export it as an optimal vehicle scheduling plan; The construction process of the objective function in step 2) is as follows: Set the objective function of the refined oil secondary distribution problem as a comprehensive objective function, which is mainly composed of two parts: vehicle distribution cost and order loss cost. The vehicle distribution cost is divided into vehicle fixed distribution cost and vehicle variable transportation cost, and the order loss cost is divided into order undelivered part loss cost and undelivered order loss cost. The expression of the vehicle fixed usage cost is shown in Equation (1). c1: Vehicle fixed usage cost, unit: yuan / vehicle; k: Distribution vehicle number, k ∈ K; u kr : u k1 is the distribution situation of vehicle k in the first trip. If vehicle k makes a delivery during trip r, then u kr = 1, otherwise u kr = 0; The expression of the vehicle variable transportation cost is shown in Equation (2). c2: The unit distribution cost of the vehicle, unit: yuan / km; i, j: Node numbers, i, j ∈ N; r: Vehicle trip number, r ∈ R k ; d ij : Route distance between node i and node j, unit: kilometer; x ijkr : If vehicle k passes through the route i, j from stop i to stop j, then x ijkr = 1, otherwise x ijkr = 0; The expression of the order undelivered part loss cost is shown in Equation (3). c3: The unit loss cost of the undelivered part of the order, unit: yuan / kiloliter; p : Order number, p ∈ P i ; m: Compartment number of the vehicle, m ∈ M k ; y ikpmr : If the order p at station i is loaded into compartment m of vehicle k and is delivered during trip r, then y ikpmr = 1, otherwise y ikpmr = 0; q ip : Demand of order p at station i, unit: kiloliter; Q km : Capacity of compartment m of vehicle k, unit: kiloliter; The expression of the undelivered order loss cost is shown in Equation (4). c4: The unit loss cost of the undelivered order, unit: yuan / kiloliter; The expression of the comprehensive objective function is shown in Equation (5): In step 2), since the refined oil secondary distribution problem is essentially a vehicle routing problem, due to the particularity and complexity of the oil distribution scenario, the model needs to be constrained for mathematical modeling. For the distribution vehicle, each trip starts from the oil depot, returns to the oil depot after completing the distribution of the oil order, and then prepares for the next trip. And the distribution vehicle can only start the next trip after completing the previous trip. To avoid generating subcircuits in the vehicle routing plan, the MTZ constraint is adopted to eliminate subcircuits, and the constraints shown in Equations (6)-(10) are obtained. Equation (6) means that any trip of any vehicle starts from the oil depot; Equation (7) means that any trip of any vehicle ends and returns to the oil depot; Equation (8) means that for any vehicle, the next trip can only start after the previous trip is completed; Equation (9) means the inflow and outflow balance constraint; Equation (10) represents the MTZ subtour elimination constraint, where n represents the number of nodes; z ikr : represents the order in which vehicle k visits site i during trip r; In the refined oil secondary distribution problem, each oil order can be loaded onto at most one cabin, and each cabin can also load at most one order. The loading feasibility of the order on the cabin is related to the actual loaded order capacity on the cabin. The ratio of the actual loading amount to the cabin capacity needs to be not less than the minimum loading rate of the cabin, and the ratio of the actual loading amount to the order capacity needs to be not less than the minimum distribution rate of the order. The constraints defined in Equations (11)-(14) are as follows. Equation (11) means that for any cabin in any trip of any vehicle, it can load at most one order; Formula (12) indicates that for any order at any site, it can be loaded into at most one cargo hold; Formula (13) indicates that if an order is loaded onto a cargo hold, the loading rate of the cargo hold cannot be lower than the minimum loading rate α; Formula (14) indicates that partial non-delivery of an order is allowed, but the actual delivery rate of the order cannot be lower than the minimum delivery rate β; For any delivery vehicle, its total delivery time cannot exceed the maximum working time. The delivery time of the vehicle in a certain trip mainly consists of three parts: the loading time of the oil product order, the unloading time of the oil product order, and the vehicle transportation time. The total delivery time of the vehicle is the sum of the delivery times of all trips. Define the constraint as in Equation (15). Formula (15) indicates that the total vehicle delivery time cannot exceed the maximum working time; s1: the oil loading rate, unit: kiloliter per minute; s2: the oil unloading rate, unit: kiloliter per minute; λ: the maximum working time of the vehicle, unit: hour; v: the vehicle driving speed, unit: kilometer per hour; Equations (16) to (19) are the definitions of variables. is the set of real numbers in one-dimensional form.
2. The solution algorithm according to claim 1, characterized in that For any order p of any gas station i, its delivery urgency O ip is calculated as follows: Among them, by counting the available delivery times of all cargo holds that meet the order loading requirements, an evaluation of the available delivery resources for the order is obtained. If the delivery resources are less, it means that the delivery urgency of this order is higher, so the cargo hold is considered to be preferentially allocated to this order; The delivery priority J for any gas station i i is calculated as follows: Among them, d 0i represents the route distance from gas station i to the oil depot; the evaluation of the delivery priority mainly considers two aspects: the distance from the station to the oil depot and the delivery urgency of the orders belonging to this station. For a feasible order loading plan L, the calculation formula of its delivery benefit is as follows: f(L) = w4C(L) + w5U(L) (22) Among them, f(L) represents the delivery benefit of the loading plan, C(L) represents the delivery cost of this loading plan, and U(L) represents the overall order delivery urgency in this loading plan. w1, w2, w3, w4, w5: control parameters; The specific operation method of step 3) includes the following steps: Step 1: Initialize the set N′ of sites to be delivered, the set K of deliverable vehicles, and the set S of vehicle delivery plans; Step 2: If the current set N′ of delivery sites is not empty, go to step 3; otherwise, go to step 13; Step 3: Update the delivery urgency of all orders based on formula (20), and then calculate the delivery priority of all sites to be delivered based on formula (21). Select the site with the highest delivery priority as the seed site i and generate the initial site combination {i}; Step 4: For the initial site combination, sequentially select vehicles from the set K of deliverable vehicles. If the vehicle has a feasible order loading plan L, add this plan to the loading plan set D; Step 5: Set the optimal loading plan L best If it is empty, set the optimal distribution benefit f best to 0; Step 6: If the current loading plan set D is empty, go to step 10; otherwise, go to step 7; Step 7: Sequentially select loading plans from the loading plan set D for removal. If there is a cargo hold in the selected loading plan that has not been assigned to load an order, go to step 8; otherwise, go to step 9; Step 8: For the selected loading plan L, based on the order information it loads, obtain the site combination visited by the current vehicle. Select the best site to insert based on the nearest neighbor insertion algorithm. For the inserted site combination, judge whether there is a feasible inserted loading plan L′. If it exists, add the new loading plan L′ to the set D and go to step 7; otherwise, go to step 9; Step 9: For the selected loading plan L, calculate the distribution benefit of the loading plan based on formula (22). If f(L) > f best , then update L best = L, f best = f(L), and go to Step 5; Step 10: If L best is empty, it means that there is no feasible distribution plan for the seed site i, go to Step 11; otherwise, go to Step 12; Step 11: Remove the seed site i from the set N′ of sites to be delivered, and go to Step 2; Step 12: According to the optimal loading plan L best , solve its corresponding optimal delivery route plan, save the loading plan and the route plan into the vehicle delivery plan set S, and update the set N' of stations to be delivered and the set K of deliverable vehicles; go to Step 2; Step 13: The algorithm terminates, and outputs the final set S of vehicle delivery plans.
3. The solution algorithm according to claim 2, characterized in that The main steps of the tabu search algorithm in Step 4) are as follows: Step 1: Initialize the algorithm, and set parameters, including the length of the tabu list, the length of the candidate set, and the maximum number of iteration steps; Step 2: Generate an initial feasible solution based on the constructive heuristic as the starting point for iterative search; Step 3: Apply the intensification strategy and the diversification strategy respectively to generate a candidate solution set; Step 4: According to the evaluation function, judge whether there is a solution in the current candidate solution set that satisfies the aspiration criterion. If so, select this solution as the initial solution for the next iteration; Otherwise, select the current local optimal solution that is not tabu from the candidate solution set as the initial solution for the next iteration; Step 5: Update the tabu list; Step 6: Judge whether the algorithm meets the termination condition. If it does, output the optimal solution that appears during the iteration and terminate the algorithm; If not, use the currently selected solution as the starting point for the next iteration, and go to Step 3.
Citation Information
Patent Citations
Oil products delivery cistern car scheduling system and method thereof
CN101159048A
Multi-agent-based platform scheduling intelligent sorting model structure
CN105976030A