Parrot optimization method
By introducing four search strategies and the normal cloud model into the parrot optimization method, combined with the alert search mechanism, the problem that the group-based meta-heuristic optimization method is prone to falling into local optimality is solved, and a more efficient global search and rapid convergence are achieved.
Patent Information
- Application Number
- CN202410778654.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-17
- Publication Date
- 2024-09-24
AI Technical Summary
Existing population-based meta-heuristic optimization methods are prone to falling into local optimal solutions when dealing with complex optimization problems, with slow convergence speed and low solution accuracy, especially in high-dimensional spaces or when there are multiple local optimal solutions.
Four search strategies are adopted: foraging, staying, communicating, and seeking advantages and avoiding disadvantages. The normal cloud model and alert search mechanism are introduced to dynamically adjust individual location updates, enhance the randomness and diversity of the algorithm, and avoid local optimality. untie.
It significantly improves the adaptability and robustness of the algorithm, quickly jumps out of the local optimal solution, improves the quality of understanding and the accuracy of optimization results, and ensures fast convergence and wide application range.
Smart Images

Figure CN118690777A
Abstract
Description
Technical Field
[0001] The invention relates to the fields of computer science and artificial intelligence technology, in particular to a parrot optimization method. Background Art
[0002] With the continuous development of the field of artificial intelligence, optimization technology has been widely used in academic research and engineering applications. Traditional optimization methods include linear programming, nonlinear programming, Newton's method, gradient descent method, etc. Although the above methods can be applied to the global optimization of specific problems, they usually require the objective function to be continuously differentiable and the feasible domain to be completely convex. However, the complex optimization problems faced by actual engineering applications are often non-differentiable, non-convex, and have multi-modal function characteristics. In this case, traditional optimization methods will be unable to cope with the task. Metaheuristic optimization methods are gradually becoming the first choice for solving large-scale complex optimization problems due to their simple concepts, easy implementation, high efficiency and robustness.
[0003] Meta-inspired intelligent optimization methods can be divided into two categories: optimization methods based on a single method and those based on a population. Among them, the population-based meta-inspired intelligent optimization methods have stronger global search capabilities and solve optimization problems by simulating the behavior and interaction of populations in nature. These methods usually include a group of individuals (also called solutions or particles) that move in the solution space and interact according to certain rules to find the optimal solution or approximate optimal solution. Population-based meta-inspired methods can search potential solution spaces more comprehensively and have stronger global search capabilities by exploring multiple solution space regions at the same time. Individuals in a population usually have certain differences. This diversity helps to enhance the robustness of the algorithm, making it more adaptable to changes and disturbances in the problem, which is more advantageous than single-based optimization methods.
[0004] However, the existing group-based meta-inspiration optimization methods still have some defects. For example, the document with application number "CN202011631340" discloses "a method for optimizing the dispatch of a multi-energy power system based on the parrot algorithm". Its technical solution is to design the parrot algorithm and introduce adaptive weights and learning factors to enhance its global learning and search capabilities. The optimization process includes a two-stage structure of exploration and development. The existing problems are: 1. Due to the use of the traditional two-stage structure of exploration and development, the development stage is usually too dependent on the candidate solutions found in the exploration stage. If the exploration stage does not find the optimal solution or only finds the local optimal solution, the algorithm will fall into the local optimal solution, and switching from the exploration stage to the development stage consumes a lot of computational costs, which will lead to slow convergence or stagnation, especially in high-dimensional space or complex problems. 2. The accuracy of the solution is easily affected by the local optimal solution. Due to the randomness of the algorithm and the uncertainty of the initial solution, the group-based meta-inspiration optimization method may fall into the local optimal solution, especially when the search space of the problem is very complex or there are multiple local optimal solutions, resulting in the accuracy of the final solution being affected by the local optimal solution.
[0005] The above problems have restricted the development of artificial intelligence and optimization technology to varying degrees. Summary of the invention
[0006] In order to solve the common defects of the prior art, such as slow convergence speed, easy to fall into local optimum, and low solution quality for complex optimization problems, the present invention proposes a parrot optimization method.
[0007] To achieve the purpose of the present invention, the technical solution provided by the present invention is as follows: a parrot optimization method, comprising the following steps:
[0008] Step 1: Initialize parameters;
[0009] Step 2: Randomly generate the position of the initialization solution;
[0010] Step 3: Start searching for the optimal solution and randomly adopt four search strategies, including: foraging search strategy, stay search strategy, communication search strategy, and benefit-seeking and harm-avoiding search strategy;
[0011] Step 4: Set up an alert search mechanism to dynamically adjust the location of subsequent solutions;
[0012] Step 5: Set the re-search evaluation criteria and compare the current number of iterations t with the maximum number of iterations Max iter ;
[0013] Step 6: If the current number of iterations t is less than the maximum number of iterations Max iter , then return to step 3 to continue searching for the optimal solution; if the current number of iterations t is less than the maximum number of iterations Maxiter , then output the location of the optimal solution.
[0014] Furthermore, in the above step 3, the specific process of the foraging search strategy is: during the foraging process, the parrots estimate the approximate location of the food by observing the location of the food or the location of the owner, and then fly to their respective estimated locations. i t+1 The update of is shown in formula (2):
[0015]
[0016] Where, X i t represents the current individual position, X best represents the optimal position obtained from the population initialization stage to the current search position, X mean t represents the average position of the current population, Levy (D) is used to describe the parrot's flight process, and t represents the current number of iterations. (X i t -X best )·Levy(dim) describes the movement of individual parrots relative to their owners. Rand(0,1)·(1-t / Max iter ) 2t / Maxiter ·X mean t Indicates where the individual parrot observes the entire population.
[0017] Furthermore, in the above step 3, the specific process of the stop search strategy is: the parrot individuals randomly fly to different parts of the owner's body and stay there for a period of time, and the subsequent individual positions X i t+1 The update of is shown in formula (4):
[0018]
[0019] In the formula, ones(1,dim) represents a vector of all 1s with dimension dim, rand(0,1)·ones(1,dim) represents the process of an individual randomly staying at a certain part of the owner's body, and X best Levy(dim) represents the process of individual parrots flying towards their owners;
[0020] The normal cloud model is introduced into the stay search strategy as a new position update strategy, and its specific process is as follows:
[0021] Generate normally distributed random numbers
[0022] En′ i=normrnd(En,He) (5)
[0023] Generate normal random numbers
[0024] x=normrnd(Ex,|En′ i |) (6)
[0025] Calculate the membership function and use it as the location X of the subsequent individual i t+1
[0026]
[0027] The expected value Ex of the cloud model is set to the current optimal parrot position X best , Entropy En=exp(t / Max iter ) is the spatial distribution, super entropy He=En / 10 -3 Represents the dispersion of the parrot flock's location distribution.
[0028] Furthermore, in the above step 3, the specific process of the communication strategy is: the parrot population generates close communication behaviors, which include flying to the population and not flying to the population. Assuming that the probability of the two behaviors is the same, and the average position of the current population is regarded as the center position of the population, the position of the subsequent individual X i t+1 The update of is shown in formula (8):
[0029]
[0030] Where, 0.2 rand(0,1) (1 – t / Max iter )·(X i t -X mean t ) represents the behavior of individuals joining the population to communicate, 0.2·rand(0,1)·exp(-t / rand(0,1)·Max iter ) indicates the behavior of individuals flying away immediately after communication.
[0031] Furthermore, in the above step 3, the specific process of the search strategy of seeking advantages and avoiding disadvantages is as follows: the parrot individuals continuously move towards the individuals in the best position during the iteration process, and at the same time move away from the individuals in the worst position. i t+1 The update of is shown in formula (9):
[0032]
[0033] In the formula, rand best with randworst is a random number between [0,1], rand best (0,1)·(X best -|X i t |) indicates the trend towards the optimal solution, while rand worst (0,1)·(X worst -|X i t |) indicates a tendency to avoid the worst position.
[0034] Furthermore, the specific process of setting the alert search mechanism in the above step 4 to dynamically adjust the position of the subsequent solution is:
[0035] When individual parrots sense danger, parrots at the edge of the group will quickly move to a safe area to ensure that their position is more advantageous; while those in the middle of the group will adopt a random movement strategy, trying to get closer to other parrots to reduce the risk of being captured. i t+1 The update of is shown in formula (10):
[0036]
[0037] In the formula, parameter β is a random number that follows a standard normal distribution and is used to control the step size, parameter K is a random number between -1 and 1. Parameter ε is a constant and is used to prevent the denominator from being 0. i Indicates the fitness value corresponding to the current parrot position, f best With f worst Represent the current global optimal and worst fitness values respectively.
[0038] Compared with the prior art, the present invention has the following beneficial effects:
[0039] (1) The present invention deviates from the two-stage structure of traditional optimization algorithms, namely exploration and exploitation. The four search strategies adopted can be randomly applied to each individual in the population, which significantly improves the randomness and diversity of individual behaviors in the population. In the stay search strategy stage, the present invention introduces the normal cloud model as a new individual position update strategy, and uses its randomness and fuzziness to further improve the adaptability and robustness of the optimization method. The combination of the normal cloud model and the Levy flight strategy makes the search strategy more extensive and flexible. When dealing with complex optimization problems, the present invention is not easy to fall into the local optimum. Even if it falls into the local optimum, it can quickly escape and continue to seek the best solution through the alert search mechanism. It can effectively improve the quality of the solution and the accuracy of the optimization results, and approach the optimal solution more simply and efficiently. It has high solution quality, fast convergence speed and a wide range of applications.
[0040] (2) In the subsequent stage of the four random search strategies, the present invention designs a search strategy that seeks benefits and avoids harm, so that individuals gradually move closer to excellent individuals and away from poor individuals during the iteration process. In each iteration, the present invention attempts to update the candidate solution set. If the newly generated solution is better than the original individual, the original individual will be replaced; otherwise, it will remain unchanged until all individuals have been traversed. This update strategy that makes full use of the optimal solution and the worst solution enables the present invention to have a stronger global optimization capability when facing continuous optimization problems.
[0041] (3) The present invention designs a vigilant search mechanism. During the optimization process, each optimal solution found so far will affect the position of subsequent solutions. This mechanism can dynamically adjust the position update strategy of subsequent individuals, so that individuals at the edge of the population can move closer to the optimal solution, thereby greatly improving the possibility of the optimization method jumping out of the local optimal solution, and having stronger global search and local development capabilities. The entire search process of the present invention will continue until the preset termination criteria are reached, and it will finally converge to the optimal solution. BRIEF DESCRIPTION OF THE DRAWINGS
[0042] Figure 1 It is an overall flow chart of a parrot optimization method of the present invention;
[0043] Figure 2 It is a comparison chart of the convergence curves of various optimization methods of the present invention on the IEEECEC2017 benchmark test set;
[0044] Figure 3 It is a regression diagram of the application example of the present invention for predicting the short-term power generation of a photovoltaic power generation system. DETAILED DESCRIPTION
[0045] The technical solution of the present invention will be fully and clearly described below in conjunction with specific embodiments to better reflect the advantages of the present invention. The described embodiments are only a part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, other embodiments obtained by ordinary technicians in this field without making creative technical premises all fall within the scope of protection of the present invention.
[0046] The design idea of the present invention is: first, after initializing the parameters, the position of the initial solution is randomly generated; second, the search for the position of the optimal solution is started and four different search strategies are randomly adopted; finally, a warning search mechanism is set to dynamically adjust the update position of subsequent solutions; if the current number of iterations is less than the maximum number of iterations, the optimizer will continue to search for the position of the optimal solution until the preset termination criteria are reached, and the position of the optimal solution so far is output.
[0047] join Figure 1The present invention provides a parrot optimization method, and its overall idea is as follows: Step S1 involves parameter initialization, setting the population size N to 300, the maximum number of iterations Maxiter to 500, and determining the upper and lower limits ub (lower limit) and lb (upper limit) of the search; in step S2, the position X of the solution is randomly generated by formula (1) i o ; Step S3 randomly selects four search strategies to update the position of the subsequent optimal solution: The foraging strategy uses formula (2) to update the position X of the subsequent individual i t+1 The stay strategy uses formula (4) to formula (7) to update the position X of the subsequent individual i t+1 , the communication strategy uses formula (8) to update the position X of the subsequent individuals i t+1 , the strategy of seeking benefits and avoiding harm uses formula (9) to update the position X of the subsequent individuals i t+1 , these four search strategies occur randomly on each individual in the population with the same probability; in step S4, a warning search mechanism is set to convert the fitness value f corresponding to the current individual position obtained in step S3 i The fitness value f corresponding to the global optimal position best Compare and update the position X of the subsequent individual according to formula (10) i t+1 In step S5, the current number of iterations t and the set maximum number of iterations Max are compared. iter In step S6, if t <Max iter , then continue to search for the location of the global optimal solution according to the search strategy in S3; if t <Max iter , the search process will terminate and output the optimal solution X found so far best The location.
[0048] The following is a more detailed description of a parrot optimization method provided by the present invention, which specifically includes the following steps:
[0049] Step 1: Initialize parameters.
[0050] Step 2: Randomly generate the location of the initialization solution. The steps include: setting the initialization population size to N, the maximum number of iterations to Max iter , the upper and lower boundaries of the search space are limited to ub (lower bound) and lb (upper bound), and the location X where the initialization solution of the i-th parrot is located is designed i o As shown in formula (1)
[0051]
[0052] In the formula, rand(0.1) represents a random number in the range of [0.1].
[0053] Step 3: Start searching for the optimal solution and randomly adopt the following four search strategies:
[0054] Foraging search strategy: When a parrot is foraging, it can estimate the approximate location of the food by observing the location of the food or the location of the owner, and then fly to the estimated location. i t+1 The update of , that is, the foraging search strategy is described as formula (2):
[0055]
[0056] Where, X i t represents the current individual position, X i t+1 represents the position of subsequent individual updates, X best represents the optimal position obtained from the population initialization stage to the current search position, that is, the location of the owner or food, X mean t represents the average position of the current population, Levy (D) is used to describe the flight process of individual parrots to simulate their random exploration in the search space, t represents the current number of iterations, (X i t -X best )·Levy(dim) describes the movement of individual parrots according to the relative position of their owners, Rand(0,1)·(1-t / Max iter ) 2t / Maxiter ·X mean t It means that individuals observe where the entire population is located to further target the direction of food.
[0057] Among them, the average position of the current population is X mean t It can be obtained from formula (3):
[0058]
[0059] Stay search strategy: The parrots randomly fly to different parts of the owner's body and stay there for a while. i t+1 The update of , that is, the stay search strategy can be described as formula (4):
[0060]
[0061] In the formula, ones(1,dim) represents a vector of all 1s with dimension dim, rand(0,1)·ones(1,dim) represents the process of an individual randomly staying at a certain part of the owner's body, and X best Levy (dim) represents the process of individual parrots flying towards their owners. With the increase of the number of iterations, the aggregation of populations will inevitably lead to a decrease in population diversity, and there is a defect that it is easy to fall into a local extreme value and cannot jump out. The present invention introduces the normal cloud model as a new position update strategy in the stay search stage, and uses the characteristics of randomness and fuzziness of the model to further enrich the diversity of the population and minimize the possibility of falling into a local optimal solution. The search strategy is carried out according to the following process:
[0062] First, generate normally distributed random numbers:
[0063] En′ i =normrnd(En,He) (5)
[0064] Next, generate normal random numbers:
[0065] x=normrnd(Ex,|En′ i |) (6)
[0066] Finally, the membership function is calculated and used as the position X of the subsequent individual i t+1 :
[0067]
[0068] The expected value Ex of the cloud model is set to the current optimal parrot individual position X best , that is, the location of the optimal solution, entropy En = exp(t / Max iter ) is the spatial distribution, which is used to adjust the distance range between the parrot population and the optimal parrot individual, and the super entropy He=En / 10 -3 It represents the discreteness of the parrot group's position distribution. By updating the entropy En value to adjust the update range of the parrot position, and updating the super entropy He value to adjust the dispersion of the parrot population, the current optimal position X best The population is densely distributed in some places and scattered in other places.
[0069] Communication search strategy: The parrot population has close communication behaviors, which include flying toward the population and not flying toward the population. Assuming that the probability of the two behaviors is the same, and the average position of the current population is regarded as the center position of the population, the position of the subsequent individual X i t+1 The update of , that is, the communication search strategy can be described as formula (8):
[0070]
[0071] Where, 0.2 rand(0,1) (1 – t / Max iter )·(X i t -X mean t ) represents the behavior of individuals joining the population to communicate, 0.2·rand(0,1)·exp(-t / rand(0,1)·Max iter ) represents the behavior of the individual flying away immediately after communication. Since these two behaviors have the same probability of occurrence and are both feasible, they can be achieved by randomly generating P values in the range of [0,1].
[0072] The search strategy of seeking benefits and avoiding harm: During the iteration process, the parrot individuals keep moving towards the individuals in the best position and away from the individuals in the worst position. The position X of the subsequent individuals i t+1 The update of , that is, the search strategy of seeking benefits and avoiding harm can be described as formula (9):
[0073]
[0074] In the formula, rand best with rand worst is a random number between [0,1]. Randomness is introduced here to prevent the algorithm from falling into the local optimum. The present invention updates the position of subsequent parrot individuals by adjusting the values of these two parameters, so that they move closer to the optimal solution position and away from the worst solution position. best (0,1)·(X best -|X i t |) indicates the trend towards the optimal solution, while rand worst (0,1)·(X worst -|X i t |) indicates the tendency to avoid the worst position. In each subsequent iteration, the search strategy will try to update the set of candidate solutions. If the generated new solution is better than the original individual, the original individual will be replaced. Otherwise, the original individual will remain unchanged until all individuals are traversed. This update strategy that makes full use of the optimal solution and the worst solution enables the present invention to have a stronger global optimization capability when facing continuous optimization problems.
[0075] Step 4: Set up a guard search strategy to dynamically adjust the location of subsequent solutions:
[0076] Parrots are always curious about the things around them, but they also remain vigilant. When parrots sense danger, those at the edge of the group will quickly move to a safe area to ensure that their position is more advantageous, while those in the middle of the group will adopt a random movement strategy and try to get close to other parrots to reduce the risk of being captured. This vigilant search mechanism can be regarded as an anti-predator behavior, that is, a defensive strategy adopted by birds to avoid being preyed on. The vigilant search strategy can be described as formula (10):
[0077]
[0078] In the formula, parameter β is a random number that follows the standard normal distribution and is used to control the step size. Parameter K is a random number between -1 and 1. Parameter ε is a constant and is used to prevent the denominator from being 0. i represents the fitness value corresponding to the current parrot individual position, f best With f worst Represent the current global optimal and worst fitness values respectively. If f i >f best , it means that the individual is already at the edge of the population and needs to move quickly to X best The safe area where it moves, if f i =f best , it means that the parrot in the middle of the population is aware of the danger and needs to move closer to other individuals to reduce the probability of being captured. The parameter K represents the direction in which the parrot moves and is also the step length control parameter.
[0079] Step 5: Set the re-search evaluation criteria and compare the current number of iterations t with the maximum number of iterations Max iter .
[0080] Step 6: Determine the current number of iterations t and the maximum number of iterations Max iter Size:
[0081] If the current number of iterations t is less than the maximum number of iterations Max iter , then return to the four search strategies described in step 3 to continue to seek the location of the optimal solution;
[0082] If the current number of iterations t is less than the maximum number of iterations Max iter , the search process will terminate and eventually converge to the location of the optimal solution found so far, and output the location of the optimal solution.
[0083] The following is a specific application example to illustrate the Parrot optimization method provided by the present invention, which is applied to the prediction results of the short-term power generation of the photovoltaic system:
[0084] Running conditions: Intel(R) Core(TM) i9-13900HX CPU running at 2.20GHz, 32GB RAM and 64-bit Window 11 operating system, all implemented using Matlab 2023a.
[0085] First, the public IEEE classic benchmark test set "CEC2017" is used to verify the performance advantages of the method of the present invention in terms of convergence speed compared with the currently available advanced or mature optimization methods. The test suite includes single-mode functions (F1), multi-mode functions (F3), combination functions (F11) and hybrid functions (F21). Secondly, in order to further verify the excellent performance of the method of the present invention, the present invention compares it with several other advanced or mature optimization methods, including Parrot Optimization Method (2024), Newton-Raphson Optimization Method (2024), Osprey Optimization Method (2023), Kepler Optimization Method (2023), Sparrow Optimization Method (2020) and JAYA Optimization Method (2015). The four benchmark functions involved in the test are all configured as 30 dimensions, each optimization method executes each benchmark function 30 times, the maximum number of iterations for each test is 500 times, and the initial population size is set to 30.
[0086] Figure 2 The convergence speed comparison of different methods on four benchmark functions is shown. Figure 2 a shows the test results of the unimodal test function, which is suitable for evaluating the performance of the optimization method because it contains only one global optimal solution; Figure 2 b shows the test results of the multimodal test function, which is suitable for testing the exploration operator of the newly developed optimization method because it contains multiple local optimal solutions; Figure 2 c and Figure 2 d shows the test results of the combination function and the hybrid test function, which are used to evaluate the ability of the optimization method to avoid local optimal solutions. Figure 2 It can be seen intuitively that the method of the present invention (OURS) shows excellent stability and fast convergence on different test functions. Thanks to the unique search strategy, the method of the present invention can effectively reduce the risk of falling into the local optimum. Even if it falls into the local optimum, it can quickly escape and continue to seek the best solution.
[0087] In order to further expand the evaluation to real-world applications, the method of the present invention is combined with the Extreme Learning Machine (ELM) to establish a prediction model for short-term photovoltaic power output power, so as to improve the prediction accuracy of the short-term output power of photovoltaic systems in the real world. Taking the real power generation data of a photovoltaic power station in a certain place in China in January 2022 as the research object, the meteorological factor input variables for photovoltaic power prediction include: temperature, azimuth, zenith angle, cloud opacity, temperature, solar radiation, atmospheric precipitation, humidity, snowfall depth, ground pressure, wind direction and wind speed, and the sampling frequency is set to 15 minutes. The preprocessed data set contains 1200 data information, which are divided into two categories, one is a training data set for building a model, and the other is a test data set for verifying the model. The test set data accounts for 0.2 of the entire data set.
[0088] This specific application example measures the accuracy of the prediction model through the following four key performance indicators:
[0089] 1. R-Square: The closer the value of R-Square is to 1, the better the model fit is and the stronger the predictive ability is.
[0090]
[0091] Where P meas,i is the actual photovoltaic power at time i, P pred,i is the predicted photovoltaic power at time i. meas is the mean of the actual photovoltaic power, and N is the number of samples.
[0092] 2. MAE (Mean Absolute Error): MAE is used to measure the accuracy of a data set. The smaller the MAE value, the higher the accuracy of the data set.
[0093]
[0094] 3. RMSE (mean square error): RMSE is used to reflect the degree of deviation between the model prediction value and the true value. The smaller the RMSE value, the smaller the deviation between the prediction value and the true value.
[0095]
[0096] 4.MAPE (Mean Absolute Percent Error): MAPE is used to measure the accuracy of model predictions. The smaller the MAPE value, the higher the prediction accuracy of the model.
[0097]
[0098] Figure 3The fitting curves and scatter plots of specific application examples in each prediction model are shown, which intuitively present the relationship between them and photovoltaic power generation. In the regression diagram of the OURS-ELM prediction model of the present invention, it is observed that the R value is closer to 1, and the predicted value and the actual value are closer to a straight line, which indicates that the prediction model has a better fitting effect on the data.
[0099] Table 1 summarizes the evaluation index results of each prediction model in the embodiment on the test set. The R-Square index of the OURS-ELM prediction model of the present invention achieved the highest numerical result, indicating that the model prediction value has the highest degree of fit with the true value and the strongest prediction ability, while the MAE, RMSE, and MAPE indicators all achieved the lowest numerical results. The deviation error between the prediction model prediction value and the true value is small, indicating that the present invention can significantly improve the accuracy of predicting the short-term power generation of the photovoltaic system.
[0100] Table 1
[0101]
[0102] The above embodiments are merely illustrative of the principles and effects of the present invention, and are not intended to limit the present invention. Anyone familiar with the technology may modify or change the above embodiments without violating the spirit and scope of the present invention. Therefore, all equivalent modifications or changes made by a person of ordinary skill in the art without departing from the spirit and technical ideas disclosed by the present invention shall still be covered by the claims of the present invention.
Claims
1. A parrot optimization method, characterized in that: The following steps are involved: Step 1: Initialize parameters; Step 2: Randomly generate the position of the initialization solution; Step 3: Start searching for the best solution and randomly adopt four search strategies, including foraging search strategy, stay search strategy, communication search strategy, and benefit-seeking and harm-avoiding search strategy; Step 4: Set up an alert search mechanism to dynamically adjust the location of subsequent solutions; Step 5: Set the re-search evaluation criteria and compare the current number of iterations t with the maximum number of iterations Max iter ; Step 6: If the current number of iterations t is less than the maximum number of iterations Max iter , then return to step 3 to continue searching for the optimal solution; if the current number of iterations t is less than the maximum number of iterations Max iter , then output the location of the optimal solution.
2. A parrot optimization method according to claim 1, characterized in that: In step 3, the specific process of the foraging search strategy is as follows: during the foraging process, the parrots estimate the approximate location of the food by observing the location of the food or the location of the owner, and then fly to their respective estimated locations. The update of is shown in formula (2): In the formula, represents the current individual position, X best represents the optimal position obtained from the population initialization stage to the current search position, X mean t represents the average position of the current population, Levy (D) is used to describe the flight process of the parrot, t represents the current number of iterations, Describes the movement of individual parrots according to the relative position of their owners, Rand(0,1)·(1-t / Max iter ) 2t / Maxiter ·X mean t Indicates where the individual parrot observes the entire population.
3. A parrot optimization method according to claim 1, characterized in that: In step 3, the specific process of the stop search strategy is: the parrot individuals randomly fly to different parts of the owner's body and stay there for a period of time. The update of is shown in formula (4): In the formula, ones(1,dim) represents a vector of all 1s with dimension dim, rand(0,1)·ones(1,dim) represents the process of an individual randomly staying at a certain part of the owner's body, and X best Levy(dim) represents the process of individual parrots flying towards their owners; The normal cloud model is introduced into the stay search strategy as a new position update strategy, and its specific process is as follows: Generate normally distributed random numbers, as shown in formula (5) In' i =normrnd(En,He) (5) Generate normal random numbers, as shown in formula (6) x=normrnd(Ex,|En′ i |) (6) Calculate the membership function and use it as the location of subsequent individuals As shown in formula (7) The expected value Ex of the cloud model is set to the current optimal parrot position X best , Entropy En=exp(t / Max iter ) is the spatial distribution, super entropy He=En / 10 -3 Represents the dispersion of the parrot flock's location distribution.
4. A parrot optimization method according to claim 1, characterized in that: In step 3, the specific process of the communication strategy is as follows: close communication behaviors are generated within the parrot population, including flying toward the population and not flying toward the population. Assuming that the probability of the two behaviors is the same, and the average position of the current population is regarded as the center position of the population, the position of the subsequent individuals is The update of is shown in formula (8): In the formula, represents the behavior of individuals joining the population to communicate, 0.2·rand(0,1)·exp(-t / rand(0,1)·Max iter ) indicates the behavior of individuals flying away immediately after communication.
5. A parrot optimization method according to claim 1, characterized in that: In step 3, the specific process of the search strategy of seeking benefits and avoiding harm is as follows: the parrot individuals continuously move towards the individuals in the best position during the iteration process, while moving away from the individuals in the worst position. The update of is shown in formula (9): In the formula, rand best with rand worst is a random number between [0,1], indicates the trend of approaching the optimal solution position, and Indicates a tendency to avoid the worst positions.
6. A parrot optimization method according to any one of claims 2 to 5, characterized in that: In step 4, the specific process of setting the alert search mechanism to dynamically adjust the position of the subsequent solution is as follows: when the individual parrots perceive danger, the parrots at the edge of the population will quickly move to a safe area to ensure that their position is more advantageous, while those in the middle of the population will adopt a random movement strategy and try to get closer to other parrots to reduce the risk of being captured. The update of is shown in formula (10): In the formula, parameter β is a random number that follows a standard normal distribution and is used to control the step size, parameter K is a random number between -1 and 1. Parameter ε is a constant and is used to prevent the denominator from being 0. i Indicates the fitness value corresponding to the current parrot position, f best With f worst Represent the current global optimal and worst fitness values respectively.
Citation Information
Cited By
Intelligent data interaction processing system
CN119420577A
A data intelligent interactive processing system
CN119420577B
Motor parameter identification method and device and storage medium
CN119853523A
Method, device and storage medium for identifying motor parameters
CN119853523B
Active power distribution network energy storage optimization configuration method and system based on improved parrot algorithm
CN120222436A
