3. Data-driven and model-based designs

where the variable r represents the air density and A is the effective rotor area. Another

with R the rotor radius. Cp(�) represents the power coefficient that is normally represented via a two-dimensional map [10]. The expression of Eq. (1) allows the computation of the signal τaero(t), by means of the estimated wind speed v(t), and the measured β(t) and ωr(t). Due to the uncertainty of the wind speed, the estimate of τaero(t) is considered affected by an unknown measurement error, which justifies the robust approaches described in Section 3. Moreover, the nonlinearity represented by the expressions of Eqs. (1) and (2) motivates the required reliable

A two-mass model is exploited to describe the drive-train system, while the hydraulic pitch system is modelled as second-order transfer function [10]. Moreover, the generator dynamics are described as a first-order transfer function. More details regarding the considered simulator are in Odgaard et al. [10]. Under these assumptions, the complete state-space description of

x\_ <sup>c</sup>ðÞ¼ t f <sup>c</sup>ð Þ xcð Þt ; u tð Þ

where u(t)=[β(t), τg(t)]<sup>T</sup> and y(t) = xc(t)=[Pg(t), ωg(t)]<sup>T</sup> are the control inputs and the monitored output measurements, respectively, as shown in Figure 1. Pg(t) is the generator power measurement, whereas fc(�) represents the continuous-time nonlinear function that will be approximated via discrete-time models from N sampled data uk and yk, with the sample index k = 1, 2, …N, as presented in Section 3. Finally, the model parameters and the map Cp(β, λ) are chosen

As described in Odgaard et al. [10], the baseline controller developed for this wind turbine system works in two normal operating conditions, namely, the region 1 corresponding to the power optimisation (partial load) and the region 2 of constant power production (full load). The partial load working condition (also known as working region 1), the optimal wind-power conversion is achieved without any pitching of the blades, which are fixed to 0�. In this case, λ is constant at its optimal value λopt that is defined by the maximal value of the power coefficient map Cp when β = 0. Therefore, this working condition is completely defined by setting τ<sup>g</sup> = τ<sup>r</sup> (i.e. the generator torque is equal to the reference one) with pitch angle β = 0.

<sup>τ</sup><sup>r</sup> <sup>¼</sup> Kopt <sup>ω</sup><sup>2</sup>

<sup>2</sup> <sup>r</sup>AR<sup>3</sup> Cpmax λ3 opt

Kopt <sup>¼</sup> <sup>1</sup>

with Cpmax the maximal value of Cp, related the to λopt, i.e. the optimal tip-speed ratio.

y tðÞ¼ xcð Þt

ωrð Þt R

v tð Þ (2)

<sup>r</sup> (4)

(3)

(5)

important variable is represented by the so-called tip-speed ratio, which is defined as

λðÞ¼ t

and robust control approaches suggested in this chapter.

the wind turbine model has the form of Eq. (3):

220 Adaptive Robust Control Systems

in order to represent a realistic turbine [10].

where:

The reference torque τ<sup>r</sup> shown in Figure 1 can be written as

This section describes the two approaches considered in this chapter for obtaining the control laws by using data-driven and model-based methodologies. Once a suitable mathematical description of the monitored process is provided, the derivation of the controller structure is sketched in Section 3.1 for the fuzzy approach, whereas Section 3.2 proposes a different method relying on an adaptive technique.

The first method proposed in this chapter for the derivation of the wind turbine controller is based on a fuzzy clustering technique to partition the available data into subsets characterised by linear behaviours. The integration between clusters and linear regression is exploited, thus allowing for the combination of fuzzy logic techniques with system identification methodologies. These tools are already available and implemented in the Matlab® Fuzzy Modelling and Identification (FMID) toolbox recalled below [5]. This study proposes the use of TS fuzzy prototypes since they are able to model nonlinear dynamic systems with arbitrary accuracy [5]. The switching between the local affine submodels is achieved through a smooth function of the system state defined exploiting the fuzzy set theory and its tools.

In more detail, the fuzzy estimation scheme relies on a two-step algorithm, in which the working regions are first defined by exploiting the data fuzzy clustering tool, i.e. the Gustafson-Kessel (GK) method [5]. On the other hand, the second step performs the identification of the controller structure and its parameters using the estimation method proposed by the same authors in Simani et al. [6]. This estimation approach can be considered as a generalisation of the general least-squares method for hybrid models.

Under these assumptions, the TS fuzzy prototypes have the form of the model of Eq. (8):

$$\begin{aligned} y\_{k+1} &= \frac{\sum\_{i=1}^{M} \mu\_i(\mathbf{x}\_k) y\_i}{\sum\_{i=1}^{M} \mu\_i(\mathbf{x}\_k)} \end{aligned} \tag{8}$$

G zð Þ¼ A z�<sup>1</sup> � �

) and B(z

The parameter vector describing the linear relationship is given by

�1

�1

whose extended version is defined as in Eq. (11):

defining the polynomials A(z

notations, in the form of Eq. (12):

where the regressor vector ψ<sup>k</sup> is defined as

where the subscript k denotes the sample index.

where the noise covariance matrix is given by

Σ<sup>ψ</sup> � Σψ<sup>~</sup> � � B z�<sup>1</sup> ð Þ <sup>¼</sup> <sup>b</sup><sup>1</sup> <sup>z</sup>�<sup>1</sup> <sup>þ</sup> … <sup>þ</sup> bnb <sup>z</sup>�nb

where ai, bi, na and nb represent the unknown parameters and the structure of the model,

θ ¼ a1…ana b1…bnb

An equivalent expression of the considered relations is obtained by using vector and matrix

ψT

<sup>ψ</sup><sup>k</sup> ¼ �yk � yk�<sup>1</sup>… � yk�na uk�<sup>1</sup>…uk�nb h i<sup>T</sup>

The Frisch scheme provides the estimates of the measurement errors affecting the input and output signals uk and yk, i.e. σ<sup>u</sup> and σy, and θ for a linear time-invariant dynamic system. Note that the polynomial orders na and nb in the relation of Eq. 9 are assumed to be fixed in advance.

> � θ ¼ 0

0 σ<sup>u</sup> Inb

k¼1

Thus, the Frisch scheme aims at providing suitable noise variances σ<sup>u</sup> and σ<sup>y</sup> such that

<sup>ψ</sup>kψ<sup>T</sup>

results to be a matrix singular positive semidefinite as it is rank-one deficient. On

" #

Σ<sup>ψ</sup> � Σψ<sup>~</sup>

<sup>Σ</sup>ψ<sup>~</sup> <sup>¼</sup> <sup>σ</sup><sup>y</sup> Inaþ<sup>1</sup> <sup>0</sup>

<sup>Σ</sup>ψ<sup>~</sup> <sup>≈</sup> <sup>1</sup> N X N

From the Frisch scheme method, the following expression is considered:

which are approximated by the sample covariance matrix over N samples:

�

1 þ a<sup>1</sup> z�<sup>1</sup> þ … þ ana z�na

), while z is the discrete-time complex variable.

Robust Control Applications to a Wind Turbine-Simulated System

http://dx.doi.org/10.5772/intechopen.71526

� �<sup>T</sup> (10)

<sup>θ</sup> <sup>¼</sup> <sup>1</sup> <sup>θ</sup><sup>T</sup> � �<sup>T</sup> (11)

<sup>k</sup> θ ¼ 0 (12)

<sup>k</sup> (16)

(9)

223

(13)

(14)

(15)

where yi <sup>¼</sup> aT <sup>i</sup> x þ bi, with ai the parameter vector (regressand) and bi is the scalar offset. x = xk represents the regressor vector, which contains delayed samples of the signals uk and yk.

The antecedent fuzzy sets μ<sup>i</sup> that determine the switching among the different submodels i are estimated from the data clusters [5]. The consequent parameters ai and bi are identified from the data by means of the methodology proposed in Simani et al. [6]. This identification scheme exploited for the estimation of the TS model parameters has been integrated into the FMID toolbox for Matlab® by the authors. This approach is preferable when the TS model of Eq. (8) is used as predictor, since it derives the consequent parameters via the so-called Frisch scheme, developed for the errors-in-variables (EIV) structures [6].

Once the description of the monitored process is obtained in the form of Eq. (8), the data-driven approach for the design of the fuzzy controller proposed in this chapter is presented in Section 3.1.

The second approach exploited for obtaining the mathematical description of the wind turbine system under investigation is based on a recursive methodology, which will be used for the design of the second control strategy presented in Section 3.2. An online version of the batch Frisch scheme estimation methodology summarised above is recalled in the remainder of this section for estimating the parameters of dynamic EIV models. For the derivation of the adaptation law, an online bias-compensating algorithm is also implemented. Thus, the online Frisch scheme estimation is generalised to enhance its applicability to real-time implementations. Moreover, by means of an exponential forgetting factor included in the adaptation law, the algorithm is able to deal with linear parameter-varying (LPV) structures that are exploited in connection with the model-based design of the adaptive control scheme, presented in Section 3.2.

Thus, the considered scheme is proposed for the online identification of the process modelled by the following transfer function G(z):

$$\mathcal{G}(\mathbf{z}) = \frac{A\left(\mathbf{z}^{-1}\right)}{B(\mathbf{z}^{-1})} = \frac{b\_1 z^{-1} + \dots + b\_{n\_b} z^{-n\_b}}{1 + a\_1 z^{-1} + \dots + a\_{n\_b} z^{-n\_a}}\tag{9}$$

where ai, bi, na and nb represent the unknown parameters and the structure of the model, defining the polynomials A(z �1 ) and B(z �1 ), while z is the discrete-time complex variable.

The parameter vector describing the linear relationship is given by

$$\boldsymbol{\Theta} = \begin{bmatrix} \boldsymbol{a}\_1 \dots \boldsymbol{a}\_{n\_a} \ b\_1 \dots \ b\_{n\_b} \end{bmatrix}^T \tag{10}$$

whose extended version is defined as in Eq. (11):

Identification (FMID) toolbox recalled below [5]. This study proposes the use of TS fuzzy prototypes since they are able to model nonlinear dynamic systems with arbitrary accuracy [5]. The switching between the local affine submodels is achieved through a smooth function of the

In more detail, the fuzzy estimation scheme relies on a two-step algorithm, in which the working regions are first defined by exploiting the data fuzzy clustering tool, i.e. the Gustafson-Kessel (GK) method [5]. On the other hand, the second step performs the identification of the controller structure and its parameters using the estimation method proposed by the same authors in Simani et al. [6]. This estimation approach can be considered as a general-

Under these assumptions, the TS fuzzy prototypes have the form of the model of Eq. (8):

represents the regressor vector, which contains delayed samples of the signals uk and yk.

P M i¼1 μi ð Þ xk yi

P M i¼1 μi ð Þ xk

The antecedent fuzzy sets μ<sup>i</sup> that determine the switching among the different submodels i are estimated from the data clusters [5]. The consequent parameters ai and bi are identified from the data by means of the methodology proposed in Simani et al. [6]. This identification scheme exploited for the estimation of the TS model parameters has been integrated into the FMID toolbox for Matlab® by the authors. This approach is preferable when the TS model of Eq. (8) is used as predictor, since it derives the consequent parameters via the so-called Frisch scheme,

Once the description of the monitored process is obtained in the form of Eq. (8), the data-driven approach for the design of the fuzzy controller proposed in this chapter is presented in Section 3.1. The second approach exploited for obtaining the mathematical description of the wind turbine system under investigation is based on a recursive methodology, which will be used for the design of the second control strategy presented in Section 3.2. An online version of the batch Frisch scheme estimation methodology summarised above is recalled in the remainder of this section for estimating the parameters of dynamic EIV models. For the derivation of the adaptation law, an online bias-compensating algorithm is also implemented. Thus, the online Frisch scheme estimation is generalised to enhance its applicability to real-time implementations. Moreover, by means of an exponential forgetting factor included in the adaptation law, the algorithm is able to deal with linear parameter-varying (LPV) structures that are exploited in connection with the model-based design of the adaptive control scheme, presented in Section 3.2. Thus, the considered scheme is proposed for the online identification of the process modelled

<sup>i</sup> x þ bi, with ai the parameter vector (regressand) and bi is the scalar offset. x = xk

(8)

ykþ<sup>1</sup> <sup>¼</sup>

system state defined exploiting the fuzzy set theory and its tools.

isation of the general least-squares method for hybrid models.

developed for the errors-in-variables (EIV) structures [6].

by the following transfer function G(z):

where yi <sup>¼</sup> aT

222 Adaptive Robust Control Systems

$$\overline{\boldsymbol{\theta}} = \begin{bmatrix} \boldsymbol{1} \ \boldsymbol{\theta}^{\mathsf{T}} \end{bmatrix}^{\mathsf{T}} \tag{11}$$

An equivalent expression of the considered relations is obtained by using vector and matrix notations, in the form of Eq. (12):

$$
\psi\_k^T \overline{\theta} = 0 \tag{12}
$$

where the regressor vector ψ<sup>k</sup> is defined as

$$\boldsymbol{\psi}\_{k} = \begin{bmatrix} -y\_{k} - y\_{k-1} \dots - y\_{k-n\_{a}} \boldsymbol{u}\_{k-1} \dots \boldsymbol{u}\_{k-n\_{b}} \end{bmatrix}^{T} \tag{13}$$

where the subscript k denotes the sample index.

The Frisch scheme provides the estimates of the measurement errors affecting the input and output signals uk and yk, i.e. σ<sup>u</sup> and σy, and θ for a linear time-invariant dynamic system. Note that the polynomial orders na and nb in the relation of Eq. 9 are assumed to be fixed in advance.

From the Frisch scheme method, the following expression is considered:

$$\left(\Sigma\_{\psi} - \Sigma\_{\bar{\psi}}\right)\overline{\Theta} = \mathbf{0} \tag{14}$$

where the noise covariance matrix is given by

$$
\Sigma\_{\bar{\psi}} = \begin{bmatrix}
\sigma\_y I\_{n\_\text{u}+1} & 0 \\
0 & \sigma\_u I\_{n\_\text{b}}
\end{bmatrix} \tag{15}
$$

which are approximated by the sample covariance matrix over N samples:

$$\Sigma\_{\bar{\psi}} \approx \frac{1}{N} \sum\_{k=1}^{N} \psi\_k \psi\_k^T \tag{16}$$

Thus, the Frisch scheme aims at providing suitable noise variances σ<sup>u</sup> and σ<sup>y</sup> such that Σ<sup>ψ</sup> � Σψ<sup>~</sup> � � results to be a matrix singular positive semidefinite as it is rank-one deficient. On the other hand, the system represented by the expression of Eq. (14) can be solved, and θ represents its solution.

The expression of Eq. (17) is determined:

$$\varepsilon\_k(\overline{\theta}) = A\{z^{-1}\} y\_k - B\{z^{-1}\} u\_k \tag{17}$$

forgetting the older ones. Therefore, the methodology represented by the expressions of Eqs. (19) and (21) with the approximation of Eq. (20) is implemented by including the socalled exponential forgetting factor. This is achieved in practice by defining the new expres-

¼ ω δð ÞΣ~ψ<sup>k</sup>

<sup>þ</sup> δψkψ<sup>T</sup> k

� �ε<sup>k</sup>þ<sup>h</sup> <sup>θ</sup><sup>k</sup>

� �

Robust Control Applications to a Wind Turbine-Simulated System

http://dx.doi.org/10.5772/intechopen.71526

(22)

225

(23)

hεh, <sup>k</sup> ¼ ω δð Þrεh, <sup>k</sup>

where ω(δ) is a scaling factor that coincides with k when no adaptation is introduced. In this

with 0 < δ < 1 representing the forgetting factor. Thus, the adaptive Frisch scheme algorithm is implemented via Eq. (23) in three steps. First, θ0, Σψ<sup>~</sup> <sup>0</sup> and rε0, <sup>h</sup> with h ≤ na are initialised. Moreover, at each recursion step, by means ofrεh, <sup>k</sup>, the noise variances σ<sup>u</sup> and σ<sup>y</sup> are computed. Finally, at each recursion step, θ<sup>k</sup> is determined by solving Eq. (14) via the expression of Eq. (23). In this

The results achieved by the online identification method recalled in this section were obtained

Finally, once the parameters θ<sup>k</sup> of the discrete-time linear time-varying model of the nonlinear dynamic process of Eq. (3) have been computed at each time step k, the adaptive controller is

This section describes the derivation of the fuzzy controller model. Once a reasonably accurate fuzzy description of the considered benchmark has been available, as described above, it is used offline to directly estimate the nonlinear fuzzy controllers. As already remarked, this design procedure differs from the approach proposed in Simani [11]. In fact, the control design proposed in this chapter relies on the so-called model inverse control principle, which is solved

With reference to stable fuzzy systems, whose inverted dynamics are also stable, a nonlinear controller can be simply designed by inverting the fuzzy model itself. Moreover, when modelling errors and disturbances are not present, this controller is able to allow for exact tracking with zero steady-state errors. However, modelling errors and disturbance effects are always present in real conditions, which can be tackled by directly identifying the controller model (i.e. the inverse controlled model) using the FMID approach. Differently from Simani [11], a robust control strategy is thus achieved by minimising a cost function, which includes the difference between the desired and controller outputs, and a penalty on the system stability. In general, a nonconvex optimisation problem has to be solved, which hampers the direct

sions of the sample covariance and autocovariance matrices in the form of Eq. (22):

(

way, the updated expressions have the form:

derived as summarised in Section 3.2.

3.1. Data-driven fuzzy controller derivation

suing the fuzzy identification approach recalled above.

<sup>H</sup><sup>Σ</sup>~<sup>ψ</sup><sup>k</sup>

8 < : <sup>H</sup><sup>Σ</sup>~ψ<sup>k</sup>

<sup>¼</sup> ð Þ <sup>1</sup> � <sup>δ</sup> <sup>H</sup><sup>Σ</sup>~<sup>ψ</sup>k�<sup>1</sup>

way, the vector θ<sup>k</sup> contains the estimates of the model parameter derived at the step k.

in the Matlab® and Simulink® environments as summarised in Section 4.

hεh, <sup>k</sup> ¼ ð Þ 1 � δ hεh, <sup>k</sup>�<sup>1</sup> þ δε<sup>k</sup> θ<sup>k</sup>

while the so-called sample autocovariance is defined in the form of Eq. (18):

$$r\_{\varepsilon h, N} = \frac{1}{N} \sum\_{l=1}^{N} \varepsilon\_l(\overline{\boldsymbol{\Theta}}) \, \varepsilon\_{l+h}(\overline{\boldsymbol{\Theta}}) \tag{18}$$

where the subscript h in Eq. (18) indicates a time-shift.

The online control development requires a recursive estimate of the model parameters represented by the vector θ<sup>k</sup> of Eq. (9), while the input and output data uk and yk acquired online by the dynamic process of the wind turbine system. In fact, the adaptive control law computed at time step k is based on the recursive estimate of a model of the process, which is derived exploiting the dynamic data up to the sample k. In this way, the algorithm of the Frisch scheme defined by the expressions of Eqs. (14), (16) and (18) is expressed by means of an online scheme.

Note that the expressions of Eqs. (16) and (18) are required in their recursive form. Therefore, while the derivation of the online form of the covariance matrix update is easily obtained as in the form of Eq. (19):

$$
\Sigma\_{\bar{\psi}k} = \frac{k-1}{k} \Sigma\_{\bar{\psi}k} + \frac{1}{k} \psi\_k \psi\_k^T \tag{19}
$$

the formulation of the autocovariance expression rεh, <sup>k</sup> can be obtained recursively for 1 ≤ l ≤ k only if the approximated expression of Eq. (20) is considered:

$$
\varepsilon\_l(\overline{\Theta}\_k) \approx \varepsilon\_l(\overline{\Theta}\_l) \tag{20}
$$

for l < k. In this way, only the residual ε<sup>k</sup> θ<sup>k</sup> � � has to be computed at time step k using the lagged data in the vector ψ<sup>k</sup> and the updated estimate θ<sup>k</sup> of the model parameters. The online computation of the expression of the autocovariance matrix of Eq. (21):

$$r\_{\varepsilon h,k} = \frac{k-1}{k} r\_{\varepsilon k,k-1} + \frac{1}{k} \varepsilon\_k (\overline{\Theta}\_k) \,\varepsilon\_{k+h}(\overline{\Theta}\_k) \tag{21}$$

can be achieved using only the vector ε<sup>k</sup>þ<sup>h</sup> θ<sup>k</sup> � � at each time step. The initial values <sup>θ</sup>0, <sup>Σ</sup>ψ<sup>~</sup> <sup>0</sup> and rε0, <sup>h</sup> for the recursive algorithm are equal to the variables of the classic Frisch scheme batch procedure.

Since variations of system properties have to be tracked online, in order to cope with timevarying systems, this chapter considers a further modification of the recursive estimation scheme. This point can be achieved by placing more emphasis on the more recent data, while forgetting the older ones. Therefore, the methodology represented by the expressions of Eqs. (19) and (21) with the approximation of Eq. (20) is implemented by including the socalled exponential forgetting factor. This is achieved in practice by defining the new expressions of the sample covariance and autocovariance matrices in the form of Eq. (22):

$$\begin{cases} H\_{\Sigma\_{\tilde{\psi}k}} = \omega(\delta) \Sigma\_{\tilde{\psi}k} \\ h\_{\varepsilon h,k} = \omega(\delta) r\_{\varepsilon h,k} \end{cases} \tag{22}$$

where ω(δ) is a scaling factor that coincides with k when no adaptation is introduced. In this way, the updated expressions have the form:

$$\begin{cases} H\_{\Sigma\_{\widetilde{\psi}k}} = (1 - \delta) H\_{\Sigma\_{\widetilde{\psi}\_{k-1}}} + \delta \psi\_k \psi\_k^T \\ h\_{\varepsilon h,k} = (1 - \delta) h\_{\varepsilon h,k-1} + \delta \varepsilon\_k (\overline{\theta}\_k) \varepsilon\_{k+h} (\overline{\theta}\_k) \end{cases} \tag{23}$$

with 0 < δ < 1 representing the forgetting factor. Thus, the adaptive Frisch scheme algorithm is implemented via Eq. (23) in three steps. First, θ0, Σψ<sup>~</sup> <sup>0</sup> and rε0, <sup>h</sup> with h ≤ na are initialised. Moreover, at each recursion step, by means ofrεh, <sup>k</sup>, the noise variances σ<sup>u</sup> and σ<sup>y</sup> are computed. Finally, at each recursion step, θ<sup>k</sup> is determined by solving Eq. (14) via the expression of Eq. (23). In this way, the vector θ<sup>k</sup> contains the estimates of the model parameter derived at the step k.

The results achieved by the online identification method recalled in this section were obtained in the Matlab® and Simulink® environments as summarised in Section 4.

Finally, once the parameters θ<sup>k</sup> of the discrete-time linear time-varying model of the nonlinear dynamic process of Eq. (3) have been computed at each time step k, the adaptive controller is derived as summarised in Section 3.2.
