Distributed Predictive Control using Frequency and Voltage Soft Constraints in AC Microgrids including Economic Dispatch of Generation

This paper proposes a distributed predictive secondary controller to tackle together frequency and voltage regulation, realize the economic dispatch and reactive power sharing of generation units in isolated AC microgrids. Contrary to most approaches, the proposed predictive controller achieves consensus objectives (economic dispatch of generation and reactive power sharing) with soft constraints (keep both frequency and average voltage within predefined bands instead of restoring them to their nominal values). Extensive simulation work validates the effectiveness of the predictive controller for communication problems and in the presence of plug-and-play scenarios.

restores the frequency only when it is above a triggering level. It is reported in the IEEE standard 1547-2018 that a distributed generator (DG) can contribute to the power sharing as long as the frequency and the voltage are within 1% and 5% of their nominal values, respectively [8].
Moreover, there is a strong trend to include the economic dispatch of generation in distributed controllers at the secondary level [3], [4], [7], [9]. This is because MGs are subject to fast load and generation changes. In this regard, consensus techniques over the incremental cost are a leading solution in a distributed fashion [4]. Most of the solutions proposed at the secondary level are based on distributed proportionalintegral controllers [3]- [5], [7]. On the other hand, there are also distributed model predictive controllers (DMPC) [9], [10] for economic dispatch and frequency restoration. Also, [6] proposed a DMPC that deals with frequency and voltage restoration to nominal values and both proportional active and reactive power sharing. Nevertheless, the vast majority of these proposals do not consider all the objectives of economic dispatch, reactive power sharing, and frequency and voltage regulation in their formulation.
Considering all these aspects, a DMPC scheme that achieves consensus objectives (economic dispatch and reactive power sharing) with soft constraints (frequency and voltage regulation within predefined bands) is proposed. Due to the use of auxiliary variables, it is possible to include these flexible objectives directly in the DMPC formulation. To the best of the authors' knowledge, a DMPC strategy to solve all these objectives has not been proposed. The contributions of this paper are: (i) A DMPC scheme is proposed for optimal dispatch of DGs, including reactive power sharing and operational constraints for frequency and voltage regulation into the same optimization problem. The DMPC uses only the usual local measurements and dynamic local models to predict the DGs' behavior, avoiding the modeling of the full MG.
(ii) The proposed DMPC can achieve accurate active power dispatch and reactive power sharing, whereas both frequency and average voltage are regulated within predefined bands, producing a more flexible control system than those usually reported [3]- [7], [9].

A. Proposed Distributed Control Scheme
Consider an AC MG with a set of N DGs with N = {1, ..., N } that achieve cooperative objectives through peerto-peer communication. The bidirectional connectivity from the ith DG (DG i ) to DG j and vice-versa is defined by the terms a ij (with a ij = a ji ) of the Adjacency matrix A (defined in Section III). The entries of A are 1 if there is communication between DG i and DG j or 0 otherwise [11]. The communication network may vary (as long as there is a spanning tree) [11] or may present communication delays. The communication delays (τ ij , with τ ij = τ ji ) are expressed in sampling periods.
The following explanation and mathematical analysis are done for DG i , as the analysis is analogous for the rest of the DGs. It has been proved that the economic dispatch of DGs can be attained in a distributed manner via a consensus on the incremental cost (IC) [3], [4], [9]. The IC for DG i is defined as η i (P i ) = 2a i P i +b i , where P i is the active power contribution of DG i , a i and b i are cost parameters defined in Section III. In this context, the economic dispatch is achieved when all DGs reach a common IC, i.e., η i = η j , where η j is the IC of neighboring DGs. In this paper, a new DMPC scheme is formulated based on the IC, while the reactive power is shared proportionally to the DGs' power capacity and the average frequency and average voltage are regulated within predefined bands, selected to accomplish with the IEEE standard 1547-2018 [8], simultaneously. Moreover, the proposed controller does not require the modeling of the MG electrical topology and only needs the usual measurements and information from communicated neighboring DGs. Fig. 1 shows the control structure for the DG i unit. Each DG is configured as a voltage source converter and has an LCL filter at its output. The primary control level (blue box) comprises frequency-active power (ω − P ) and voltagereactive power (V − Q) droop controllers, an outer self-tuning proportional-resonant (PR) voltage controller, an inner selftuning PR current controller and an active damping loop to attenuate the oscillation produced in the output filter. The proposed predictive controller is implemented at the secondary level (see the orange box). This controller receives as inputs the local measurements and estimates from the primary control level and state variable predictions of communicated neighboring DG units. Note that no additional measurements are needed, and the voltage after (L i ) is estimated through a nonlinear observer, described in detail in [9]. The DMPC outputs are the frequency control action variation, the voltage control action variation (vectors ∆ω s,i and ∆V s,i ), and the predictions of the local optimization problem X p,i , defined in Section II-B. To ensure zero error in steady-state, discrete-time integrators process the control actions while the predictions are sent via the communication network. In the following section, the DMPC controller is stated directly in its discretized predictive form.

B. Distributed Predictive Control Formulation
The predictive controller considers the following predictive models that represent the dynamic of the primary control to rule the future behavior of DG i . In the following models N y is the prediction horizon, N u is the control horizon, k = nT sec , n ∈ Z + , and T sec is the controller sample time. All models are generalized for k + m steps ahead, where m ∈ Z + . The predictive model of the IC, defined previously, is presented in (1a). The predictive model (1b) represents the ω − P droop controller, which allows that a variation in the active power (P i ) be reflected as a frequency variation (ω i ). M pω,i is the droop slope, and ∆ω s,i is the frequency control action variation. Similarly, the predictive model (1c) represents the V − Q droop controller, which allows that a variation in the reactive power (Q i ) be reflected as a voltage variation (V i ). M qv,i is the droop slope, and ∆V s,i is the voltage control action variation. The predictive model (1d) states the phase angle deviation (δθ i ) trough the inductance (L i ) of the LCL output filter. This model is used to predict the active and reactive power contribution of DG i to the MG, whereω B i (k) is the frequency estimation after L i (see Fig. 1). The linearized predictive model (1e) determines the active power contribution of DG i to the MG with i (k) are the voltage measurements/estimations before and after the inductance L i ; P i (k) is the active power measurement, and δθ i (k) is the phase angle deviation measurement. In a similar way, the linearized model (1f) predicts the reactive power contribution of DG i to the MG, where Q i (k) is the reactive power measurement. The triangular linearized constraint (1g) limits the active and reactive power contributions within the power capacity (S max ) of DG i . Note that in models (1d) to (1g) all the variables at time instant (k) are measurements/estimations produced in the discretization and linearization of the continuous time models; they are not predicted variables (see [6]). The interested reader is encouraged to read the previous work of some of this paper authors [6] for a detailed explanation of the continuous-time models of (1b) to (1g).
Models (2a) and (2b) compute local approximations of the MG average frequency (ω i ) and MG average voltage (V i ). the models consider the communication terms a ij (k) and the estimated time delayτ ij , which is defined as one sample period on the secondary level. Finally, soft constraints (2c) and (2d) work together with the previous defined models and the auxiliary variables ω aux,i , V aux,i of the cost function (3) to preserve both average frequency and average voltage within predefined bands and avoid unfeasible solutions [12]. These soft constraints relax the average frequency and average voltage limits temporally by allowing the auxiliary variables to take values outside their predefined bands for a short time. The auxiliary variables are penalized in the cost function, see (3); thus, the average frequency and average voltage must be within their bands in steady-state.
The cost function (3) comprises six quadratic terms. The first term accomplishes a consensus on the predicted incremental cost, hence, fulfilling the economic dispatch. The second term finds a consensus on the contribution of normalized reactive power. The third and fourth terms regulate average frequency and average voltage within predefined bands, where both variables are auxiliary variables that relax the inequality constraints (2c) and (2d). The fifth and sixth terms minimize the variations of control actions, improving the frequency and voltage transient responses. The terms λ 1i to λ 6i are the tuning parameters. All the consensus objectives consider the communication terms a ij (k) and the estimated time delayτ ij .

The optimization problem, which comprises the cost function (3) and linear constraints (1)-(2), is incorporated in a Quadratic
Programming formulation. The optimization output consists of the predictive vector X p,i and the future control sequence X ∆,i presented in (4) and (5), respectively. Then only the first control actions (∆ω s,i (k) and ∆V s,i (k)) are applied in the MG and the process is repeated at the next sample time [12].

III. SETUP AND RESULTS
The DMPC strategy performance is assessed in three case scenarios: (i) load steps, (ii) combined communication link failures and disconnection/reconnection of a DG unit, and (iii) communication delays. For this purpose the MG simulator illustrated in Fig. 2 with the electrical parameters of Table I  was implemented. Table II presents the DGs' physical and cost parameters; the latter were obtained from [3]. The MG electrical model, which comprises four DG units, is built using PLECS blockset® while the primary and secondary controllers are implemented in Matlab/Simulink® environment. Each DG unit has at the primary level the ω − P and V − Q droop controllers, self-tuning voltage and current PR controllers in the abc natural frame (see the blue box in Fig. 1). Table III presents the DMPC parameters (chosen to reduce the computational effort) and the weighting factors. The prediction and control horizons were chosen as 10 samples to have a good performance and reduce the traffic over the communication network. The weighting factors were tuned heuristically, looking for a trade-off between the control objectives [6], [9]. Note that the frequency and average voltage limits are also shown in Table III. These limits are fixed for all the test scenarios; however, they can be modified as long as they are within the recommendations of the IEEE standard [8].

A. Scenario I (Base Case) -Load steps
This test evaluates the performance of the DMPC under several load steps at different nodes. The adjacency matrix, which remains constant for the whole test, is shown at the    bottom of Fig. 2. The MG starts with Z 1 and Z 2 connected and the primary control enabled, i.e., droop controllers and PR controllers. The results are presented in Fig. 3 and Fig. 4. Note that without the DMPC, there is neither consensus in the incremental cost (η i = η j , and the active power is regulated only by the droop control without considering generation costs), nor consensus on the reactive power, as shown in Fig. 3 before t = 10s. At t = 10s, the DMPC scheme is enabled; thus, the consensus on the IC is achieved (see Fig. 3.a at t = 10s and onwards), hence, the active power is redispached according the generation costs (see Table II). Furthermore, the consensus on reactive power is also achieved. At t = 30s and t = 50s, Z 3 and Z 4 are connected at different nodes, respectively. When the total load is connected, the average frequency and average voltage are taken outside their bands, and the DMPC restores these variables inside their bands immediately, as shown in Fig. 4 at t = 50s. This flexible approach regulates both frequency and average voltage only when strictly necessary, instead of restoring these variables to their nominal values at each sample time, as reported in most approaches [3]- [7], [9]. Finally, at t = 70s, Z 4 is disconnected. The controller presents a good dynamic response during all the load perturbations, achieving all the objectives with settling times below 5 seconds and minor overshoots.

B. Scenario II -Combined Communication Link Failures and Plug-and-Play
This experiment appraises the DMPC performance when two stringent scenarios occur at the same time. The test starts with Z 1 and Z 2 connected and the controllers enabled (see Fig. 5 and Fig. 6 before t = 10s) the MG continues operating with only four communication channels, and the MG adjacency matrix is modified (see A(k) in Fig. 5.a at t = 10s). Then, at t = 20s DG4 is disconnected from both the electrical system and the communication network and at t = 40s Z 3 is connected. DG4 is reconnected to the MG at t = 60s (after a synchronization routine). The controller autonomously detects all these phenomena and modifies the consensus (3) and average calculations (2a) and (2b) accordingly. Note that when DG4 is disconnected there is only one communication path among the remaining DGs, which is the worst case-scenario for distributed controllers [11] (see A(k) in Fig. 5a at t = 20s).
The results in Fig. 5 and Fig. 6 verify the efficacy of the DMPC. For instance, when the communication links fail (t = 10s), the DMPC does not experience noticeable deterioration. Even when both phenomena are present simultaneously, the controller performance is not affected, and the operating DGs fulfill the consensus objectives. Nonetheless, both overshoot and settling time are marginally increased. This is because the controller depends on the known information of the neighboring DGs (completeness of the adjacency matrix A) [11].

C. Scenario III -Communication Delays
This scenario asses the DMPC scheme under what are considered medium (τ ij = 0.5s) and large (τ ij = 1s) time delays at the secondary level [3], [4]. During the whole test, a constant delay τ ij is present in the entire communication network, while the estimated delayτ ij is kept constant as one sample period. In this test, the MG experience the same load perturbations of scenario I and has the same adjacency matrix A (see at the bottom of Fig. 2).
The results are presented in Fig. 7. The active power behavior for the medium and large delays are presented in Fig. 7.a and Fig. 7.b, respectively. Fig. 7.c depicts the frequency regulation performance for both delays, and Fig. 7.d shows the average voltage regulation for both delays. The communication delay slightly affects the controller's overshoot and settling time. Although the load steps take both frequency and average voltage outside their bands (cyan dashed lines), the proposed controller regulates these variables within their predefined bands. This is accomplished through inequality constraints (2c) and (2d) that allow temporary violations. These violations are higher for the extreme delay (τ ij = 1s). Nevertheless, the results demonstrate the good performance of the proposed DMPC against communication delays even when the delay is two times the prediction/control horizons. The DMPC has the rolling horizon property, which determines the adequate control action sequences at each sample time, even with past information from neighboring DGs [6], [12]. Moreover, the proposed DMPC always respects the operational constraints, showing its effectiveness.
IV. CONCLUSION This paper presented a novel DMPC strategy for isolated MGs that simultaneously accounts for optimal dispatch, reactive power sharing and frequency, and average voltage regulation. Contrary to most approaches, both frequency and average voltage are regulated, using soft constraints, within predefined bands that fulfill the IEEE standard 1547-2018 recommendations instead of nominal values. Extensive simulation studies verify the effectiveness of the proposed controller. The proposed distributed controller addresses communication delays, communication failures, and the disconnection/reconnection of DGs. Future research is focused on the experimental validation of the control strategy and the application of the DMPC scheme for hybrid AC/DC MGs.   Fig. 7. Communication delay test, a) Normalized active power dispatch for τ ij = 0.5s, b) Normalized active power dispatch for τ ij = 1s, c) Frequency regulation for τ ij = 0.5s and τ ij = 1s, d) Average voltage regulation for τ ij = 0.5s and τ ij = 1s. The dashed cyan lines represent the predefined band limits for both latter variables.