1. Introduction
Microgrids, as carriers integrating diesel generators, renewable energy sources (RESs), energy storage systems (ESSs), and local loads, can achieve integrated generation–storage–consumption operations, offering vast development potential [
1]. However, microgrids with a high penetration of RESs have lower inertia and reserve levels, making frequency security issues prominent during power disturbance events, such as unintentional islanding events or load disturbances. Frequency-constrained optimal dispatch is proposed in this context to enhance the frequency security of microgrids from the system operation level.
In the field of frequency-constrained optimal dispatch research, the modeling and convexification of frequency constraints is an interesting yet challenging topic. Due to the close electrical distances within microgrids, the topology can be neglected [
2], and current research on the modeling of frequency constraints is typically based on center-of-inertia frequency response models (i.e., average system frequency model [
3] or system frequency response model [
4]). By linearizing the primary frequency response (PFR) process of generators [
5] or constructing the frequency deviation function [
6], the high-order, closed-loop average system frequency model is opened up, yielding the three key frequency metrics of rate of change of frequency (RoCoF), frequency zenith/nadir (i.e., maximum frequency deviation (MFD)), and quasi-steady-state frequency deviation (QSSFD). However, the open-loop method of the average system frequency model can only obtain approximate frequency constraints, leading to significant errors and unnecessary conservatism [
7]. By directly solving the second-order system frequency response model, the analytical expression for the frequency deviation function is obtained, thereby yielding accurate frequency constraints [
8,
9]. Specifically, this refers to the MFD constraint, as the other two constraints can be accurately derived regardless of the model used. To improve the accuracy of frequency constraints, we will conduct research based on the system frequency response model in the subsequent sections.
Currently, some studies are focused on developing algorithms to convexify the MFD constraint. The piecewise linearization method has been widely adopted [
10]. However, this method struggles to achieve a balance between accuracy and the computational burden of the fitting process. From a classification perspective, a support vector machine-based convexification method [
8] for the MFD constraint is used. Additionally, a convex hull approximation method has been proposed to delineate the frequency security boundary [
11]. However, this method can only convexify the MFD constraint for a specific power imbalance. When the power imbalance is a priori unknown (i.e., when it is a decision variable in the optimization model), the security boundary is influenced not only by the system parameters but also by the power imbalance itself. Therefore, it is necessary to find a convexification method for the MFD constraint that offers high accuracy, strong scalability, and does not introduce excessive computational burden. Similar convex relaxation challenges arise in hybrid AC/DC microgrid optimization, where the authors of [
12] proposed steady-state convex bi-directional converter models to handle massive RES uncertainty scenarios.
In recent years, with the introduction of various advanced control algorithms, inverter-based resources have acquired frequency support capabilities similar to those of synchronous generators. This is particularly important in weak power grids. Previously, some studies focused on developing real-time control algorithms at the device level for inverter-based resources [
13]. Recently, attention has shifted towards how to integrate device-level control with system-level operation to achieve both economic efficiency and system security in power systems. The coupling of rotor speed, primary frequency reserve, and virtual inertia in wind turbines is modeled in detail, and the control parameters of wind turbines are optimized online in look-ahead dispatch [
14]. The inertia and damping constants of RESs and ESSs are treated as decision variables and are similarly optimized in a rolling manner in look-ahead power dispatch [
11] to comply with newly released grid codes [
15]. Similarly, the coordination of frequency regulation capabilities from multi-source converters is considered in unit commitment, and the control modes of wind turbines and ESSs are modeled [
16]. These studies have detailed the modeling of the coupling relationships between the operating conditions of inverter-based resources (such as wind speeds for wind turbines or energy reserves for ESSs) and control parameters. However, the previous work only ensures that frequency metrics stay within thresholds, neglecting crucial factors such as frequency fluctuations and their duration in dynamic response. This oversight can lead to significant issues, such as an unsatisfactory frequency response, even when the frequency constraints are met [
17]. The integral time absolute error (ITAE) of frequency is defined as a measure of the extent to which the frequency deviates from its rated value over a period of time. It is calculated as the integral of the absolute value of the frequency deviation over time, which serves as a proxy for the changes in kinetic energy induced by the disturbance [
18]. Superior frequency response characteristics include a shorter recovery time for frequency and a lower frequency deviation during disturbances [
19]. A poor ITAE of frequency can also lead to certain safety issues [
20], such as the overheating failures of electric motors, which subsequently aggravate the failure rates of sophisticated production lines. Therefore, it is necessary to improve the ITAE of frequency as much as possible while ensuring frequency security [
21].
As the penetration of RESs continues to increase, in addition to deploying PFR reserves, additional headroom should be reserved to smooth out RES fluctuations. This part of the reserves is referred to as the “regulation reserves”. The deployment of regulation reserves depends on the forecast error of RESs. Over-deployment can lead to economic inefficiencies, while under-deployment can cause power imbalances. However, unlike large-scale disturbances, this type of power imbalance is continuous and smaller in scale, not causing severe frequency security issues, but it can still pose a threat to system operation over time. To reasonably describe and address the uncertainty of RESs, the distributionally robust chance-constrained approach has recently garnered significant attention. This approach combines distributionally robust optimization and chance-constrained optimization to provide more flexible and reliable solutions when dealing with uncertainty. The benefits include improved system reliability in uncertain environments and avoiding overly conservative results [
22]. The works of [
23,
24] describe the uncertainty of RESs using moment-based ambiguity set. However, since moment-based ambiguity set cannot fully utilize historical data, the results tend to be overly conservative. Additionally, in microgrids, aside from diesel generators, both ESSs and power exchange lines between microgrids and the main grid can reserve regulation reserves to fully utilize various regulating resources. To the best of the authors’ knowledge, current studies have rarely considered this aspect.
Based on the aforementioned literature review and the knowledge gaps shown in
Table 1, this work makes the following contributions:
A distributionally robust frequency-constrained economic dispatch (DRFC-ED) model is proposed, with the objectives of minimizing economic costs and enhancing the ITAE of frequency, a crucial metric for evaluating frequency response performance. This model simultaneously optimizes generation dispatch, power exchange, and upward/downward PFR and regulation reserves.
The MFD and ITAE of frequency are modeled as ternary functions of the inertia constant, damping constant, and power imbalance. To address their highly non-convex nature, linear layers are used from deep neural networks (DNNs) for convexification and embedded into the mixed-integer linear programming model using the big-M method.
To address the challenge of the different dimensions of economic cost and the ITAE of frequency in the objective function, a multi-objective optimization method is used to directly obtain the compromise optimal solution. This method transforms the original multi-objective mixed-integer linear programming model into a single-objective model that is easier to solve.
The Wasserstein distance-based ambiguity set is used to describe the uncertainty of RESs, which can make fuller use of historical data compared to the moment-based ambiguity set. The regulation reserves of diesel generators, ESSs, and the power exchange line are modeled to fully utilize various resources’ contributions in managing the uncertainty of RESs.
The rest of the paper is organized as follows.
Section 2 derives the expressions for frequency constraints and the ITAE of frequency based on the system frequency response model and introduces the convexification method based on DNNs.
Section 3 presents the formulation of DRFC-ED, and
Section 4 introduces the solution methodology of DRFC-ED.
Section 5 conducts a case study, and finally,
Section 6 concludes the paper. Before introducing the detailed content, this paper first outlines the assumptions and simplifications made in this paper:
Although RES generators are also a type of inverter-based resource and various control algorithms have been developed to provide frequency support, they are currently mostly operated at the maximum power point to achieve maximum resource utilization [
25]. Additionally, the uncertainty of RESs introduces further uncertainty in their frequency support, making the problem more complex. Therefore, this paper considers the frequency support provided only by diesel generators and ESSs in microgrids.
Power electronic inverters can be categorized into grid-following and grid-forming types. Given that this paper focuses on microgrids, which are typically more fragile, ESSs are considered to be connected to the grid through grid-forming inverters to participate in the construction of frequency [
26]. Additionally, the VSG strategy is used to control ESSs, which is considered the most widespread and typical control method [
19,
27].
5. Case Study
The effectiveness of the proposed DRFC-ED is evaluated using a test microgrid system composed of four diesel generators, four ESSs, one wind turbine, one photovoltaic generator, and one aggregate load. The case study is carried out on a computer with a 3.00 GHz Intel Core i5-8500 CPU and 16 GB of RAM, using Gurobi 11.0.0 as the solver and Python 3.10.6 as the programming language.
The forecast power for the RESs and load are scaled based on actual data from a region in Guangdong Province, China, as shown in
Figure 4. Data for the diesel generators, ESSs, and power prices have been uploaded to [
29].
Based on the RES forecast value, 5000 samples conforming to a normal distribution with a mean of 0 and a standard deviation of 15% of the forecast value are generated using the Monte Carlo sampling method. From these samples, 20 samples are selected to construct the ambiguity set. The remaining samples are used to verify the empirical violation probability (EVP) of each chance constraint, with a confidence level of = 95%.
The power base value
PB is 100 MW, and the nominal frequency is 50 Hz. The frequency constraint limits
,
, and
are set to 1 Hz/s, 0.5 Hz, and 0.25 Hz, respectively. The load damping coefficient
DL is 0 [
35]. The load disturbance coefficient
= 15%. Additionally, before training the DNNs, the number of neurons is set to 32 for each layer, i.e.,
m = 32. The mean squared error is chosen as the loss function, and the maximum number of epochs is set to 1000. The ITAE of frequency is calculated by integrating the frequency deviation, with an integration step size of 0.01 s and an integration time of 30 s.
To facilitate subsequent explanations, the following three models are defined: M1—a DR-ED model for microgrids without considering frequency constraints and the ITAE of frequency; M2—a single-objective DRFC-ED model considering frequency constraints but not the ITAE of frequency; and M3—the proposed multi-objective DRFC-ED model.
5.1. Selection of Ball Radius θ
Before performing multi-objective optimization, it is necessary to calculate the optimal and worst values for each single-objective problem. Different radii result in varying degrees of conservative estimation of the RESs’ uncertainty, thereby affecting the upper and lower bounds of objective F1. Therefore, the M2 model under different ball radius settings to obtain a trade-off between EVP and economic performance is first solved. Based on this, the M3 model is then solved.
The M2 model under five different ball radius settings is solved, and the results are shown in
Table 2. As can be seen, when the ball radius is equal to 0.025 and 0.02, the maximum EVP among all DR chance constraints exceeds 5%, failing to meet the set confidence level. When the ball radius is greater than or equal to 0.03, the maximum EVP meets the requirement, albeit at the cost of increased economic expense. Balancing the maximum EVP and economic efficiency, θ = 0.03 is chosen as a compromise.
It should be noted that once the ball radius is determined, the maximum EVP in the M1–M3 models will be the same. Therefore, it is a reasonable practice to first determine the ball radius through M2.
5.2. Comparison of Optimization Results
5.2.1. Comparison of Single-Objective and Multi-Objective Optimization Results
After determining the ball radius, the DRFC-ED is solved with
F1 from (20) and
F2 from (21) as the optimization objectives, respectively, to obtain the optimal and worst values of each objective. Subsequently, M3 is solved. The results of the single-objective and multi-objective optimization models are shown in
Table 3.
It can be seen that when F1 is the objective, the model is economically optimal but overlooks the ITAE of frequency. When F2 is the objective, the model fully deploys the inertia and damping of ESSs, increasing the reserve costs of ESSs and thereby increasing economic costs. However, in the multi-objective optimization model, by directly solving for the compromise optimal solution, the ITAE of frequency improves by 8.03% at the cost of only a 2.1% increase in economic costs. This demonstrates that the proposed multi-objective formulation enables a balance between economic efficiency and frequency performance.
5.2.2. Optimization Results of M1–M3
Table 4 presents the optimization results of M1–M3. From the perspective of economic costs, the costs for M2 and M3 are approximately 37% higher than those for M1. This is because M2 and M3 incur additional PFR reserve costs due to the inclusion of frequency constraints. Additionally, more power is sourced from diesel generators and ESSs rather than the main grid to prevent excessive power imbalance after unintentional islanding events, resulting in higher power exchange costs for M1 compared to M2 and M3.
Figure 5 shows the scheduling results of diesel generators, ESSs, and power exchange for the three models. It can be observed that due to the lack of frequency constraints, M1 purchases a large amount of power from the main grid at night and stores it in ESSs, which then supply power during the day when the RES output is low. This results in lower power supply requirements from diesel generators compared to M2 and M3. However, under such a scheduling result, unintentional islanding events would result in a significant power imbalance, posing safety risks. After considering frequency constraints, M2 and M3 both limit power exchange and rely more on power generation from devices within the microgrid to ensure frequency security after unintentional islanding events.
Comparing M2 and M3, the most significant difference lies in the PFR reserve costs (the PFR reserve scheduling results are shown in
Figure 6). Since M3 optimizes the ITAE of frequency, it results in more damping being deployed (damping is more effective than inertia in improving the ITAE of frequency [
18]). M2, on the other hand, only ensures that the frequency constraints are met without considering the different characteristics of inertia and damping in the frequency response.
Figure 7 shows the scheduling results of the ESSs’ virtual inertia and damping in M2 and M3. The orange line serves as a baseline, representing the inherent inertia and damping of diesel generators. It can be observed that M2 prioritizes the deployment of the ESSs’ inertia because this approach maximizes benefits while ensuring frequency security. In contrast, M3 prioritizes the deployment of damping to optimize the ITAE of frequency, which leads to a reduction in inertia deployment to keep the ESSs’ PFR reserve costs from being excessively high. Furthermore,
Figure 8 shows the scheduling results for each ESS’s virtual inertia and damping in M3. It can be observed that only the inertia of ESS #1 is deployed, while the inertias of ESSs #2–#4 are not scheduled. In terms of damping scheduling, the damping for ESSs #1 and #2 is fully deployed to the maximum limit, while ESS #3 reaches full deployment in some cases, and ESS #4 is scheduled the least. This is because the PFR reserve cost coefficients increase from ESS #1 to ESS #4, leading to the prioritization of the more cost-effective ESS #1 for inertia and damping scheduling.
By inputting the scheduling results of each time period for M2 and M3 into the system frequency response model, we obtain the frequency response curves for M2 and M3 (calculated for low-frequency scenarios), as shown in
Figure 9. It can be seen that M3, which schedules more virtual damping, has a smaller QSSFD compared to M2. Additionally, the distribution range of QSSFD for M3 is broader, while M2 maintains the QSSFD at 0.25 Hz, which is the set threshold. Furthermore, M3 shows no oscillation process before reaching quasi-steady-state, indicating better stability. In contrast, M2’s frequency curve is not smooth due to lower damping. This phenomenon supports the conclusion of Sajadi et al. that increasing damping can alleviate concerns among power system experts regarding the reduction of inertia [
18].
5.2.3. Verification of Frequency Constraints’ Effectiveness
Figure 10 shows the MFD and the maximum power imbalance of M1–M3. Since the RoCoF constraint and the QSSFD constraint are linear constraints and do not involve errors, their results are not displayed here. It can be observed that, due to the lack of constraints on power exchange in M1, the power exchange line transmits a large capacity during nighttime. If unintentional islanding events occur at this time, the MFD can reach 3.5 Hz, severely impacting power supply reliability.
In contrast, M2 and M3, after applying frequency constraints, strictly maintain the MFD within 0.5 Hz and also impose limits on power exchange. The maximum power imbalance in all cases is kept below 15% of the current load power. This ensures that seamless islanding can be maintained after unintentional islanding events, and frequency support capability is available during load disturbances.
Additionally, it can be observed that although the MFD of both M2 and M3 remains below 0.5 Hz, M3 is farther away from the threshold. Therefore, the improvement in the ITAE of frequency is closely related to the frequency metrics.
5.2.4. Verification of the Effectiveness of DNN Method
The Latin Hypercube Sampling method is used to sample power imbalance, inertia, and damping constants, generating 20,000 samples. Of these, 90% are used for training the DNNs, while 10% are used for testing.
Table 5 presents the evaluation metrics of the DNNs used for convexifying the MFD constraint (DNN
1) and frequency quality (DNN
2).
Figure 11 shows the testing performance of DNN
1 and DNN
2 based on 200 samples drawn from 2000 testing samples.
It can be observed that the DNN method shows high accuracy in convexifying the MFD constraint and frequency quality. Additionally, the inclusion of DNNs does not introduce excessive computational burden. The average time to solve M3 is only 8 s with a convergence gap of 0.1%.
Additionally, we compared the predicted values at each time period in M3 with the actual values obtained through simulation by substituting the solved results. The relative error statistics are shown in
Table 6. It can be observed that the performance of the DNNs is satisfactory when applied to the DRFC-LAED.
5.2.5. Comparison of Different Stochastic Optimization Methods
The optimization results and maximum EVP of M2 under different stochastic optimization methods are compared. The definitions are as follows: C1—Gaussian-approximation chance-constrained method, where the uncertainty of RESs is assumed to follow a Gaussian distribution; C2—moment-based ambiguity set DRCC method; and C3—Wasserstein distance-based ambiguity set DRCC method (θ = 0.03).
Table 7 presents the results under different stochastic optimization methods. It can be observed that the cost of C1 is lower than that of C2 and C3, but the maximum EVP exceeds the set threshold. This approach, which directly assumes a Gaussian distribution for the RESs’ uncertainty, clearly fails to meet the requirements. Both C2 and C3 satisfy the confidence level constraint, but the cost of C2 is higher than C3, despite its maximum EVP being well below 5%. This is because the moment-based ambiguity set can only utilize the mean and variance of historical data. In contrast, the Wasserstein distance-based ambiguity set can more comprehensively utilize the available data. Therefore, its conservativeness is reduced, but it can still balance conservativeness by controlling the ball radius.
6. Conclusions
This paper proposes a microgrid frequency response enhancement-oriented DRFC-ED dispatch model. For the first time, the ITAE of frequency is used as a metric to optimally deploy the combination of system inertia and damping in frequency-constrained optimal dispatch research while also optimizing the coordination of diesel generators, ESSs, RESs, and power exchange. The case study verifies that the DRFC-ED model can effectively ensure frequency security at the system operation level. Furthermore, case studies confirm that the damping coefficients exhibit greater sensitivity in minimizing the ITAE metric compared to inertia constants. Strategic damping enhancement can alleviate concerns about the reduction of inertia. The proposed DNN-based convexification method achieves satisfactory accuracy. Additionally, the proposed method effectively solves the multi-objective optimization problem without incurring extra computational burden. The uncertainty of RESs is effectively managed through the distributionally robust chance-constrained approach, which ensures that the EVP does not exceed the limit. This study contributes to enhancing both the economic efficiency and dynamic security in renewable-dominated microgrids while addressing critical challenges in modern power systems.
While this study focuses on inertia-damping coordination via ITAE optimization, two important extensions are warranted: (1) incorporating RES frequency support mechanisms (e.g., wind turbine virtual inertia and PV droop control) to enhance primary frequency response, and (2) exploring hybrid ambiguity sets (e.g., Wasserstein-moment combined) for uncertainty modeling to balance the robustness and computational efficiency. These directions will be pursued in subsequent research.