*2.1. GCIS Description*

A GCIS is shown in Figure 1. The system contains a PV array, a DC link capacitor, a three-phase voltage source inverter (VSI), and a three-phase grid. The VSI facilitates the MPPT through regulation of the dc-link voltage, along with power transfer to the utility grid.

**Figure 1.** Three-phase grid-connected inverter.

The output power of the PV system is a highly nonlinear and uncertain system. The PV output voltage corresponding to the maximum output power of the PV array varies with cell temperature and solar irradiation. The PV system should always be designed to operate at its maximum output power level. The MPPT technique is usually incorporated with the PV system to adjust the PV array output voltage to obtain the maximum available power at any change in solar irradiation or temperature of the cells. In addition, the MPPT scheme has the capability to release the dc-link voltage reference command [44]. Many MPPT techniques have been reported for PV systems, however, in practice, the most commonly used methods are perturb and observe (P&O) and the incremental conductance (IC) techniques [45].

### *2.2. MIMO Model of GCIS*

The model of the GCIS shown in Figure 1 can be represented by

$$
\upsilon\_{\mathfrak{d}} = R i\_{\mathfrak{d}} + L \frac{d i\_{\mathfrak{a}}}{d t} + \upsilon\_{\mathfrak{J}^{\mathfrak{a}}} \tag{1}
$$

$$
\omega\_b = R i\_b + L \frac{d i\_b}{d t} + \upsilon\_{\mathcal{g}b} \tag{2}
$$

$$
\upsilon\_c = R i\_c + L \frac{d i\_c}{d t} + \upsilon\_{\mathcal{S}^c} \tag{3}
$$

where *vga*, *vgb*, *vgc* are the grid voltage components, *ia*, *ib*, *ic* are the grid current components, and *va*, *vb*, *vc* are the inverter output voltage [46]. Park's transformation is used to represent Equations (1)–(3) in the rotating *dq* frame as

$$
\omega \upsilon\_d = \upsilon\_{\mathcal{S}^d} + R \dot{\imath}\_d + L \frac{d \dot{\imath}\_d}{dt} + \omega L \dot{\imath}\_q \tag{4}
$$

$$
\omega\_q = \upsilon\_{\mathcal{S}^q} + R i\_q + L \frac{d i\_q}{d t} + \omega L i\_d \tag{5}
$$

where *vgd*, *vgq* are the *dq* grid voltage components, *id*, *iq* are the *dq* grid current components, and *vd*, *vq* are the *dq* inverter output voltage components. Upon neglecting the power loss in the inverter switches [46], the dc-input side connection with the ac-output side are given by

$$
\upsilon\_{\mathcal{S}^d} i\_d + \upsilon\_{\mathcal{S}^q} i\_{\emptyset} = \upsilon\_{dc} i\_{dc} \tag{6}
$$

$$\mathbb{C}\frac{d\upsilon\_{dc}}{dt} = i\_{pv} - i\_{dc} = i\_{pv} - \frac{\upsilon\_{\mathcal{S}^d} i\_d + \upsilon\_{\mathcal{S}^q} i\_q}{\upsilon\_{dc}} \tag{7}$$

where *vdc* and *ipv* are the PV output voltage and current respectively and *idc* is the input current to the inverter.

Defining the state vector *x* and the control input *u* as

$$\mathbf{x} = \begin{bmatrix} \mathbf{x}\_1 \\ \mathbf{x}\_2 \\ \mathbf{x}\_3 \end{bmatrix} = \begin{bmatrix} i\_d \\ i\_q \\ v\_{dc} \end{bmatrix} \tag{8}$$

$$\boldsymbol{u} = \begin{bmatrix} \boldsymbol{u}\_1 \\ \boldsymbol{u}\_2 \end{bmatrix} = \begin{bmatrix} \boldsymbol{v}\_d \\ \boldsymbol{v}\_q \end{bmatrix} \tag{9}$$

Then, the state model of the GCIS can be formed as in Equation (10).

$$\dot{\mathbf{x}} = \begin{bmatrix} -\frac{R}{L}\mathbf{x}\_1 + \omega \mathbf{x}\_2 - \frac{v\_{gd}}{v\_{\perp}^\prime} \\ -\frac{R}{L}\mathbf{x}\_2 - \omega \mathbf{x}\_1 - \frac{v\_{gq}^\prime}{L} \\ \frac{i\_{pv}}{C} - \frac{v\_{gd}\mathbf{x}\_1 + v\_{gq}\mathbf{x}\_2}{C\mathbf{x}\_3} \end{bmatrix} + \begin{bmatrix} \frac{1}{L} & 0 \\ 0 & \frac{1}{L} \\ 0 & 0 \end{bmatrix} u \tag{10}$$

The control objective is to regulate the power factor of the grid, through the qcomponent of the grid current, and the dc-input voltage *vdc*. Therefore, the output vector of the system is considered as

$$\begin{bmatrix} y = \begin{bmatrix} y\_1 \\ y\_2 \end{bmatrix} = \begin{bmatrix} x\_2 \\ x\_3 \end{bmatrix} = \begin{bmatrix} i\_q \\ v\_{\rm dc} \end{bmatrix} \tag{11}$$

The Equations (10) and (11) can be written in the following general expression of the MIMO system

$$
\dot{\mathbf{x}} = f(\mathbf{x}) + \mathbf{g}(\mathbf{x})\mathbf{u}, \ y = h(\mathbf{x}) \tag{12}
$$

where *x* is a 3 × 1 state vector, *u* is a 2 × 1 control input vector, *y* is a 2 × 1 output vector, and *f*(*x*) and *g*(*x*) are defined by

$$\begin{aligned} f \quad = \begin{bmatrix} f\_1 \\ f\_2 \\ f\_3 \end{bmatrix} = \begin{bmatrix} -\frac{\mathbb{R}}{L} \mathbf{x}\_1 + \omega \mathbf{x}\_2 - \frac{\mathbb{V}\_{\mathcal{S}}}{L} \\ -\frac{\mathbb{R}}{L} \mathbf{x}\_2 - \omega \mathbf{x}\_1 - \frac{\mathbb{V}\_{\mathcal{S}\mathcal{S}}}{L} \\ \frac{\mathbb{V}\_{\mathcal{V}}}{\mathbb{C}} - \frac{\mathbb{V}\_{\mathcal{S}} \mathbf{x}\_1 + \mathbf{v}\_{\mathcal{S}} \mathbf{x}\_2}{\mathbb{C} \mathbf{x}\_3} \end{bmatrix}, \text{ g } = \begin{bmatrix} \frac{1}{L} & 0 \\ 0 & \frac{1}{L} \\ 0 & 0 \end{bmatrix} \end{aligned} \tag{13}$$

The MIMO model of the GCIS in Equations (12) and (13) can be converted to a feedback linearizable form by using the input-output feedback linearization approach. In this approach, a nonlinear control signal is designed and used to convert the nonlinear system dynamics Equation (12) into decoupled linear subsystems. The feedback linearization for GCIS is presented next.

#### *2.3. Input-Output Feedback Linearization of GCIS*

In order to design a feedback linearization control, we used the notion of relative degree where each output is differentiated successively until one input *u*1 or *u*2 appears [47]. It can be shown that the relative degree *r*1 for the first output *y*1 is *r*1= 1 and the relative degree *r*2 for the second output *y*2 is *r*2= 2. The first derivative of *y*1 and the second derivative of *y*2 are given by Equations (14) and (15).

$$
\dot{y}\_1 = f\_2 + \frac{1}{L} u\_2 \tag{14}
$$

$$\ddot{y}\_2 = \dot{f}\_3 = \frac{1}{\mathbb{C}} \frac{d\dot{t}\_{pv}}{dt} - \frac{1}{\mathbb{C}.x\_3} \left[ v\_{\mathbb{S}d} \left( f\_1 + \frac{1}{L} u\_1 \right) + v\_{\mathbb{S}q} \left( f\_2 + \frac{1}{L} u\_2 \right) \right] + \frac{\left( v\_{\mathbb{S}d} x\_1 + v\_{\mathbb{S}q} x\_2 \right)}{\mathbb{C}x\_3^2} f\_3 \tag{15}$$

Equations (14) and (15) can be cast in the following matrix form

$$
\begin{bmatrix}
\dot{\Psi}\_1\\\ddot{\Psi}\_2
\
\end{bmatrix} = \alpha(\mathbf{x}) + \beta(\mathbf{x}) \begin{bmatrix}
u\_1\\u\_2
\
\end{bmatrix} \tag{16}
$$

where

$$\mathbf{a}(\mathbf{x}) = \begin{bmatrix} f\_2 \\ m - \frac{1}{\mathbb{C} \mathbf{x}\_3} \left( \upsilon\_{\mathcal{S}\mathcal{S}} f\_1 + \upsilon\_{\mathcal{S}\mathcal{S}} f\_2 \right) + \frac{\left( \upsilon\_{\mathcal{S}\mathcal{S}} x\_1 + \upsilon\_{\mathcal{S}\mathcal{S}} x\_2 \right)}{\mathbb{C} x\_3^2} f\_3 \end{bmatrix} \tag{17}$$

$$\beta(x) = \begin{bmatrix} 0 & \frac{1}{L} \\ -\frac{v\_{gd}}{LCx\_3} & -\frac{\tilde{v}\_{gy}}{LCx\_3} \end{bmatrix} \tag{18}$$

and *m* = 1*C dipv dt* .

The control law in Equation (19) when used in Equation (16) yields to the linear input-output relation in Equation (20)

$$
\begin{bmatrix} u\_1 \\ u\_2 \end{bmatrix} = \beta^{-1}(\mathbf{x}) \begin{bmatrix} v\_1 - \alpha\_1 \\ v\_2 - \alpha\_2 \end{bmatrix} \tag{19}
$$

$$
\begin{bmatrix}
\dot{y}\_1\\\dot{y}\_2
\end{bmatrix} = \begin{bmatrix}
v\_1\\v\_2
\end{bmatrix} \tag{20}
$$

where *v*1 and *v*2 are external signals that can be chosen in a way to ensure asymptotic tracking of the outputs *y*1 and *y*2 to their references *yref* 1<sup>=</sup> *iqre f* and *yref* 2<sup>=</sup> *vdcre f* . Defining the tracking errors *e*1 = *yref* 1− *y*1 and *e*2 = *yref* 2− *y*2 , the signals *v*1 and *v*2 can be selected as

$$
\omega\_1 = k\_{01}\varepsilon\_1 + \dot{y}\_{ref1} \tag{21}
$$

$$
v\_2 = k\_{02}e\_2 + k\_{12}\dot{e}\_2 + \ddot{y}\_{ref2} \tag{22}$$

Now, substituting Equations (21) and (22) into Equation (20), we obtain the following tracking errors dynamics:

$$
\dot{e}\_1 + k\_{01}e\_1 = 0 \tag{23}
$$

$$
\ddot{e}\_2 + k\_{12}\dot{e}\_2 + k\_{02}e\_2 = 0\tag{24}
$$

The coefficients *k*01, *k*02, and *k*12 are design parameters selected such that the characteristic polynomials of Equations (23) and (24) are Hurwitz and hence ensuring that

the tracking errors *e*1 and *e*2 converge to zero asymptotically [47]. It is worth mentioning that the control law given in Equation (19) is implementable since the matrix *β*(*x*) is non-singular, provided that *ed* = 0 (which is the case for GCIS).

A main disadvantage of the control law in Equation (19) is that the exact values of the system parameters involved in *α*(*x*) and *β*(*x*) should be known and any change in the parameters affects the output of the controller. In practice, the parameters of the GCIS may be unknown or imprecise and the uncertainty in these parameters is inevitable. To overcome this drawback, the universal approximation capability of the fuzzy systems is used to approximate the nonlinear functions *α*(*x*) and *β*(*x*). In the next section, the proposed adaptive fuzzy controller for GCIS is presented.

## **3. The Proposed Controller**

#### *3.1. Adaptive Fuzzy Approximation Controller for GCIS*

In this section, the proposed controller is developed using the Equation (12) which is a square MIMO nonlinear system. The input-output feedback linearization given in Equation (16) with *r*1= 1 and *r*2= 2 can be written in the form

$$y^{(r)} = a(\mathbf{x}) + \beta(\mathbf{x})u \tag{25}$$

where *y*(*r*) = *y* (*<sup>r</sup>*1) 1 *y* (*<sup>r</sup>*2) 2 = . *y*1 .. *y*2 , *u* = *u*1 *u*2 , *α*(*x*) and *β*(*x*) are as given in Equations (17) andandtheirentriesinnonlinearfunctionswith

 (18), are general imprecise parameters.

Approximations of the nonlinear functions *α*(*x*) and *β*(*x*) were generated using a fuzzy logic system with singleton fuzzifier, product inference rule, and weighted average defuzzifier. To construct these estimates, the notion of the fuzzy basis function (FBF) expansion *ξ*(*x*) was used [37]. The fuzzy estimates *<sup>a</sup>*<sup>ˆ</sup>*i*(*x*) and *β*<sup>ˆ</sup>*ij*(*x*) of the nonlinear functions *<sup>α</sup>i*(*x*) and *βij*(*x*), *i* = 1, 2 and *j* = 1, 2 were determined as

$$\mathfrak{d}\_{\mathfrak{i}}(\mathfrak{x}) = \theta\_{\mathfrak{i}}^{\,T} \mathfrak{j}(\mathfrak{x}) \tag{26}$$

$$\beta\_{ij}(\mathbf{x}) = \theta\_{ij}{}^T \zeta(\mathbf{x}) \tag{27}$$

where *θi* ∈ *R M*×1 and *θ*ij ∈ *R M*×1 represent vectors of adjustable parameters and *ξ*(*x*) ∈ *R M*×1 represents the vector of FBFs. The FBF was generated using the weighted-average defuzzifier [48].

$$f\_{i^l}^{\alpha}(\mathbf{x}) = \frac{\prod\_{i=1}^{n} \boldsymbol{\pi}\_i \ \boldsymbol{\mu}\_{il}(\mathbf{x}\_i)}{\sum\_{l=1}^{M} (\prod\_{i=1}^{n} \boldsymbol{\mu}\_{il}(\mathbf{x}\_i))} \tag{28}$$

where *n* is the number of states, *μil*(*<sup>x</sup> i* ) is the membership function of the *ith* state *xi* in the *lth* rule, and *M* is the number of If-Then rules.

Upon replacing *α*(*x*) and *β*(*x*) in Equation (25) by their corresponding fuzzy estimates Equations (26) and (27), we ge<sup>t</sup>

$$y^{(r)} = \mathbb{A}(\mathbf{x}) + \beta(\mathbf{x})u \tag{29}$$

where *α*<sup>ˆ</sup>(*x*) = *α*ˆ 1 *α*ˆ 2 and *β*<sup>ˆ</sup>(*x*) = *β*ˆ11 *β*ˆ12 *β*ˆ21 *β*ˆ22 

Therefore, the AFC can be written in terms of the fuzzy estimates Equations (26) and (27) as

.

$$
\mu = \hat{\beta}^{-1}(\mathbf{x}) \left( y\_{ref}^{(r)} + \mathbf{K}\mathbf{z} - \hat{\mathbf{a}}(\mathbf{x}) \right) \tag{30}
$$

where *y* (*r*) *ref* = *y* (*<sup>r</sup>*1) *ref* 1 *y* (*<sup>r</sup>*2) *ref* 2 *T* , *K* = *diag*[*k*1 *k*2 ], *e* = *e* 1 *e* 2 *T* , *k*1 = *k*01, *k*2 = [*k* 02 *k*12], *e* 1 = *e*1, *e* 2 = [*e* 2 . *e*2 , and *ei* = *yrefi* −*yi* , *i* = 1, 2. It is worth mentioning that the implementation

of the proposed AFC given in Equation (30) needs only the fuzzy estimates *α*<sup>ˆ</sup>(*x*) , *β*<sup>ˆ</sup>(*x*) , the derivatives of the reference signal *y*(*r*) *ref* , and the tracking error *e*.
