Engineering optimization method based on improved particle swarm optimization

By improving the particle swarm algorithm, using double indexes to update the position and velocity of particles, and combining reinforcement learning to select evolutionary learning strategies, the shortcomings of existing algorithms in balancing diversity and convergence, reducing computational complexity and improving adaptability are solved, and more efficient engineering optimization is achieved.

CN120218113APending Publication Date: 2025-06-27WUYI UNIV
View PDF 0 Cites 3 Cited by

Patent Information

Application Number
CN202510168349.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-02-17
Publication Date
2025-06-27

AI Technical Summary

Technical Problem

The existing particle swarm optimization algorithms have shortcomings in maintaining population diversity, balancing global exploration and local development capabilities, and avoiding local optimization. It is difficult to achieve a significant and lasting improvement in performance, and it is highly complex and weak in adaptability, making it difficult to adapt to complex and changeable engineering optimization problems.

Method used

By establishing an engineering optimization method based on improved particle swarm algorithm, the initial position and velocity of particles are updated using dual indicators (convergence data and diversity data), the particle exploration and development capabilities are balanced, and evolutionary learning strategies are selected through reinforcement learning to dynamically adjust the particle's search behavior.

Benefits of technology

It achieves a more efficient balance of the convergence and diversity of particle swarms, reduces the computational complexity, improves the adaptability of the algorithm, and can find the optimal solution to engineering problems faster and more accurately.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120218113A_ABST
    Figure CN120218113A_ABST
Patent Text Reader

Abstract

The invention discloses an engineering optimization method based on an improved particle swarm algorithm, and the method comprises the steps: constructing a particle swarm optimization model according to an engineering problem mathematical model, and initializing the position and speed of particles; then, calculating a fitness value index and a diversity index of the particles according to the model, and constructing convergence and diversity data according to the fitness value index and the diversity index; the two kinds of data are used for updating the initial positions and speeds of the particles, and the middle adjustment positions and speeds are obtained. Then, on the basis of the particle swarm optimization model and the intermediate adjustment position, the particle individuals and the global position are updated, and individual convergence and global convergence positions are obtained; and calculating a particle swarm output result according to convergence and diversity data and individual and global convergence positions. And finally, obtaining an optimal solution of the engineering problem according to an output result. According to the embodiment of the invention, two kinds of data are constructed by taking population diversity and fitness value as evaluation criteria, the population position and speed are updated, the optimal solution can be found more quickly and accurately, and the engineering optimization problem is efficiently solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present application relate to, but are not limited to, the fields of computer science and artificial intelligence technology, and in particular to an engineering optimization method based on an improved particle swarm algorithm. Background Art

[0002] Engineering optimization problems are widespread in many key fields such as bioinformatics, biomedical engineering, image processing, industrial scheduling, and pattern recognition. Swarm intelligence optimization algorithms, especially the particle swarm optimization algorithm, have become a common means to solve these problems due to their high robustness and wide applicability. However, there are many pain points in the existing technologies. The current improvements of the particle swarm optimization algorithm mostly rely on mixing other existing methods, and there is insufficient in-depth analysis of the structure of the particle swarm algorithm itself, which cannot fundamentally solve the inherent defects of the algorithm structure and is difficult to achieve a substantial and lasting improvement in performance. In the core issues of maintaining population diversity, balancing global exploration and local exploitation capabilities, and avoiding local optima, although there are numerous methods based on the particle swarm optimization algorithm emerging in an endless stream, most of them inevitably increase the computational complexity while improving performance. Moreover, the universality of these algorithms is poor. Facing complex and changeable engineering optimization problems, their adaptability can often only play a role for specific types of problems. For example, in the image segmentation task of biomedical engineering, the existing algorithms may perform well on simple images, but when encountering complex medical images, it is difficult to accurately segment due to insufficient diversity and poor adaptability; in the field of industrial scheduling, facing dynamic production tasks and resource constraints, the existing algorithms have high computational complexity and weak adaptability, and it is difficult to give an efficient scheduling plan.

[0003] Therefore, there is an urgent need for a particle swarm optimization algorithm that can effectively balance diversity and convergence, reduce computational complexity, and improve adaptability to efficiently solve corresponding engineering optimization problems. Summary of the Invention

[0004] The following is an overview of the subject matter described in detail in this article. This overview is not intended to limit the scope of protection of the claims.

[0005] The embodiments of the present application provide an engineering optimization method based on an improved particle swarm algorithm, and the improved algorithm can effectively balance diversity and convergence, reduce computational complexity, and improve its adaptability, so as to more effectively solve various engineering optimization problems.

[0006] In a first aspect, an embodiment of the present application provides an engineering optimization method based on an improved particle swarm optimization algorithm, including: establishing a particle swarm optimization model according to the mathematical model of the engineering problem, and initializing the initial position and initial velocity of each particle in the particle swarm; according to the particle swarm optimization model, calculating the fitness value index and diversity index of the particle swarm, constructing the convergence data of the particle swarm according to the fitness value index, and constructing the diversity data of the particle swarm according to the diversity index; according to the convergence data and the diversity data, updating the initial position and initial velocity of the particle to obtain an intermediate adjustment position and an intermediate adjustment velocity; based on the particle swarm optimization model and the intermediate adjustment position, updating the individual position and global position of the particle to obtain an individual convergence position and a global convergence position; calculating the output result of the particle swarm according to the convergence data, the diversity data, the individual convergence position and the global convergence position of the particle; obtaining the optimal solution of the engineering problem according to the output result of the particle swarm.

[0007] In an embodiment of the present application, updating the initial position and initial velocity of the particle according to the convergence data and the diversity data to obtain an intermediate adjustment position and an intermediate adjustment velocity includes: constructing a variety of evolutionary learning strategies for the particle swarm according to the convergence data and the diversity data; selecting a target learning strategy from the variety of evolutionary learning strategies according to the state of the particle swarm; updating the initial position and initial velocity of the particle according to the target learning strategy to obtain an intermediate adjustment position and an intermediate adjustment velocity.

[0008] In an embodiment of the present application, constructing the convergence data of the particle swarm according to the fitness value index includes: obtaining the fitness value of each particle in the particle swarm according to the fitness value index; obtaining a first target particle from the particle swarm according to the fitness value of the particle, and constructing the convergence data of the particle swarm based on the first target particle, where the fitness value of the first target particle is greater than a preset convergence threshold.

[0009] In an embodiment of the present application, constructing the diversity data of the particle swarm according to the diversity index includes: obtaining the diversity score of each particle in the particle swarm according to the diversity index; obtaining a second target particle from the particle swarm according to the diversity score of the particle, and constructing the diversity data of the particle swarm based on the second target particle, where the diversity score of the second target particle is greater than a preset diversity threshold.

[0010] In an embodiment of the present application, according to the convergence data and the diversity data, a variety of evolutionary learning strategies for the particle swarm are constructed, including: dividing the evolutionary process of the particle swarm to obtain multiple evolutionary stages; obtaining the individual learning strategies of the particles in each of the evolutionary stages according to the convergence data and the diversity data; and obtaining the evolutionary learning strategy of the particle swarm according to the individual learning strategies.

[0011] In an embodiment of the present application, obtaining the individual learning strategies of the particles in each of the evolutionary stages according to the convergence data and the diversity data includes: obtaining the position information of the parent particles of the particle in the current evolutionary stage according to the convergence data and the diversity data; and obtaining the individual learning strategy of the particle in the evolutionary stage according to the position information of the parent particles.

[0012] In an embodiment of the present application, obtaining the position information of the parent particles of the particle in the current evolutionary stage according to the convergence data and the diversity data includes: in the current evolutionary stage, selecting a first parent particle from the convergence data and a second parent particle from the diversity data; obtaining the first historical target position of the first parent particle and the second historical target position of the second parent particle; and performing a cross calculation on the first historical target position and the second historical target position to obtain the position information of the parent particles of the particle.

[0013] In an embodiment of the present application, calculating the output result of the particle swarm according to the convergence data, the diversity data, and the individual convergence position and the global convergence position of the particle includes: selecting a first parent particle from the convergence data and a second parent particle from the diversity data; obtaining the first historical target position of the first parent particle and the second historical target position of the second parent particle; generating perturbation position information according to the first historical target position and the second historical target position, and calculating the fitness value of the particle; and updating the individual convergence position and the global convergence position of the particle according to the perturbation position information and the fitness value to obtain the output result of the particle swarm.

[0014] In an embodiment of the present application, selecting a target learning strategy from the variety of evolutionary learning strategies according to the state of the particle swarm includes: obtaining evolutionary reward information according to the state of the particle swarm; calculating the expected action score of the particle swarm according to the evolutionary reward information; and selecting a target learning strategy from the variety of evolutionary learning strategies according to the expected action score.

[0015] In an embodiment of the present application, the state of the particle swarm includes a convergence index, an optimization index, and a diversity index; according to the state of the particle swarm, evolutionary reward information is obtained, including: obtaining the current convergence index, the current optimization index, and the current diversity index of the particle swarm in the current evolutionary stage, as well as the historical convergence index, the historical optimization index, and the historical diversity index in the previous evolutionary stage; according to the current convergence index, the current optimization index, and the current diversity index, as well as the historical convergence index, the historical optimization index, and the historical diversity index, obtaining the improved state information of the particle swarm; and obtaining the evolutionary reward information according to the improved state information.

[0016] An engineering optimization method based on an improved particle swarm algorithm provided by an embodiment of the present application. First, a particle swarm optimization model is established according to the mathematical model of the engineering problem, and the initial position and initial velocity of each particle in the particle swarm are initialized; then, according to the particle swarm optimization model, the fitness value index and the diversity index of the particles are calculated, and the convergence data of the particle swarm is constructed according to the fitness value index, and the diversity data of the particle swarm is constructed according to the diversity index; next, according to the convergence data and the diversity data, the initial position and initial velocity of the particles are updated to obtain an intermediate adjustment position and an intermediate adjustment velocity. This data update method based on dual indexes can more effectively balance the exploration and exploitation capabilities of the particles. Subsequently, based on the particle swarm optimization model and the intermediate adjustment position, the individual position and the global position of the particles are updated to obtain an individual convergence position and a global convergence position. In this way, the particles are guided to approach a better solution. According to the convergence data, the diversity data, and the individual convergence position and the global convergence position of the particles, the output result of the particle swarm is calculated. Finally, according to the output result of the particle swarm, the optimal solution of the engineering problem is obtained. This embodiment uses the diversity and fitness value of the population as the key evaluation criteria, constructs convergence data and diversity data, and updates the position and velocity of the population based on these two types of data, which can more accurately adjust the search behavior of the particles, and thus more effectively balance the global exploration and local development capabilities of the algorithm, improving the adaptability of the algorithm to different engineering optimization problems. On the other hand, since the global exploration and local development can be better balanced, the algorithm can find the optimal solution faster and more accurately, so as to efficiently solve various engineering optimization problems. Brief Description of the Drawings

[0017] Figure 1 is a flowchart of the engineering optimization method based on the improved particle swarm algorithm provided by an embodiment of the present application;

[0018] Figure 2 is provided by an embodiment of the present application Figure 1 specific flowchart of step 120 in

[0019] Figure 3 This is provided by another embodiment of the present application Figure 1 The specific flowchart of step 120 in

[0020] Figure 4 This is provided by an embodiment of the present application Figure 1 The specific flowchart of step 130 in

[0021] Figure 5 This is provided by an embodiment of the present application Figure 4 The specific flowchart of step 410 in

[0022] Figure 6 This is provided by an embodiment of the present application Figure 5 The specific flowchart of step 520 in

[0023] Figure 7 This is provided by an embodiment of the present application Figure 1 The specific flowchart of step 150 in

[0024] Figure 8 This is a simplified model diagram of the pressure vessel problem provided by a specific example of the present application Detailed implementation manners

[0025] In order to make the purpose, technical solutions and advantages of the present application clearer, the present application will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application

[0026] It should be noted that although the logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in a different order from that in the flowchart. Terms such as "first", "second", etc. in the specification, claims and the above-mentioned drawings are used to distinguish similar objects and do not necessarily need to describe a specific order or sequence. It should be noted that the structures, ratios, sizes, etc. shown in the drawings of this specification are only used to cooperate with the content disclosed in the specification for those skilled in this technology to understand and read, and are not used to limit the limiting conditions under which the present application can be implemented. Therefore, they do not have a technical essence. Any modification of the structure, change of the proportional relationship or adjustment of the size, without affecting the effects that the present application can produce and the purposes that can be achieved, should still fall within the scope covered by the technical content disclosed in the present application. At the same time, terms such as "upper", "lower", "left", "right", "middle" and "one" cited in this specification are only for the convenience of clear narration and are not used to limit the scope under which the present application can be implemented. The change or adjustment of their relative relationships, without substantial change in the technical content, should also be regarded as the scope within which the present application can be implemented

[0027] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those skilled in the technical field to which this application belongs. The terms used herein are only for the purpose of describing the embodiments of this application and are not intended to limit this application.

[0028] In many key fields such as bioinformatics, biomedical engineering, image processing, industrial scheduling, and pattern recognition, engineering optimization problems are ubiquitous. Swarm intelligence optimization algorithms, especially the particle swarm optimization algorithm, have become a common means to solve these problems due to their high robustness and wide applicability. However, there are many pain points in the existing technologies. The current improvements of the particle swarm optimization algorithm mostly rely on mixing other existing methods, lacking a deep analysis of the structure of the particle swarm algorithm itself, and unable to fundamentally solve the inherent defects of the algorithm structure, making it difficult to achieve a substantial and lasting improvement in performance. Regarding the core issues such as maintaining population diversity, balancing global exploration and local exploitation capabilities, and avoiding local optima, although numerous methods based on the particle swarm optimization algorithm have emerged, most of them inevitably increase the computational complexity while improving performance. Moreover, the universality of these algorithms is poor. Facing complex and changing engineering optimization problems, their adaptability is greatly reduced, and they often can only play a role for specific types of problems. For example, in the image segmentation task of biomedical engineering, existing algorithms may perform well on simple images, but when encountering complex medical images, due to insufficient diversity and poor adaptability, it is difficult to accurately segment; in the field of industrial scheduling, facing dynamic production tasks and resource constraints, existing algorithms have high computational complexity and weak adaptability, making it difficult to give an efficient scheduling plan.

[0029] Based on the various limitations of the existing technologies, there is an urgent need for a particle swarm optimization algorithm that can effectively balance diversity and convergence, reduce computational complexity, and improve adaptability to efficiently solve the corresponding engineering optimization problems.

[0030] In view of this, the embodiments of the present application provide an engineering optimization method based on an improved particle swarm optimization algorithm. First, a particle swarm optimization model is established according to the mathematical model of the engineering problem, and the initial position and initial velocity of each particle in the particle swarm are initialized. Then, according to the particle swarm optimization model, the fitness value index and the diversity index of the particle swarm are calculated, the convergence data of the particle swarm is constructed according to the fitness value index, and the diversity data of the particle swarm is constructed according to the diversity index. Next, according to the convergence data and the diversity data, the initial position and initial velocity of the particles are updated to obtain the intermediate adjustment position and the intermediate adjustment velocity. This data update method based on dual indexes can more effectively balance the exploration and exploitation capabilities of the particles. Subsequently, based on the particle swarm optimization model and the intermediate adjustment position, the individual position and the global position of the particles are updated to obtain the individual convergence position and the global convergence position. In this way, the particles are guided to approach the optimal solution. According to the convergence data, the diversity data, and the individual convergence position and the global convergence position of the particles, the output result of the particle swarm is calculated. Finally, according to the output result of the particle swarm, the optimal solution of the engineering problem is obtained. Based on the structure of the classical particle swarm optimization algorithm, this embodiment uses the diversity and fitness value of the population as the key evaluation criteria, constructs the convergence data and the diversity data, and updates the position and velocity of the population based on these two types of data, which can effectively solve the deficiencies existing in the analysis of the particle swarm optimization algorithm structure by the existing algorithms. Specifically, traditional algorithms often have difficulty in comprehensively considering the convergence and diversity of the particle swarm. However, in this embodiment, by separately managing the convergence data and the diversity data, the search behavior of the particles can be adjusted more accurately, and thus the global exploration and local exploitation capabilities of the algorithm can be balanced more effectively, improving the adaptability of the algorithm to different engineering optimization problems. On the other hand, since the global exploration and local exploitation can be better balanced, the algorithm can find the optimal solution faster and more accurately, thus efficiently solving various engineering optimization problems.

[0031] The following further elaborates on the embodiments of the present application with reference to the accompanying drawings.

[0032] Refer to Figure 1 , Figure 1 which is a flowchart of the engineering optimization method based on the improved particle swarm optimization algorithm provided by the embodiments of the present application. The method includes but is not limited to steps 110 to 160.

[0033] Step 110: Establish a particle swarm optimization model according to the mathematical model of the engineering problem, and initialize the initial position and initial velocity of each particle in the particle swarm;

[0034] Step 120: Calculate the fitness value index and the diversity index of the particle swarm according to the particle swarm optimization model, construct the convergence data of the particle swarm according to the fitness value index, and construct the diversity data of the particle swarm according to the diversity index;

[0035] Step 130: Update the initial position and initial velocity of the particles according to the convergence data and diversity data to obtain the intermediate adjusted position and intermediate adjusted velocity;

[0036] Step 140: Update the individual position and global position of the particles based on the particle swarm optimization model and the intermediate adjusted position to obtain the individual convergence position and global convergence position;

[0037] Step 150: Calculate the output result of the particle swarm according to the convergence data, diversity data, individual convergence position and global convergence position of the particles;

[0038] Step 160: Obtain the optimal solution to the engineering problem according to the output result of the particle swarm.

[0039] The following elaborates on Steps 110 to 160 in detail.

[0040] In a feasible embodiment, the mathematical model of the engineering problem can usually be represented as an objective function. For example, in the optimization of resource allocation problems, the goal may be to minimize costs or maximize benefits; in structural design problems, it may be to minimize weight while meeting certain strength constraints, etc. Assume the objective function is f(x), where x = {x1, x2,..., x n} is a vector composed of n decision variables. At the same time, the problem may also have some constraint conditions, such as g i (x) ≤ 0 (inequality constraint) and h i (x) ≤ 0 (equality constraint).

[0041] It can be understood that the particle swarm optimization (PSO) algorithm is a swarm intelligence optimization algorithm with global optimization capabilities, similar to the foraging behavior of a flock of birds. In PSO, each solution to the optimization problem is represented as a particle in the search space, and each particle consists of a velocity and a position. Each particle is updated according to the historical information of the population and the individual, and the historical information of the population and the individual is used to guide the continuous evolution of the population to obtain the optimal solution to the problem. The particle swarm optimization algorithm can find a better solution for many engineering problems within an acceptable time. By transforming the mathematical model of the engineering problem into a particle swarm optimization model, the advantages of this algorithm can be utilized to solve practical problems.

[0042] In a feasible embodiment, in the particle swarm optimization model, the position x i of each particle i in the D-dimensional search space = {x i1 , x i2 ,..., x iD} corresponds to a candidate solution to the engineering problem, that is, x iis a specific value of x in the objective function f(x). The velocity v of each particle i i ={v i1 , v i2 ,..., v iD} determines the direction and step size of the particle's movement in each iteration, where N is the population size. Further, the objective function f(x) of the engineering problem can be directly used as the fitness function in the particle swarm optimization model. The fitness function can be used to evaluate the quality of each particle's position, that is, to measure the degree to which the solution represented by the particle satisfies the engineering problem. The update equations for the particle velocity and position are shown in equations (1) and (2) respectively.

[0043] v ij (t + 1)=ω * v ij (t)+c1 * r1(t)(Pbest ij (t)-x ij (t))+c2 *

[0044] r2(t)(Gbest j (t)-x ij (t))(1),

[0045] x ij (t + 1)=x ij (t)+v ij (t + 1)(2),

[0046] where t is the current iteration number, j is a dimension in [1, D]; x ij is the j-th component of the position of particle i; Pbest ij is the j-th component of the individual historical best position of particle i; Gbest j is the j-th component of the global historical best position; ω is the inertia weight; r1 and r2 are random numbers following a uniform distribution from 0 to 1; c1 and c2 are acceleration coefficients.

[0047] In a feasible embodiment, during the process of initializing the initial position and initial velocity of each particle in the particle swarm, the initial position can be randomly generated within the value range of the decision variable. For example, if the value range of the decision variable x j is [a j , b j , then the initial position x ij (0) of the j-th dimension of particle i can be generated by equation (3).

[0048] x ij (0)=a j +r * (b j -a j )(3), where r is a random number between [0, 1].

[0049] In addition, the initial velocity can also be randomly generated within a small range. The range of the velocity can be adjusted according to the characteristics of the problem. For example, if the value range of the velocity is set as [-v max , v max , then the initial velocity v ij (0) of the i-th particle in the j-th dimension can be generated by Equation (4).

[0050] v ij (0) = -v max + 2r * v max (4).

[0051] In a feasible embodiment, the fitness value index of the particle swarm is mainly used to measure the quality of the solution represented by each particle at the current position, and it can usually be calculated based on the objective function of the engineering problem. Specifically, for the problem of minimizing the value, if the objective function is f(x), where x is the position vector of the particle, then the fitness value F i of the i-th particle is equal to f(x i ), where x i is the current position of the particle. For the problem of maximizing the value, the objective function can be appropriately transformed. For example, let the fitness value F i = -f(x i ). In this way, the problem of maximizing the value can be transformed into the problem of minimizing the value for processing. Finally, the larger the fitness value, the better the solution.

[0052] In a feasible embodiment, the diversity index is an important index to measure the degree of dispersion of particles in the particle swarm, and it reflects the exploration ability of the particle swarm in the search space. The common calculation methods of the diversity index are mainly divided into two categories: the calculation of the diversity index based on position and the calculation of the diversity index based on fitness value. In the calculation of the diversity index based on position, it mainly includes the average distance method and the standard deviation method. The average distance method measures the degree of dispersion of particle distribution by calculating the average Euclidean distance between particles; the standard deviation method evaluates the discreteness of particle distribution by calculating the standard deviation of particle positions. In the calculation of the diversity index based on fitness value, it mainly includes the fitness variance method and the fitness entropy method. The fitness variance method reflects the degree of dispersion of the particle swarm in the fitness space by calculating the variance of particle fitness values; the fitness entropy method uses the concept of information entropy to measure the complexity of particle fitness distribution.

[0053] It should be noted that this embodiment does not limit the specific methods for calculating the particle fitness value index and the diversity index.

[0054] In a feasible embodiment, such as Figure 2As shown, the specific process of constructing the convergence data of the particle swarm according to the fitness value index in step 120 may at least include steps 210 to 220.

[0055] Step 210: Obtain the fitness value of each particle according to the fitness value index of the particle swarm;

[0056] Step 220: Obtain the first target particle from the particle swarm according to the fitness value of the particle, and construct the convergence data of the particle swarm based on the first target particle, where the fitness value of the first target particle is greater than a preset convergence threshold.

[0057] In a feasible embodiment, after calculating the fitness value index of the particle swarm, the fitness value of each particle can be obtained by traversing these fitness value indexes. Subsequently, the particles are screened according to the fitness value to obtain the particles with fitness values greater than the convergence threshold (i.e., the first target particles), and the convergence data of the particle swarm is constructed based on these particles. Specifically, for the problem of minimizing the objective function (that is, the closer the obtained solution is to the theoretical optimal value, the better, and the theoretical optimal values of different engineering optimization problems are different, some are 0, and some are not), in each generation, first, the fitness values of each particle in the population are ranked, and then the top e particles are selected, and the convergence data is constructed based on these particles. Specifically, these particles can be stored in the convergence archive E. According to the change of the particle fitness value, the archive is updated in each generation, as shown in formula (5).

[0058] E = {x i1 , x i2 ,.., x ie | f(x i1 ) ≤ f(x i2 ) ≤... ≤ f(x ie ) ≤... ≤ f(x iN )}(5),

[0059] where, x ie represents the position of the i-th particle in the convergence archive E; f(x ie ) represents the fitness value of x ie .

[0060] In a feasible embodiment, as Figure 3 shown, the specific process of constructing the diversity data of the particle swarm according to the diversity index in step 120 may include, but is not limited to, steps 310 to 320.

[0061] Step 310: Obtain the diversity score of each particle according to the diversity index of the particle swarm;

[0062] Step 320: Obtain a second target particle from the particle swarm according to the diversity score of the particles, and construct diversity data of the particle swarm based on the second target particle, where the diversity score of the second target particle is greater than a preset diversity threshold.

[0063] In a feasible embodiment, after calculating the diversity index of the particle swarm, the diversity score of each particle can be obtained by traversing these diversity indices. Subsequently, the particles are screened according to the diversity scores to obtain particles with diversity scores greater than the diversity threshold (i.e., the second target particles), and the diversity data of the particle swarm is constructed based on these particles. Specifically, for the problem of minimizing the objective function, in each generation, first, the diversity of each particle in the population is ranked, and then the top c particles are selected and the diversity data is constructed based on these particles. Specifically, these particles can be stored in the diversity archive C. According to the change of particle diversity, the archive is updated in each generation, as shown in formula (6). C = {x i1 , x i2 ,.., x ic | d(x i1 ) ≤ d(x i2 ) ≤... ≤ d(x ic ) ≤... ≤ d(x iN )} (6),

[0064] In formula (6), x ic represents the position of the i-th particle in the diversity archive C; d(x ic ) represents the diversity of x ic . Among them, N represents the population size, x icj represents the j-th component of the position of the c-th particle in the diversity archive C, and x kj represents the j-th component of the position of particle k.

[0065] In a feasible embodiment, as Figure 4 shown, the specific process of step 130 may include, but is not limited to, steps 410 to 430.

[0066] Step 410: Construct various evolutionary learning strategies of the particle swarm according to the convergence data and the diversity data;

[0067] Step 420: Select a target learning strategy from the various evolutionary learning strategies according to the state of the particle swarm;

[0068] Step 430: Update the initial position and initial velocity of the particles according to the target learning strategy to obtain an intermediate adjusted position and an intermediate adjusted velocity.

[0069] It can be understood that during the optimization process of the particle swarm algorithm, the convergence data reflects whether the algorithm is approaching the optimal solution, and the diversity data reflects the degree of dispersion of the particles in the search space. Constructing various evolutionary learning strategies by combining these two types of data helps to balance the global search and local search capabilities of the algorithm.

[0070] In a feasible embodiment, as Figure 5 shown, the specific process of constructing various evolutionary learning strategies for the particle swarm in step 410 may include, but is not limited to, steps 510 to 530.

[0071] Step 510: Divide the evolutionary process of the particle swarm to obtain multiple evolutionary stages;

[0072] Step 520: Based on the convergence data and the diversity data, obtain the individual learning strategies of the particles in each evolutionary stage;

[0073] Step 530: Based on the individual learning strategies, obtain the evolutionary learning strategy of the particle swarm.

[0074] In a feasible embodiment, in order to optimize the balance between global exploration and local exploitation during the population evolution process, this embodiment divides the entire population evolution process into four stages, namely the global exploration stage, the transition stage from global exploration to local exploitation, the local exploitation stage, and the fast convergence stage. On this basis, according to the convergence data and the diversity data, it is possible to calculate the individual learning strategies for the particles in different evolutionary stages. Furthermore, based on the individual learning strategies, the evolutionary learning strategy of the particle swarm can be deduced.

[0075] In a feasible embodiment, the process of determining the individual learning strategies of the particles in each evolutionary stage according to the convergence data and the diversity data in step 520 includes two steps: Step one: First, combine the convergence data and the diversity data to determine the position information of the parent particles of the particle swarm in the current evolutionary stage. The convergence data can reflect the degree to which the population approaches the optimal solution, and the diversity data reflects the dispersion of the particles in the search space. By comprehensively analyzing these two types of data, the evolutionary trend of the population can be grasped more accurately, so as to determine the reasonable positions of the parent particles. Step two: Then, based on the position information of the parent particles, deduce the individual learning strategies of the particles in this evolutionary stage. The position information of the parent particles provides an important reference for the learning of the particles, and the particles can adjust their search directions and step sizes according to this information to better adapt to different evolutionary stages.

[0076] In a feasible embodiment, as Figure 6 shown, the specific process of step one of step 520 may include, but is not limited to, steps 610 to 630.

[0077] Step 610: In the current evolution stage, select the first parent particle from the convergence data and the second parent particle from the diversity data;

[0078] Step 620: Obtain the first historical target position of the first parent particle and the second historical target position of the second parent particle;

[0079] Step 630: Perform a crossover calculation on the first historical target position and the second historical target position to obtain the position information of the parent particles of the particle swarm.

[0080] In a feasible embodiment, in the global exploration stage, a parent particle m (i.e., the first parent particle) can be randomly selected from the convergence data (i.e., the convergence archive E), and a parent particle n (i.e., the second parent particle) can be randomly selected from the diversity data (i.e., the diversity archive C). It should be noted that the first historical target position refers to the individual historical optimal position of the parent particle m, and the second historical target position refers to the individual historical optimal position of the parent particle n. After obtaining the individual historical optimal positions of these two parent particles, a crossover operation is performed on these two positions, so that the position information of the parent particles of the particle swarm can be obtained. Then, based on the position information of the parent particles, the individual learning strategy of the particles in this evolution stage is deduced. Specifically, the learning strategy S of particle i in this evolution stage can be deduced based on the position information of the parent particles in the following way i : Assume that a new position vector (referring to the learning strategy S i ) is generated after the crossover operation. Each dimensional position in this vector is composed of the corresponding dimensional positions of the parent particles m and n with a certain probability. That is, the probability that the jth position S ij in the new position vector comes from the parent particle n is p, and the probability that it comes from the parent particle m is 1 - p. The p value determines the contribution degree of the parent particles n and m to the individual learning strategy S i of particle i. Further, according to the individual learning strategy of particle i, the evolutionary learning strategy of the particle swarm in this evolution stage can be deduced, and this strategy is shown in formula (7). In the actual application of this strategy, the p value can be set to 0.8, which means that when generating a new position vector, the contribution ratio of the individual historical optimal position of the parent particle n to the learning strategy of particle i is 80%, and the contribution ratio of the parent particle m is 20%.

[0081]

[0082] In a feasible embodiment, during the transition stage from global exploration to local exploitation, similarly, a parent particle m can be randomly selected from the convergence archive E first, and a parent particle n can be randomly selected from the diversity archive C. Then, a crossover operation is performed on the individual historical best positions of n and m to obtain the position information of the parent particles in the particle swarm. Then, based on the position information of the parent particles, the individual learning strategy of the particle at this evolutionary stage is deduced. Specifically, the learning strategy S of particle i at this evolutionary stage is deduced based on the position information of the parent particles in the following way i : Assume that a new position vector is generated after the crossover operation, and the position of each dimension in this vector is composed of the corresponding dimension positions of the parent particles m and n with a certain probability. That is, the probability that the j-th position S ij in the new position vector comes from the parent particle n is q, and the probability that it comes from the parent particle m is 1 - q. The value of q determines the contribution degrees of the parent particles n and m to the individual learning strategy S i of particle i. Further, according to the individual learning strategy of particle i, the evolutionary learning strategy of the particle swarm at this evolutionary stage can be deduced, and this strategy is shown in formula (8). In the practical application of this strategy, the value of q can be set to 0.5, which means that when generating the new position vector, the contribution ratio of the individual historical best position of the parent particle n to the learning strategy of particle i is 50%, and the contribution ratio of the parent particle m is 50%.

[0083]

[0084] In a feasible embodiment, during the local exploitation stage, similarly, a parent particle m can be randomly selected from the convergence archive E first, and a parent particle n can be randomly selected from the diversity archive C. Then, a crossover operation is performed on the individual historical best positions of n and m to obtain the position information of the parent particles in the particle swarm. Then, based on the position information of the parent particles, the individual learning strategy of the particle at this evolutionary stage is deduced. Specifically, the learning strategy S of particle i at this evolutionary stage is deduced based on the position information of the parent particles in the following way i : Assume that a new position vector is generated after the crossover operation, and the position of each dimension in this vector is composed of the corresponding dimension positions of the parent particles m and n with a certain probability. That is, the probability that the j-th position S ij in the new position vector comes from the parent particle n is 1 - p, and the probability that it comes from the parent particle m is p. The value of p determines the contribution degrees of the parent particles n and m to the individual learning strategy S iDegree of contribution. Further, according to the individual learning strategy of particle i, the evolutionary learning strategy of the particle swarm at this evolutionary stage can be deduced, and this strategy is shown in formula (9). In the practical application of this strategy, the p value can be set to 0.8, which means that when generating a new position vector, the proportion of the contribution of the individual historical optimal position of the parent particle n to the learning strategy of particle i is 20%, and the contribution proportion of the parent particle m is 80%.

[0085]

[0086] In a feasible embodiment, in the fast convergence stage, the learning strategy S of the i-th particle i uses the global optimal position Gbest in the classical PSO j . The strategy is shown in formula (10).

[0087] S ij = Gbest j (10).

[0088] In a feasible embodiment, in each evolutionary stage, the velocity update method of the particle is shown in formula (11).

[0089] v ij (t + 1)= ω * v ij (t)+ c1 * r1(t)(Pbest ij (t)- x ij (t))+ c2 *

[0090] r2(t)(S ij (t)- x ij (t))(11),

[0091] where t is the current iteration number, j is a dimension in [1, D]; x ij is the j-th component of the position of particle i; Pbest ij is the j-th component of the individual historical optimal position of particle i; S ij is the j-th component of the learning strategy of particle i; ω is the inertia weight; r1 and r2 are random numbers obeying the uniform distribution from 0 to 1; c1 and c2 are acceleration coefficients.

[0092] In a feasible embodiment, after obtaining the evolutionary learning strategies corresponding to the particle swarm in these four evolutionary stages, the dynamic selection of these strategies can be further achieved by means of reinforcement learning. Specifically, as an effective means to solve dynamic decision-making problems, Q-learning can provide a quantitative decision-making basis for strategy selection. To accelerate the convergence speed of the algorithm, Q-learning can be used to construct a selection method for evolutionary learning strategies. This method takes the Q-learning algorithm as the core, and by continuously updating the action-state value function (Q-value), the optimal strategy is selected from multiple evolutionary learning strategies according to the current state information at each evolutionary stage, so as to guide the evolution process of the particle swarm and enable the algorithm to converge to the optimal solution more efficiently.

[0093] In a feasible embodiment, as a reinforcement learning algorithm, the basic components of Q-learning include an agent, an environment, actions, states, and rewards. These elements interact with each other to jointly promote the learning process. Specifically, the search space of the population can be regarded as the environment in Q-learning, which limits the activity range of the particles and the possible state distribution. The particles act as the agents, exploring and learning in the environment, and searching for the optimal solution by interacting with the environment. The actions correspond to the four evolutionary learning strategies, which can be divided into four types. The particles can select appropriate actions from them in different states to adjust their own evolutionary methods. The state of the particle swarm can be defined based on the performance of the population in terms of convergence, optimality, and diversity.

[0094] In a feasible embodiment, in the process of selecting the target learning strategy from multiple evolutionary learning strategies according to the state of the particle swarm, the evolutionary reward information can be obtained first according to the state of the particle swarm; then, based on the evolutionary reward information, the expected action score of the particle swarm can be calculated; then, according to the expected action score, the target learning strategy is selected from multiple evolutionary learning strategies. Specifically, the following steps can be taken for operation: comprehensively analyze the state of the particle swarm, and calculate according to the preset reward function in combination with the current state of the particle swarm to obtain the evolutionary reward information. This reward information is a quantitative evaluation of the current performance of the particle swarm. The higher the reward value, the closer the state of the particle swarm is to the expected optimization goal. Further, based on the obtained evolutionary reward information, using the Q-value update formula of Q-learning, calculate the expected action score corresponding to each evolutionary learning strategy. The expected action score is essentially an estimate of the long-term cumulative reward that may be brought about by taking a certain action (i.e., a certain evolutionary learning strategy) in the current state, which comprehensively considers the current reward and the rewards that may be obtained in the future. Subsequently, compare the expected action scores of all evolutionary learning strategies, and select the strategy with the highest score as the target learning strategy. In this way, the particle swarm can adopt the strategy that is most likely to guide it to converge to the optimal solution quickly and efficiently at each evolutionary stage, thereby improving the efficiency and quality of the entire optimization process.

[0095] In a feasible embodiment, the state of the particle swarm can be characterized by three key indicators: the convergence index, the optimization index, and the diversity index. Among them, the convergence index is used to measure the degree to which the population converges towards the optimal solution. Its definition is shown in formula (12), which evaluates the convergence of the population by calculating the average Euclidean distance from each particle in the population to the global optimal position. The smaller the average Euclidean distance, the closer the particle swarm is to the global optimal position, that is, the better the convergence. This index can intuitively reflect whether the particle swarm gradually gathers near the optimal solution during the search process. The optimization index is used to evaluate the performance of the algorithm during the search for the optimal solution. Its definition is shown in formula (13), which is calculated based on the average fitness value of the population. The higher the average fitness value (for maximization problems) or the lower the average fitness value (for minimization problems), the better the solution found by the algorithm at the current stage, that is, the better the optimization performance of the algorithm. The diversity index is used to measure the degree of dispersion of the particles in the population. Its definition is shown in formula (14), and diversity is defined as the average Euclidean distance between the positions of any two particles in the population. The larger the average Euclidean distance, the more dispersed the particles are distributed in the search space, and the higher the diversity of the population. Maintaining appropriate diversity is crucial for preventing the algorithm from falling into local optimal solutions because higher diversity allows the particle swarm to explore the search space more extensively. By comprehensively considering these three indicators, the state of the particle swarm can be described comprehensively and accurately, providing a strong basis for subsequent optimization algorithm design and decision-making.

[0096]

[0097] In a feasible embodiment, in order to eliminate the differences in numerical range, dimension, etc. among the three evaluation indicators of convergence, optimization, and diversity, and to ensure their equal importance and comparability in subsequent analyses, the calculation results of these three indicators can be normalized. Normalization is a common data preprocessing method that maps the values of each indicator to a specific interval (usually [0,1]), which can avoid biases in the overall analysis caused by the different characteristics of the indicators themselves. After normalization, each evaluation indicator can be regarded as having two state tendencies. For example, the convergence index can tend to have better convergence (values close to 1) or worse convergence (values close to 0), the optimization index can tend to have good optimization effects or poor optimization effects, and the diversity index can tend to have high diversity or low diversity. According to the principle of permutation and combination, for the three evaluation indicators, each with 2 state tendencies, a total of eight different state combinations can be formed. The specific representations of these eight states are shown in formula (15).

[0098]

[0099] In Equation (15), con′, opt′, and div′ respectively represent the convergence, optimality, and diversity of the population in the previous iteration. con, opt, and div respectively represent the convergence, optimality, and diversity of the population in the current iteration.

[0100] Further, after the agent (i.e., the particle) executes the corresponding action according to the current state, it will obtain the corresponding reward. To comprehensively and objectively evaluate the performance of various actions in the process of searching for the optimal solution, this embodiment constructs a reward mechanism based on the state change of the population in two consecutive iterations. The following details the specific process of obtaining the evolutionary reward information according to the state of the particle swarm in this embodiment: First, obtain the current convergence index, current optimality index, and current diversity index of the particle swarm in the current evolutionary stage, as well as the historical convergence index, historical optimality index, and historical diversity index in the previous evolutionary stage. The states involved here cover the three important indicators of convergence, optimality, and diversity mentioned above. Then, compare the current three indicators (convergence, optimality, diversity) with the historical indicators to obtain the improved state information of the particle swarm. This information can intuitively reflect the state change of the particle swarm between two iterations. Finally, determine the evolutionary reward information according to the improved state information. Specifically, the reward mechanism is designed based on the improvement of these three indicators in two consecutive iterations. If the population improves in terms of convergence, optimality, and diversity in two consecutive iterations, it indicates that this action helps to guide the particle swarm to evolve in a better direction. At this time, the agent will obtain a higher reward; on the contrary, if the state deteriorates, a lower reward or even punishment will be given. The specific calculation method of the reward is given by Equation (16). This equation comprehensively considers the change degree and weight of each indicator and can accurately measure the quality of the action in a quantitative manner. It should be noted that in the Q-learning algorithm, the reward is the key basis for updating the Q-table. The Q-table stores the expected values corresponding to executing various actions in different states. Based on the above reward mechanism, the Q-table can be updated. By combining the currently obtained reward, the old Q-value, and parameters such as the learning rate, the Q-table can be continuously optimized as the agent interacts with the environment. In this way, when making future decisions, the agent can select better actions according to the Q-table, thereby continuously adjusting its preference for different actions. The update equation of the Q-table is shown in Equation (17).

[0101] R = (con′ - con) + (opt′ - opt) + (div′ - div) (16),

[0102] Q next (s,a) = (1 - α)Q(s,a) + α[R + γmax a Q(s next ,a)] (17),

[0103] In Equation (17), s and a represent the current state and the current action; s next represents the next state; max a Q(s next , a) is the maximum Q-value in the Q-table for the next state s next ; R is the immediate reward obtained after executing action a; γ and α are the discount factor and the learning rate respectively.

[0104] Furthermore, after completing the update calculation of the Q-table, the population can select the most appropriate action according to the best selection principle based on the updated Q-table information. The update calculation of the Q-table here is carried out according to the reward mechanism and the Q-table update equation (Equation (17)) mentioned above. Through each interaction between the agent (particle) and the environment, combined with the obtained rewards, the expected values corresponding to executing each action in different states stored in the Q-table are continuously adjusted and optimized, so that the Q-table can more accurately reflect the advantages and disadvantages of different actions in different states. It should be noted that the best selection principle is an important basis for decision-making in the Q-learning algorithm, and its core purpose is to enable the population to select the action that is most likely to lead it to approach the optimal solution in the current state. This principle is shown in Equation (18), which comprehensively considers the expected values of each action recorded in the Q-table. Usually, the best selection principle will select the action with the maximum Q-value in the current state, because this means that this action has been proven to be the most rewarding in the historical interaction process. In summary, after completing the update calculation of the Q-table, the population can use the best selection principle, refer to the expected value information in the Q-table, and select the most appropriate action (i.e., the target learning strategy) from the set of optional actions, so as to promote the population to continuously explore in the search space and gradually approach the optimal solution.

[0105]

[0106] In Equation (18), Argmax[Q(s, a)] represents the action corresponding to the maximum Q-value in state s; □ represents a control parameter ranging from 0 to 1, and a r represents a randomly selected action.

[0107] In a feasible embodiment, after calculating the target learning strategy, the initial position and initial velocity of the particles can be updated based on the target learning strategy, so as to obtain the intermediate adjusted position and intermediate adjusted velocity. Subsequently, according to the particle swarm optimization model (or the objective function referred to by the mathematical model) and the intermediate adjusted position, the individual position and global position of the particles are updated, and finally the individual convergence position and global convergence position are determined. Specifically, the velocity and position of the particles are updated according to the target learning strategy. After the update is completed, the fitness value of the particle at the new position is evaluated, and this fitness value is the function value corresponding to the objective function at this position. Then, based on these fitness values, the individual historical optimal position and global historical optimal position of each particle are updated to obtain the individual convergence position and global convergence position of the particle. During this process, if the fitness value of a certain particle at the new position is better than the fitness value corresponding to its individual historical optimal position, then the new position is updated to the individual historical optimal position of the particle; if the fitness value of the new position is better than the fitness value corresponding to the global historical optimal position, then the global historical optimal position is updated.

[0108] It should be noted that the individual historical optimal position of each particle may be either a local optimal position or a global optimal position. When the historical optimal position of the current individual is a local optimal solution, the population is very likely to fall into the dilemma of local optimality and thus cannot find the global optimal solution. To effectively enhance the ability of the population to jump out of the local optimum, this embodiment particularly proposes a local search strategy. Based on this strategy, in a feasible embodiment, as Figure 7 shown, in step 150, according to the convergence data, diversity data, and the individual convergence position and global convergence position of the particles, the specific process of calculating the output result of the particle swarm may include, but is not limited to, the following steps 710 to step 740.

[0109] Step 710: Select the first parent particle from the convergence data and the second parent particle from the diversity data;

[0110] Step 720: Obtain the first historical target position of the first parent particle and the second historical target position of the second parent particle;

[0111] Step 730: Generate perturbation position information according to the first historical target position and the second historical target position, and calculate the fitness value of the particle;

[0112] Step 740: Update the individual convergence position and global convergence position of the particle according to the perturbation position information and the fitness value to obtain the output result of the particle swarm.

[0113] In a feasible embodiment, in step 710, the convergence data reflects the trend of the particle swarm converging to the optimal solution. Selecting the first parent particles from the convergence data means choosing those particles that perform better during the convergence process and are closer to the currently considered optimal region. The diversity data reflects the degree of dispersion of the particles in the search space. Selecting the second parent particles from the diversity data is to introduce particles with different search directions and positions, increasing the diversity of the search. Combining two particles with convergence advantages and diversity advantages as parents so that when generating new search positions subsequently, it is possible to explore in the current convergence direction and expand to different search regions, avoiding falling into local optima.

[0114] In a feasible embodiment, in step 720, the first historical target position of the first parent particle is the optimal position that the particle has ever reached, reflecting its best achievement in the historical search process; similarly, the second historical target position of the second parent particle is the same. Obtaining these two positions provides basic information for generating new search positions subsequently. Using the historical optimal positions of the parent particles as reference points for generating new search positions, it is expected to further explore based on these historical optimal positions to find better solutions.

[0115] In a feasible embodiment, in step 730, perturbation position information is generated by performing a certain operation (such as crossover, mutation, etc.) on the first historical target position and the second historical target position, introducing a certain degree of randomness and variation so that the new position can explore other regions in the search space. Calculate the fitness value of the particle at this perturbation position to evaluate the quality of this position.

[0116] In a feasible embodiment, in step 740, if the fitness value of the perturbation position is better than the current individual convergence position or global convergence position of the particle, then update the corresponding position, enabling the particle swarm to evolve in a better direction. The finally obtained updated individual convergence position and global convergence position are the output results of the particle swarm. In this step, by continuously optimizing the search results of the particle swarm, the particle swarm can gradually approach the global optimal solution.

[0117] In a feasible embodiment, in each iteration process, two parent particles are randomly selected from the convergence archive E and the diversity archive C, denoted as m and n respectively. Then, calculate the individual historical optimal position Pbest of particle m m and the individual historical optimal position Pbest of particle n n of the difference vector, and perform a scaling operation on it to generate the perturbation vector G i . In the early stage of the algorithm, to widely explore the search space, for each dimension information of the current particle CPbest i , it mainly comes from G iThe perturbation of the individual historical optimal position Pbest of the particle itself i has only a low probability of originating from G i The perturbation of the global optimal position Gbest, which can prompt the particle to actively explore new regions and avoid premature convergence. In the late stage of the algorithm, after sufficient exploration in the early stage, it is more necessary for the algorithm to converge to a better solution at this time. Therefore, each dimension of information of CPbest i mostly originates from G i The perturbation of the global optimal position Gbest, and a small probability originates from G i The perturbation of Pbest i to guide the particle to approach the global optimal position, while maintaining a certain diversity to prevent missing a better solution. The update formula for this strategy is shown in Equation (19), which describes how to update the position of the particle according to the above rules at different stages to balance the global search and local search capabilities of the algorithm.

[0118]

[0119] The optimization process of this embodiment is described below with a specific example.

[0120] Suppose there is an optimization design problem of a pressure vessel, and its core goal is to minimize the design cost as much as possible while fully meeting the production requirements. Figure 8 A simplified model of the pressure vessel design problem is presented. This model contains 4 design variables, namely: the inner radius x1 of the container, the length x2 of the container, the thickness x3 of the container, and the thickness x4 of the container head.

[0121] The mathematical model of the pressure vessel is represented by Equation (20), and the constraint conditions are given by Equation (21). The objective function represented by Equation (20) aims to minimize the design cost. At the same time, Equation (21) establishes a series of constraint conditions to ensure the practical feasibility of the design scheme.

[0122]

[0123] In Equation (21), the boundary constraints of the 4 design variables are satisfied: 0 ≤ x1 ≤ 99, 0 ≤ x2 ≤ 99, 10 ≤ x3 ≤ 99, 10 ≤ x4 ≤ 99.

[0124] Furthermore, a particle swarm optimization model is constructed based on the above mathematical model, and initial positions and velocities are randomly assigned to each particle in the particle swarm. During the iteration process, the following steps are performed: First, calculate the fitness value index and diversity index of the particle swarm. The fitness value index can reflect the advantages and disadvantages of the design scheme represented by each particle in terms of cost reduction, and the diversity index reflects the degree of dispersion of the particles in the search space. Based on these two indexes, a dual archive is constructed, namely the convergence archive and the diversity archive. The convergence archive is used to record the particle information tending to the optimal solution, and the diversity archive retains the particle information with different search directions, so as to balance the global search and local search capabilities of the algorithm. Then, a learning strategy selection method based on reinforcement learning is adopted to dynamically select a suitable strategy from multiple evolutionary learning strategies. Reinforcement learning can adaptively select the strategy that is most conducive to finding the optimal solution according to the historical performance and current state of the particle swarm. Next, according to the selected evolutionary learning strategy, update the initial velocity and position of the particle. The update of the velocity determines the moving direction and step size of the particle in the search space, and the update of the position changes the design scheme represented by the particle. At the same time, evaluate the fitness value of the particle, that is, the objective function value, which can be calculated according to Equation (20). According to these fitness values, update the individual historical best position and the global historical best position of each particle. If the fitness value of a particle at the new position is better than the fitness value corresponding to its individual historical best position, then update the individual historical best position; if the fitness value of the new position is better than the fitness value corresponding to the global historical best position, then update the global historical best position. Further, perturbations are generated based on the dual archive. By applying perturbations to the individual historical best positions of the population, particles are prompted to jump out of the local optimal solution and explore a wider search space. Evaluate the fitness value of each particle again, and update the individual historical best position and the global historical best position. According to the updated individual historical best position and global historical best position, update the velocity and position of the particle again. During the update process, ensure that all particles still satisfy the constraint conditions specified by Equation (21) after the update.

[0125] The iteration process continues until a preset termination condition is met, such as reaching the maximum number of iterations, the change in the fitness value being less than a certain threshold, etc. Finally, the global optimal solution is output as the optimal design scheme for this pressure vessel design problem.

[0126] The above description of the disclosed embodiments enables those skilled in the art to implement or use the present application. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein can be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application will not be limited to the embodiments shown herein, but will be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims

1. An engineering optimization method based on an improved particle swarm algorithm, characterized in that: include: A particle swarm optimization model is established based on the mathematical model of the engineering problem, and the initial position and initial velocity of each particle in the particle swarm are initialized; According to the particle swarm optimization model, a fitness value index and a diversity index of the particle swarm are calculated, and convergence data of the particle swarm is constructed according to the fitness value index, and diversity data of the particle swarm is constructed according to the diversity index; According to the convergence data and the diversity data, the initial position and the initial velocity of the particle are updated to obtain an intermediate adjustment position and an intermediate adjustment velocity; Based on the particle swarm optimization model and the intermediate adjustment position, the individual position and the global position of the particle are updated to obtain an individual convergence position and a global convergence position; Calculating an output result of the particle swarm according to the convergence data, the diversity data, and the individual convergence positions and the global convergence positions of the particles; According to the output result of the particle swarm, an optimal solution to the engineering problem is obtained.

2. The engineering optimization method according to claim 1, characterized in that: According to the convergence data and the diversity data, the initial position and the initial velocity of the particle are updated to obtain an intermediate adjustment position and an intermediate adjustment velocity, including: constructing multiple evolutionary learning strategies of the particle swarm according to the convergence data and the diversity data; Selecting a target learning strategy from the multiple evolutionary learning strategies according to the state of the particle swarm; The initial position and initial velocity of the particle are updated according to the target learning strategy to obtain an intermediate adjustment position and an intermediate adjustment velocity.

3. The engineering optimization method according to claim 1, characterized in that: The step of constructing the convergence data of the particle swarm according to the fitness value indicator includes: According to the fitness value indicator, obtaining the fitness value of each particle in the particle swarm; According to the fitness value of the particle, a first target particle is obtained from the particle swarm, and convergence data of the particle swarm is constructed based on the first target particle, wherein the fitness value of the first target particle is greater than a preset convergence threshold.

4. The engineering optimization method according to claim 1, characterized in that: The step of constructing the diversity data of the particle swarm according to the diversity index includes: According to the diversity index, a diversity score of each particle in the particle group is obtained; According to the diversity score of the particle, a second target particle is obtained from the particle group, and diversity data of the particle group is constructed based on the second target particle, wherein the diversity score of the second target particle is greater than a preset diversity threshold.

5. The engineering optimization method according to claim 2, characterized in that: According to the convergence data and the diversity data, multiple evolutionary learning strategies of the particle swarm are constructed, including: Dividing the evolution process of the particle swarm to obtain multiple evolution stages; Obtaining individual learning strategies of particles at each of the evolutionary stages according to the convergence data and the diversity data; According to the individual learning strategy, an evolutionary learning strategy of the particle swarm is obtained.

6. The engineering optimization method according to claim 5, characterized in that: According to the convergence data and the diversity data, the individual learning strategies of the particles at each evolutionary stage are obtained, including: Obtaining, according to the convergence data and the diversity data, the parent particle position information of the particle in the current evolution stage; According to the position information of the parent particle, the individual learning strategy of the particle in the evolution stage is obtained.

7. The engineering optimization method according to claim 6, characterized in that: According to the convergence data and the diversity data, the parent particle position information of the particle in the current evolution stage is obtained, including: In the current evolution stage, a first parent particle is selected from the convergence data, and a second parent particle is selected from the diversity data; Obtaining a first historical target position of the first parent particle and a second historical target position of the second parent particle; The first historical target position and the second historical target position are cross-calculated to obtain the parent particle position information of the particle.

8. The engineering optimization method according to claim 1, characterized in that: The output result of the particle swarm is calculated based on the convergence data, the diversity data, and the individual convergence positions and the global convergence positions of the particles, including: Selecting a first parent particle from the convergence data and selecting a second parent particle from the diversity data; Obtaining a first historical target position of the first parent particle and a second historical target position of the second parent particle; Generate disturbance position information according to the first historical target position and the second historical target position, and calculate the fitness value of the particle; According to the disturbance position information and the fitness value, the individual convergence position and the global convergence position of the particle are updated to obtain the output result of the particle group.

9. The engineering optimization method according to claim 2, characterized in that: The step of selecting a target learning strategy from the plurality of evolutionary learning strategies according to the state of the particle swarm comprises: Obtaining evolution reward information according to the state of the particle swarm; Calculating the expected action score of the particle swarm according to the evolution reward information; A target learning strategy is selected from the multiple evolutionary learning strategies according to the expected action score.

10. The engineering optimization method according to claim 9, characterized in that: The state of the particle swarm includes a convergence index, an optimization index and a diversity index; According to the state of the particle swarm, evolution reward information is obtained, including: Obtaining a current convergence index, a current optimization index, and a current diversity index of the particle swarm in the current evolutionary stage, as well as a historical convergence index, a historical optimization index, and a historical diversity index in the previous evolutionary stage; Obtaining improved state information of the particle swarm according to the current convergence index, the current optimization index and the current diversity index, and the historical convergence index, the historical optimization index and the historical diversity index; According to the improved state information, evolution reward information is obtained.

Citation Information

Cited By

  • Scheduling modeling and intelligent scheduling method for multi-wall parallel construction

    CN120822275A

  • A scheduling modeling and intelligent scheduling method for multi-wall parallel construction

    CN120822275B

  • Super-multi-objective optimization method and system based on dual-file coevolution and dual-distance index

    CN121980808A