## 3 Control Approach  
A simplified equivalent circuit of two DGs operating in parallel is represented in Figure 5, where their output voltages are \(E_{i}\angle\phi_{i}\ (i=1,\ 2)\) and \(\phi_{i}\) is the voltage phase angle of each DG. The feeder impedance is notated with \(r_{k}+jX_{k}\ (k=1,\ 2)\) and the load integrated with AC grid is shown by \(R+jX\) with voltage \(UL20\). Therefore, the active and reactive power supplied by each DG is determined in (4), respectively. \[ \begin{split}& P_{i}=\frac{1}{|Z_{i}|}\big{(}\big{(}UE_{i}\cos( \phi_{i})-U^{2}\big{)}\cos(\theta_{i})+UE_{i}\sin(\phi_{i})\sin(\theta_{i}) \big{)}\\ & Q_{i}=\frac{1}{|Z_{i}|}\big{(}\big{(}UE_{i}\cos(\phi_{i})-U^{2} \big{)}\sin(\theta_{i})+UE_{i}\sin(\phi_{i})\cos(\theta_{i})\big{)}\end{split}  \tag{4}\]  
Figure 4: The equivalent circuits of a DG; (**a**) grid-connected mode, (**b**) islanding mode. Figure 5: A simplified equivalent circuit of two DGs operating in parallel. where  
\[Z_{i}=r_{i}+jX_{i}\rightarrow\left\{ \begin{array}{l}|Z_{i}|=\sqrt{r_{i}^{2}+X_{i }^{2}}\\ \theta_{i}=\tan^{-1}\Big{(}\frac{\dot{X}_{i}}{r_{i}}\Big{)}\end{array} \right. \tag{5}\]  
Since the inverter impedance is assumed to be resistive and the inductive part is negligible, Equation (4) can be simplified to (6). \[ \begin{array}{l}P_{i}=\frac{1}{r_{i}}\big{(}UE_{i}\cos(\phi_{i})-U^{2}\big{)} \\ Q_{i}=\frac{-1}{r_{i}}\big{(}UE_{i}\sin(\phi_{i})\big{)}\end{array}  \tag{6}\]  
As mentioned in introduction section, the resistive droop controller is structured in (7). \[ \begin{array}{l}E_{i}=E_{i}^{*}+m\big{(}P_{i}^{*}-P_{i}\big{)}\\ f_{i}=f_{i}^{*}-\frac{n}{2\pi}\big{(}Q_{i}^{*}-Q_{i}\big{)}\end{array}  \tag{7}\]  
where \(E_{i}^{*}\) and \(f_{i}^{*}\) are the rated voltage and frequency of the system and the droop constants are called \(m\) and \(n\). In closed loop equivalent circuit of grid connected operation mode, the main purpose is to achieve good power sharing and load current tracking, because the system voltage and frequency references are supplied by the upstream network. Then the principal system equation is mathematically formulated in (8). \[\frac{d}{dt}(i_{o})=-\frac{R_{f}}{L_{f}}i_{o}+\frac{K_{PWM}v_{i}}{L_{f}}-\frac{v_{s}}{L _{f}}+m(t) \tag{8}\]  
Since we want to analyze the general form of system equation, it should be converted to (9). \[\frac{d}{dt}x_{gc}(t)=a\ x_{gc}(t)+b\ u(t)+c\ z(t)+m(t) \tag{9}\]  
where the parameters \(a\), \(b\) and \(c\) are determined by comparing (8) and (9). \(m(t)\) is a bounded distortion applied to the system where \(|m(t)|<\delta\), and \(\delta\) is a positive constant. The error of current tracking is described as \(e_{gc}=i_{o}-i_{ref}\). Therefore, the dynamic sliding surface can be expressed as follow:  
\[ \begin{array}{l}S_{gc}(t)=e_{gc}(t)+k_{1}\int\limits_{0}^{t}e_{gc}(t^{ \prime})dt^{\prime}+k_{2}\frac{d(e_{gc}(t))}{dt}\\ \frac{d}{dt}\big{(}S_{gc}(t)\big{)}=\frac{d\big{(}e_{gc}(t)\big{)}}{dt}+k_{1} e_{gc}(t)+k_{2}\frac{d^{2}(e_{gc}(t))}{dt^{2}}\end{array}  \tag{10}\]  
The coefficients \(k_{1}\) and \(k_{2}\) are positive and the control law is defined as:  
\[ \begin{array}{l}u=u_{o}+u_{sw}\\ u_{o}=-b^{-1}(c_{p}v_{s}+(a+k_{1})e_{gc}+k_{2}\frac{d^{2}\big{(}e_{gc}(t) \big{)}}{dt^{2}}+a\ i_{ref}-\frac{d\big{(}i_{ref}\big{)}}{dt}\\ u_{sw}=-b^{-1}\ \hat{\Upsilon}(t)sign\big{(}S_{gc}(t)\big{)}\end{array}  \tag{11}\]  
where \(u_{o}\) is the control parameter related to the system specifications and \(u_{sw}\) represent the switching control model. The system stability analysis is reported in the next section, however, the observative gain of the system is approximated by (12). \[\hat{\Upsilon}(t)=\frac{1}{\xi_{gc}}\int S_{gc}\big{(}t^{\prime}\big{)}dt^{ \prime}+S_{gc}(t) \tag{12}\]  
where \(\xi_{gc}\) is a positive constant. Subsequently, since the DG is operating in islanding operation mode, the main purpose of control system is to supply the rated voltage and frequency in the allowable range.