A Quasi-Average Estimation Aided Hierarchical Control Scheme for Power Electronics-Based Islanded Microgrids

Self-governed micro power networks are a promising solution for meeting the energy needs of isolated communities not having access to regular transmission networks. The control of such isolated networks requires regulation and “fair” sharing of several power generation and storage resources as well as efficient peer-to-peer coordination between power converters operating in the network. The regulation of key parameters as voltage, frequency and power sharing is to be ensured for the system to operate optimally. This paper proposes a new, de-centralized, and hierarchical control approach for power inverters in isolated micro networks with multi-layered controls, each addressing the regulation of key system parameters. The proposed scheme uses distributed quasi-averaging estimators at each participating node to achieve resilience towards disturbances caused by delayed transmission of measurement and control signals in the data acquisition and information exchange layer. Detailed system models are developed using MATLAB and Sim-power systems to test the effectiveness of the proposed scheme under varying control and network scenarios. The results of these studies are presented as pole zero evolutions, stability margins and case study wise simulations. The studies carried out verify the validity of the proposed control strategy for micro-distribution networks.


Introduction
Microgrids (MGs) have emerged as a viable solution for widespread integration of distributed renewable energy resources (RES).Distributed generation units (DGUs) drawing upon renewable resources, exhibit a variable stochastic output [1,2].Therefore, additional supervisory controls must be present to ensure seamless integration with the legacy power network.Conversely, a "microgrid" can be used as a smaller power network functioning independently from the main power grid, locally producing and consuming power for the benefit of local consumers [3,4].Such a micro-network may consist of several DGUs, energy storage systems (ESS), plug-in hybrid electric vehicles (PHEV), data acquisition and supervisory control devices, several localized and/or centralized controllers [1][2][3][4].
The ESS employed in a microgrid environment may include battery energy storage systems (BESS) [5], Fly wheel energy storage systems [6], and Plug in Electric Vehicle batteries (PEV) [7].Based on the dynamics of each storage system, operational limits, discharge constraints, possible faults and local storage management systems, and appropriate additional controls may be added in the overall microgrid control scheme [5,6,8,9].
Typically, power conversion units form front end conditioning stages of DGUs that operate in parallel.Proportional power sharing between these nodes is required for fair and stable operation of a microgrid.To this end, various power sharing control strategies are employed [10]: Droop control techniques are decentralized power sharing methods based on the principle of proportional reduction in voltage and frequency magnitudes to realize active and reactive power sharing by each unit.As such there are several variations of basic droop methodologies for different inductive and resistive nature of microgrids considered [10][11][12].A secondary control layer is however required to observe and correct such deviations in frequency and voltage to keep these parameters within a nominal range [10,[13][14][15][16][17][18][19].
Alternatively, some research presents a communication-based control paradigm, partially based on power and voltage observers to achieve equivalent power contribution by distributed generation units along with voltage restoration and frequency synchronism [10,20,21].Such methods tend to be largely dependent on the transmission of data for the proper functioning of an elaborate control scheme.Both above-mentioned methodologies work with a hierarchical control system, implemented either as a centralized controller or through decentralized controllers located alongside each power contributing unit.Centralized control strategies will typically require two-way communication with a microgrid central controller (MGCC).Centralized strategies are expensive to implement.Furthermore, the MGCC stands out as a single point of failure (SPOF) in the system that can cause widespread failure, should the central controller suffer a breakdown.
Conversely, decentralized methods exhibit more flexibility and agree well with the use of innovative new control schemes based on artificial intelligence and multi-agent systems consensus [2,10,[22][23][24][25][26].The fundamental feature of multi-agent-based control methods is enabling the computational abilities at every DGU node to participate in the decision-making process, thus enabling all said agents to arrive at a consensus of corrective measures for the system in time.The microgrid operation and control problem can be formulated such that each power converter is made to behave as an agent within a multiagent systems framework.Power sharing, voltage and frequency restoration problems are formulated as tracker synchronization problems where all nodes strive to reach a consensus on corrective measures [2,27,28].
The system regulation problem can be seen as a hierarchical multi-layered control structure, where the primary layer controls power sharing, whereas, secondary and tertiary layers restore frequency and voltage [23,29,30].Secondary layers function on the multiagent consensus principle and convert frequency and voltage restoration problem to a tracker synchronization distributed problem.Another approach is to frame the power sharing problem as a distributed consensus-based control goal [31].Reactive power sharing is addressed as a primary goal in references [32,33], through a distributed control approach that also restores voltage.Small signal modeling has been used to analyze system stability under distributed control algorithms aimed at power sharing, voltage and frequency restoration.In reference [34], authors present a consensus based distributed voltage control algorithm aimed at regulating voltage and sharing reactive power in meshed electrical micro-grids.This method replaces the traditional V-Q droop method.In reference [20], authors present a distributed cooperative control strategy for microgrids that proposes alternates for centralized secondary control and the primary droop control of each inverter.Voltage, reactive power, and active power regulators are designed to regulate these parameters.
The effectiveness of consensus based regulatory methods is largely dependent upon the health of communication links comprising the information exchange layer [35,36].Therefore, fast relaying of measured parameters and control signals translates into earlier convergence and improved system regulation, whereas intermittent and latent communication links cause deterioration in control performance.However, to simplify problem formulation and control design, most researchers [23,29,30,32,34] assume fault-free communication networks with no broken, disrupted or latent communication links.The information digraph represented in such system models is therefore time in-varying.However, the studies [31], [37], and [20] take a more detailed view and consider scenarios with faulty communication links.In reference [37], faulty communications are represented through a dynamically varying digraph.
In practical systems, communication intermittencies in wired and wireless networks are inevitable and common.The performance of control methods based solely on multiagent consensus and communication of values deteriorates under these circumstances.Therefore, an innovative and coherent strategy to address the problems created by delayed transmission of key parameter estimates and control signals is required.The authors have previously presented hybrid, hierarchical control methods to address the problems of microgrid control considering faulty and latent communication links [33,36,38,39].In this present work, the authors follow a different approach and propose a new and improved control scheme to deal with the problem of faulty and latent communication links in the hierarchical control of islanded AC microgrid networks.A merger between two decentralized control approaches is proposed, i.e.: a completely communication dependent power sharing control and the conventional droop control, such that benefits of both schemes can be accrued.An innovative distributed quasi-average estimation-based power sharing approach is presented here for balancing active power contribution by all the participating DGUs, such that a degree of resilience to communication latencies is achieved.Mathematical analysis and numerical simulation of the proposed method is provided for verification and closure.A multiagent consensus based secondary control layer is added to restore system frequency and voltage.
The major contributions of this work, therefore are: (1) An innovative distributed quasi-averaging based approach for active power sharing in islanded microgrids that improves upon existing methods.(2) A multi-layer, distributed control structure that eliminates the need for centralized monitoring and control.(3) Analysis of resilience of the proposed methodology under communication latencies.(4) A small signal analysis for studying MG system stability under the proposed control scheme.
(5) Comparison of the proposed methodology with conventional communication and consensus-based power sharing.
The remainder of this paper is organized as follows.Section 2 gives the problem description with details of the system used in this study.Section 3 outlines the proposed distributed quasi-averaging method for power sharing.Section 4 outlines details of the consensus-based observer used for comparison.Section 5 provides details on secondary voltage and frequency regulation controls.Section 6 gives the derivation of the small signal model for this microgrid system with the employed controls.Section 7 gives details on the discretization of the derived system model.Section 8 elaborates stability analysis of the system under discussed controls.Section 9 gives system performance evaluation with simulation studies and Section 10 concludes the paper.

Problem Description
This section details the microgrid system used in this study.The smart micro network may be considered as two overlaying and dynamically interacting systems composed of: (i) the power distribution network and (ii) The communication and control infrastructure.Therefore, every power injecting system may be considered as a participant node or agent in a larger multiagent system.To properly describe the problem and propose the control strategy, we systematically describe component theories as basic notions of graph theory and power systems steady state equations along with the necessary mathematical representations.A description of communication latencies is presented as a prerequisite to the work that follows.

Micro-grid Power Network
Figure 1 shows the power distribution network and the proposed overlying control layers.A simplified radial, three-phase, three wire distribution system is used in this study where all busses are connected to the power distribution network using power electronic converters with LC filters.The buses from 2 through 6 are directly loaded with adjustable power loads, bus-1 has no load directly connected.Bus 7 links this isolated network with the legacy power grid.This network can be operated in islanded mode by disconnecting the link through bus 7. Table 1 details rated system parameters and Table 2 gives bus loads.The major divisions of the hierarchical control scheme used in this work and its interaction with the spanning communication are outlined in Figure 1.
Electronics 2018, 7, x FOR PEER REVIEW 4 of 30 Figure 1 shows the power distribution network and the proposed overlying control layers.A simplified radial, three-phase, three wire distribution system is used in this study where all busses are connected to the power distribution network using power electronic converters with LC filters.The buses from 2 through 6 are directly loaded with adjustable power loads, bus-1 has no load directly connected.Bus 7 links this isolated network with the legacy power grid.This network can be operated in islanded mode by disconnecting the link through bus 7. Table 1 details rated system parameters and Table 2 gives bus loads.The major divisions of the hierarchical control scheme used in this work and its interaction with the spanning communication are outlined in Figure 1.Equation (1) presents a steady state model of the MG system.Wherein, Ysi denotes the inverter coupling LCL admittance; Yij gives the equivalent line admittance present between i th and j th nodes; Isi represents the current flowing into the i th bus.The active, reactive power injected at each node is represented by (2) and (3).

Values Parameters Values
where, Yin is the admittance connected between the i th and n th bus; Vi is the voltage magnitude at i th inverter terminal and Vn is voltage magnitude at the n th bus; θ in is the admittance angle present between bus i th and n th bus, δ n is the voltage angle at nth bus, whereas δ i is the voltage angle at the i th bus.Y bus matrix of the microgrid is given in Appendix C.

Hierarchical Control Structure and Information Exchange Media
The control scheme for the microgrid system is divided into a hierarchical control structure composed of three broad layers, graphically represented in Figure 1: the inner or zero level control loops are dedicated to regulating voltage and current loops for each power converter, generating gate pulses to operate individual converter.The primary layer regulates power sharing using droop control technique with the droop gains selected as (m P *, n Q *).The secondary/tertiary layer is composed of power, voltage and frequency observers that estimate these parameters based on information from neighborhood nodes (∑ k∈N ω oi , ∑ k∈N v oi , ∑ k∈N P εi ), thereby providing regular corrective updates for power injection, voltage and frequency values (P refi , ω ni , V ni ) to maintain these within an agreeable range on a system wide scale.The communication network layer serves as the media for measured/estimated values and control signals to travel through the control system based on connectivity structure.For modelling and control design the connectivity between system nodes can be mapped as a digraph.A digraph is represented mathematically as G com = (V g E g A g ), which is composed of a non-empty, finite set of M nodes represented by V g = {v 1 v 2 v 3 . . .v M }.The arcs that link these nodes are given by E g ⊂ V g × V g .The adjacency matrix representing the mapping and interconnection of different nodes through these arcs is given by A g = [a ij ] ∈ R N×N .The DGUs can be considered as the nodes of a communication digraph, whereas the arcs show communication links [40].Figure 2a details the interaction between primary and secondary control layers at a single node.Voltage and frequency corrections (ω ni , V ni ) are generated through observer consensus based on global voltage and frequency references (v re f , ω re f ) as well as neighborhood estimates (v oj , ω oj ).The third component estimates injected power average reference (P refi ), based on neighbor estimates (εP avg.N ), as later elaborated mathematically in Section 3.
Electronics 2018, 7, x FOR PEER REVIEW 6 of 30 on connectivity structure.For modelling and control design the connectivity between system nodes can be mapped as a digraph.A digraph is represented mathematically as  = (    ), which is composed of a non-empty, finite set of M nodes represented by  =    …  .The arcs that link these nodes are given by  ⊂  ×  .The adjacency matrix representing the mapping and interconnection of different nodes through these arcs is given by  =  ∈  × .The DGUs can be considered as the nodes of a communication digraph, whereas the arcs show communication links [40].Figure 2a details the interaction between primary and secondary control layers at a single node.
Voltage and frequency corrections (ωni, Vni) are generated through observer consensus based on global voltage and frequency references ( ,  )as well as neighborhood estimates (  ,  ).
The third component estimates injected power average reference (Prefi), based on neighbor estimates ( .), as later elaborated mathematically in Section 3.An initially stable communication network is assumed for convenience that may be described as a time invariant digraph, as represented in Figure .2b, where the solid bi-directional arrows represent healthy communication links between DG nodes.Communication channel noise may be neglected for simplifying calculations.The resulting digraph is time invariant, i.e.  is a constant.An arc emanating from node j and leading to node i is denoted by ( ,  ), where node j receives information from node i. aij represents the weight of the arc connecting vi to vj.  0 if  ,  ∈  , otherwise  = 0. Node i is called a neighbor of node j if the arc  ,  ∈  .Set of nodes neighboring the i th DGU  are given by  =  ∈  : ( ,  ) ∈  }.The Laplacian matrix,  = ( ) × is defined as  = − ,   and  = ∑    = 1, … ., .Such that  = 0 with 1 = (1, … ,1) ∈  .The in-degree matrix can be defined as  =   , where,  = ∑ ( ∈ )and out-degree matrix as  =   , where  = ∑ ( ) ∈ .Multiagent consensus-based algorithms implemented across the networked control system cause system states  to converge over a span of time and this can be represented as (4), (5).
Where, An initially stable communication network is assumed for convenience that may be described as a time invariant digraph, as represented in Figure 2b, where the solid bi-directional arrows represent healthy communication links between DG nodes.Communication channel noise may be neglected for simplifying calculations.The resulting digraph is time invariant, i.e., A g is a constant.An arc emanating from node j and leading to node i is denoted by (v j , v i ), where node j receives information from node i. a ij represents the weight of the arc connecting ). Multiagent consensus-based algorithms implemented across the networked control system cause system states x to converge over a span of time and this can be represented as ( 4), (5).
where, L g = D g − A g (5) Equation ( 5) represents the Laplacian matrix L g calculated for the communication network based on adjacency matrix A g and degree matrix D g , x represents the system states and .
x represents their evolved values as per the consensus algorithm, the factor C is a convergence factor whose value can be modeled based on network parameters [41].The matrices A g , D g and L g for the communication topology used are given in the Appendix B.

Network Latencies
Figure 2c represents the effect of communication latencies considered affecting three nodes, i.e., DG 1,6 and 5.The dotted lines represent communication links suffering from latencies whereas DGs are labelled 1 to 6 accordingly.The DG 6 is shown to be dually affected by communication health decay since all the links connecting it suffer from communication latencies.To elaborate upon the modelling of communication latencies, a networked control system can be described in discrete state space form as in (6): where, matrices A, B and C represent a simplified form for state space matrices of a networked controlled system in discrete time, x p represents vector of system states considered in the modelling, u p are the inputs and y p are the outputs derived from the system.Assuming that a networked communication system is in place to relay the measured outputs, for a general case we may assume that all parameter measurements after passing through the communication network exhibit a randomly varying communication delay given by ( 7) where, τ m k represents the communication delay occurring at time instant k and δ(k) is a stochastic binary variable with Prob{δ(k) = 1} = p k where p k can take only discrete values [42].In this work, for convenience in a larger system modeling, we approximate the communication delay τ m k with a uniform unit time delay represented by t d as in reference [41].This delay is varied incrementally in discrete equal steps to emulate an increasing delay for different scenarios.

Distributed Quasi-average Estimation
Distributed multiagent control systems decompose the collective system average value estimation problem as a decentralized problem to be solved by every node (or agent).Consensus among participant agents can be achieved effectively when the communication network relays information and control signals with reasonable fidelity.However, with deteriorating communication link health, the average estimation convergence is affected [43].As a solution to the adverse effects of communication intermittencies and faults, a new power sharing control is proposed, based on a distributed "quasi-average" estimation principle.Drawing inspiration from the theory and basics of infinite impulse response filters (IIR) [44], distributed quasi-average power estimators are programmed at every node as shown in Figures 3a and 4c, that enable averaged values to be estimated.The structural interaction between averaging filters at each node is shown in Figure 3a.Each blue box represents the averaging filter at each node; node 1 to N are indicated accordingly.x m1 through x mN represent locally measured values, whereas x 1 through x N represent average estimates, the term z −1 represents a transmission unit delay of one processing cycle.All nodes converge at a "quasi-average" of values based on estimates received from neighboring nodes.As an example, a simplified experiment given here shows the convergence of such quasi-average filters to values that are within an acceptable neighborhood of the true mean of measured values.A vector of real values is input to the system,  = [1,1.5,1.3,1.32],where the first entry denotes  , the second denotes  , and so forth.The filter gain a is chosen within a range of (0.5 ≤ a ≤ 1), the estimates computed are influenced by the value of the filter gain chosen.For this experiment, a= 0.96 and the sampling time T=1×10 -3 seconds.Figure 3b shows the results of such an estimation for a simplified system of four nodes.the blue stems denote actual measured values, the yellow stars represent estimated values and the orange crosses denote actual mean value.Figure 3c shows results of time simulation of this filter study, while the magnified part shows value variation with each sample.It can be observed that there are minor differences between the actual mean value and the estimated averages, the major part of the average converges to the vicinity of the mean value, hence the term "quasi-average" has been used.In a feedback system, the controlled variable values are drawn towards the mean through the proposed control strategy.
These average estimates are used as references for localized droop control according to (8) as shown in Figure 4a, where frequency is proportionally reduced to create an offset from the common angular reference frame; this varies power injected by each unit and achieves active power sharing as shown by Equations ( 8) and (9). .
Where, a is the filter gain of quasi-average estimation observers, N is the number of nodes, i is the present node. is the averaged power exchanged between nodes:  is the average received from the neighbor node, and  is the power measured at node i.

Elaboration: Distributed Estimation of Measured Power through Quasi-Average estimation
This section elaborates the proposed quasi-average estimation method by means of mathematical proof and deduction.Let the measured power at a node i, be represented by xmi, while the estimate of the summation of all node injected powers received from neighboring nodes is given by xƹi.Assuming that measured values xm are a constant vector of arbitrary values, as elaborated in Figure 3, the estimate of summations of powers calculated at nodes 1 and 2 can be given by ( 10) and ( 11) respectively We can write these equations for N nodes as ( 12) and ( 13) ( 1) ( ) ( ) ( ) . As an example, a simplified experiment given here shows the convergence of such quasi-average filters to values that are within an acceptable neighborhood of the true mean of measured values.A vector of real values is input to the system, x m = [1, 1.5, 1.3, 1.32], where the first entry denotes x m1 , the second denotes x m2 , and so forth.The filter gain a is chosen within a range of (0.5 ≤ a ≤ 1), the estimates computed are influenced by the value of the filter gain chosen.For this experiment, a= 0.96 and the sampling time T = 1 × 10 −3 seconds.Figure 3b shows the results of such an estimation for a simplified system of four nodes.the blue stems denote actual measured values, the yellow stars represent estimated values and the orange crosses denote actual mean value.Figure 3c shows results of time simulation of this filter study, while the magnified part shows value variation with each sample.It can be observed that there are minor differences between the actual mean value and the estimated averages, the major part of the average converges to the vicinity of the mean value, hence the term "quasi-average" has been used.In a feedback system, the controlled variable values are drawn towards the mean through the proposed control strategy.
These average estimates are used as references for localized droop control according to (8) as shown in Figure 4a, where frequency is proportionally reduced to create an offset from the common angular reference frame; this varies power injected by each unit and achieves active power sharing as shown by Equations ( 8) and (9).
where, a is the filter gain of quasi-average estimation observers, N is the number of nodes, i is the present node.P εi is the averaged power exchanged between nodes: x εN is the average received from the neighbor node, and x mi is the power measured at node i.
Elaboration: Distributed Estimation of Measured Power through Quasi-Average estimation This section elaborates the proposed quasi-average estimation method by means of mathematical proof and deduction.Let the measured power at a node i, be represented by x mi , while the estimate of the summation of all node injected powers received from neighboring nodes is given by x εi .Assuming that measured values x m are a constant vector of arbitrary values, as elaborated in Figure 3, the estimate of summations of powers calculated at nodes 1 and 2 can be given by ( 10) and ( 11) respectively We can write these equations for N nodes as ( 12) and ( 13) where z −1 represents a unit delay, and [I] N×N represents an N by N Identity matrix converse with the number of N nodes of the system, the matrices [A] N×N and [B] N×N represent IIR filter gains for each node as in equation (13).Writing ( 13) and ( 14) in compact form as (14), With mathematical manipulations ( 15), ( 16) and ( 17) may be obtained For a system of N nodes, Assume that we apply a constant input to each node, the steady state output can be obtained by final value theorem (19), we can now write ( 20) and ( 21) Assuming that, the values measured at every instant are the sum of system average values plus a marginal variation, we may write Equation ( 22) where N is the total number of nodes.By substituting (22) in ( 21), we have, Considering a system of four nodes, the equations (23) yield the estimated averaged values as (24) [ Simplifying for the matrix of estimated values, we may write a 4 + a(x m4 +∆x)(a−1) + a 2 (x m4 +∆x)(a−1) a 4 + a(x m2 +∆x)(a−1) a 4 + a(x m3 +∆x)(a−1) Following from these, we may write, where x m is the average of measured values of power injected by each node into the system and ∆x is the marginal variation in every measured value.The average power estimated at any node in the system converges to the major component of measured values x m whereas the term ∆x → 0 i.e., marginal variations tend towards zero.By approximation, we can say that the estimated value is nearly equal to the average of measured values: From the above elaborative analysis, it can be concluded that for a given value of a within a reasonable range, the proposed method accurately estimates a quasi-average value of measured power at every node in the system, within acceptable limits of being considered a nearly true average.As the proposed control is designed to operate in feedback, the system is collectively drawn towards an early convergence as shown in latter sections of this paper and further verified through system simulations.
For synchrony in notation we may replace the terms x ε by P ε , representing active power average estimate and x m by P m , representing the measured active power.Therefore, Equations (26,27) can now be written as. [ [P εi ] ∼ = P mi (29)

Conventional Consensus Observers
For the sake of completeness, conventional consensus based observes are presented as an alternate for primary power sharing controller is described [20,45].This method renders the average power reference P εi through observation of previous measurements.Such an observer may be described as in (30).
Differentiating with respect to time, we obtain system dynamics .
The system-wide observer dynamics may therefore be formulated as (32) and (33).
where (33) gives the dynamics of the decentralized power estimator used as a comparison benchmark tool to evaluate and verify the effectiveness of the proposed scheme.

Secondary Regulation: Frequency and Voltage
Multiagent consensus-based controls are used for the secondary restoration of voltage magnitude and frequency [40].Figure 2a shows the distributed voltage frequency and voltage restoration control scheme.
Frequency regulation controls can be given as (34).
where, ω re f represents the angular frequency reference, ω oj is the measured angular frequency at nodes in proximity of the i th node.The terms k pf and k if are proportional gain and integral gain as seen in Figure 2a.δω i is the correction factor applied to frequency reference of the i th inverter node.h i is the pinning gain whose value is zero for the primary node.The voltage regulation method can be described by (35): where, v nom is the nominal reference voltage in p.u. for the system, v oj is the voltage measured at all nodes in the communication neighborhood of the node i being considered.The terms k pv and k iv represent proportional and integral gains as shown in Figure 2a.δV i is the voltage correction term applied to the i th inverter node.g i is the pinning gain, whose value is zero for the principal node.

Small Signal Model of the Microgrid System
Small signal models are derived for the MG system as shown in Figure 1.Component-wise state space models of the MG system are described in terms of matrices A, B, C and D [41,42,46].Dynamical equations for the system are perturbed to obtain a corresponding small signal model of the MG system.This section elaborates each one of the model components used in development and analysis of the proposed control scheme.

Fundamental/Zero Level Controls
Voltage and current controls formulated in d-q-0 frame amount to localized, "zero-level" control loops for each of the power converter units as elaborated in Figure 4b,d.Small signal equations for voltage control loop are given as (36) (37), are obtained by perturbing respective dynamical equations around quiescent point [47,48]. where, where, where, K PVi and K IVi are the proportional gain and integral gain of the voltage controller.φ di and φ qi represent auxiliary state variables for these PI controllers.F i is an output feed-back gain.v oqi , v oid , i odi and i oqi are system measurements as seen in Figure 4b,d.Similarly, (38) (39) represent the small signal model for the current control loop at each node as shown in Figure 2d. where, where, where, K PCi and K ICi represent the proportional gain and integral gain of the voltage controller respectively.ς d and ς q are auxiliary state variables for the PI controllers used.I lqi and, I ldi , are system measurements as seen in Figure 2a.

Primary Power Balancing Control
Power balancing controls operate at the primary control level as elaborated in Figure 4a.These can be written in mathematical form as (40) (41) that represent the droop controller.
where, ω i and V 0 represent the nominal references for frequency and voltage of the i th inverter.P i , Q i correspond to active and reactive powers being injected by the i th inverter at output terminals.is the power estimate generated through the proposed quasi-averaging method or alternatively through consensus-based estimators described in Section 4. m Pi and n Qi are droop gains [23].Primary control involves calculating power injected using two-axis theory.For accurately measuring the fundamental power component, low pass filters are used having a cut off frequency of ω ci .The corresponding linearized small signal equations for the power controllers can be written as given by (42).The power controller provides operating frequency for the DGU (ω i ), and reference voltage (v odi * and v oqi *) for voltage control loop. where, where I od , I oq , V od and V oq represent steady state values of i od , i oq , v od , v oq as in Figure 4b,d; ω ci represents the cut-off frequency value for low pass filters employed in the power calculation.
The small signal model of frequency and voltage control are given by (43).
The reference frames of all inverters can be seen with reference to a common reference frame.The angle difference between i th inverter and common frequency reference frame is shown as (44) δ = (ω − ω com )•dt (44) where, ω com is the MG common frequency measured at any one point in the system.The linearized small signal model is given by (45). where, The fractional change in power is represented by the difference between measured and estimated values at any instant.P εi are estimates of active power flowing at node i and P mi are averaged values of measured power calculated through the proposed averaging observers described in Section 3 Equations ( 30) and (31).

Secondary Controls
Secondary control law given in Section 5. Secondary frequency regulation can be given by: where, δw Ai = −k p f (w oi (t) − w oj (t)) Assuming an information transmission delay of time t d , the combined small signal model for frequency regulation can be modelled as per [41] and represented as. [∆δ where, the correction factor perturbations are given by [∆δ .
w Bi ] (50) The perturbations in frequencies can be given by The secondary voltage regulation law can be given by where, Considering an information transmission delay of time t d , the combined small signal model for voltage regulation can be given as The perturbations in voltage correction terms can be given as By adding perturbed correction terms ∆δ .v dqi to the voltage terms [∆ .
v dqi ], we can describe the total variation in voltages by [∆ The variations in line and load currents as well as inverter parameters with these perturbations are now written as Considering the perturbations, the variation in inverter parameters may be described as.

Inverter Grid-side Filters
The small signal model for the LC output filters is given as, The input and output parameters, as seen in Figure 2d may be transformed to a common rotationg d-q-0 reference frame using a transformation matrix T γ , rotating with angular frequency ω com as described in (60) (61).

Model of an Individual Inverter
The components in described previous sections in equations (36) to (61) can be combined to formulate a complete small signal model for the i th distributed generation unit power inverter.This model can be written in suitable and compact form as (62).
where, the state vector is given as (63) The matrices Ainvi, Binvi, Biwcom, Cinwi, Cinvci are provided in the Appendix A.

Combined Model of Inverters
A combined model for N power converters that are connected to the microgrid network is presented as in: (64) to (69).
where the state vector is, And the system matrices can be given as, (67)

. Network and Load Model
A model for the distribution network and system loads is derived through Kirchhoff voltage and current laws and can be expressed in terms of line currents and node voltages as in (70), ( 71) and (72). [∆ where, and,

Complete Model of Micro Grid
Individual component models can be combined to form a small signal model of the complete microgrid system as described by (73-77).The system used here is composed of s = 6 DGUs, n = 6 lines, p = 5 loads, m = 7 nodes.MATLAB Simulink and linear analysis tools have been used to process this complex system. where, where, (77) represents the complete MG system used in this study expressed as a small signal model.The system matrix A MG is given in the Appendix A.

Discretization of System Models
Consider continuous-time state space and output equations of the above described systems: .
where, A csys , B csys , C csys and D csys represent the continuous time representation of the MG systems.
The discrete time state space representation of these equations takes the form: where, the matrices G d , H d ,C d ,D d are discrete-time counterparts for A csys , B csys , C csys and D csys matrices in continuous-time that can be obtained from (80)(81),and (82).
The matrices G d and H d depend on sampling period T. If the sampling period T is fixed, the matrices are constant.Matrices C and D are constant matrices independent of the sampling period T [49].For delay analyses, the time delays are considered to be greater than the sampling period and being integral multiples of the sampling period.

Stability Analysis Studies
A discrete time model of the MG system is presented here, outlined as (79-82).This model is used for system behavioral studies under different scenarios.The proposed averaging model is tested for different values of the IIR averaging gains a and b = (1 − a).Furthermore, communication latencies and control gains are varied to plot the results.Thereby, limits are determined for control parameter variations.The droop gains of power sharing controllers (m Pi , n Qi ) are varied to observe operational limits of the system.Communication time delays for selected link pairs connecting one system node (a 16 , a 61 ) and (a 56 , a 65 ) are varied incrementally to observe the effect produced on system poles and zeros.
Figure 5a-d elaborate the effect of incremental variations in reactive power control gains n Qi and active power gains m Pi .Figure 5a,b show the effect of varying m Pi and n Qi respectively under the proposed distributed power averaging method.For comparison, Figure 5c,d show the effect of variation in m Pi and n Qi under conventional consensus-based power sharing methods.With incrementally increasing control gains each successive plot shows the trend of movement in system poles and zeros.The control values (m Pi , n Qi ), for which the system poles appear in the near vicinity of the unit origin are considered to be maximum allowable limits with regards to system stability.Therefore, system stability, sensitivity towards control gain and behavior are predicted using these pole-zero evolutions.In comparison with the conventional consensus-based power sharing approach, the proposed methodology adds more stability to the MG system under varying primary control gains.Among the two active and reactive power sharing gains, the system is more sensitive towards variations in reactive power gain n Qi than m Pi .the reactive power sharing controls therefore operate over a narrow margin.Table 3 outlines operational limits of control parameters obtained from the analysis.
Electronics 2018, 7, x FOR PEER REVIEW 19 of 30 control gains.Among the two active and reactive power sharing gains, the system is more sensitive towards variations in reactive power gain nQi than mPi. the reactive power sharing controls therefore operate over a narrow margin.Table 3 outlines operational limits of control parameters obtained from the analysis.Pole and zero traces given in Figure 6a,b, elaborate the behavior of this MG system under the influence of incrementally varying time delays with the proposed control scheme.Alternatively, Figure 6c,d elaborate the behavior of the proposed MG system under a conventional consensus-based power sharing approach for incrementally varying time delays.It can be inferred that in comparison with a consensus-based approach, the proposed distributed averaging-based method exhibits more system stability in the presence of communication latencies.The matrices Gd and Hd depend on sampling period T. If the sampling period T is fixed, the matrices are constant.Matrices C and D are constant matrices independent of the sampling period T [49].For delay analyses, the time delays are considered to be greater than the sampling period and being integral multiples of the sampling period.The consensus-based methods are integral methods that achieve consensus by collective error minimization.Communication latencies cause them to develop erroneous local estimates that magnify due to the integral effect of the controllers and the system values diverge.In comparison, the proposed error estimation method is resilient to errors resulting from delayed transmission of measurements and therefore results in a more robust control method that doesn't diverge in the presence of communication latencies.

Case Study simulations
This section presents simulation studies undertaken in MATLAB and Simulink environment developed for stability studies.Possibilities resulting from multiple communication link latencies are considered.To emulate latencies, a time delay of 10ms to 5 seconds is introduced in the two links connecting DGU-6.The control algorithm subsequently strives to achieve equal power sharing along with voltage and frequency restoration.In comparison with consensus-based controls, the distributed average estimation method performs better.Even in the presence of large communication delays, the power sharing between nodes doesn't significantly diverge.Whereas, in consensus-based methods, time delays lead to an observable divergence in controlled parameters.

Active Power Sharing
Compared with a consensus observer-based approach given as (29), two scenarios are considered in this study: the first one has a communication network between nodes forming a complete ring digraph as represented in Figure 2b.All nodes receive information from at least two neighboring nodes.No communication latencies are considered at this stage.Figure 7a shows the results of power sharing with the proposed method and Figure 7b gives the results of power sharing with observer-based control for this scenario.The proposed method achieves power sharing more effectively as compared to the consensus-based method that exhibits measurable mismatch between active power injected by each node.
The second scenario considers dual link latencies leading to an isolated delay of information transmission directed towards and from DGU-6 as shown in Figure 2c. Figure 7c,d compare the results of power sharing under the proposed averaging based method and consensus observer-based control for this scenario.A divergence in injected powers can be observed in case of the consensus-based method.However, the proposed method achieves power sharing within finite time.

Frequency Regulation
This section compares the results of proposed frequency restoration method while working with distributed averaging-based power sharing and consensus-based power sharing schemes.Figure 8a shows the results of frequency restoration under the proposed power sharing method, whereas Figure 8c shows the result of frequency restoration under consensus observer-based method.A time delay can be observed in the presence of link latencies.With the proposed method, system frequency is restored to the desired value in a lesser time duration as compared with the consensus-based method.

Frequency Regulation
This section compares the results of proposed frequency restoration method while working with distributed averaging-based power sharing and consensus-based power sharing schemes.Figure 8a shows the results of frequency restoration under the proposed power sharing method, whereas Figure 8c shows the result of frequency restoration under consensus observer-based method.A time delay can be observed in the presence of link latencies.With the proposed method, system frequency is restored to the desired value in a lesser time duration as compared with the consensus-based method.

Voltage Regulation
The proposed method is compared with consensus observer-based controls.Figure 8b represents voltage restoration under proposed method whereas, Figure 8d shows results of the observer-based scheme.Both methods achieve voltage restoration to desired values.However, the consensus observer-based scheme exhibits more divergence in node voltages during initial two seconds following the startup transient.Meanwhile, distributed power averaging-based method achieves voltage restoration without significant node voltage deviations during this initial time span.

Voltage Regulation
The proposed method is compared with consensus observer-based controls.Figure 8b represents voltage restoration under proposed method whereas, Figure 8d shows results of the observer-based scheme.Both methods achieve voltage restoration to desired values.However, the consensus observer-based scheme exhibits more divergence in node voltages during initial two seconds following the startup transient.Meanwhile, distributed power averaging-based method achieves voltage restoration without significant node voltage deviations during this initial time span.
For the proposed method, all converters in the system reach a consensus of corrective values for P εi , δω i and δV i , thereby, directing overall system power sharing, frequency and voltage to desired values within finite time.However, for the consensus observer-based method the system frequency and voltage take greater time to converge.Overall, the results show that the proposed method adds resilience towards communication delays, wherein accurate power sharing, voltage and frequency restoration is achieved within finite time.

Performance of Controllers under Grid Faults
To present the performance of proposed controls under grid fault, a three-phase fault is introduced at bus-4 for a duration of 0.5 second.The fault parameters are given in Table 4.The performance of primary active power sharing controls as well as frequency and voltage restoration secondary controls are presented in Figure 9. Figure 9a through 9c present the results of power sharing, voltage restoration, and frequency restoration.Whereas 9d shows frequency variations observed at PCC buss 7. It can be observed that once the fault is cleared the proposed controls rapidly recover system values to pre-fault levels.
Electronics 2018, 7, x FOR PEER REVIEW 24 of 30 For the proposed method, all converters in the system reach a consensus of corrective values for  ,  and  , thereby, directing overall system power sharing, frequency and voltage to desired values within finite time.However, for the consensus observer-based method the system frequency and voltage take greater time to converge.Overall, the results show that the proposed method adds resilience towards communication delays, wherein accurate power sharing, voltage and frequency restoration is achieved within finite time.

Performance of Controllers under Grid Faults
To present the performance of proposed controls under grid fault, a three-phase fault is introduced at bus-4 for a duration of 0.5 second.The fault parameters are given in Table 4.The performance of primary active power sharing controls as well as frequency and voltage restoration secondary controls are presented in Figure 9. Figure 9a through 9c present the results of power sharing, voltage restoration, and frequency restoration.Whereas 9d shows frequency variations observed at PCC buss 7. It can be observed that once the fault is cleared the proposed controls rapidly recover system values to pre-fault levels.Fault Resistance Ron 0.001 Ω

Conclusions
An observer aided, decentralized and hierarchical control strategy has been proposed for power sharing between distributed generation units connected to an islanded AC micro-grid.Localized quasi-average power estimators based on the theory of IIR filters are employed to arrive at an estimate of instantaneous power being injected by each node.A multi-agent based secondary control for voltage and frequency regulation is implemented to observe and minimize deviations in key system parameters.A sparse communication network that links all DGUs in the MG system provides media for control signals to flow.The proposed distributed method stabilizes the MG system operation when this supervisory communication layer is experiencing link latencies.Discrete time mathematical small signal models of individual system components are combined to form an MG system model.This model is then used to analyze the performance of the proposed methodology using pole-zero evolutions with regards to system stability and sensitivity towards variations in control parameters.Simulation studies are undertaken to test the effectiveness of the proposed method.A comparison of the proposed method with conventional consensus-based control scheme reveals that the proposed strategy adds resilience to the system against control errors caused by communication link latencies.Even for large delays the system remains stable, which is in stark difference with purely consensus-based methods that show marked divergence in controlled variables once communication latencies are experienced.The mathematical stability analyses and simulation studies further verify the effectiveness of the proposed control methodology for the given scenarios.

Appendix C
Bus Admittance Matrix

Figure 1 .
Figure 1.Power distribution network and proposed hierarchical control.

Figure 1 .
Figure 1.Power distribution network and proposed hierarchical control.

Figure 2 .
Figure 2. Distributed control scheme: (a) Secondary controls at every node (b) Full bi-directional connected ring communication network (c) Ring communication network with isolated dual link latencies.

Figure 2 .
Figure 2. Distributed control scheme: (a) Secondary controls at every node (b) Full bi-directional connected ring communication network (c) Ring communication network with isolated dual link latencies.

Figure 3 .
Figure 3. (a) Distributed averaging at every node (b) Steady state results of quasi-averaging estimates for four node system (c) Time simulation of quasi-averaging estimates for four node system showing individual samples.

Figure 3 .
Figure 3. (a) Distributed averaging at every node (b) Steady state results of quasi-averaging estimates for four node system (c) Time simulation of quasi-averaging estimates for four node system showing individual samples.Electronics 2018, 7, x FOR PEER REVIEW 9 of 30

Figure 5 .
Figure 5. Pole zero plots: (a) Effect of mPi variation with distributed proposed power estimators (b) Effect of nQi variation with proposed power estimators (c) Effect of mPi variation with consensusbased observer (d) Effect of nQi variation with consensus-based observer.

Figure 5 .
Figure 5. Pole zero plots: (a) Effect of m Pi variation with distributed proposed power estimators (b) Effect of n Qi variation with proposed power estimators (c) Effect of m Pi variation with consensus-based observer (d) Effect of n Qi variation with consensus-based observer.

Figure. 6 :Figure 6 .
Figure.6:Comparison of the effect of time delays on system stability: (a) With proposed distributed averaging method(b) With proposed distributed averaging method (magnified) (c) With consensus-based power estimation method (d) With consensus-based power estimation method (magnified).

Figure 7 .
Figure 7. Active power sharing results: (a) Power sharing with proposed method and no link latencies (b) Power sharing with consensus-based control and no link latencies (c) Power sharing with proposed control having link latencies (d) Power sharing with consensus-based control having link latencies.

Figure 7 .
Figure 7. Active power sharing results: (a) Power sharing with proposed method and no link latencies (b) Power sharing with consensus-based control and no link latencies (c) Power sharing with proposed control having link latencies (d) Power sharing with consensus-based control having link latencies.

Figure 8 .
Figure 8.(a) Frequency regulation with proposed scheme (b) Voltage regulation with proposed scheme (c) Frequency regulation with conventional observer-based control (d) Voltage regulation with conventional observer-based control.

Figure 8 .
Figure 8.(a) Frequency regulation with proposed scheme (b) Voltage regulation with proposed scheme (c) Frequency regulation with conventional observer-based control (d) Voltage regulation with conventional observer-based control.

Figure 9 .
Figure 9. Performance of proposed Control Scheme under grid fault (a) Active Power sharing (b) Voltage regulation (c) Frequency regulation of individual inverters (d) Frequency measured at PCC bus.

Table 4 .
Short Circuit Fault Parameters.

Figure 9 .
Figure 9. Performance of proposed Control Scheme under grid fault (a) Active Power sharing (b) Voltage regulation (c) Frequency regulation of individual inverters (d) Frequency measured at PCC bus.

Table 3 .
Variation Range for Controller Parameters.

Table 3 .
Variation Range for Controller Parameters.

Table 4 .
Short Circuit Fault Parameters.