Material distribution center site selection method and system based on particle swarm algorithm
Optimizing the distribution center location selection through the particle swarm algorithm and DEMATEL method, the problem of strong dependence on the initial solution in the existing technology is solved, and more stable optimal solution acquisition is achieved, ensuring the effectiveness of the distribution center location selection.
Patent Information
- Application Number
- CN202111231645.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Priority Date
- 2021-08-13
- Filing Date
- 2021-10-22
- Publication Date
- 2024-11-22
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The existing distribution center site selection method relies too much on the initial solution, resulting in unstable quality of the optimal solution, making it difficult to find the optimal solution in complex scenarios.
Using a method based on particle swarm algorithm, the position and velocity of the particle swarm is initialized, and the optimal particles are selected in combination with the DEMATEL method, the particle position and velocity are updated, and the location selection scheme of the distribution center is gradually optimized to ensure the effectiveness of the optimal solution.
The quality stability of the optimal solution is improved, local optimal traps are avoided, and the effectiveness and accuracy of distribution center site selection is ensured.
Smart Images

Figure CN114021781B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of distribution center site selection, and in particular to a material distribution center site selection method and system based on a particle swarm algorithm. Background Art
[0002] The location problem refers to determining the relative position, quantity and scale of service nodes (such as distribution centers) in the area based on the spatial location of the demand location and the relationship between material demand. The point service satisfaction of demand depends on the spatial distance or supply time. As the spatial distance (supply time) gradually increases to exceed the facility service radius, and finally continues to increase to a certain value, the facility service quality (customer satisfaction) gradually decreases until it reaches zero. This relationship better reflects the basic concept of progressive coverage. In the process of emergency material distribution, it is particularly important to shorten the response time to major sudden outbreaks.
[0003] The existing site selection methods generally search for the optimal solution of site selection through the taboo search algorithm. For example, the document "Shi Zhao. Logistics Distribution Site Selection - Research on Transportation Path Optimization Problem [D]. Changsha. Central South University, 2014: 50-56." Since the taboo search algorithm needs to select an initial value, it is highly dependent on the initial solution. A good initial solution helps the search to reach the optimal solution quickly, while an initial solution that deviates from the final optimal solution will make the search process difficult or even affect the inability to obtain the optimal solution. That is, the existing site selection methods are overly dependent on the initial solution, resulting in unstable quality of the optimal solution. Summary of the invention
[0004] 1. Technical issues to be solved
[0005] In view of the deficiencies of the prior art, the present invention provides a material distribution center site selection method and system based on a particle swarm algorithm, which solves the technical problem of the existing site selection method being overly dependent on the initial solution.
[0006] (II) Technical solution
[0007] To achieve the above objectives, the present invention is implemented through the following technical solutions:
[0008] In a first aspect, the present invention provides a material distribution center site selection method based on a particle swarm algorithm, the method comprising the following steps:
[0009] S1. Set input parameters and build an optimization model based on the input parameters with the goal of minimizing the construction cost of the distribution center;
[0010] S2, initializing the execution parameters of the particle swarm algorithm and randomly determining the particle position and initial velocity of the initial particle swarm;
[0011] S3, calculating the fitness value of each particle in the initial particle swarm according to the optimization model, and selecting the particle with the smallest fitness value as the global optimal particle;
[0012] S4, update the position and velocity of each particle, and check whether the updated particle position is in the feasible domain. If not, readjust the position;
[0013] S5. Calculate the fitness value of the current position of each particle after the update, and compare it with the fitness value of the position of the particle before the update, and select the position with the smaller fitness value as the updated position of the current particle.
[0014] S6. Use the DEMATEL method to select the best particle in the entire population from the updated particles;
[0015] S7, compare the optimal particle with the global optimal particle. If the fitness value of the optimal particle is better than the fitness value of the global optimal particle, then update the global optimal particle, and update the particle position without updating the particle speed; otherwise, keep the global optimal particle unchanged, update the speed according to the speed update formula, and then update the particle position;
[0016] S8, determine whether the end condition is met, if so, output the global optimal particle and end the algorithm, otherwise, execute step S5.
[0017] Preferably, the S1 comprises:
[0018] S101. Obtain the candidate set of emergency material distribution centers, the set of demand points, and other information such as the construction cost of the distribution center, and set input parameters according to the information. The input parameter settings are as follows:
[0019] X i represents the i-th emergency medical supplies distribution center, i=1,...,n;
[0020] Y i represents the demand point for emergency medical supplies, j = 1, ..., m;
[0021] a k is the system influencing factor of the emergency medical material distribution center, k = 1, 2, …, s;
[0022] Z represents the construction cost of the distribution center;
[0023] H represents the total investment in distribution center facilities;
[0024] M represents fixed investment, M i represents the fixed investment in the construction of the i-th emergency medical material distribution center, i=1,...,n;
[0025] N represents the distribution cost of emergency medical supplies, N j represents the distribution cost of emergency medical supplies for the jth emergency medical supplies demand point, j = 1, ..., n;
[0026] b represents the transportation cost per unit distance for providing needed materials to the disaster-stricken areas;
[0027] a j It indicates the demand for emergency supplies in the affected areas after a major epidemic occurs;
[0028] d ij represents the transportation distance from distribution center point i to disaster-stricken area j;
[0029] S102, constructing an optimization model with the goal of minimizing the construction cost of the distribution center, the model includes an objective function and constraints, specifically including:
[0030] The total construction cost of the emergency medical supplies distribution center consists of two parts: fixed investment and distribution costs, which can be expressed as:
[0031] Z=M+N (1-1)
[0032] The distribution cost is the product of the demand for emergency supplies to the disaster-stricken areas, the distribution distance from the distribution center to the disaster-stricken areas, and the unit freight, which can be expressed as a parameter:
[0033]
[0034] The final objective function is:
[0035]
[0036] Constraints:
[0037] (1) Ensure that the facility cost of the emergency medical supplies distribution center does not exceed the total investment:
[0038]
[0039] (2) Guarantee X i is an integer between 0 and 1. i When it is 1, it means that point i is selected. i When it is 0, point i is not selected:
[0040] X i ={0,1}.
[0041] Preferably, the execution parameters in S2 include:
[0042] Inertia weight factor ω and two learning factors c1 and c2, population size L, maximum speed vmax , maximum number of iterations T max and the current iteration number t;
[0043]
[0044] Among them, ω max is the maximum inertia weight, ω min is the minimum inertia weight, T max is the maximum evolutionary generation.
[0045] Preferably, the method for updating the position and velocity of each particle comprises:
[0046] The calculation formula for location update is as follows:
[0047]
[0048] When the inertia weight factor ω is used, the speed update formula of the algorithm is as follows:
[0049]
[0050] Among them: r1, r2 are random numbers on [0, 1], is the best position that the ith particle has passed by until the tth iteration, is the best position that all particles have passed by until the tth iteration.
[0051] Preferably, S5 includes:
[0052] According to the objective function, the fitness value of each particle's current position after the update is calculated, and the fitness value of each particle's current position is compared with the fitness value of the particle's position before the update, and the position with the smaller fitness value is selected as the current particle's own best position pbest. That is, if the fitness value of the particle's current position is less than the fitness value of the particle's position before the update, the particle's current position is selected as the current particle's own best position pbest, otherwise, the particle's position before the update is selected as the current particle's own best position pbest.
[0053] Preferably, S6 includes:
[0054] Using the DEMATEL method, the position of each particle is regarded as a system structure diagram. The optimal particle found by all particles in the current group is determined according to the centrality and causality of the factor, and updated in gbest. k The centrality m k and the degree of cause n k The calculation formula is as follows:
[0055] m k=f k +e k (6-1)
[0056] n k =f k -e k (6-2)
[0057] Among them, f k and e k They are respectively k The degree of influence and the degree of being influenced.
[0058] Preferably, the S8 includes:
[0059] Determine whether the current number of iterations has reached the maximum number of iterations. If so, output the global optimal particle and determine the location plan for the emergency medical supplies distribution center based on the global optimal particle. Otherwise, t=t+1 and return to step S5.
[0060] In a second aspect, the present invention provides a material distribution center site selection system based on a particle swarm algorithm, comprising:
[0061] an optimization model building module, for executing S1, setting input parameters, and building an optimization model based on the input parameters with the goal of minimizing the construction cost of the distribution center;
[0062] An initialization module is used to execute S2, initialize the execution parameters of the particle swarm algorithm and randomly determine the particle position and initial velocity of the initial particle swarm;
[0063] The first calculation module is used to execute S3, calculate the fitness value of each particle in the initial particle group according to the optimization model, and select the particle with the smallest fitness value as the global optimal particle;
[0064] The first updating module is used to execute S4, update the position and velocity of each particle, and detect whether the updated particle position is in the feasible domain. If not, readjust the position;
[0065] The second calculation module is used to execute S5, calculate the fitness value of the current position of each particle after the update, and compare it with the fitness value of the position of the particle before the update, and select the position with the smaller fitness value as the updated current particle position.
[0066] The selection module is used to execute S6 and select the best particle in the entire population from the updated particles using the DEMATEL method;
[0067] The second updating module is used to execute S7, compare the optimal particle with the global optimal particle, if the fitness value of the optimal particle is better than the fitness value of the global optimal particle, then update the global optimal particle, and update the particle position without updating the particle speed; otherwise, the global optimal particle is kept unchanged, the speed is updated according to the speed update formula, and then the particle position is updated;
[0068] The judgment module is used to execute S8 and judge whether the end condition is met. If so, the global optimal particle is output and the algorithm is terminated. Otherwise, the second calculation module is transferred to execute step S5.
[0069] In a third aspect, the present invention provides a computer-readable storage medium storing a computer program for material distribution center site selection based on a particle swarm algorithm, wherein the computer program enables a computer to execute the material distribution center site selection method based on a particle swarm algorithm as described above.
[0070] In a fourth aspect, the present invention provides an electronic device, comprising:
[0071] one or more processors;
[0072] Memory; and
[0073] One or more programs, wherein the one or more programs are stored in the memory and are configured to be executed by the one or more processors, and the programs include methods for executing the material distribution center site selection method based on the particle swarm algorithm as described above.
[0074] (III) Beneficial effects
[0075] The present invention provides a material distribution center site selection method and system based on particle swarm algorithm. Compared with the prior art, it has the following beneficial effects:
[0076] The present invention solves the technical problem of over-reliance on the initial solution in the existing site selection method through the particle swarm algorithm, thereby improving the quality stability of the optimal solution and ensuring the effectiveness of the optimal solution. At the same time, when comparing the optimal value in the entire updated population, the DEMATEL method is introduced to determine the optimal particle found by all particles in the entire population according to the centrality and causality of the factor, thereby improving the particle topology structure in the local version of the PSO algorithm, so that the algorithm is not easy to fall into the local optimum, further improving the quality stability of the optimal solution and ensuring the effectiveness of the optimal solution. BRIEF DESCRIPTION OF THE DRAWINGS
[0077] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0078] Figure 1 The block diagram is a method for selecting a material distribution center site based on a particle swarm algorithm according to an embodiment of the present invention. DETAILED DESCRIPTION
[0079] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention are clearly and completely described. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0080] The embodiments of the present application provide a material distribution center site selection method and system based on a particle swarm algorithm, thereby solving the technical problem of over-reliance on initial solutions in existing site selection methods, improving the quality stability of the optimal solution, and ensuring the effectiveness of the optimal solution.
[0081] The technical solution in the embodiment of the present application is to solve the above technical problems, and the overall idea is as follows:
[0082] In the prior art, the optimal solution for site selection is generally searched by a taboo search algorithm. Since the taboo search algorithm needs to select an initial value, it is highly dependent on the initial solution. A good initial solution helps the search to quickly reach the optimal solution, while an initial solution that deviates from the final optimal solution will make the search process difficult or even affect the inability to obtain the optimal solution. For more complex site selection problems, it is more difficult to solve them using a taboo search algorithm. At the same time, the taboo search algorithm has a strong "climbing" ability. During the search, it can jump out of the local optimal solution and turn to other areas of the solution space, thereby increasing the probability of obtaining the optimal solution. However, the iterative search process in the steps is serial, which is only a single state movement, not a parallel search. In order to solve the above problems, the embodiment of the present invention proposes a material distribution center site selection method and system based on a particle swarm algorithm, constructs a model design algorithm for the site selection problem of the material distribution center (the embodiment of the present invention takes the site selection problem of the emergency medical material distribution center as an example), and verifies whether the final calculation result can be used as a reference for the site selection requirements. First, determine the position and initial velocity of the particle, and then compare the position experienced by the particle in the group vertically and horizontally to determine the position of the particle with the best fitness in the group. Compared with the iterative calculation process of the traditional taboo search algorithm, unlike its single state movement, PSO repeatedly compares the fitness value of the particle during the group search process. And unlike the emergency search algorithm, the particle swarm algorithm does not rely on the selected initial solution. After determining the initial position and velocity of the particle, the group particles move in the direction of the optimal solution, satisfying the convergence conditions and ensuring the effectiveness of the optimal solution.
[0083] In order to better understand the above technical solution, the above technical solution will be described in detail below in conjunction with the accompanying drawings and specific implementation methods.
[0084] The embodiment of the present invention provides a material distribution center site selection method based on particle swarm algorithm, such as Figure 1 As shown, the method includes steps S1 to S7:
[0085] S1. Set input parameters and build an optimization model based on the input parameters with the goal of minimizing the construction cost of the distribution center;
[0086] S2, initializing the execution parameters of the particle swarm algorithm and randomly determining the particle position and initial velocity of the initial particle swarm;
[0087] S3, calculating the fitness value of each particle in the initial particle swarm according to the optimization model, and selecting the particle with the smallest fitness value as the global optimal particle;
[0088] S4, update the position and velocity of each particle, and check whether the updated particle position is in the feasible domain. If not, readjust the position;
[0089] S5. Calculate the fitness value of the current position of each particle after the update, and compare it with the fitness value of the position of the particle before the update, and select the position with the smaller fitness value as the updated position of the current particle.
[0090] S6. Use the DEMATEL method to select the best particle in the entire population from the updated particles;
[0091] S7, compare the optimal particle with the global optimal particle. If the fitness value of the optimal particle is better than the fitness value of the global optimal particle, then update the global optimal particle, and update the particle position without updating the particle speed; otherwise, keep the global optimal particle unchanged, update the speed according to the speed update formula, and then update the particle position;
[0092] S8, determine whether the end condition is met, if so, output the global optimal particle and end the algorithm, otherwise, execute step S5.
[0093] The embodiment of the present invention solves the technical problem of over-reliance on the initial solution in the existing site selection method through the particle swarm algorithm, thereby improving the quality stability of the optimal solution and ensuring the effectiveness of the optimal solution. At the same time, when comparing the optimal value in the entire updated population, the DEMATEL method is introduced to determine the optimal particle found by all particles in the entire population according to the centrality and causality of the factor, thereby improving the particle topology structure in the local version of the PSO algorithm, so that the algorithm is not easy to fall into the local optimum, further improving the quality stability of the optimal solution and ensuring the effectiveness of the optimal solution.
[0094] The following is a detailed description of each step:
[0095] In step S1, input parameters are set and an optimization model is constructed based on the input parameters with the goal of minimizing the construction cost of the distribution center. The specific implementation process is as follows:
[0096] S101. Obtain the candidate set of emergency material distribution centers, the set of demand points, and other information such as the construction cost of the distribution center, and set input parameters according to the information. The input parameter settings are as follows:
[0097] X i represents the i-th emergency medical supplies distribution center, i=1,...,n;
[0098] Y i represents the demand point for emergency medical supplies, j = 1, ..., m;
[0099] a k is the system influencing factor of the emergency medical material distribution center, k = 1, 2, …, s;
[0100] Z represents the construction cost of the distribution center;
[0101] H represents the total investment in distribution center facilities;
[0102] M represents fixed investment, M i represents the fixed investment in the construction of the i-th emergency medical material distribution center, i=1,...,n;
[0103] N represents the distribution cost of emergency medical supplies, N j represents the distribution cost of emergency medical supplies for the jth emergency medical supplies demand point, j = 1, ..., n;
[0104] b represents the transportation cost per unit distance for providing needed materials to the disaster-stricken areas;
[0105] a j It indicates the demand for emergency supplies in the affected areas after a major epidemic occurs;
[0106] d ij Represents the transportation distance from distribution center point i to disaster-stricken area j.
[0107] S102: construct an optimization model with the goal of minimizing the construction cost of the distribution center, the model including an objective function and constraints. Specifically, it includes:
[0108] The total construction cost of the emergency medical supplies distribution center consists of two parts: fixed investment and distribution costs, which can be expressed as:
[0109] Z=M+N (1-1)
[0110] The distribution cost is the product of the demand for emergency supplies to the disaster-stricken areas, the distribution distance from the distribution center to the disaster-stricken areas, and the unit freight, which can be expressed as a parameter:
[0111]
[0112] The final objective function is:
[0113]
[0114] Constraints:
[0115] (1) Ensure that the facility cost of the emergency medical supplies distribution center does not exceed the total investment:
[0116]
[0117] (2) Guarantee X i is an integer between 0 and 1. i When it is 1, it means that point i is selected. i When it is 0, point i is not selected:
[0118] X i ={0,1}.
[0119] In step S2, the execution parameters of the particle swarm algorithm are initialized and the particle positions and initial velocities of the initial particle swarm are randomly determined. The specific implementation process is as follows:
[0120] The parameters include: inertia weight factor ω, contraction factor χ and two learning factors c1 and c2. Reasonable modification and determination of these parameters can effectively improve the efficiency of the particle swarm algorithm and its ability to escape from the local optimum. It should be noted that either the inertia weight factor ω or the contraction factor χ can be selected.
[0121] In addition, it is necessary to set the population size L, the maximum speed v max , maximum number of iterations T max and the current number of iterations t, etc.
[0122] The inertia weight factor ω directly affects the strength of the particle's global and local search capabilities. When the inertia weight factor ω is large, the algorithm's global search capability is stronger, and vice versa. The value of ω is generally selected between [0.9, 1.2], or a decreasing inertia weight factor ω is used, and the calculation formula is as follows:
[0123]
[0124] Among them, ω max is the maximum inertia weight, ω min is the minimum inertia weight, T max is the maximum evolutionary generation.
[0125] The shrinkage factor χ has a similar effect to the inertia weight factor ω. When the shrinkage factor χ is larger, the global search capability of the algorithm is stronger, and vice versa.
[0126]
[0127]
[0128] The learning factors c1 and c2 control the cognitive and social terms of the particles, respectively. According to the algorithm principle of the particle swarm, if the acceleration factor is set too small, the particles will hesitate near the target area, while a higher acceleration factor will pull the particles to the target area or directly jump over the target area. Therefore, it is usually better to set c1=c2=2 so that the algorithm has a suitable search speed and avoids the algorithm falling into the local optimum.
[0129] In step S3, the fitness value of each particle in the initial particle swarm is calculated according to the optimization model, and the particle with the smallest fitness value is selected as the global optimal particle. The specific implementation process is as follows:
[0130] The fitness value of each particle in the initial particle swarm is calculated according to the objective function, that is, The particle with the smallest fitness value is selected as the global optimal particle gbest.
[0131] In step S4, the position and velocity of each particle are updated, and it is detected whether the updated particle position is in the feasible domain. If not, the position is readjusted. The specific implementation process is as follows:
[0132] Update the position and velocity of each particle
[0133] The calculation formula for location update is as follows:
[0134]
[0135] When the inertia weight factor ω is used, the speed update formula of the algorithm is as follows:
[0136]
[0137] When the shrinkage factor χ is used, the speed update formula of the algorithm is as follows:
[0138]
[0139] Among them: r1, r2 are random numbers on [0, 1], is the best position that the ith particle has passed by until the tth iteration, is the best position that all particles have passed by until the tth iteration.
[0140] The constraint conditions (1) of the optimization model are used to determine whether the updated particle position is within the feasible domain. If not, the position is readjusted.
[0141] In step S5, the fitness value of the current position of each particle after the update is calculated and compared with the fitness value of the position of the particle before the update, and the position with the smaller fitness value is selected as the updated position of the current particle.
[0142] According to the objective function, the fitness value of each particle's current position after the update is calculated, and the fitness value of each particle's current position is compared with the fitness value of the particle's position before the update, and the position with the smaller fitness value is selected as the current particle's own best position pbest. That is, if the fitness value of the particle's current position is less than the fitness value of the particle's position before the update, the particle's current position is selected as the current particle's own best position pbest, otherwise, the particle's position before the update is selected as the current particle's own best position pbest.
[0143] In step S6, the DEMATEL method is used to select the best particle in the entire population from the updated particles. The specific implementation process is as follows:
[0144] Using the DEMATEL method, the position of each particle is regarded as a system structure diagram, and the best position found by all particles in the current group is determined according to the centrality and causality of the factors, and updated in gbest. k The centrality m k and the degree of cause n k The calculation formula is as follows:
[0145] m k =f k +e k (6-1)
[0146] n k =f k -e k (6-2)
[0147] Among them, f k and e k They are respectively k The degree of influence and the degree of being influenced.
[0148] In step S7, the optimal particle is compared with the global optimal particle. If the fitness value of the optimal particle is better than the fitness value of the global optimal particle, the global optimal particle is updated, and the particle position is updated without updating the particle speed; otherwise, the global optimal particle is kept unchanged, the speed is updated according to the speed update formula, and then the particle position is updated. The specific implementation process is as follows:
[0149] Compare the optimal particle with the global optimal particle. If the fitness value of the optimal particle is better than the fitness value of the global optimal particle, update the global optimal particle gbest, and update the particle position according to formula (4-1) without updating the particle speed. Otherwise, keep the global optimal particle gbest unchanged, update the speed according to the speed update formula (4-2) or (4-3), and then update the particle position. At the same time, check whether the updated particle position is in the feasible domain. If not, readjust the position according to the above rules.
[0150] In step S8, it is determined whether the end condition is met. If so, the global optimal particle is output and the algorithm ends. Otherwise, step S5 is executed. The specific implementation process is as follows:
[0151] Determine whether the current number of iterations has reached the maximum number of iterations. If so, output the global optimal particle and determine the location plan for the emergency medical supplies distribution center based on the global optimal particle. Otherwise, t=t+1 and return to step S5.
[0152] The embodiment of the present invention further provides a material distribution center site selection system based on a particle swarm algorithm, comprising:
[0153] an optimization model building module, for executing S1, setting input parameters, and building an optimization model based on the input parameters with the goal of minimizing the construction cost of the distribution center;
[0154] An initialization module is used to execute S2, initialize the execution parameters of the particle swarm algorithm and randomly determine the particle position and initial velocity of the initial particle swarm;
[0155] The first calculation module is used to execute S3, calculate the fitness value of each particle in the initial particle group according to the optimization model, and select the particle with the smallest fitness value as the global optimal particle;
[0156] The first updating module is used to execute S4, update the position and velocity of each particle, and detect whether the updated particle position is in the feasible domain. If not, readjust the position;
[0157] The second calculation module is used to execute S5, calculate the fitness value of the current position of each particle after the update, and compare it with the fitness value of the position of the particle before the update, and select the position with the smaller fitness value as the updated current particle position.
[0158] The selection module is used to execute S6 and select the best particle in the entire population from the updated particles using the DEMATEL method;
[0159] The second updating module is used to execute S7, compare the optimal particle with the global optimal particle, if the fitness value of the optimal particle is better than the fitness value of the global optimal particle, then update the global optimal particle, and update the particle position without updating the particle speed; otherwise, the global optimal particle is kept unchanged, the speed is updated according to the speed update formula, and then the particle position is updated;
[0160] The judgment module is used to execute S8 and judge whether the end condition is met. If so, the global optimal particle is output and the algorithm is terminated. Otherwise, the second calculation module is transferred to execute step S5.
[0161] It can be understood that the material distribution center site selection system based on particle swarm algorithm provided in the embodiment of the present invention corresponds to the material distribution center site selection method based on particle swarm algorithm mentioned above, and the explanations, examples, beneficial effects and other parts of its relevant contents can refer to the corresponding contents in the material distribution center site selection method based on particle swarm algorithm, which will not be repeated here.
[0162] An embodiment of the present invention also provides a computer-readable storage medium storing a computer program for material distribution center site selection based on a particle swarm algorithm, wherein the computer program enables a computer to execute the material distribution center site selection method based on a particle swarm algorithm as described above.
[0163] An embodiment of the present invention further provides an electronic device, including:
[0164] one or more processors;
[0165] Memory; and
[0166] One or more programs, wherein the one or more programs are stored in the memory and are configured to be executed by the one or more processors, and the programs include methods for executing the material distribution center site selection method based on the particle swarm algorithm as described above.
[0167] In summary, compared with the prior art, the present invention has the following beneficial effects:
[0168] 1. The embodiment of the present invention solves the technical problem of over-reliance on the initial solution in the existing site selection method through the particle swarm algorithm, thereby improving the quality stability of the optimal solution and ensuring the effectiveness of the optimal solution. At the same time, when comparing the optimal value in the entire updated population, the DEMATEL method is introduced to determine the optimal particle found by all particles in the entire population according to the centrality and causality of the factor, thereby improving the particle topology structure in the local version of the PSO algorithm. Therefore, the algorithm is not easy to fall into the local optimum, further improving the quality stability of the optimal solution and ensuring the effectiveness of the optimal solution.
[0169] 2. The embodiment of the present invention adopts a typical linear decreasing strategy to determine the inertia weight, as shown in formula (2-1). This typical linear decreasing strategy is currently widely used. Using a larger initial inertia weight value can quickly locate the approximate position of the optimal solution. As the inertia weight decreases, the particle speed slows down and begins a fine search. At this time, the convergence speed can be accelerated, thereby improving the performance of the algorithm.
[0170] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.
[0171] The above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A material distribution center site selection method based on particle swarm algorithm, characterized in that: The method comprises the following steps: S1. Set input parameters and build an optimization model based on the input parameters with the goal of minimizing the construction cost of the distribution center; S2, initializing the execution parameters of the particle swarm algorithm and randomly determining the particle position and initial velocity of the initial particle swarm; S3, calculating the fitness value of each particle in the initial particle swarm according to the optimization model, and selecting the particle with the smallest fitness value as the global optimal particle; S4, update the position and velocity of each particle, and check whether the updated particle position is in the feasible domain. If not, readjust the position; S5, calculating the fitness value of the current position of each particle after the update, and comparing it with the fitness value of the position of the particle before the update, and selecting the position with the smaller fitness value as the updated position of the current particle; S6. Use the DEMATEL method to select the best particle in the entire population from the updated particles; S7, compare the optimal particle with the global optimal particle. If the fitness value of the optimal particle is better than the fitness value of the global optimal particle, then update the global optimal particle, and update the particle position without updating the particle speed; otherwise, keep the global optimal particle unchanged, update the speed according to the speed update formula, and then update the particle position; S8, determine whether the end condition is met, if so, output the global optimal particle and end the algorithm, otherwise, execute step S5; Wherein, the S1 includes: S101. Obtain the candidate set of emergency material distribution centers, the set of demand points, and other information such as the construction cost of the distribution center, and set input parameters according to the information. The input parameter settings are as follows: X i represents the i-th emergency medical supplies distribution center, i=1,...,n; Y i represents the demand point for emergency medical supplies, j = 1, ..., m; a k is the system influencing factor of the emergency medical material distribution center, k = 1, 2, …, s; Z represents the construction cost of the distribution center; H represents the total investment in distribution center facilities; M represents fixed investment, M i represents the fixed investment in the construction of the i-th emergency medical material distribution center, i=1,...,n; N represents the distribution cost of emergency medical supplies, N j represents the distribution cost of emergency medical supplies for the jth emergency medical supplies demand point, j = 1, ..., n; b represents the transportation cost per unit distance for providing needed materials to the disaster-stricken areas; a j It indicates the demand for emergency supplies in the affected areas after a major epidemic occurs; d ij represents the transportation distance from distribution center point i to disaster-stricken area j; S102, constructing an optimization model with the goal of minimizing the construction cost of the distribution center, the model includes an objective function and constraints, specifically including: The total construction cost of the emergency medical supplies distribution center consists of two parts: fixed investment and distribution costs, which can be expressed as: Z=M+N (1-1) The distribution cost is the product of the demand for emergency supplies to the disaster-stricken areas, the distribution distance from the distribution center to the disaster-stricken areas, and the unit freight, which can be expressed as a parameter: The final objective function is: Constraints: (1) Ensure that the facility cost of the emergency medical supplies distribution center does not exceed the total investment: (2) Guarantee X i is an integer between 0 and 1. i When it is 1, it means that point i is selected. i When it is 0, point i is not selected: Xi={0,1}.
2. The material distribution center site selection method based on particle swarm algorithm as claimed in claim 1, characterized in that: The execution parameters in S2 include: Inertia weight factor ω and two learning factors c1 and c2, population size L, maximum speed v max , maximum number of iterations T max and the current iteration number t; Among them, ω max is the maximum inertia weight, ω min is the minimum inertia weight, T max is the maximum evolutionary generation.
3. The material distribution center site selection method based on particle swarm algorithm as claimed in claim 2, characterized in that: The method for updating the position and velocity of each particle includes: The calculation formula for location update is as follows: When the inertia weight factor ω is used, the speed update formula of the algorithm is as follows: Among them: r1, r2 are random numbers on [0, 1], is the best position that the ith particle has passed by until the tth iteration, is the best position that all particles have passed by until the tth iteration.
4. The material distribution center site selection method based on particle swarm algorithm as claimed in claim 2, characterized in that: The S5 includes: According to the objective function, the fitness value of each particle's current position after the update is calculated, and the fitness value of each particle's current position is compared with the fitness value of the particle's position before the update, and the position with the smaller fitness value is selected as the current particle's best position pbest. That is, if the fitness value of the particle's current position is less than the fitness value of the particle's position before the update, the particle's current position is selected as the current particle's best position pbest. Otherwise, the particle's position before the update is selected as the current particle's best position pbest.
5. The material distribution center site selection method based on particle swarm algorithm as described in any one of claims 1 to 4, characterized in that: The S6 includes: Using the DEMATEL method, the position of each particle is regarded as a system structure diagram. The optimal particle found by all particles in the current group is determined according to the centrality and causality of the factor, and updated in gbest. k The centrality m k and the degree of cause n k The calculation formula is as follows: mk=fk+ek (6-1) nk=fk-ek (6-2) Among them, f k and e k They are respectively k The degree of influence and the degree of being influenced.
6. The material distribution center site selection method based on particle swarm algorithm as described in any one of claims 2 to 4, characterized in that: The S8 includes: Determine whether the current number of iterations has reached the maximum number of iterations. If so, output the global optimal particle and determine the location plan for the emergency medical supplies distribution center based on the global optimal particle. Otherwise, t=t+1 and return to step S5.
7. A material distribution center site selection system based on particle swarm algorithm, characterized in that: The material distribution center site selection system includes: an optimization model building module, for executing S1, setting input parameters, and building an optimization model based on the input parameters with the goal of minimizing the construction cost of the distribution center; An initialization module is used to execute S2, initialize the execution parameters of the particle swarm algorithm and randomly determine the particle position and initial velocity of the initial particle swarm; The first calculation module is used to execute S3, calculate the fitness value of each particle in the initial particle group according to the optimization model, and select the particle with the smallest fitness value as the global optimal particle; The first updating module is used to execute S4, update the position and velocity of each particle, and detect whether the updated particle position is in the feasible domain. If not, readjust the position; The second calculation module is used to execute S5, calculate the fitness value of the current position of each particle after the update, and compare it with the fitness value of the position of the particle before the update, and select the position with the smaller fitness value as the updated current particle position; The selection module is used to execute S6 and select the best particle in the entire population from the updated particles using the DEMATEL method; The second updating module is used to execute S7, compare the optimal particle with the global optimal particle, if the fitness value of the optimal particle is better than the fitness value of the global optimal particle, then update the global optimal particle, and update the particle position without updating the particle speed; otherwise, the global optimal particle is kept unchanged, the speed is updated according to the speed update formula, and then the particle position is updated; A judgment module is used to execute S8 and judge whether the end condition is met. If so, the global optimal particle is output and the algorithm ends. Otherwise, the second calculation module is transferred to execute step S5; The S1 includes: S101. Obtain the candidate set of emergency material distribution centers, the set of demand points, and other information such as the construction cost of the distribution center, and set input parameters according to the information. The input parameter settings are as follows: X i represents the i-th emergency medical supplies distribution center, i=1,...,n; Y i represents the demand point for emergency medical supplies, j = 1, ..., m; a k is the system influencing factor of the emergency medical material distribution center, k = 1, 2, …, s; Z represents the construction cost of the distribution center; H represents the total investment in distribution center facilities; M represents fixed investment, M i represents the fixed investment in the construction of the i-th emergency medical material distribution center, i=1,...,n; N represents the distribution cost of emergency medical supplies, N j represents the distribution cost of emergency medical supplies for the jth emergency medical supplies demand point, j = 1, ..., n; b represents the transportation cost per unit distance for providing needed materials to the disaster-stricken areas; a j It indicates the demand for emergency supplies in the affected areas after a major epidemic occurs; d ij represents the transportation distance from distribution center point i to disaster-stricken area j; S102, constructing an optimization model with the goal of minimizing the construction cost of the distribution center, the model includes an objective function and constraints, specifically including: The total construction cost of the emergency medical supplies distribution center consists of two parts: fixed investment and distribution costs, which can be expressed as: Z=M+N (1-1) The distribution cost is the product of the demand for emergency supplies to the disaster-stricken areas, the distribution distance from the distribution center to the disaster-stricken areas, and the unit freight, which can be expressed as a parameter: The final objective function is: Constraints: (1) Ensure that the facility cost of the emergency medical supplies distribution center does not exceed the total investment: (2) Guarantee X i is an integer between 0 and 1. i When it is 1, it means that point i is selected. i When it is 0, point i is not selected: X i ={0,1}。 8. A computer-readable storage medium, characterized in that: It stores a computer program for material distribution center site selection based on particle swarm algorithm, wherein the computer program enables the computer to execute the material distribution center site selection method based on particle swarm algorithm as described in any one of claims 1 to 6.
9. An electronic device, characterized in that: include: one or more processors; Memory; as well as One or more programs, wherein the one or more programs are stored in the memory and are configured to be executed by the one or more processors, and the programs include programs for executing the material distribution center site selection method based on particle swarm algorithm as described in any one of claims 1 to 6.
