A method and system for allocating unit output based on improved whale algorithm

Through the improved whale algorithm, using cubic chaotic mapping, adaptive inertial weights and dynamic spiral updates, combined with elite reverse learning, the existing algorithms' slow convergence speed and easy to fall into local optimality in unit combination optimization, and achieved Quick and accurate optimization solution.

CN112865195BActive Publication Date: 2024-12-03SHANDONG UNIV OF TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202110095538.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-01-25
Publication Date
2024-12-03
Estimated Expiration
2041-01-25

AI Technical Summary

Technical Problem

The existing heuristic algorithms, including the whale algorithm, converge at a slow speed and are easily trapped in local optimization in unit combination optimization, resulting in errors in optimization results and affecting the formulation of scheduling schemes.

Method used

Adopting the improved whale algorithm, initializes the algorithm population through cubic chaos mapping, introduces adaptive inertial weights and dynamic spiral update formulas, combines the elite reverse learning mechanism to improve the algorithm's global search ability and local optimization ability, and improves the convergence factor to enhance convergence. Speed ​​and accuracy.

Benefits of technology

It effectively improves the convergence speed and accuracy of the algorithm, and can quickly and accurately solve the unit combination optimization in high-dimensional complex problems, avoid local optimal traps, and improves the accuracy of optimization results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN112865195B_ABST
    Figure CN112865195B_ABST
Patent Text Reader

Abstract

The present invention relates to a method and system for allocating unit combination output based on an improved whale algorithm, the allocation method comprising: determining the output of a wind power unit according to predicted wind speed; determining the operating parameters of a generator set; determining the objective function and constraint conditions of a combination of wind power and thermal power units based on the output of the wind power unit and the operating parameters of the generator set, and constructing a mathematical model; solving the mathematical model using an improved whale algorithm to obtain a unit combination output allocation scheme. The above method in the present invention can improve the convergence speed and convergence accuracy to achieve rapid and accurate solution of unit combination optimization.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of whale algorithms, and in particular to a method and system for allocating unit combination output based on an improved whale algorithm. Background Art

[0002] At present, the demand for electric energy is still provided by thermal power units, which are still mainly fossil fuels. Since there are many variables involved in the unit combination, it is necessary to establish a mathematical optimization model for multiple units for the optimization of the unit combination, with the overall economic and environmental protection and the minimum sum of equipment maintenance costs as the objective function, and it is necessary to consider the output characteristics and constraints between various units. It is a non-convex, high-dimensional, nonlinear mathematical optimization problem, and is often solved by heuristic algorithms.

[0003] There are many existing heuristic algorithms, such as particle swarm algorithm (PSO), genetic algorithm (GA), etc. Existing experts have also been engaged in optimization algorithms and innovations in this field. However, the existing algorithms have the defects of slow convergence speed and easy to fall into local optimality. These shortcomings will cause certain errors in the optimization results and have an adverse impact on the formulation of scheduling plans.

[0004] The whale algorithm is a meta-heuristic algorithm proposed by Seyedali Mirjalili et al. in Australia in 2016. The existing whale optimization algorithm also has the problems of slow convergence speed and easy to fall into local optimum. Therefore, the present invention makes certain improvements to the whale optimization algorithm, so that it can achieve higher convergence speed and convergence accuracy even in high-dimensional complex problems, and is used to achieve fast and accurate solution of unit combination optimization. Summary of the invention

[0005] The purpose of the present invention is to provide a method and system for allocating unit combination output based on an improved whale algorithm, so as to improve the convergence speed and convergence accuracy and realize fast and accurate solution of unit combination optimization.

[0006] To achieve the above object, the present invention provides the following solutions:

[0007] A method for allocating unit combination output based on an improved whale algorithm, the method comprising:

[0008] Determine the output of the wind turbine according to the predicted wind speed;

[0009] Determine the operating parameters of the generator set;

[0010] Determine the objective function and constraint conditions of the combination of wind power and thermal power units based on the output of the wind power unit and the operating parameters of the generator set, and construct a mathematical model;

[0011] The improved whale algorithm is used to solve the mathematical model and obtain the unit combination output allocation plan.

[0012] Optionally, the wind turbine output is determined according to the predicted wind speed using the following formula:

[0013]

[0014] Among them, P t w represents the output of the wind turbine at time t, v ci 、v co 、v N Respectively represent the cut-in wind speed, cut-out wind speed and rated wind speed; P N Indicates rated power.

[0015] Optionally, the operating parameters of the generator set include: the operating cost coefficient a of the i-th generator set i , b i , c i , the number of types of pollutant gases emitted is M, the power of generator set i is P i,t The emission of different pollutants and the cost of treating each kg of pollutants m k ,ω k , the operation and maintenance cost of the i-th unit And the equipment maintenance cost of wind turbines

[0016] Optionally, the mathematical model is:

[0017]

[0018] Among them, F MG is the total operating cost of the unit combination after considering wind power output, C i is the operating cost function of the i-th generator, E i is the pollutant emission cost, T is the dispatch period, N is the generator set in the microgrid, Maintenance cost of the unit C i (P i,t ) is the generator output cost model E i (P i,t ) is the pollutant emission cost The equality constraint is It means that the power at each moment must be balanced with the load at that moment, and the inequality constraint is P i,min ≤P i,t ≤P i,max , P i,min , P i,max are the upper and lower limits of the processing of the i-th generator set.

[0019] Optionally, the improved whale algorithm is used to solve the mathematical model to obtain the unit combination output allocation plan, which specifically includes:

[0020] S1: Set algorithm parameters: population size N, optimization problem dimension D, inertia coefficient k, spiral update coefficient λ, w, set the maximum number of iterations Max_iter, and count the current number of iterations as iter = 1;

[0021] S2: Use cubic chaos mapping to initialize the population and randomly generate a [-1,1] individual in the search space;

[0022] S3: The generated chaotic variables are iterated D-1 times according to the following formula to generate the chaotic sequence x(t) = (x1, x2, ···, x n ), where x(t)∈[-1,1];

[0023] x(n+1)=4x(n) 3 -3x(n)

[0024] -1≤x(n)≤1, n=1,2,3…

[0025] Among them, x1,x2,···,x n represents the coordinates in n-dimensional space,

[0026] S4: After all whale individuals have been iterated, they are mapped to the original search space according to the following formula;

[0027]

[0028] Among them, X d represents the chaotic variable mapped to the solution space, u d represents the upper bound of the search space, l d represents the lower bound of the search space, x d Represents chaotic sequence

[0029] S5: Calculate the reverse solution according to the following formula, calculate the fitness value of the reverse solution and the original solution, and compare the sizes;

[0030]

[0031] in, represents the elite reverse solution, rand represents the generalization coefficient, l i represents the i-th upper bound, u i represents the ith lower bound, x id represents the original solution,

[0032] S6: If the fitness value of the reverse solution is less than the original solution, update the population, otherwise keep the population unchanged;

[0033] S7: Update ω, a, A, C, b according to the following formula

[0034]

[0035]

[0036] A=2ar-a

[0037] C=2r

[0038]

[0039] ω represents the adaptive inertia weight, a is the convergence factor, A and C represent the coefficient vectors, b represents the spiral shape parameter, a initial represents the initial value of the convergence factor a, a final represents the final value of the convergence factor a, r represents a random number between [0,1], and λ represents the spiral update coefficient.

[0040] S8: Update the parameters according to steps S4-S7 to further update the position of the whale, generate a random probability number p, if p < 0.5 and |A| ≤ 1, then according to the formula X(t+1) = ω·X * (t)-A·D executes the contraction predation strategy, where X(t+1) represents the updated whale position, ω represents the adaptive inertia weight, and X * (t) represents the current optimal whale position vector, A represents the coefficient vector, and D represents the distance between the individual and the optimal whale. If p < 0.5 and |A| ≥ 1, then according to the formula X(t+1) = ω·D'·e bl ·cos(2πl)+X * (t) Execute the search and foraging strategy, where D' represents the distance between the whale and the prey. If p>0.5, then according to the formula X(t+1)=ω·X(t) rand -A·D implements a variable spiral search strategy, where X(t) rand represents a randomly selected whale position vector;

[0041] S9: Determine whether iter reaches Max_iter. If so, the algorithm ends. Otherwise, set iter=iter+1 and return to steps S4-S6 to continue iterating.

[0042] The present invention further provides a unit combination output distribution system based on an improved whale algorithm, the system comprising:

[0043] A wind power group output determination module is used to determine the wind power group output according to the predicted wind speed;

[0044] A generator set operating parameter determination module, used to determine the operating parameters of the generator set;

[0045] A mathematical model building module, used to determine the objective function and constraint conditions of the combination of wind power and thermal power units based on the output of the wind power unit and the operating parameters of the generator set, and to build a mathematical model;

[0046] The unit combination output allocation scheme determination module is used to solve the mathematical model using an improved whale algorithm to obtain the unit combination output allocation scheme.

[0047] Optionally, the wind power group output determination module specifically adopts the following formula:

[0048]

[0049] Among them, P t w represents the output of the wind turbine at time t, v ci 、v co 、v N Respectively represent the cut-in wind speed, cut-out wind speed and rated wind speed; P N Indicates rated power.

[0050] Optionally, the operating parameters of the generator set include: the operating cost coefficient a of the i-th generator set i , b i , c i , the number of types of pollutant gases emitted is M, the power of generator set i is P i,t The emission of different pollutants and the cost of treating each kg of pollutants m k ,ω k , the operation and maintenance cost of the i-th unit And the equipment maintenance cost of wind turbines

[0051] Optionally, the mathematical model is:

[0052]

[0053] Among them, F MG is the total operating cost of the unit combination after considering wind power output, C i is the operating cost function of the i-th generator, E i is the pollutant emission cost, T is the dispatch period, N is the generator set in the microgrid, Maintenance cost of the unit C i (P i,t ) is the generator output cost model Ei (P i,t ) is the pollutant emission cost The equality constraint is It means that the power at each moment must be balanced with the load at that moment, and the inequality constraint is P i,min ≤P i,t ≤P i,max , P i,min , P i,max are the upper and lower limits of the processing of the i-th generator set.

[0054] Optionally, the unit combination output allocation scheme determination module specifically includes:

[0055] Algorithm parameter setting unit, used to set algorithm parameters: population size N, optimization problem dimension D, inertia coefficient k, spiral update coefficient λ, w, set the maximum number of iterations Max_iter, and count the current number of iterations as iter = 1;

[0056] An initialization unit is used to initialize the population using a cubic chaotic map and randomly generate a [-1,1] individual in the search space;

[0057] The chaotic sequence generating unit is used to iterate the generated chaotic variables D-1 times according to the following formula to generate the chaotic sequence x(t)=(x1,x2,···,x n ), where x(t)∈[-1,1];

[0058] x(n+1)=4x(n) 3 -3x(n)

[0059] -1≤x(n)≤1, n=1,2,3…

[0060] Among them, x1,x2,···,x n represents the coordinates in n-dimensional space,

[0061] The original search space mapping unit is used to map to the original search space according to the following formula after all whale individuals have been iterated;

[0062]

[0063] Among them, X d represents the chaotic variable mapped to the solution space, u d represents the upper bound of the solution space, l d represents the lower bound of the solution space, x d Represents chaotic sequence

[0064] The reverse solution calculation unit is used to calculate the reverse solution according to the following formula, and calculate the fitness value of the reverse solution and the original solution, and compare the sizes;

[0065]

[0066] in, represents the elite reverse solution, rand represents the generalization coefficient, l i represents the ith lower bound, u i represents the i-th upper bound, x id represents the original solution;

[0067] A comparison unit is used to update the population when the fitness value of the reverse solution is less than the original solution, otherwise the population remains unchanged;

[0068] Update unit, used to update ω, a, A, C, b according to the following formula

[0069]

[0070]

[0071] A=2ar-a

[0072] C=2r

[0073]

[0074] ω represents the adaptive inertia weight, a represents the convergence factor, A and C coefficient vectors, b represents the spiral shape parameter, a initial represents the initial value of the convergence factor a, a final represents the final value of the convergence factor a, r represents a random number between [0,1], and λ represents the spiral update coefficient.

[0075] The whale position update unit is used to further update the whale's position according to the update parameters of the original search space mapping unit-update unit, generate a random probability number p, and if p < 0.5 and |A| ≤ 1, then according to the formula X(t+1) = ω·X * (t)-A·D executes the contraction predation strategy, where X(t+1) represents the updated whale position ω represents the adaptive inertia weight, X * (t) represents the current optimal whale position vector, A represents the coefficient vector, and D represents the distance between the individual and the optimal whale. If p < 0.5 and |A| ≥ 1, then according to the formula X(t+1) = ω·D'·e bl ·cos(2πl)+X * (t) Execute the search and foraging strategy, where D' represents the distance between the whale and the prey. If p>0.5, then according to the formula X(t+1)=ω·X(t) rand -A·D implements a variable spiral search strategy, where X(t) rand represents the randomly generated whale position vector;

[0076] The judgment unit is used to judge whether iter reaches Max_iter. If it reaches Max_iter, the algorithm ends. Otherwise, iter=iter+1 is set and the original search space mapping unit-comparison unit is returned to continue iteration.

[0077] According to the specific embodiments provided by the present invention, the present invention discloses the following technical effects:

[0078] The above method in the present invention, when solving the problem of global optimal solution of the unit combination optimization problem considering wind power output, improves the quality of the initial solution by adopting the cubic chaos map initialization algorithm population, adopts the global search and local optimization of the proposed nonlinear adaptive inertia weight balance algorithm, improves the convergence factor a to make its nonlinear convergence enhance the convergence speed and local search, enhances the global search ability of the algorithm by adopting the dynamically adjusted spiral update formula, and introduces elite reverse learning to improve the ability to jump out of the local optimum. BRIEF DESCRIPTION OF THE DRAWINGS

[0079] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.

[0080] Figure 1 This is a flow chart of a method for allocating unit combination output based on an improved whale algorithm according to an embodiment of the present invention;

[0081] Figure 2 The flowchart of the improved whale algorithm according to the embodiment of the present invention is as follows;

[0082] Figure 3 It is a structural schematic diagram of a unit combination output distribution system based on an improved whale algorithm according to an embodiment of the present invention. DETAILED DESCRIPTION

[0083] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0084] The purpose of the present invention is to provide a method and system for allocating unit combination output based on an improved whale algorithm, so as to improve the convergence speed and convergence accuracy and realize fast and accurate solution of unit combination optimization.

[0085] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, the present invention is further described in detail below with reference to the accompanying drawings and specific embodiments.

[0086] Considering the optimization of 10 wind power unit combinations, the objective function mainly takes the economic and environmental performance of the unit combination as the main indicators, while considering the equipment maintenance costs of wind turbines and generator sets. The improved whale algorithm is used for solving, which can effectively improve the convergence speed and convergence accuracy of the algorithm. The objective function and the constraints are as follows:

[0087] Wind power output model

[0088]

[0089] Used to solve the wind turbine output, where P w is the output of the wind turbine, v ci 、v co 、v N Respectively represent the cut-in wind speed, cut-out wind speed and rated wind speed; P N Represents rated power.

[0090] Objective Function

[0091]

[0092] Where F MG is the total operating cost of the unit combination after considering wind power output, where C i is the operating cost function of the i-th generator, E i is the pollutant emission cost, T is the dispatch period, and N is the generator set in the microgrid.

[0093] Generator output cost model

[0094]

[0095] a i , b i , c i is the operating cost coefficient of the i-th generator set.

[0096] Pollutant emission costs

[0097]

[0098] MThe type of pollutant gas emitted, m k ,ω k The power of generator set i is P i,t The emission of different pollutants and the cost of treating each kg of pollutants.

[0099] Equipment maintenance costs

[0100]

[0101] P t w is the output value of the wind turbine at time t, is the operation and maintenance cost of the i-th unit, It is the equipment maintenance cost of wind turbines.

[0102] Equality constraints

[0103]

[0104] Inequality constraints

[0105] Unit upper and lower limit constraints

[0106] P i,min ≤P i,t ≤P i,max \*MERGEFORMAT(7)

[0107] P i,min , P i,max are the upper and lower limits of the processing of the i-th generator set.

[0108] Basic Whale Algorithm

[0109] The whale algorithm is a metaheuristic optimization algorithm that simulates the hunting behavior of humpback whales. The algorithm's search mechanism is different from other algorithms in that it uses random search or the best individual to simulate population hunting behavior. The algorithm is mainly divided into three stages: contraction and encirclement, spiral update, and search and foraging.

[0110] 1) Encirclement and predation

[0111] Since the position of the optimal design in the search space is not known a priori in the WOA algorithm, the WOA algorithm assumes that the current best candidate solution is the best individual in the population. After defining the best candidate solution, the population will move closer to the best individual according to formula (8):

[0112] X(t+1)=X * (t)-A·D\*MERGEFORMAT(8)

[0113] D=|C·X * (t)-X(t)|\*MERGEFORMAT(9)

[0114] Where t is the current iteration number, represents the position of the prey, where A and C are coefficient vectors, defined by formulas (10) and (11):

[0115] A=2ar-a\*MERGEFORMAT(10)

[0116] C=2r\*MERGEFORMAT(11)

[0117]

[0118] Where r is a random number between [0,1], a is the convergence factor that decreases linearly from 2 to 0 during the iteration process, and Max_iter represents the maximum number of iterations.

[0119] 2) Internet Bubble Attack

[0120] (1) Contraction and encirclement: This is achieved by reducing the convergence factor a in formula (12). The value of a decreases as the number of iterations increases, so that the individual whales continuously update their position coefficients to approach the prey, and then complete the encirclement.

[0121] (2) Spiral update: When searching for prey, individual whales adopt a spiral upward strategy to adjust their position relative to the prey. Its mathematical model can be expressed as:

[0122] X(t+1)=D'·e bl ·cos(2πl)+X * (t)\*MERGEFORMAT(13)

[0123] D'=|X * (t)-X(t)|\*MERGEFORMAT(14)

[0124] where D' represents the distance between the prey and the individual whale, b is a constant that defines the shape of the spiral search, and l is a random number in [-1,1].

[0125] When |A|≤1, the whale adopts the bubble net attack behavior. When executing, there is a 50% probability to choose between shrinking and surrounding and spiral updating. When p<0.5, shrinking and surrounding is performed, otherwise spiral updating is performed. The mathematical model is as follows:

[0126]

[0127] 3) Searching for food

[0128] In contrast to the shrinking and encircling phase, when |A|>1, a whale is randomly selected to find another better prey and no longer follows the reference whale to enhance the global search capability of the algorithm. Its mathematical model is as follows:

[0129] X(t+1)=X(t) rand -A·D\*MERGEFORMAT(16)

[0130] D=|C·X rand-X|\*MERGEFORMAT(17)

[0131] Where X rand is a randomly selected whale position vector.

[0132] The improved whale algorithm in the present invention is as follows:

[0133] Aiming at the problems of low convergence accuracy and easy falling into local optimum of the whale algorithm, the present invention improves the initialization phase, position update formula and convergence factor of the algorithm, and proposes a multi-strategy improved whale optimization algorithm (MSI-WOA) by introducing elite reverse learning on the basis of the above improvement ideas.

[0134] (1) Chaos initialization

[0135] The position of the initial solution in the intelligent algorithm plays a vital role in the global search and convergence of the algorithm. When the algorithm is initialized, the individual position uses pseudo-random numbers to generate the population. Although the population can be distributed in the solution space, it is difficult to avoid the problem of uneven population distribution. Therefore, chaos theory is introduced on this basis. Due to its pseudo-randomness, non-repeatability and ergodicity, the population can be evenly distributed in the entire search space. The cubic chaos map is used to initialize the population, as shown in formula (18):

[0136]

[0137] The initialization steps using chaos mapping are as follows:

[0138] The chaos initialization steps are as follows:

[0139] 1) Randomly generate a [-1,1] individual in the search space;

[0140] 2) The generated chaotic variables are iterated D-1 times according to formula (18) to generate the chaotic sequence x(t) = (x1, x2, ···, x n ), where x(t)∈[-1,1];

[0141] 3) After all whale individuals have been iterated, they are mapped to the original search space according to formula (19).

[0142]

[0143] Where u d , l d is the boundary of the search space, X d is the chaotic variable mapped to the solution space.

[0144] (2) Adaptive inertia weight

[0145] By analyzing the improved method of particle swarm algorithm, the present invention introduces adaptive inertia weight into standard WOA. Reasonable design of inertia weight improves the convergence speed and accuracy of the algorithm. The introduced adaptive inertia weight is dynamically adjusted with the number of iterations, which improves the search efficiency of the algorithm. The proposed adaptive inertia weight strategy is shown in formula (20):

[0146]

[0147] The initial value of the algorithm is large at the beginning, which has a strong global search ability. At the same time, due to its nonlinear attenuation characteristics, it converges to a higher accuracy at a faster speed in the early stage. In the later stage of the algorithm, the individual whales enter the spiral update stage. As the number of iterations increases, the nonlinearity of ω decreases. The whales continue to approach the prey, improving the local optimization ability, making the algorithm continue to approach the theoretical optimum. While balancing the global search and local optimization of the algorithm, the speed of the algorithm searching for the optimal solution is improved. The position update formula after introducing ω is as follows:

[0148] X(t+1)=ω·X * (t)-A·D\*MERGEFORMAT(21)

[0149] X(t+1)=ω·D'·e bl ·cos(2πl)+X * (t)\*MERGEFORMAT(22)

[0150] X(t+1)=ω·X(t) rand -A·D\*MERGEFORMAT(23)

[0151] Where k is the adaptive inertia coefficient, which is set to 0.2, so that it starts to decay with a smaller value, avoiding excessive decay in the early stage and causing the algorithm to fall into the local optimum. In the later stage, it enters the spiral update stage. The whale spirals closer to the prey. Using a smaller weight value can enhance the local optimization ability.

[0152] (3) Nonlinear convergence factor

[0153] The analysis of the standard whale optimization algorithm shows that the convergence factor a is crucial to the global search and local search of the algorithm. However, the standard WOA algorithm converges linearly, while the WOA search is a nonlinear optimization strategy, which makes it difficult to improve the convergence speed of the algorithm and easily falls into the local optimum during local search. Therefore, it is hoped that the algorithm has a better convergence speed under the premise of having a strong global search capability in the early stage. To this end, the present invention improves the convergence factor a after introducing ω, so that it converges nonlinearly with the number of iterations. In the early stage, it decays at a faster rate to improve the convergence speed, and in the later stage, the decay speed slows down, the amplitude change is reduced to enhance the local search, and the convergence accuracy of the algorithm is improved. The nonlinear improvement expression is shown in formula (24):

[0154]

[0155] Where a initial , a final is the initial value and final value of a, iter is the current number of iterations, and Max_iter is the maximum number of iterations.

[0156] (4) Dynamic spiral update

[0157] In the spiral update phase, individual whales update and move in a spiral manner according to the position of the prey, and adjust the position of individual whales. It can be seen from the standard WOA that the established equation is a logarithmic spiral, but the spiral shape parameter b in the standard WOA is set to a constant, which makes the whale only search according to a fixed spiral line when entering the spiral search phase, and has the defect of being easily trapped in the local optimum and unable to achieve global search. In view of the above problems, the present invention sets b to a value that changes with the number of iterations, so that the individual whale can dynamically adjust the spiral shape during the search after entering the spiral search phase, which enhances the global search ability of the algorithm and effectively improves the problem of being trapped in the local optimum. The improved b is shown in formula (25):

[0158]

[0159] Where λ is the spiral update coefficient, which is set to 10, and w = 0.5.

[0160] (5) Elite reverse learning mechanism

[0161] In order to improve the defect that WOA cannot jump out of the local optimum, an elite reverse learning mechanism is introduced on the basis of dynamic spiral update to enhance the ability of population individuals to explore the space around them, which gives the algorithm the ability to jump out of the local optimum to a certain extent.

[0162] Elite reverse learning is a feasible solution to a problem. It solves its elite reverse solution, compares the fitness values ​​of the original solution and the reverse solution, selects the better solution as the new population individual, and updates the population.

[0163] Reverse solution: x id =(x1,x2,···,x n ) is a point in n-dimensional space, x i ∈[l i ,u i ], where u i , l i is the i-th upper and lower limits, and its corresponding elite reverse solution is:

[0164]

[0165] rand is a generalized coefficient, which is a random number in the interval [0,1].

[0166] Optimization of the reverse solution: Calculate the fitness values ​​of the original solution and the reverse solution. If the problem to be optimized is a minimization problem and Then use the reverse solution Instead of the original solution x id .

[0167] Figure 1 Flow chart of a method for allocating unit combination output based on an improved whale algorithm according to an embodiment of the present invention. Figure 2 The flowchart of the improved whale algorithm according to the embodiment of the present invention is as follows: Figure 1 and Figure 2 As shown, the method includes:

[0168] Step 101: Determine the output of the wind turbine according to the predicted wind speed.

[0169] The following formula is used to determine the output of the wind turbine according to the predicted wind speed:

[0170]

[0171] Among them, P t w represents the output of the wind turbine at time t, v ci 、v co 、v N Respectively represent the cut-in wind speed, cut-out wind speed and rated wind speed; P N Indicates rated power.

[0172] Step 102: Determine the operating parameters of the generator set.

[0173] The operating parameters of the generator set include: the operating cost coefficient a of the i-th generator set i , b i , c i , the number of types of pollutant gases emitted is M, the power of generator set i is P i,t The emission of different pollutants and the cost of treating each kg of pollutants m k ,ωk , the operation and maintenance cost of the i-th unit And the equipment maintenance cost of wind turbines

[0174] Step 103: Determine the objective function and constraint conditions of the combination of wind power and thermal power units based on the output of the wind power unit and the operating parameters of the generator set, and construct a mathematical model.

[0175] The mathematical model is:

[0176]

[0177] Among them, F MG is the total operating cost of the unit combination after considering wind power output, C i is the operating cost function of the i-th generator, E i is the pollutant emission cost, T is the dispatch period, N is the generator set in the microgrid, Maintenance cost of the unit C i (P i,t ) is the generator output cost model E i (P i,t ) is the pollutant emission cost The equality constraint is It means that the power at each moment must be balanced with the load at that moment, and the inequality constraint is P i,min ≤P i,t ≤P i,max , P i,min , P i,max are the upper and lower limits of the processing of the i-th generator set.

[0178] Step 104: using the improved whale algorithm to solve the mathematical model and obtain a unit combination output allocation plan.

[0179] Specifically include:

[0180] S1: Set algorithm parameters: population size N, optimization problem dimension D, inertia coefficient k, spiral update coefficient λ, w, set the maximum number of iterations Max_iter, and count the current number of iterations as iter = 1;

[0181] S2: Use cubic chaos mapping to initialize the population and randomly generate a [-1,1] individual in the search space;

[0182] S3: The generated chaotic variables are iterated D-1 times according to the following formula to generate the chaotic sequence x(t) = (x1, x2, ···, x n ), where x(t)∈[-1,1];

[0183] x(n+1)=4x(n) 3 -3x(n)

[0184] -1≤x(n)≤1, n=1,2,3…

[0185] Among them, x1,x2,···,x n represents the coordinates in n-dimensional space,

[0186] S4: After all whale individuals have been iterated, they are mapped to the original search space according to the following formula;

[0187]

[0188] Among them, X d represents the chaotic variable mapped to the solution space, u d represents the upper bound of the solution space, l d represents the lower bound of the solution space, x d Represents chaotic sequence

[0189] S5: Calculate the reverse solution according to the following formula, calculate the fitness value of the reverse solution and the original solution, and compare the sizes;

[0190]

[0191] in, represents the elite reverse solution, rand represents the generalization coefficient, l i represents the ith lower bound, u i represents the i-th upper bound, x id represents the original solution;

[0192] S6: If the fitness value of the reverse solution is less than the original solution, update the population, otherwise keep the population unchanged;

[0193] S7: Update ω, a, A, C, b according to the following formula

[0194]

[0195]

[0196] A=2ar-a

[0197] C=2r

[0198]

[0199] ω represents the adaptive inertia weight, a represents the convergence factor, A, C represent the coefficient vector, b represents the spiral shape parameter, a initial represents the initial value of the convergence factor a, a finalrepresents the initial value and final value of a, r represents a random number between [0,1], and λ represents the spiral update coefficient.

[0200] S8: Update the parameters according to steps S4-S7 to further update the position of the whale, generate a random probability number p, if p < 0.5 and |A| ≤ 1, then according to the formula X(t+1) = ω·X * (t)-A·D executes the contraction predation strategy, where X(t+1) represents the updated whale position, ω represents the adaptive inertia weight, and X * (t) represents the current optimal whale position vector, A represents the coefficient vector, and D represents the distance between the individual and the optimal whale. If p < 0.5 and |A| ≥ 1, then according to the formula X(t+1) = ω·D'·e bl ·cos(2πl)+X * (t) Execute the search and foraging strategy, where D' represents the distance between the whale and the prey. If p>0.5, then according to the formula X(t+1)=ω·X(t) rand -A·D implements a variable spiral search strategy, where X(t) rand represents the randomly generated individual whale position vector;

[0201] S9: Determine whether iter reaches Max_iter. If so, the algorithm ends. Otherwise, set iter=iter+1 and return to steps S4-S6 to continue iterating.

[0202] Figure 3 FIG. 1 is a schematic diagram of the structure of a unit combination output allocation system based on an improved whale algorithm according to an embodiment of the present invention. Figure 3 As shown, the system comprises:

[0203] A wind power group output determination module 201 is used to determine the wind power group output according to the predicted wind speed;

[0204] The generator set operating parameter determination module 202 is used to determine the operating parameters of the generator set;

[0205] A mathematical model building module 203 is used to determine the objective function and constraint conditions of the combination of wind power and thermal power units based on the output of the wind power unit and the operating parameters of the generator set, and to build a mathematical model;

[0206] The unit combination output allocation scheme determination module 204 is used to solve the mathematical model using an improved whale algorithm to obtain a unit combination output allocation scheme.

[0207] In this specification, each embodiment is described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the embodiments can be referred to each other. For the system disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part.

[0208] The present invention uses specific examples to illustrate the principles and implementation methods of the present invention. The above examples are only used to help understand the method and core ideas of the present invention. At the same time, for those skilled in the art, according to the ideas of the present invention, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as limiting the present invention.

Claims

1. A method for allocating unit output based on an improved whale algorithm, characterized in that: The allocation method includes: Determine the output of the wind turbine according to the predicted wind speed; Determine the operating parameters of the generator set; Determine the objective function and constraint conditions of the combination of wind power and thermal power units based on the output of the wind power unit and the operating parameters of the generator set, and construct a mathematical model; The mathematical model is: Among them, F MG is the total operating cost of the unit combination after considering wind power output, C i is the operating cost function of the i-th generator, E i is the pollutant emission cost, T is the dispatch period, N is the generator set in the microgrid, is the maintenance cost of the unit, C i (P i,t ) is the generator output cost model, E i (P i,t ) is the pollutant emission cost The equality constraint is It means that the power at each moment must be balanced with the load at that moment, and the inequality constraint is P i,min ≤P i,t ≤P i,max , P i,min , P i,max are the upper and lower limits of the processing of the i-th generator set; The improved whale algorithm is used to solve the mathematical model to obtain the unit combination output allocation plan, which specifically includes: S1: Set algorithm parameters: population size N, optimization problem dimension D, inertia coefficient k, spiral update coefficient λ,w, set the maximum number of iterations Max_iter, and count the current number of iterations as iter=1; S2: Use cubic chaos mapping to initialize the population and randomly generate a [-1,1] individual in the search space; S3: The generated chaotic variables are iterated D-1 times according to the following formula to generate the chaotic sequence x(t) = (x1, x2, ..., x n ), where x(t)∈[-1,1]; x(n+1)=4x(n) 3 -3x(n) -1≤x(n)≤1, n=1,2,3… Among them, x1,x2,…,x n Represents coordinates in n-dimensional space; S4: After all whale individuals have been iterated, they are mapped to the original search space according to the following formula; Among them, X d represents the chaotic variable mapped to the solution space, u d represents the upper bound of the solution space, l d represents the lower bound of the solution space, x d represents a chaotic sequence; S5: Calculate the reverse solution according to the following formula, calculate the fitness value of the reverse solution and the original solution, and compare the sizes; in, represents the elite reverse solution, rand represents the generalization coefficient, l i represents the ith lower bound, u i represents the ith upper bound, x id represents the original solution; S6: If the fitness value of the reverse solution is less than the original solution, update the population, otherwise keep the population unchanged; S7: Update ω, a, A, C, b according to the following formula A=2ar-a C=2r ω represents the adaptive inertia weight, a represents the convergence factor, A and C coefficient vectors, b represents the spiral shape parameter, a initial represents the initial value of the convergence factor a, a final represents the final value of the convergence factor a, r represents a random number between [0,1], and λ represents the spiral update coefficient; S8: Update the parameters according to steps S4-S7 to further update the position of the whale, generate a random probability number p, if p < 0.5 and |A| ≤ 1, then according to the formula X(t+1) = ω·X * (t)-A·D executes the contraction predation strategy, where X(t+1) represents the updated whale position, ω represents the adaptive inertia weight, and X * (t) represents the current optimal whale position vector, A represents the coefficient vector, and D represents the distance between the individual and the optimal whale. If p < 0.5 and |A| ≥ 1, then according to the formula X(t+1) = ω·D'·e bl ·cos(2πl)+X * (t) Execute the search and foraging strategy, where D' represents the distance between the whale and the prey. If p>0.5, then according to the formula X(t+1)=ω·X(t) rand -A·D implements a variable spiral search strategy, where X(t) rand represents the randomly generated whale position vector; S9: Determine whether iter reaches Max_iter. If so, the algorithm ends. Otherwise, set iter=iter+1 and return to steps S4-S5 to continue iterating.

2. The unit combination output allocation method based on the improved whale algorithm according to claim 1 is characterized in that: The following formula is used to determine the output of the wind turbine according to the predicted wind speed: Among them, P t w represents the output of the wind turbine at time t, v ci 、v co 、v N Respectively represent the cut-in wind speed, cut-out wind speed and rated wind speed; P N Indicates rated power.

3. The unit combination output allocation method based on the improved whale algorithm according to claim 1 is characterized in that: The operating parameters of the generator set include: the operating cost coefficient a of the i-th generator set i , b i , c i , the number of types of pollutant gases emitted is M, the power of generator set i is P i,t The emission of different pollutants and the cost of treating each kg of pollutants m k ,ω k , the operation and maintenance cost of the i-th unit And the equipment maintenance cost of wind turbines 4. A unit combination output allocation system based on an improved whale algorithm, characterized in that: The system comprises: A wind power group output determination module is used to determine the wind power group output according to the predicted wind speed; The operating parameter determination module of the generator set is used to determine the operating parameters of the generator set; The mathematical model building module is used to determine the objective function and constraint conditions of the combination of wind power and thermal power units based on the output of the wind power unit and the operating parameters of the generator set, and to build a mathematical model; the mathematical model is: Among them, F MG is the total operating cost of the unit combination after considering wind power output, C i is the operating cost function of the i-th generator, E i is the pollutant emission cost, T is the dispatch period, N is the generator set in the microgrid, Maintenance cost of the unit C i (P i,t ) is the generator output cost model E i (P i,t ) is the pollutant emission cost The equality constraint is It means that the power at each moment must be balanced with the load at that moment, and the inequality constraint is P i,min ≤P i,t ≤P i,max , P i,min , P i,max are the upper and lower limits of the processing of the i-th generator set; The unit combination output allocation scheme determination module is used to solve the mathematical model using the improved whale algorithm to obtain the unit combination output allocation scheme; the unit combination output allocation scheme determination module specifically includes: Algorithm parameter setting unit, used to set algorithm parameters: population size N, optimization problem dimension D, inertia coefficient k, spiral update coefficient λ, w, set the maximum number of iterations Max_iter, and count the current number of iterations as iter = 1; An initialization unit is used to initialize the population using a cubic chaotic map and randomly generate a [-1,1] individual in the search space; The chaotic sequence generating unit is used to iterate the generated chaotic variables D-1 times according to the following formula to generate the chaotic sequence x(t)=(x1,x2,…,x n ), where x(t)∈[-1,1]; x(n+1)=4x(n) 3 -3x(n) -1≤x(n)≤1, n=1,2,3… Among them, x1,x2,…,x n represents the coordinates in n-dimensional space, The original search space mapping unit is used to map to the original search space according to the following formula after all whale individuals have been iterated; Among them, X d represents the chaotic variable mapped to the solution space, u d represents the upper bound of the solution space, l d represents the lower bound of the solution space, x d Represents a chaotic sequence. The reverse solution calculation unit is used to calculate the reverse solution according to the following formula, and calculate the fitness value of the reverse solution and the original solution, and compare the sizes; in, represents the elite reverse solution, rand represents the generalization coefficient, l i represents the ith lower bound, u i represents the ith upper bound, x id represents the original solution, A comparison unit is used to update the population when the fitness value of the reverse solution is less than the original solution, otherwise the population remains unchanged; Update unit, used to update ω, a, A, C, b according to the following formula A=2ar-a C=2r ω represents the adaptive inertia weight, a represents the convergence factor, A and C coefficient vectors, b represents the spiral shape parameter, a initial represents the initial value of the convergence factor a, a final represents the final value of the convergence factor a, r represents a random number between [0,1], and λ represents the spiral update coefficient; The whale position update unit is used to further update the whale's position according to the update parameters of the original search space mapping unit-update unit, generate a random probability number p, and if p < 0.5 and |A| ≤ 1, then according to the formula X(t+1) = ω·X * (t)-A·D executes the contraction predation strategy, where X(t+1) represents the updated whale position, ω represents the adaptive inertia weight, and X * (t) represents the current optimal whale position vector, A represents the coefficient vector, and D represents the distance between the individual and the optimal whale. If p < 0.5 and |A| ≥ 1, then according to the formula X(t+1) = ω·D'·e bl ·cos(2πl)+X * (t) Execute the search and foraging strategy, where D' represents the distance between the whale and the prey. If p>0.5, then according to the formula X(t+1)=ω·X(t) rand -A·D implements a variable spiral search strategy, where X(t) rand represents the randomly generated whale position vector; The judgment unit is used to judge whether iter reaches Max_iter. If it reaches Max_iter, the algorithm ends. Otherwise, iter=iter+1 is set and the original search space mapping unit-comparison unit is returned to continue iteration.

5. The unit combination output distribution system based on the improved whale algorithm according to claim 4 is characterized in that: The wind power group output determination module specifically adopts the following formula: Among them, P t w represents the output of the wind turbine at time t, v ci 、v co 、v N Respectively represent the cut-in wind speed, cut-out wind speed and rated wind speed; P N Indicates rated power.

6. The unit combination output distribution system based on the improved whale algorithm according to claim 4 is characterized in that: The operating parameters of the generator set include: the operating cost coefficient a of the i-th generator set i , b i , c i , the number of types of pollutant gases emitted is M, the power of generator set i is P it The emission of different pollutants and the cost of treating each kg of pollutants m k ,ω k , the operation and maintenance cost of the i-th unit And the equipment maintenance cost of wind turbines