Capacity Configuration Method of Hybrid Energy Storage Participating in AGC Based on Improved Meta-Model Optimization Algorithm

To improve the performance and economy of the hybrid energy storage system (HESS) coordinating thermal generators to participate in automatic generation control (AGC), a HESS bi-layer capacity configuration model that considers the control strategy and net benefits of HESS is proposed. In addition, an improved mode-pursuing sampling (MPS) optimization algorithm based on meta-model is presented to improve the accuracy of model solving. In the lower layer, to improve the performance of HESS participating in AGC, a model predictive control (MPC) strategy is presented to distribute HESS power reasonably. Based on this, the upper layer develops a life-cycle net benefit model of HESS participating in AGC to improve its economy. The bi-layer model realizes iterative optimization of HESS capacity and operation through parameter transmission. Furthermore, to improve the solution accuracy of the bi-layer model, the convergence speed of the MPS algorithm is improved, so that the global search and local convergence speed can be taken into account. The case study results show that the bi-layer model can comprehensively consider the interaction between the economy and operating strategy of HESS. The proposed MPC strategy has better frequency regulation performance and the improved MPS algorithm has better solution performance.


INTRODUCTION
Presently, with the increase of renewables penetration, the adjustment of automatic generation control (AGC) commands is more intense (Akram et al., 2020;Ashouri-Zadeh et al., 2020;Bevrani et al., 2021;Liu et al., 2021). However, the power response performance of traditional thermal generators is poor and it is difficult to meet the frequency regulation requirements of power systems with high penetration of renewable energy (Bryant et al., 2021), (Zhang et al., 2021). Generally, a hybrid energy storage system (HESS) is composed of power-type energy storage with small energy and energy-type energy storage with slow power response. It has the advantages of power and energy response of various types of energy storage systems (ESS) and has better economy (Joshi et al., 2021), (Luo et al., 2021). Coordinating the power of thermal generators through the HESS is an effective way to improve the AGC performance of generators, which has a good engineering application prospect. It can not only improve the power response performance of thermal generators, but also increase the income of ancillary service (He et al., 2021). However, the capacity configuration cost and performance of HESS are contradictory. Meanwhile, the control strategy of HESS is the key to improving the AGC performance. Therefore, to improve the performance and economy of HESS, the capacity configuration and control strategy of HESS are key issues for HESS participating in AGC.
Researchers have been paying attention to the related fields of ESS involved in frequency regulation. Relevant references have studied the features of AGC commands and developed AGC models, which provide a basis for further control and scheduling of AGC participants (Qiu et al., 2021)- (Donadee and Wang, 2014). In (Qiu et al., 2021), stochastic differential equations were used to model the uncertainty of AGC commands, which can be used for AGC optimal scheduling or other issues. In (Zhang et al., 2019), an AGC dynamics-constrained economic dispatch model was proposed to provide a more reliable and economical regulation reserve schedule. It can be applied to short-term prediction or as a benchmark based on historical data.
The control strategy of HESS is one of the key issues in its participation in AGC. The key issue to the HESS control strategy is to improve the AGC performance of the "HESS-generator" system, avoid the energy limitation of HESS, and prolong its lifetime. Most existing studies are based on ESS as an independent AGC participant, directly scheduled by the AGC controller (Yang et al., 2022)- (Cheng et al., 2014). In (Yang et al., 2022), to complete the frequency regulation service of battery energy storage (BES) and effectively manage its state of charge (SOC), a BES multi-state control strategy was proposed, which considered the interdependency between frequency regulation performance, SOC, and lifetime of the BES. In (Xiong et al., 2020), to improve the consistency of each ESS participating in AGC, a discrete prescribed time consensus control strategy was proposed and an event triggered communication protocol was presented to reduce the information interaction between ESSs. In (Mégel et al., 2018), to improve the dynamic performance of distributed batteries when following AGC commands, a distributed battery energy management method considering storage efficiency was proposed. However, it is also an effective approach for ESS to participate in AGC by aiding generators to respond to AGC commands (Xie et al., 2018)- (He et al., 2022). Compared with ESS as an independent AGC participant, this approach has many advantages, such as, easier system update, will not affect existing controls, and the capacity configuration is smaller. For example, based on this approach, (Xie et al., 2018) proposed a method for BES to participate in frequency regulation to improve the AGC performance of thermal generators. In (Doenges et al., 2020), a BES control strategy was proposed to improve AGC performance by minimizing the rate of noncompliance with the corresponding dynamic performance criteria. At present, there are few studies on ESS coordinated generators and how they respond to AGC commands and most of them are based on a single BES and there are even fewer studies on capacity configuration and control strategies based on HESS.
Although HESS has advantages in power response, participation in AGC may have a great impact on its lifetime, resulting in high frequency regulation costs. To improve the economy of HESS participating in AGC, optimizing its capacity configuration is another key issue (Chen et al., 2016), (Wang et al., 2022). (Chen et al., 2016) studied the BES capacity configuration through a series of system-level performance tests with different BES penetration rates. Furthermore, the response effect of BES under different interference levels was analyzed. (Wang et al., 2022) considered the interaction between the battery degradation and the market clearing process and a bilevel optimization model was proposed to optimize the economics of ESS participating in frequency regulation services. Since the operating strategy and capacity configuration of HESS are related to each other, it is necessary to jointly optimize them to improve the performance of HESS. However, there is little research on it at present.
In this paper, considering the interaction between the economy and operation strategy of HESS, an HESS bi-layer capacity configuration method is proposed for HESS to coordinate thermal generators to participate in AGC. First of all, a bi-layer optimization model of HESS is formulated. In the lower layer, to improve the AGC performance of HESS participating in AGC, an MPC strategy is presented to distribute HESS power. Based on this, the upper layer develops a HESS net benefit model to optimize the economy of HESS. The bi-layer model implements the iterative optimization of HESS capacity and operation through parameter transmission. Furthermore, to improve the solution accuracy of the bi-layer optimization model, an improved MPS algorithm based on the meta-model is presented. Simulation results based on historical data show that the proposed HESS bi-layer capacity configuration method is effective in both the economy and operation control. The main contributions of this paper are summarized as follows: 1) A bi-layer capacity configuration model of HESS is presented to jointly optimize the economy and control strategy of HESS. 2) A model predictive control strategy of HESS is presented to improve the performance of HESS participating in AGC. 3) A MPS algorithm with improved convergence speed is presented, which take into account both the global search and the local convergence speed.
The rest of this paper is organized as follows: Section 2 introduces the overview of the bi-layer capacity configuration method, Section 3 introduces the presented MPC strategy in the lower layer, HESS net benefit model in the upper layer is presented in Section 4, the improved MPS algorithm is discussed in Section 5, Section 6 presents the case study results, and finally, conclusions are presented in Section 7.

OVERVIEW OF HYBRID ENERGY STORAGE SYSTEM BI-LAYER CAPACITY CONFIGURATION METHOD
In this paper, HESS is composed of flywheel energy storage (FES) and lithium-ion batteries (LiB). Figure 1 presents the approach of HESS-aided AGC and the proposed bi-layer capacity configuration method. In this approach, HESS is not directly controlled by the AGC controller but coordinates the generator to improve its AGC performance.
At present, the AGC performance evaluation of the State Grid in North China implements the "Two Detailed Rules," which is formulated by the North China Power Regulatory Bureau (North China Power Regulat, 2019). In the "Two Detailed Rules," the AGC performance index K p is the comprehensive performance of the three indexes of regulation rate K 1 , regulation accuracy K 2 , and response rate K 3 , which respectively represent the performance of different stages in an AGC cycle. The performance index K p of the ith adjustment K i p is calculated as follows.
According to the "Two Detailed Rules," the performance index K p can be better improved only by comprehensively improving the performance of the three indexes, rather than one or two indexes. However, in an AGC cycle, due to the energy limitation of FES, it is difficult to completely compensate the power difference between the generator and the AGC command. Therefore, a reasonable distribution of HESS power is the key to improving its performance. Based on the prediction model of the controlled object, MPC can minimize the impact of possible future operating conditions by solving an optimal cost function. The goal of HESS power distribution is consistent with the features of the MPC strategy. Therefore, it is feasible to implement the MPC strategy to realize the optimal control of HESS.
Another goal of HESS participating in AGC is to increase the income of frequency regulation services. The economic benefits of HESS include its cost and the increased frequency regulation income due to the implementation of HESS. Therefore, in this paper, the upper layer optimization model is formulated based on the annualized net benefits of HESS in the project operating time.
In addition, because the bi-layer model is computationally intensive and nonlinear, the solution requires a large amount of computational consumption. Although the solution efficiency of the MPS algorithm based on the meta-model is high (Xiao et al., 2018), , it has the problem of aggressive convergence evaluation, which is easy to fall into a local optimum before generating enough exploratory points (Wang et al., 2004). Therefore, in this paper, the convergence evaluation index is modified and the convergence speed is dynamically adjusted, so that the improved MPS algorithm can take into account the global search and local convergence speed. All of these efforts are to improve the accuracy and efficiency of solving the bi-layer model.

MODEL PREDICTIVE CONTROL STRATEGY OF HYBRID ENERGY STORAGE SYSTEM IN LOWER LAYER
In this paper, the HESS compensates the power difference between AGC commands and the power output of thermal generators. Its control objective is to reasonably distribute the HESS power to coordinate thermal generators, so as to improve AGC performance, prolong the lifetime of LiB, and improve economy.

System Model of Hybrid Energy Storage System-Aided Automatic Generation Control
Assuming that the power demand of HESS at time k is P d (k), then Where P bat (k) and P fl (k) are the power of LiB and FES at time k, respectively, and P dif is the power difference between the AGC command and the "HESS-generator" system. The SOC of LiB and FES at k + 1 can be determined as follows: Where SOC bat and SOC fl are the SOC of LiB and FES respectively, and Δt is the control cycle of the system. P bat and E bat are the power capacity, and energy capacity of LiB, respectively, and P fl and E fl are the power capacity and energy capacity of FES, respectively. According to (2-4), the SOC of HESS is used as a state vector and an output vector, such that The LiB power and the power difference after compensation are used as a control vector, such that u (k) = [P bat (k) P dif (k)] T . The power demand of HESS is the disturbance, such that w (k) = P d (k), which can be obtained according to the rated ramp rate of the generator. Therefore, the system state-space model can be formulated as follows:

Model Predictive Control Strategy for Hybrid Energy Storage System
It is a multi-objective optimization problem for HESS-aided AGC. The goal is to improve the AGC performance of the generator, reduce the power fluctuation of LiB and the compensated power difference, and keep the SOC of HESS within a reasonable range. In summary, according to the principle of MPC strategy, the cost function is formulated as follows: Where N p is the prediction horizon. y (k + i) and u (k + i) are the output vector and control vector of the ith prediction step at k, respectively, y ref is the reference of the output vector. Q and R are the weight coefficient matrix of the cost function, respectively. Q, R, and y ref are as follows: Where Q soc bat , Q soc fl , R p bat , and R p dif are all greater than zero. The four weight coefficients in the cost function will influence different objectives and even contradict each other in different scenarios. The larger the Q soc bat , the smaller the SOC change of LiB, so the degradation of LiB can be reduced to prolong its lifetime. Similarly, Q soc fl affects the SOC change of FES. The larger the weight coefficient R p bat , the smaller the SOC change of LiB. Similarly, the larger R p dif is, the output of "HESS-generator" is as close to the power demand P d as possible. Therefore, when implementing the presented MPC strategy, it is necessary to adjust them reasonably according to the performance.
To implement the presented MPC strategy, the state vector and control vector of the system must meet certain constraints.
s.t. 1) SOC constraints. In every prediction step, the state of the system must meet the SOC constraints of HESS, such that Where SOC min bat and SOC max bat are the minimum and maximum SOC constraints of LiB, respectively. SOC min fl and SOC max fl are the minimum and maximum SOC constraints of FES, respectively.
2) Power constraints. In every prediction step, the state of the system must meet the power constraints of HESS, such that Where P max bat and P max fl are the maximum power constraints of LiB and FES, respectively.
3) System model constraints. To avoid the power circulation inside the HESS and reduce the unnecessary charging/ discharging, P d , P bat , P fl , and P dif , should be the same positive or negative values, such that The optimization problem of Equations 6-10 can be transformed into a standard quadratic programming (QP) problem to obtain the control vector u i . The specific transformation process can be found in the Supplementary Material. Since the proposed MPC strategy of HESS is implemented through a computer, it can be easily applied to real-time control. Once the control vector u i is obtained, the control vector u 0 is used as the power output of the HESS to compensate the generator. In addition, based on the presented MPC strategy, 1-day historical power response data of a thermal generator is used to implement HESS-aided AGC. Once the compensation results are obtained, the operating parameters of the lower layer can be obtained, which are the lifetime of LiB T lt and the 1-day AGC performance index K p day , respectively. The T lt can be obtained from the SOC change of LiB in 1 day by the rain flow counting method (Li et al., 2015), and the K p day can be obtained from the compensation results based on the "Two Detailed Rules."

ECONOMIC OPTIMIZATION MODEL OF HYBRID ENERGY STORAGE SYSTEM IN UPPER LAYER
Increasing the income of frequency regulation services is one of the goals of HESS participating in AGC. The economy of HESS includes the cost of HESS and the increased frequency regulation income due to the implement of HESS. Therefore, the upper layer takes the maximum annualized net benefits of HESS as the optimization goal. The cost function is formulated as follows: Where C ben is the annualized net benefit of HESS participating in AGC, C inc is the annual frequency regulation income of HESS, and C cos t is the annualized cost of HESS.

Annual Frequency Regulation Income of Hybrid Energy Storage System C inc
According to the "Two Detailed Rules", the annual income of the "HESS-generator" system G AGC when configuring HESS is as follows: Where K i p day is the K p value on the ith day, Y AGC is the payment standard for generators participating in AGC, and Y hour is the payment standard for the available time of generators, both of which are formulated by the local regulatory agency. η is the proportion of the daily operation time of generators, and D i day is the daily regulation depth of the generator on the ith day.
Similarly, the annual income of frequency regulation services without HESS can be calculated as follows: Where K ′ i p day and D ′ i day are the daily K p value and daily regulation depth of the generator without HESS, respectively.
The daily regulation depth is the sum of the power adjustments of the "HESS-generator" system in response to AGC commands in 1 day, which can be obtained as follows When the power output of the system reaches the jth AGC command, P j in (14) is equal to the jth AGC command. When not reached, P j is the power output of the system when the (j + 1)-th AGC command is received.
In summary, the annual frequency regulation income of HESS is as follows:

Annualized Cost of Hybrid Energy Storage System C cost
The annualized cost of HESS is the sum of annualized capital cost, annual replacement cost, and annual maintenance cost. The annualized capital cost of HESS is as follows: Where c pb and c eb are the unit power cost and unit energy cost of LiB, respectively, c pf and c ef are the unit power cost and unit energy cost of FES, respectively. P bat and E bat are the power and energy of LiB, respectively. P fl and E fl are the power and energy of FES, respectively. γ is the interest rate. T rt is the operation time of the "HESS-generator" project. The replacement cost of HESS within the project operation time is as follows: Where n bat is times of LiB replacement in T rt , which can be obtained according to the lifetime of the LiB T lt , the calculation is as follows: Where the ceil (x) function refers to the smallest integer greater than or equal to x, since the lifetime of FES generally exceeds 20 years, the replacement cost of FES is not considered.
The maintenance cost of HESS is as follows: Where c pm_bat and c pm_fl are the annual maintenance cost of LiB and FES per unit capacity, respectively. To meet the optimal power distribution in the lower layer, the capacity configuration of HESS in the upper layer needs to meet certain minimum power capacity and energy capacity constraints.
s.t. 1) The power capacity and energy capacity limits of HESS should be reasonably set according to the actual operating conditions.
Where P max bat , E max bat , P max fl and E max fl are the maximum power capacity and energy capacity limits of LiB and FES according to the actual operating conditions, respectively.
2) To improve the economy of HESS, according to Equation 2, the sum of the power capacity of P bat and P fl should be less than the maximum HESS power demand, which can be obtained according to the historical data of AGC commands and generators, such that Where P max d is the maximum HESS power demand in the historical data.
The optimization variables of the upper-layer cost function are the capacity parameters of HESS P bat , E bat , P fl , and E fl . When the upper layer is optimized to obtain a set of HESS capacity, the lower layer is called to realize the optimal control of HESS. Then, the optimal results of the lower layer are updated and returned to the upper layer to repeat the upper-layer optimization, so as to realize iterative optimization.

IMPROVED MODEL PREDICTIVE CONTROL ALGORITHM
In the bi-layer optimization model, the lower layer is a QP optimization problem. Although it is easy to solve, in this paper, to obtain the control results of HESS in 1 day, it will lead to a large amount of calculation consumption. As a result, when solving the outer layer, traditional heuristic optimization algorithms [such as particle swarm optimization (PSO)] need a large number of calls to the lower-layer model, resulting in reduced calculation accuracy or low efficiency. The key of meta model-based optimization algorithm is to formulate a meta model to replace the original complex model for calculation. It can effectively reduce expensive calculation times and improve solution efficiency.
In this paper, the MPS algorithm based on meta-model is adopted, which is effective in solving computation-intensive black box optimization problems. The MPS algorithm uses multi-correlation coefficient R 2 to evaluate the global convergence and control the convergence speed. However, the author also pointed out that it is risky (Wang et al., 2004) because the index R 2 may be aggressive for convergence speed control and the optimization process may converge to a local optimum before generating enough exploratory points. Therefore, an improvement of convergence speed control factor is implemented to address this issue in this paper.
The modification of the convergence speed control factor in MPS is divided into two parts, which are the modification of the multi-correlation coefficient R 2 and the modification of the convergence speed factor based on modified R 2 .

Modification of Multi-Correlation Coefficient R 2
In the process of formulating the response surface model (RSM) in the MPS algorithm, the accuracy evaluation index of RSM R 2 ∈ (0, 1). The more R 2 tends to 1, the higher the fitting accuracy of the RSM model. However, an increase in the number of variables tends to increase R 2 , but this does not mean that the RSM model has been well fitted. That is, R 2 approaching 1 does not necessarily mean a better fit, but it is also related to the number of variables. Therefore, the global convergence based on R 2 evaluation index may cause the optimization process to converge prematurely before generating enough exploratory points, thus falling into a local optimal solution. Therefore, to be able to consider the influence of the number of variables, the evaluation index R 2 can be modified as follows: Where R 2 adj is the modified accuracy evaluation index of RSM, n s is the sample size, and n t is the number of variables.
In (23), the quadratic form of n t is introduced to correct the multi-correlation coefficient R 2 . The corrected R 2 dynamically decreases with the increase of the number of the sample size, so as to increase more exploration points and avoid premature convergence to a local optimum.

Modification of the Convergence Speed Control Factor
The function of the convergence speed control factor is to dynamically adjust the range of the search region according to the accuracy of the RSM model. The increase of R 2 means the increase of the fitting accuracy of the RSM model, so the speed control factor r will increase to generate more sample points in the current region, thereby accelerating the convergence process. On the contrary, if R 2 decreases, r will tend to 1, thereby expanding the sampling region to search for the global optimum. Based on the above analysis, the Sigmoid function has strong nonlinearity and its curve features are consistent with the dynamic change requirements of r. Therefore, based on the Sigmoid function, the r can be modified as follows: Where r max is the maximum value of r adj , which can be set as an empirical value through the MPS algorithm, α is an adjustment coefficient, which can be adjusted according to r max . The nonlinear characteristic of the curve in (24) is shown in Figure 2.
According to the above two step modification, the "greediness" of the convergence speed control factor is dynamically adjusted, so as to avoid the problems of premature convergence to a local Frontiers in Energy Research | www.frontiersin.org March 2022 | Volume 10 | Article 828913 6 optimum and slow convergence when finally converging to the local optimum region.
The flow diagram of the proposed bi-layer capacity configuration method is shown in Figure 3. The bi-layer model realizes mutual iterative optimization through parameter transmission. When the lower-layer LiB lifetime T lt and AGC performance index K p day are obtained, the upper layer optimizes the capacity configuration of HESS. When the HESS capacity configuration of the upper layer is obtained, the lower layer optimizes the power distribution of the HESS. The final optimization results meet both the optimal capacity configuration and optimal HESS control.

CASE STUDY
To verify the effectiveness of the proposed bi-layer capacity configuration method, in this section, the historical data of a thermal generator with poor AGC performance is used for simulation analysis. The rated power P rate of the generator is 330 MW, located in North China. The control period Δt of the generator is 3 s, the data sampling period is 1 s, and the generator FIGURE 2 | Characteristic diagram of speed control factor r adj (α = 5). participates in AGC throughout the day. The historical power curves of thermal generators in response to AGC commands and the capacity configuration analysis of HESS are presented in Supplementary Material. The proposed models and algorithm were validated based on MATLAB, and the parameter settings (Zhang et al., 2020), (Han et al., 2014) are shown in Table 1. Table 2 shows the HESS capacity results obtained using the bilayer capacity configuration method. Figure 4 shows the partial results of the lower-layer optimization control under the optimal capacity, where Figure 4A shows the HESS compensation results, Figure 4B shows the power distribution of HESS, and Figure 4C shows the SOC change of HESS in 1 day.

Optimization Results of the Bi-Layer Model
According to Figure 4B and Figure 4C, although the AGC command fluctuates constantly, its average change is close to zero. The HESS compensates for the power difference between AGC commands and the generator. Its power output is continuously charged and discharged with the change of AGC commands, so the energy requirement of HESS is not high. This   feature also determines that a power-type ESS with a longer cycle life can be used for compensation, so as to improve its economy.
According to the results in Figure 4 and Table 2, compared with the AGC performance compensated by the generator alone, the K p is increased by 114% when HESS is configured using the proposed method. Meanwhile, the annual frequency regulation income of "HESS-generator" system is increased by 78.8%. Both the AGC performance and frequency regulation income are significantly improved. In addition, the annual net benefit of HESS is US$ 948,000.

Performance Comparison of Different Control Strategies
To verify the effectiveness of the presented MPC strategy, under the optimal capacity configuration of HESS in Section 6.1, two other control strategies are used for power compensation. 1) RULE: common rule-based strategy (Xie et al., 2018), (Zhang et al., 2020) is used for comparison. 2) PMPC: MPC strategy based on prescient information is used for comparison. It is assumed that the power demand of HESS can be obtained in advance and participate in the control. It is an ideal case and is usually used as a benchmark for comparing the limits of the MPC strategy. 3) No HESS: the power response is completely dependent on generators without configuring HESS. Table 3 shows the results of the AGC performance index K p within 1 day under different strategies. Figure 5 shows the comparison of compensation results between the MPC strategy and other strategies.
The performance index K p under different strategies is significantly higher than that without HESS configuration. Under the optimal capacity, the K p of the presented MPC strategy is 5.7% higher than that of the rule-based strategy. This is because in the "Two Detailed Rules", the AGC performance index K p is a comprehensive evaluation of different stages of an AGC cycle. However, the RULE strategy requires that the difference between AGC commands and the generator power be fully compensated as much as possible. The compensation performance of the RULE strategy strongly depends on the energy capacity of HESS, especially the energy of FES. As a result, the RULE strategy uses most of the energy of FES to compensate for the initial stage of the AGC command but it does little to improve the performance of K 3 . However, in the later stage of K 1 stage and K 2 stage, due to the energy limitation of FES, it is difficult to continue compensation, or even withdraw the compensation suddenly, resulting in secondary disturbance. It will affect the overall performance of K p . In contrast, the MPC strategy solves this problem better. For example, in the multiple AGC cycles from 1,600 s to 1,800 s in Figure 5A, the power compensated by HESS under the RULE strategy fluctuates significantly in the K 2 stage, which leads to a decrease in K 2 and thus affects K p . However, under the MPC strategy, the fluctuation of the compensated power in K 2 stage is smaller. Based on the future power demand of HESS, the decision of MPC strategy considers the system state of N p cycles in the future. Therefore, MPC can optimize the power output of the HESS at the current time according to the control target to prolong the compensation time, so as to improve the performance of K 1 and K 2 stages.
Since the actual power response of the generator may not operate completely at the rated ramp rate, the MPC strategy was compared with the ideal PMPC strategy. The K p performance under the MPC strategy is only 3.0% lower than that of the PMPC strategy. The PMPC strategy uses the actual historical power data of the generator to replace the rated ramp rate. Under the same parameters, its power output is the ideal result of the MPC strategy. Compared with PMPC strategy, MPC has lower K 2 and higher K 1 . This means that MPC consumes more energy in the K 1 stage, which leads to a decrease in the performance of the K 2 stage. This is consistent with the analysis of the HESS compensation process in Section 2 and at the same time verifies the effectiveness of the presented MPC strategy.

Influence of Different Control Strategies on Capacity Configuration
To analyze the interaction between the bi-layer models and their influence on the performance of HESS participating in AGC, different strategies were used to configure the capacity of HESS.
The results are shown in Table 4. As shown in Table 4, under different control strategies, the results of HESS capacity and economy are significantly different. The optimal result of the annual net benefit of HESS under the MPC strategy is 15.1% higher than that under the RULE strategy. According to the HESS capacity configuration results, compared with the MPC strategy, the LiB capacity under the RULE strategy is larger and FES capacity is smaller. This means that due to the high capital cost of FES, it is more economical to configure higher LiB capacity under the RULE strategy. In addition, because the RULE strategy needs to fully compensate the power difference, it has higher requirements for the capacity of HESS, which affects its economy.
The optimal result of the annual net benefit of HESS under the MPC strategy is 16.8% lower than that under the PMPC strategy. The main reason for the higher economy of HESS under the PMPC strategy is that the power distribution of HESS is more reasonable, which can obtain better performance benefits. Meanwhile, under the PMPC strategy, the optimal capacity of HESS increases the LiB energy capacity and the FES capacity. As a result, the lifetime of LiB T lt under the PMPC strategy is 10.8 years, while that under the MPC strategy is 5.6 years. The increase in HESS capacity further increases K p and reduces the replacement cost of HESS, thereby increasing the net benefit of HESS. The results verify that the proposed bi-layer model can comprehensively take into account the influence of HESS operation control and economic benefits.
Furthermore, the influence of the key operating parameters of the lower layer on the economy of HESS is analyzed in this paper. Figure 6 shows the variations in the annual net benefit of HESS under different parameters, which are the proportion of the daily operation time of HESS η and payment standard Y AGC . It can be seen from Figure 6 that under different operating parameters, the annual net benefit of HESS presents nonlinear changes. With the increase of η and Y AGC , the annual net benefit of HESS increases faster. Compared with η, the annual net benefit of HESS is more sensitive to the change of Y AGC .

Results of Different Optimization Algorithms
To verify the effectiveness of the improved MPS optimization algorithm, the PSO algorithm and standard MPS algorithm were used to solve the bi-layer model. The parameters of the PSO algorithm are set to the default value, such that the particle swarm size is 20, the minimum inertia weight is 0.4, the maximum inertia weight is 0.8, and the learning factor is 1.5. The number of iterations of all algorithms is set to 50, and all algorithms are calculated five times. Table 5 shows the optimization results of different optimization algorithms. Figure 7 shows the comparison of five calculation results of different algorithms. (Since the solution time of the PSO algorithm is almost fixed, it is not shown in the figure).
According to Table 5, the improved MPS algorithm has a higher annual net benefit, which is $22,000 and $61,000 higher than that under the standard MPS and PSO, respectively. According to Figure 7, the improved MPS algorithm improves the accuracy and robustness of the model solution. At the same time, the average solution time of the improved MPS is only 1/6 of that of the PSO algorithm and is slightly slower than that of the standard MPS algorithm.
In this paper, the convergence speed of the MPS algorithm is improved. By modifying the global convergence evaluation index and using a nonlinear curve as the speed control factor, the improved MPS dynamically adjusts the convergence region to avoid premature convergence to a local optimal region. The improved MPS algorithm only calls the lower-layer model 168 times for evaluation but it can obtain higher solution accuracy. This is because the improved MPS algorithm is more efficient in global sampling. Firstly, when the sampling points increase, the multi-correlation coefficient R 2 adj is modified, which reduces the impact of the increase of variables on the convergence evaluation index. Secondly, when speed control factor r adj is small, the search region can be quickly expanded for more exploration points, and when r adj is close to the threshold, the search region can be quickly reduced to promote algorithm convergence. Therefore, the improved MPS algorithm can effectively expand the search region and sample more exploration points to determine the global optimum and avoid premature convergence. At the same time, the solution time is basically the same as that of the standard MPS algorithm. If the other two algorithms improve the solution accuracy, it is necessary to increase the number of iterations to increase the sampling points but this also reduces the solution efficiency.

CONCLUSION
To improve the performance and economy of HESS participating in AGC, a bi-layer capacity optimization method considering the operating strategy and net benefits of HESS is proposed in this paper. In addition, an improved MPS algorithm is presented to improve the accuracy of model solving. In an AGC cycle, to reasonably distribute the HESS power to improve AGC performance in the lower layer, an MPC strategy of HESS is presented to coordinate the power of generators. In the upper layer, the net benefit optimization model of HESS is formulated to improve its economy. Through bi-layer mutual iterative optimization, the optimization results obtained meet both the optimal capacity and optimal control of HESS. Furthermore, to improve the solution accuracy of the bi-layer model, the convergence speed of the MPS algorithm is improved, so that the global search and local convergence speed can be taken into account. The case study results show that the bi-layer model can comprehensively consider the interaction between the economy and operating strategy of HESS. Compared with the commonly used RULE strategy, the presented MPC strategy not only has better AGC performance, but also has better economic benefits. The improved MPS algorithm has higher solution accuracy. Compared with the results of the standard MPS algorithm, the annual net benefits of HESS increased by $22,000.