Battery delivery route optimization method, device, computer equipment and storage medium

By establishing logistics objective function and soft time window penalty cost function in the battery swap network, and using genetic algorithms to optimize the battery distribution path, the problem of high battery distribution costs in the battery swap network is solved, and efficient battery distribution and user needs are achieved.

CN114548564BActive Publication Date: 2025-08-26SHENZHEN UNIV
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202210173590.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-02-24
Publication Date
2025-08-26
Estimated Expiration
2042-02-24

AI Technical Summary

Technical Problem

In the prior art, there are few researches on battery distribution issues under battery swap networks, resulting in high distribution costs and difficult to meet users' battery swap needs, affecting the service level of battery swap networks.

Method used

Based on the factors influencing distribution paths, relevant constraints are established, logistics objective function and soft time window punishment cost function are constructed, and the path optimization model is used to solve the path optimization model and optimize the battery distribution path.

Benefits of technology

By optimizing the battery distribution path, it reduces distribution costs, improves distribution efficiency, meets users' battery swap needs, and improves the service level of battery swap network.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114548564B_ABST
    Figure CN114548564B_ABST
Patent Text Reader

Abstract

The present invention discloses a battery delivery path optimization method, device, computer equipment and storage medium. The method includes: establishing delivery path related constraints based on delivery path influencing factors; under the delivery path related constraints, establishing a logistics objective function based on the total delivery cost of battery replacement; quantifying the timeliness and satisfaction of battery delivery to establish a soft time window penalty cost function; constructing a path optimization model based on the logistics objective function and the soft time window penalty cost function; using a genetic algorithm to solve the output result of the path optimization model, and using the solution result as the final battery delivery path. The present invention quantifies the soft time window constraint into the objective function in the form of penalty cost, and at the same time establishes a battery delivery path optimization model in combination with the total delivery cost of battery replacement, and solves it through a genetic algorithm to obtain the optimal battery delivery path, thereby improving the delivery efficiency of battery delivery vehicles and reducing delivery costs.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of vehicle route optimization, and in particular to a battery delivery route optimization method, device, computer equipment and storage medium. Background Art

[0002] As global energy shortages and environmental pollution become increasingly prominent, the electric vehicle industry, characterized by low energy consumption and minimal pollution, has experienced rapid growth. At the same time, energy supply for electric vehicles has become a major bottleneck restricting the industry's growth. Battery swapping, with its rapid energy supply, low battery costs, and ease of centralized charging management, has become a key solution to this energy supply issue.

[0003] The battery swap model is suitable for battery-swap electric vehicles (EVs) that are "separate from the vehicle and battery." Research on this model can be divided into two directions: the charging-battery swap model and the centralized charging and unified distribution model. Compared to the charging-battery swap model, the centralized charging and unified distribution model offers advantages in terms of site selection, construction scale, investment and operating costs, and battery batch management. Current research on EV battery swap models primarily focuses on site selection and planning, commercial management and operation, and charging scheduling optimization and control. However, little research has been conducted on battery distribution within the battery swap network.

[0004] The electric vehicle battery distribution problem within a battery swapping network is a variant of the complex Vehicle Routing Problem (VRP). Optimizing battery distribution routes within a battery swapping network can not only reduce distribution and operating costs, but also meet user battery swapping needs in a timely manner, improving the service quality of the battery swapping network. Summary of the Invention

[0005] Embodiments of the present invention provide a battery delivery route optimization method, apparatus, computer equipment, and storage medium, aiming to improve the delivery efficiency of battery delivery vehicles and reduce delivery costs.

[0006] In a first aspect, an embodiment of the present invention provides a battery delivery route optimization method, comprising:

[0007] Establish distribution path related constraints based on distribution path influencing factors;

[0008] Under the constraints related to the delivery path, a logistics objective function is established based on the total cost of battery replacement delivery;

[0009] Quantify the timeliness and satisfaction of battery delivery to establish a soft time window penalty cost function;

[0010] Constructing a path optimization model according to the logistics objective function and the soft time window penalty cost function;

[0011] A genetic algorithm is used to solve the output result of the path optimization model, and the solution is used as the final battery delivery path.

[0012] In a second aspect, an embodiment of the present invention provides a battery delivery route optimization device, comprising:

[0013] A constraint establishing unit, used to establish distribution path related constraints based on distribution path influencing factors;

[0014] A first function establishment unit is configured to establish a logistics objective function based on the total cost of battery replacement delivery under the constraints related to the delivery path;

[0015] The second function establishment unit is used to quantify the timeliness and satisfaction of battery delivery, so as to establish a soft time window penalty cost function;

[0016] A model building unit, configured to build a path optimization model according to the logistics objective function and the soft time window penalty cost function;

[0017] The path solving unit is used to solve the output result of the path optimization model using a genetic algorithm, and use the solution result as the final battery delivery path.

[0018] In a third aspect, an embodiment of the present invention provides a computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the battery delivery route optimization method as described in the first aspect is implemented.

[0019] In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, characterized in that a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, the battery delivery route optimization method as described in the first aspect is implemented.

[0020] An embodiment of the present invention provides a battery delivery path optimization method, apparatus, computer equipment, and storage medium, the method comprising: establishing delivery path-related constraints based on delivery path influencing factors; establishing a logistics objective function based on the total delivery cost of battery swapping under the delivery path-related constraints; quantifying the timeliness and satisfaction of battery delivery to establish a soft time window penalty cost function; constructing a path optimization model based on the logistics objective function and the soft time window penalty cost function; solving the output of the path optimization model using a genetic algorithm, and using the solution as the final battery delivery path. The embodiment of the present invention quantifies the soft time window constraint into the objective function in the form of a penalty cost, and at the same time establishes a logistics objective function based on the total delivery cost of battery swapping, establishes a battery delivery path optimization model based on the battery swapping network, and solves the output of the optimization model using a genetic algorithm, thereby obtaining the optimal battery delivery path, thereby improving the delivery efficiency of battery delivery vehicles and reducing delivery costs. BRIEF DESCRIPTION OF THE DRAWINGS

[0021] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0022] Figure 1 A schematic diagram of a flow chart of a battery delivery route optimization method provided by an embodiment of the present invention;

[0023] Figure 2 A schematic diagram of a sub-process of a battery delivery route optimization method provided by an embodiment of the present invention;

[0024] Figure 3 A schematic diagram of a crossover operation of a genetic algorithm in a battery delivery route optimization method provided by an embodiment of the present invention;

[0025] Figure 4 A schematic block diagram of a battery delivery route optimization device provided by an embodiment of the present invention;

[0026] Figure 5 This is a sub-schematic block diagram of a battery delivery route optimization device provided in an embodiment of the present invention. DETAILED DESCRIPTION

[0027] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of them. All other embodiments obtained by ordinary technicians in this field based on the embodiments of the present invention without making any creative efforts shall fall within the scope of protection of the present invention.

[0028] It will be understood that when used in this specification and the appended claims, the terms “comprises” and “comprising” indicate the presence of described features, integers, steps, operations, elements and / or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or groups thereof.

[0029] It should also be understood that the terminology used in this specification is for the purpose of describing particular embodiments only and is not intended to limit the present invention. As used in the specification and appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms unless the context clearly indicates otherwise.

[0030] It should be further understood that the term "and / or" used in the present description and the appended claims refers to and includes any and all possible combinations of one or more of the associated listed items.

[0031] See below Figure 1 , Figure 1 A flowchart of a battery delivery route optimization method provided by an embodiment of the present invention specifically includes steps S101 to S105.

[0032] S101. Establishing distribution path related constraints based on distribution path influencing factors;

[0033] S102. Establishing a logistics objective function based on the total cost of battery replacement delivery under the constraints related to the delivery path;

[0034] S103, quantifying the timeliness and satisfaction of battery delivery, thereby establishing a soft time window penalty cost function;

[0035] S104, constructing a path optimization model according to the logistics objective function and the soft time window penalty cost function;

[0036] S105 , using a genetic algorithm to solve the output result of the path optimization model, and using the solution result as the final battery delivery path.

[0037] This embodiment quantifies the soft time window constraint into the objective function in the form of penalty cost, and at the same time establishes a logistics objective function based on the total cost of battery swap delivery. A battery delivery path optimization model based on the battery swap network is established, and the output of the optimization model is solved by a genetic algorithm to obtain the optimal battery delivery path. The delivery cost corresponding to the optimal battery delivery path is the optimal cost, which provides a reference for the service operation and battery delivery decision-making of the battery swap network, thereby improving the delivery efficiency of battery delivery vehicles and reducing delivery costs.

[0038] In this embodiment, the battery delivery path is optimized, that is, an optimal battery delivery path is selected. In this embodiment, a logistics objective function is established based on the total delivery cost of the battery replacement battery, and a soft time window penalty function is established based on the timeliness and satisfaction of battery delivery. Therefore, the optimal battery delivery path is the delivery path with the best cost and delivery time.

[0039] In one embodiment, the S101 includes:

[0040] Control all battery delivery vehicles to depart from the same centralized charging station and return to the centralized charging station after completing their respective delivery tasks, thereby establishing a distribution center constraint;

[0041] Control that all battery delivery vehicles have the same model and maximum load capacity, and make the load capacity of all battery delivery vehicles less than or equal to the maximum load capacity during the delivery process, thereby establishing vehicle load constraints;

[0042] Control that each battery swap station is served by only one battery delivery vehicle once, and the delivery and pickup requirements of the battery swap station are fixed, thereby establishing access service constraints;

[0043] Construct time window restriction constraints based on the service time window requirements of each battery swap station;

[0044] Construct a delivery distance constraint based on the maximum single travel distance limit of the battery delivery vehicle;

[0045] Control each battery delivery vehicle to travel at a constant speed during the delivery process to establish traffic condition constraints.

[0046] In this embodiment, distribution path-related constraints are established based on distribution path influencing factors. The distribution path influencing factors mentioned here can refer not only to the influencing factors of the battery distribution vehicle itself (such as load capacity, driving distance, etc.), but also to environmental factors on the distribution path (such as traffic conditions during the distribution process, etc.), and of course, other factors that can affect battery distribution. The distribution path-related constraints are specifically as follows:

[0047] Distribution center constraints: Vehicles participating in the battery distribution service must depart from the same centralized charging station and return to the centralized charging station after completing their respective delivery tasks.

[0048] Vehicle load constraints: Battery delivery vehicles have the same model and maximum load capacity. The load capacity of the battery delivery vehicles during battery delivery and pickup cannot exceed the corresponding maximum load capacity.

[0049] Access service constraints: Each battery swap station is served by one and only one battery delivery vehicle, and the battery delivery and pickup requirements of the battery swap station are inseparable.

[0050] Time window restriction: Each battery swap station has its own service time window requirement.

[0051] Delivery distance constraint: Battery delivery vehicles participating in the battery delivery service have a maximum single-trip driving distance limit.

[0052] Traffic condition constraints: Each battery delivery vehicle travels at a constant speed and complex traffic conditions are not considered.

[0053] In one embodiment, the S102 includes:

[0054] The sum of the vehicle transportation distance cost and the vehicle fixed cost is taken as the total cost of the battery replacement delivery;

[0055] Taking the lowest total cost of battery replacement distribution as the optimization target of the logistics objective function, the logistics objective function is established;

[0056] Among them, the vehicle transportation distance cost C d Calculated according to the following formula:

[0057]

[0058] Where C k represents the unit transportation distance cost of the battery delivery vehicle, d ij represents the distance between two battery swap stations, x ijk is the vehicle routing decision variable;

[0059]

[0060] The vehicle fixed cost is calculated according to the following formula:

[0061]

[0062] Where, f k represents the fixed cost of a single delivery battery of the vehicle, x ijk represents the vehicle routing decision variable.

[0063] In this embodiment, in addition to meeting the battery swapping needs of the battery swapping stations, the actual battery swapping delivery characteristics are also considered. Specifically, the centralized charging station is responsible for providing battery delivery services to the battery swapping stations in the area, and the centralized charging station is equipped with battery delivery vehicles. In addition, the battery delivery vehicle loaded with fully charged batteries departs from the centralized charging station. Given the battery delivery and pickup needs, service hours, and the location of the centralized charging station and each battery swapping station, the battery delivery service is provided to each battery swapping station within the allowed time window to meet the battery swapping needs of the station. In addition, after completing the battery delivery and pickup services for all battery swapping stations, all battery delivery vehicles return to the centralized charging station.

[0064] Based on the above characteristics, a mathematical model for the battery swap distribution problem in the battery swap network is established. The battery distribution task is completed with the lowest total cost of battery swap distribution in the regional battery swap network as the optimization goal. The total cost of battery swap distribution needs to take into account the conventional transportation distance cost and vehicle fixed costs.

[0065] As for the vehicle transportation distance cost, it mainly refers to the fuel cost consumed by the battery delivery vehicle in the process of transporting the replacement battery, so it is positively correlated with the driving distance of the battery delivery vehicle, as shown in the following formula:

[0066]

[0067] Among them, C k represents the unit transportation distance cost of the battery delivery vehicle, d ij Represents the distance between the two stations. At the same time, the vehicle routing decision variable is introduced:

[0068]

[0069] As for the fixed cost of vehicles, it includes vehicle leasing, depreciation and labor costs incurred by battery delivery vehicles participating in the battery swap delivery service. This is related to the number of battery delivery vehicles participating in the battery delivery service, as shown in the following formula:

[0070]

[0071] Among them, f k represents the fixed cost of a single delivery battery of the vehicle, x ijk represents the vehicle routing decision variable.

[0072] In one embodiment, the S103 includes:

[0073] According to the following formula, the penalty fee C is generated based on the quantitative processing results of battery delivery timeliness and satisfaction. i (t i ):

[0074]

[0075] Where M is a positive number, CT e Indicates that the battery delivery vehicle arrives earlier than the specified time window [ET i ,LT i ]The penalty cost per unit time of arrival, CT l Indicates that the battery delivery vehicle is later than the specified time window [ET i ,LT i ]The penalty cost per unit time of arrival;

[0076] According to the following formula, the soft time window penalty cost function C is established in combination with the penalty fee: p :

[0077]

[0078] In this example, the battery delivery process is complex and subject to interference from various factors, such as weather and traffic conditions. Therefore, the optimization of delivery routes is subject to significant uncertainty. Previous studies have often overlooked these influencing factors, making the resulting models difficult to implement effectively in real-world projects. To address these challenges, this example utilizes soft time window constraints to rationally account for these interfering factors, improving the model's robustness and practicality.

[0079] The soft time window penalty cost is based on the timeliness and satisfaction of the delivery service. Specifically, due to the uncertainty of battery delivery vehicles on the road, battery delivery vehicles that do not arrive within the service time window specified by the battery swap station, that is, arrive at the battery swap station a certain period of time earlier or later, will be penalized by quantifying the delivery timeliness and satisfaction. The soft time window penalty cost is related to the time when the vehicle arrives at the battery swap station. Specifically:

[0080]

[0081] Among them, M is a positive number, which can be a very large positive number, CT e Indicates that the battery delivery vehicle arrives earlier than the specified time window [ET i ,LT i ]The penalty cost per unit time of arrival, CT l Indicates that the battery delivery vehicle is later than the specified time window [ET i ,LT i ]The penalty cost per unit time of arrival.

[0082] As shown in the above formula, if the battery delivery vehicle arrives at the battery swap station within the specified time window, no penalty fee will be incurred; if the battery delivery vehicle arrives within the time window, a time penalty fee will be required; if the battery delivery vehicle arrives outside the maximum time window acceptable to the battery swap station, the time penalty cost is M, and the target model has no solution at this time. Therefore, a soft time window penalty cost function C can be constructed as shown in the following formula: p :

[0083]

[0084] In one embodiment, the S104 includes:

[0085] According to the logistics objective function and the soft time window penalty cost function, the path optimization model is planned according to the following formula:

[0086] min Z T =C d +C f +C p

[0087] Where min Z T Represents the optimal battery delivery path solution.

[0088] In this embodiment, with the goal of minimizing multiple distribution costs (i.e., the vehicle transportation distance cost and the vehicle fixed cost) and the soft time window penalty cost function, a mathematical model of the battery swapping route considering the soft time window under the battery swapping network is established, i.e., the route optimization model.

[0089] The path optimization model described in this embodiment analyzes the battery distribution behavior between centralized charging stations and battery swap stations based on the battery flow characteristics under the battery swap network operation model. Under the constraints of the maximum distance and load of battery delivery vehicles, the service time window characteristics of battery swap delivery are quantified, and a soft time penalty cost function is added to the delivery cost objective function. The objective function is to minimize the total cost of multiple battery swap delivery operations, and the optimal battery swap delivery path plan is planned:

[0090] min Z T =C d +C f +C p

[0091] Based on the analysis and symbolic definition of the above problems, a battery swap delivery route that considers time windows and simultaneous delivery and pickup is constructed, and the route optimization model shown below is constructed:

[0092]

[0093] This formula represents the objective function of minimizing the battery distribution cost, including the vehicle transportation distance cost Cd 、Fixed cost of using vehicle C f and soft time window penalty cost function C p .

[0094] In one embodiment, if Figure 2 As shown, the S105 includes:

[0095] S201. Remove centralized charging station 0 from the chromosome, use the numbers of each battery swap station {1, 2, ..., n} to form a positive integer encoding form of the chromosome, and use the chromosomes with 9-digit decimal encoding to form population individuals;

[0096] This step is the chromosome encoding and decoding in the genetic algorithm. However, this step is different from the traditional natural number encoding form. The centralized charging center 0 is removed from the chromosome, and a positive integer encoding form is adopted in which the chromosome is composed of the numbers of each battery swap station {1,2,…,n}. The individuals are composed of 9-digit decimal-coded chromosomes, and the random order eliminates the subjectivity of the generated population individuals. For example, chromosome 674193582 has breakpoints at 4 and 3, that is, 674|193|582, which means that three battery delivery vehicles are used to provide delivery services to 9 battery swap stations, among which the first battery delivery vehicle performs delivery services in the order of 674, the second battery delivery vehicle performs delivery services in the order of 193, and the third battery delivery vehicle performs delivery services in the order of 582. By determining whether the battery delivery order encoded by the chromosome meets the model constraints, the breakpoint decoding operation is performed to obtain multiple feasible solutions for the delivery path, which can be specifically combined with Figure 3 .

[0097] S202: generating an initial population by random permutation under the constraints related to the delivery path;

[0098] This step is the initial population generation step. Specifically, the initial population is generated by combining the random permutation generation method with the method of generating chromosomes under the constraints of the delivery path. The steps are as follows:

[0099] Under the constraints related to the delivery path, calculate the arrival time of the battery delivery vehicle at each battery swap station;

[0100] Obtain the earliest expected service time for each battery swap station and calculate the time difference between the arrival time and the earliest expected service time for each battery swap station;

[0101] The battery swap stations are selected in order of time difference from small to large until the battery swap station no longer meets the constraints related to the delivery path. This is a delivery path, and the delivery path is set as a feasible solution chromosome in the initial population.

[0102] S203: Using the fitness function, evaluate the quality of individuals in the initial population according to the following formula:

[0103] Fi=1 / Zi

[0104] Where Fi is the fitness function, Zi is the total cost of battery replacement delivery for chromosome i;

[0105] In this step, the fitness function is calculated to evaluate the quality of individuals in the initial population. Specifically, let the total vehicle delivery cost objective function be Z, and set Zi to represent the delivery cost objective function value of the battery delivery vehicle for chromosome i. For chromosomes that meet the model constraints, the objective function value Zi is calculated, and the reciprocal of Zi is taken as the fitness function Fi for that individual, i.e., Fi = 1 / Zi. If the corresponding solution of an individual in the population does not meet the constraints, Zi is assigned a maximum positive value.

[0106] S204: Based on the evaluation results of the quality, individuals in the initial population are retained or eliminated according to a preset threshold;

[0107] This step selects individuals from the initial population based on the results of the fitness evaluation. Individual selection is crucial for ensuring the quality of the offspring population. Individuals with the best fitness are retained directly, while the remaining individuals are more likely to be retained if their fitness exceeds a preset threshold. Individuals with low fitness are eliminated, meaning those whose fitness does not exceed the preset threshold are eliminated. In one specific embodiment, the preset threshold is set based on a 5% to 10% elimination rate, meaning that individuals that do not exceed the preset threshold account for 5% to 10% of all individuals.

[0108] S205. For the retained individuals, a post-crossover operator based on partial matching crossover is used to exchange gene segments, thereby changing the corresponding order of the exchange stations.

[0109] This step uses a post-crossover operator based on partially matched crossover (PMX) to perform crossover operation. The operation process is as follows: Figure 3 As shown, take any two individuals of the parent generation A and the parent generation B, exchange the gene segments between two different randomly generated crossover points on the chromosomes of A and B, move them to the ends of each other's chromosomes, and delete the duplicated genes in each chromosome at the same time to obtain new offspring A1 and B1, and the order of distribution sites will change.

[0110] S206. Perform mutation operations on the chromosomes using preset transposition mutation operators, shift mutation operators, and inversion mutation operators to reconstruct the chromosome mutation mode, and select mutation operators in an equal-probability random manner to generate a new population.

[0111] This step reconstructs the mutation method when performing chromosome mutation operations by designing three different mutation operators: transposition, shift, and inversion. The mutation operator is then selected using a random, equal-probability approach. Changes in chromosome segments affect distribution points, increasing individual diversity within the population and overcoming the problem of being easily trapped in local optima.

[0112] S207: recalculate the fitness of individuals in the new population and determine whether the maximum number of iterations has been reached.

[0113] S208. If it is determined that the maximum number of iterations has not been reached, continue to perform crossover mutation operations on the new population;

[0114] S209: If it is determined that the maximum number of iterations has been reached, the current population is output as the final battery delivery route.

[0115] After the crossover and mutation operations are performed, a new population will be generated. For this new population, continue to calculate its individual fitness and determine whether the maximum number of iterations has been reached. If the maximum number of iterations has not been reached, continue to perform selection, crossover and mutation operations on the new population, then generate the next new population, and repeat the above operations until the maximum number of iterations is reached. At this time, the current population corresponding to the maximum number of iterations can be output and used as the solution to the output result of the path optimization model, that is, the final battery distribution path, and the total cost of battery replacement distribution corresponding to the final battery distribution path is optimal.

[0116] Figure 4 A schematic block diagram of a battery delivery route optimization device 400 provided in an embodiment of the present invention, the device 400 includes:

[0117] A constraint establishing unit 401 is used to establish delivery path related constraints based on delivery path influencing factors;

[0118] A first function establishing unit 402 is configured to establish a logistics objective function based on the total cost of battery replacement delivery under the constraints related to the delivery path;

[0119] The second function establishment unit 403 is used to quantify the timeliness and satisfaction of battery delivery, thereby establishing a soft time window penalty cost function;

[0120] A model building unit 404 is used to build a path optimization model according to the logistics objective function and the soft time window penalty cost function;

[0121] The path solving unit 405 is configured to solve the output result of the path optimization model using a genetic algorithm, and use the solution result as the final battery delivery path.

[0122] In one embodiment, the constraint establishing unit 401 includes:

[0123] A distribution center constraint establishment unit is used to control all battery delivery vehicles to depart from the same centralized charging station and return to the centralized charging station after completing their respective delivery tasks, thereby establishing a distribution center constraint;

[0124] The vehicle load constraint establishment unit is used to control all battery delivery vehicles to be of the same model and have the same maximum load capacity, and to ensure that the load capacity of all battery delivery vehicles during the delivery process is less than or equal to the maximum load capacity, thereby establishing the vehicle load constraint;

[0125] The access service constraint establishment unit is used to control each battery swap station to be served by only one battery delivery vehicle once, and the delivery and pickup requirements of the battery swap station are fixed, thereby establishing the access service constraint;

[0126] A time window constraint establishing unit, configured to establish a time window constraint according to the service time window requirements of each battery swap station;

[0127] A delivery distance constraint establishing unit, used to establish a delivery distance constraint based on the single maximum travel distance limit of the battery delivery vehicle;

[0128] The traffic condition constraint establishing unit is used to control each battery delivery vehicle to travel at a constant speed during the delivery process, thereby establishing traffic condition constraints.

[0129] In one embodiment, the first function establishing unit 402 includes:

[0130] A total cost setting unit, configured to calculate the sum of the vehicle transportation distance cost and the vehicle fixed cost as the total cost of the battery replacement delivery;

[0131] An optimization target setting unit, configured to set the lowest total cost of battery replacement distribution as the optimization target of the logistics objective function, thereby establishing the logistics objective function;

[0132] Among them, the vehicle transportation distance cost C d Calculated according to the following formula:

[0133]

[0134] Where C k represents the unit transportation distance cost of the battery delivery vehicle, d ij represents the distance between two battery swap stations, x ijk is the vehicle routing decision variable;

[0135]

[0136] The vehicle fixed cost is calculated according to the following formula:

[0137]

[0138] Where, f k represents the fixed cost of a single delivery battery of the vehicle, x ijk represents the vehicle routing decision variable.

[0139] In one embodiment, the second function establishing unit 403 includes:

[0140] The penalty fee generation unit is used to generate the penalty fee C according to the quantitative processing results of battery delivery timeliness and satisfaction according to the following formula: i (t i ):

[0141]

[0142] Where M is a positive number, CT e Indicates that the battery delivery vehicle arrives earlier than the specified time window [ET i ,LT i ]The penalty cost per unit time of arrival, CT l Indicates that the battery delivery vehicle is later than the specified time window [ET i ,LT i ]The penalty cost per unit time of arrival;

[0143] A combination establishment unit is used to establish the soft time window penalty cost function C in combination with the penalty fee according to the following formula: p :

[0144]

[0145] In one embodiment, the model building unit 404 includes:

[0146] The model planning unit is used to plan the path optimization model according to the logistics objective function and the soft time window penalty cost function according to the following formula:

[0147] min Z T =C d +C f +C p

[0148] Where min Z T Represents the optimal battery delivery path solution.

[0149] In one embodiment, if Figure 5 As shown, the path solving unit 405 includes:

[0150] Coding unit 501, used to remove centralized charging station 0 from the chromosome, use the numbers of each battery swap station {1, 2, ..., n} to form the positive integer encoding form of the chromosome, and use the chromosomes with 9-digit decimal encoding to form the population individuals;

[0151] A population generation unit 502 is configured to generate an initial population by random permutation under the constraints related to the delivery path;

[0152] The evaluation unit 503 is configured to evaluate the quality of individuals in the initial population using a fitness function according to the following formula:

[0153] Fi=1 / Zi

[0154] Where Fi is the fitness function, Zi is the total cost of battery replacement delivery for chromosome i;

[0155] A selection unit 504 is configured to retain or eliminate individuals in the initial population according to a preset threshold based on the evaluation results of the quality;

[0156] The crossover unit 505 is used to exchange gene segments for the retained individuals using a post-crossover operator based on partial matching crossover, thereby changing the corresponding order of the exchange stations;

[0157] The mutation unit 506 is used to perform mutation operations on the chromosomes using preset transposition mutation operators, shift mutation operators, and inversion mutation operators to reconstruct the chromosome mutation mode and select mutation operators in an equal probability random manner to generate a new population;

[0158] The iteration judgment unit 507 is used to recalculate the fitness of individuals in the new population and judge whether the maximum number of iterations has been reached.

[0159] A first determination unit 508 is configured to continue performing a crossover mutation operation on the new population if it is determined that the maximum number of iterations has not been reached;

[0160] The second determination unit 509 is configured to output the current population as the final battery delivery route if it is determined that the maximum number of iterations has been reached.

[0161] In one embodiment, the population generation unit 502 includes:

[0162] An arrival time calculation unit, configured to calculate the arrival time of the battery delivery vehicle at each battery swap station under the constraints associated with the delivery route;

[0163] A time difference calculation unit is used to obtain the earliest expected service time of each battery swap station and calculate the time difference between the arrival time corresponding to each battery swap station and the earliest expected service time;

[0164] The chromosome setting unit is used to select the battery swap station in order of time difference from small to large until the battery swap station no longer meets the constraints related to the delivery path, and set the delivery path as a feasible solution chromosome in the initial population.

[0165] Since the embodiments of the apparatus part correspond to the embodiments of the method part, please refer to the description of the embodiments of the method part for the embodiments of the apparatus part, and will not be repeated here.

[0166] The present invention also provides a computer-readable storage medium having a computer program stored thereon. When executed, the computer program can implement the steps provided in the above embodiments. The storage medium can include a USB flash drive, a mobile hard drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk, among other media capable of storing program code.

[0167] The present invention also provides a computer device that may include a memory and a processor. The memory stores a computer program, and when the processor calls the computer program in the memory, the steps provided in the above embodiment can be implemented. Of course, the computer device may also include various network interfaces, a power supply, and other components.

[0168] The various embodiments in the specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same and similar parts between the various embodiments can be referred to each other. For the system disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part description. It should be pointed out that for ordinary technicians in this technical field, without departing from the principles of this application, several improvements and modifications can be made to this application, and these improvements and modifications also fall within the scope of protection of the claims of this application.

[0169] It should also be noted that, in this specification, relational terms such as first and second, etc., are used only to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations. Moreover, the terms "comprises," "comprising," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or elements inherent to such process, method, article, or apparatus. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not exclude the presence of additional identical elements in the process, method, article, or apparatus comprising the element.

Claims

1. A battery distribution path optimization method, characterized in that: include: Establish distribution path related constraints based on distribution path influencing factors; Under the constraints related to the delivery path, a logistics objective function is established based on the total cost of battery replacement delivery; Quantify the timeliness and satisfaction of battery delivery to establish a soft time window penalty cost function; Constructing a path optimization model according to the logistics objective function and the soft time window penalty cost function; Using a genetic algorithm to solve the output result of the path optimization model, and using the solution result as the final battery delivery path; The method of using a genetic algorithm to solve the output result of the path optimization model and using the solution as the final battery delivery path includes: Remove the centralized charging station 0 from the chromosome, use the numbers of each battery swap station {1, 2, ..., n} to form the positive integer encoding form of the chromosome, and use the chromosomes with 9-digit decimal encoding to form the population individuals; Under the constraints related to the delivery path, an initial population is generated by random permutation; According to the following formula, the fitness function is used to evaluate the quality of individuals in the initial population: Fi=1 / Zi Where Fi is the fitness function, Zi is the total cost of battery replacement delivery for chromosome i; Based on the evaluation results of the quality, individuals in the initial population are retained or eliminated according to the preset threshold; For the retained individuals, a post-crossover operator based on partial matching crossover is used to exchange gene segments, thereby changing the corresponding order of the exchange stations; The chromosomes are mutated by using the preset transposition mutation operator, shift mutation operator and inversion mutation operator to reconstruct the chromosome mutation mode, and the mutation operator is selected randomly with equal probability to generate a new population. For the new population, recalculate the fitness of the individuals in the new population and determine whether the maximum number of iterations has been reached; If it is determined that the maximum number of iterations has not been reached, the crossover mutation operation will continue to be performed on the new population; If it is determined that the maximum number of iterations has been reached, the current population is output as the final battery delivery route.

2. The battery delivery route optimization method according to claim 1, characterized in that: The establishment of delivery path related constraints based on delivery path influencing factors includes: Control all battery delivery vehicles to depart from the same centralized charging station and return to the centralized charging station after completing their respective delivery tasks, thereby establishing a distribution center constraint; Control that all battery delivery vehicles have the same model and maximum load capacity, and make the load capacity of all battery delivery vehicles less than or equal to the maximum load capacity during the delivery process, thereby establishing vehicle load constraints; Control that each battery swap station is served by only one battery delivery vehicle once, and the delivery and pickup requirements of the battery swap station are fixed, thereby establishing access service constraints; Construct time window restriction constraints based on the service time window requirements of each battery swap station; Construct a delivery distance constraint based on the maximum single travel distance limit of the battery delivery vehicle; Control each battery delivery vehicle to travel at a constant speed during the delivery process to establish traffic condition constraints.

3. The battery delivery route optimization method according to claim 1, characterized in that: Under the constraints related to the delivery path, a logistics objective function is established based on the total cost of battery replacement delivery, including: The sum of the vehicle transportation distance cost and the vehicle fixed cost is taken as the total cost of the battery replacement delivery; Taking the lowest total cost of battery replacement distribution as the optimization target of the logistics objective function, the logistics objective function is established; Among them, the vehicle transportation distance cost C d Calculated according to the following formula: Where C k represents the unit transportation distance cost of the battery delivery vehicle, d ij represents the distance between two battery swap stations, x ijk is the vehicle routing decision variable; The vehicle fixed cost is calculated according to the following formula: Where, f k represents the fixed cost of a single delivery battery of the vehicle, x ijk represents the vehicle routing decision variable.

4. The battery delivery route optimization method according to claim 3, characterized in that: The path optimization model is constructed according to the logistics objective function and the soft time window penalty cost function, including: According to the logistics objective function and the soft time window penalty cost function, the path optimization model is planned according to the following formula: min Z T =C d +C f +C p Where min Z T represents the optimal battery delivery path solution, C p represents the soft time window penalty cost function.

5. The battery delivery route optimization method according to claim 1, characterized in that: The initial population is generated by random permutation under the constraints related to the delivery path, including: Under the constraints related to the delivery path, calculate the arrival time of the battery delivery vehicle at each battery swap station; Obtain the earliest expected service time for each battery swap station and calculate the time difference between the arrival time and the earliest expected service time for each battery swap station; The battery swap stations are selected in order of time difference from small to large until the battery swap station no longer meets the constraints related to the delivery path. This is a delivery path, and the delivery path is set as a feasible solution chromosome in the initial population.

6. A battery delivery route optimization device, characterized in that: include: A constraint establishing unit, used to establish distribution path related constraints based on distribution path influencing factors; A first function establishment unit is configured to establish a logistics objective function based on the total cost of battery replacement delivery under the constraints related to the delivery path; The second function establishment unit is used to quantify the timeliness and satisfaction of battery delivery, so as to establish a soft time window penalty cost function; A model building unit, configured to build a path optimization model according to the logistics objective function and the soft time window penalty cost function; A path solving unit, configured to solve the output result of the path optimization model using a genetic algorithm, and use the solution as the final battery delivery path; The path solving unit includes: The encoding unit is used to remove the centralized charging station 0 from the chromosome, use the numbers of each battery swap station {1, 2, ..., n} to form the positive integer encoding form of the chromosome, and use the chromosomes with 9-digit decimal encoding to form the population individuals; A population generation unit, configured to generate an initial population by random permutation under the constraints related to the delivery path; An evaluation unit is used to evaluate the quality of individuals in the initial population using a fitness function according to the following formula: Fi=1 / Zi Where Fi is the fitness function, Zi is the total cost of battery replacement delivery for chromosome i; A selection unit is used to retain or eliminate individuals in the initial population according to a preset threshold based on the evaluation results of the quality; The crossover unit is used to exchange gene segments for the retained individuals using a post-crossover operator based on partial matching crossover, thereby changing the corresponding order of the exchange stations; The mutation unit is used to perform mutation operations on chromosomes through preset transposition mutation operators, shift mutation operators, and inversion mutation operators, reconstruct the chromosome mutation mode, and select mutation operators in an equal probability random manner to generate a new population; an iterative judgment unit, configured to recalculate the fitness of individuals in the new population and judge whether a maximum number of iterations has been reached; A first determination unit is configured to continue performing a crossover mutation operation on the new population if it is determined that the maximum number of iterations has not been reached; The second determination unit is configured to output the current population as the final battery delivery route if it is determined that the maximum number of iterations has been reached.

7. A computer device, characterized in that: The method comprises a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the battery delivery route optimization method according to any one of claims 1 to 5 when executing the computer program.

8. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the battery delivery route optimization method according to any one of claims 1 to 5 is implemented.

Citation Information

Patent Citations

  • Vehicle distribution path optimization method based on cargo load and soft time window limitation

    CN111191813A