**3. Sampled-data behavior**

2 Advances in Discrete Time Systems

specialized literature.

**2. UUV dynamics**

Let *η*= [*x*, *y*, *z*, *ϕ*, *θ*, *ψ*]

*T*

referred to as surge, sway, heave, roll, pitch and yaw, respectively.

and angular rates *p*, *q*,*r* about these directions, respectively.

ODE (*cf*. Jordán and Bustamante, 2009a; *cf*. Fossen, 1994)

fluid current in ROV's/AUV's), all of them applied to *O*.

*T*

earth-fixed coordinate system termed *O*′

. *v*=*M*<sup>−</sup><sup>1</sup>

.

Additionally let *v*= [*u*, *v*, *w*, *p*, *q*,*r*]

Dealing with pure delays in the controller design, a Smith-predictor solution stays in mind at the first place. However, the needs of a precise model to construct the predictor upon the usually uncertain and potentially unstable dynamics of an UUV, makes this alternative quite unfeasible (Leonard and Abba, 2012). On the other way, simple controllers like for instance PID controllers, are viable to be tuned with less dynamics information but generally can not counteract by itself the undesirable effects of relatively large pure delays. Adaptive controllers had proved to work properly in these scenarios with many advantages (Jordán and Bustamante, 2011). Nevertheless, the roll played by pure delays in the stability and performance of control systems for underwater vehicles is much less dealt with in the

In this Chapter we focus the design of a 6-degrees-of-freedom adaptive controller for UUV's directly in the sample-time domain. The controller pertains to the class of speed gradient adaptive control systems. This controller was developed in (Jordán and Bustamante, 2011) and shows clearly advantages in stability over the same digital speed-gradient controller which is first designed in continuous time and finally translated to discrete time. One starts from the fact that the UUV dynamics, together with the control communication link in the feedback, involves a considerable delay. In this work, we depart from a hypothesis that an optimal sampling time for the control stability should have some upper limit for the stability in the presence of pure delays, disturbances in the samples and rapid desired maneuvers. To support our hypothesis, we close the analysis with a classification of certain influence variables on the stability and performance of the proposed digital adaptive control system.

*ϕ*, *θ*, *ψ* about these directions, respectively. The motions associated to the elements of *η* are

coordinate system termed *O*, oriented according to its main axes with translation rates *u*, *v*, *w*

The vehicle dynamics with a time delay in the communication system, is described by the

Here *M*, *C* and *D* are the inertia, the Coriolis-centripetal and the drag matrices, respectively and *J* is the matrix expressing the transformation from the inertial frame to the vehicle-fixed frame. Moreover, *g* is the restoration force due to buoyancy and weight, *τ* is the generalized propulsion force whose action is delayed *Td* seconds, *τ<sup>c</sup>* is a generalized perturbation force (for instance due to cable tugs in ROV's) and *vc* is a velocity perturbation (for instance the

−*C*[*v*]*v*−*D*[|*v*|]*v*−*g*[*η*] + *τ<sup>c</sup>* + *τ*(*t* − *Td*)

*η*=*J*[*η*](*v*+*vc*). (2)

be the generalized position vector of the UUV referred to an

, with displacements *x*, *y*, *z*, and rotation angles

(1)

be the generalized rate vector referred on a vehicle-fixed

For the continuous-time dynamics there exists an associated exact sampled-data dynamics described by the set of sequences {*η*[*ti*], *v*[*ti*]} = {*ηti* ,*vti* } for the states *η*[*t*] and *v*[*t*] at sample times *ti* with a sampling rate *h*. When measures are affected with noise values {*δηtn* ,*δvtn* }, we use {*ηδ*[*ti*],*vδ*[*ti*]} = *ηδt i* ,*vδ<sup>t</sup> i* = {*ηtn*+*δηtn* ,*vtn*+*δvtn* } instead.

Since the pure delay period is supposed to be originated in the control communication system, we will assume in some particular scenarios that *Td* in (1), satisfies

$$T\_d = d \text{ } h = d\_0 \text{ } h + \delta d \text{ } h,\tag{3}$$

which is saying that *d* is a variable integer, while *d*<sup>0</sup> is a constant positive integer and *δd* a sign-undefined integer representing a perturbation that fulfills *d*<sup>0</sup> ≥ |*δd*| ≥ 0 and *d* can range between 0 and 2*d*0. Another feature of the communication hardware is that the sample times *ti* of the instrument (from Gyro and DVL for instance) are indicated together with the samples, and so, when these are transmitted to the controller, the calculation of *d* is possible.

Now, let us rewrite the ODE (1)-(2) in a more compact form

$$
\dot{\boldsymbol{\sigma}} = \boldsymbol{M}^{-1} \boldsymbol{p}[\boldsymbol{\eta}, \boldsymbol{\sigma}] + \boldsymbol{M}^{-1} \boldsymbol{\pi} \tag{4}
$$

$$
\dot{\eta} = q[\eta, \sigma],
\tag{5}
$$

with *p* and *q* being Lipschitz vector functions located at the right-hand memberships of the (1) and (2), respectively. Here no exogenous perturbation was considered as agreed above.

For further analysis, we can state a model-based predictor for one step or more steps ahead. To this end it might employ high order approximators like Adams-Bashforth types, though for perturbed states a simple Euler approximator is more convenient (Jordán and Bustamante, 2009b). So

$$
\sigma\_{n+1} = \sigma\_{t\_n} + \delta \sigma\_{t\_n} + hM^{-1} \left( \mathcal{p}\_{\delta\_{t\_n}} + \tau\_{n-d} \right) \tag{6}
$$

$$
\eta\_{n+1} = \eta\_{t\_n} + \delta \eta\_{t\_n} + hq\_{\delta\_{t\_n}\prime} \tag{7}
$$

where *ηn*+<sup>1</sup> and *vn*+<sup>1</sup> are one-step-ahead predictions. Herein it is valid with (1)-(2)

$$\mathfrak{p}\_{\delta\_{li}} = -\sum\_{i=1}^{6} \mathbb{C}\_{i} \cdot \times \mathbb{C}\_{\mathbb{U}\_{li}} \mathfrak{v}\_{\delta\_{li}} - D\_{I} \mathfrak{v}\_{\delta\_{li}} - \sum\_{i=1}^{6} D\_{q\_{i}} \left| \upsilon\_{i\delta\_{li}} \right| \mathfrak{v}\_{\delta\_{li}} - B\_{1} \mathfrak{g}\_{1\_{\mathbb{u}}} - B\_{2} \mathfrak{g}\_{2\_{\mathbb{u}}} \tag{8}$$

$$\mathfrak{q}\_{\delta\_{l\_{\mathbb{R}}}} = \mathfrak{f}\_{\delta\_{l\_{\mathbb{R}}}} \mathfrak{v}\_{\delta\_{l\_{\mathbb{R}}}} \tag{9}$$

where *Cvin* means *Cvi* [*vδtn* ], *g*1*<sup>n</sup>* and *g*2*<sup>n</sup>* mean *g*1[*ηδtn* ] and *g*2[*ηδtn* ] respectively, *Jδtn* means *J*[*ηδtn* ] and *vitn* is an element of *vtn* . Additionally, the matricial product ".×" in (8) means an element-by-element product between the matrices to both sides. Besides, the control action *τ* is retained one sampling period *h* by a sample holder, so it is valid *τn*=*τtn* . We finally remark that since *p*, *q* and *r* are Lipschitz continuous in the attraction domains in *v* and *η*, then the samples, predictions and local errors all yield bounded.

#### **4. Predictions**

The accuracy of one-step-ahead predictions (6)-(7) with known perfect model and without perturbation is defined by the local model errors as

$$
\mathfrak{e}\_{\mathfrak{v}\_{n+1}} = \mathfrak{v}\_{\delta\_{l\_{n+1}}} - \mathfrak{v}\_{n+1} \tag{10}
$$

It is noticing the difference between *rδn*−*<sup>d</sup>* and *rn*−*d*+<sup>1</sup> from the procedence of their variables, namely *rδn*−*<sup>d</sup>* is based upon the samples *vδn*−*<sup>d</sup>* and *ηδn*−*<sup>d</sup>* , while *rn*−*d*+<sup>1</sup> is based upon the

The same consideration between *<sup>q</sup>δn*−*<sup>d</sup>* and *<sup>q</sup>n*−*d*+*<sup>i</sup>* (for *<sup>i</sup>* > 0) mentioned before can be said as in the comparison made between *<sup>r</sup>δn*−*<sup>d</sup>* and *<sup>r</sup>n*−*d*+*<sup>i</sup>* (for *<sup>i</sup>* > 0) with respect to samples and

and since the Method is consistent, *α*0(*h*, **0**, **0**) goes to zero as *h* tends to zero, then global

*<sup>δ</sup>vtn*−*<sup>d</sup>*−*α*0(*h*, *<sup>δ</sup>ηti*

*<sup>δ</sup>ηtn*−*<sup>d</sup>* <sup>−</sup> *<sup>β</sup>*0(*h*, *<sup>δ</sup>ηti*

,*δvti*) = max *ti*>0 *ηδt i* −*ηi*+<sup>1</sup> *<sup>h</sup>* <sup>−</sup>*qδ<sup>i</sup>*

Clearly from (18) and (19), for any *Td* > 0, the convergence of the predictions is ensured for

As the so-called local truncation error of the Euler method is bounded, it is for *v*

,*δvti*) = max *ti*>0 *vδ<sup>t</sup> i* −*vi*+<sup>1</sup>

(*rn*+1−*i*+*τn*+1−*i*) <sup>+</sup>*hM*<sup>−</sup><sup>1</sup>

Stability Analysis of Nonlinear Discrete-Time Adaptive Control Systems with Large Dead-Times

*<sup>h</sup>* <sup>−</sup>*M*−<sup>1</sup>

,*δvti*)

,*δvti*)

 *e κη* ( *Td*

> 

 *e <sup>κ</sup><sup>v</sup>* ( *Td*

*κv*

*κη*

where *κ<sup>v</sup>* is the Lipshitz constant of *M*−<sup>1</sup> (*p*[*η*,*v*]+*τ*). The same is said for *η*, where there

*rδn*−*<sup>d</sup>*+*τn*−*<sup>d</sup>*

*<sup>q</sup>n*+1−*i*+*hqδn*−*<sup>d</sup>* . (16)

*rδi* +*τ<sup>i</sup>*  http://dx.doi.org/10.5772/52224

121

, (15)

, (17)

*<sup>h</sup>* <sup>+</sup>1)*h*, (18)

*<sup>h</sup>* <sup>+</sup>1)*h*, (19)

. (20)

For control purposes, the prediction for *tn*<sup>+</sup><sup>1</sup> will be necessary. This is

<sup>+</sup>*hM*<sup>−</sup><sup>1</sup> *<sup>d</sup>* ∑ *i*=1

predictions *vn*−*d*+<sup>1</sup> and *ηn*−*d*+1.

*vn*+<sup>1</sup> = *vδ<sup>t</sup>*

*ηn*+<sup>1</sup> = *ηδ<sup>t</sup>*

predictions.

and

error *εvn*<sup>+</sup><sup>1</sup> has a bound

*n*−*d*

*n*−*d* +*h d* ∑ *i*=1

*α*0(*h*, *δηti*


exists a Lipshitz constant *κη* of *q*[*η*,*v*] and it is valid

 *εηn*+<sup>1</sup> ≤ 

*h* tending to zero and with *δη*, *δv* uniformly null.

*β*0(*h*, *δηti*

$$
\varepsilon\_{\eta\_{n+1}} = \eta\_{\delta\_{n+1}} - \eta\_{n+1}.\tag{11}
$$

with *εηn*+<sup>1</sup> , *εvn*<sup>+</sup><sup>1</sup> ∈ O[*h*] and O being such a function that *f* [*x*] ∈ O[*x*] means that there exists a neighborhood of *x* around null such that *f* [*x*]/*x* is bounded inside the neighborhood.

We have also the goal to predict states counteracting the negative influence of a delay in them. In order to be able to produce a prediction of many steps in advance based upon the last past information known, we can employ (6)-(7) tied in succession in many links of first order.

So we attempt to construct the state predictions *ηn*+<sup>1</sup> and *vn*+<sup>1</sup> taken the sample at *tn*<sup>−</sup>*<sup>d</sup>* as the unique support to predict at *tn*. We start with

$$
\sigma\_{n-d+1} = \sigma\_{\delta\_{l\_{n-d}}} + h\underline{M}^{-1} \left( \mathbf{r}\_{\delta\_{n-d}} + \mathbf{r}\_{n-d} \right) \, , \tag{12}
$$

where *vδ<sup>t</sup> <sup>n</sup>*−*<sup>d</sup>* is the last sample known at the current time, *<sup>M</sup>* is some known lower matrix of *M* and

$$\mathfrak{r}\_{\mathfrak{f}} = \sum\_{i=1}^{6} \mathsf{U}\_{i} . \times \subset\_{\mathfrak{v}\_{\mathfrak{i}\_{\mathfrak{f}}}} \mathfrak{v}\_{\mathfrak{j}} + \mathsf{U}\_{7} \mathfrak{v}\_{\mathfrak{j}} + \sum\_{i=1}^{6} \mathsf{U}\_{7+i} |\mathfrak{v}\_{\mathfrak{i}\_{\mathfrak{j}}}| \mathfrak{v}\_{\mathfrak{j}} + \mathsf{U}\_{14} \mathfrak{g}\_{1\_{\mathfrak{j}}} + \mathsf{U}\_{15} \mathfrak{g}\_{2\_{\mathfrak{j}}} \tag{13}$$

where the matrices *Ui* will account for every unknown system matrix in *pδtn* in (8) with some appropriate value. We will return to these matrices *Ui*´s later in the controller design.

As there is no information of the sample at *tn*<sup>−</sup>*d*<sup>+</sup>1, the next prediction is with (12) included

$$
\sigma\_{n-d+2} = \sigma\_{\delta\_{l\_{n-d}}} + h\underline{M}^{-1} \left(\mathfrak{r}\_{n-d+1} + \mathfrak{r}\_{n-d+1}\right) + h\underline{M}^{-1} \left(\mathfrak{r}\_{\delta\_{n-d}} + \mathfrak{r}\_{n-d}\right). \tag{14}
$$

It is noticing the difference between *rδn*−*<sup>d</sup>* and *rn*−*d*+<sup>1</sup> from the procedence of their variables, namely *rδn*−*<sup>d</sup>* is based upon the samples *vδn*−*<sup>d</sup>* and *ηδn*−*<sup>d</sup>* , while *rn*−*d*+<sup>1</sup> is based upon the predictions *vn*−*d*+<sup>1</sup> and *ηn*−*d*+1.

For control purposes, the prediction for *tn*<sup>+</sup><sup>1</sup> will be necessary. This is

$$
\boldsymbol{\sigma}\_{n+1} = \boldsymbol{\sigma}\_{\boldsymbol{\delta}\_{n-d}} + h \underline{\boldsymbol{M}}^{-1} \sum\_{i=1}^{d} \left( \boldsymbol{r}\_{n+1-i} + \boldsymbol{\pi}\_{n+1-i} \right) + h \underline{\boldsymbol{M}}^{-1} \left( \boldsymbol{r}\_{\delta\_{n-d}} + \boldsymbol{\pi}\_{n-d} \right), \tag{15}
$$

$$
\eta\_{n+1} = \eta\_{\delta\_{n-d}} + h \sum\_{i=1}^{d} q\_{n+1-i} + hq\_{\delta\_{n-d}}.\tag{16}
$$

The same consideration between *<sup>q</sup>δn*−*<sup>d</sup>* and *<sup>q</sup>n*−*d*+*<sup>i</sup>* (for *<sup>i</sup>* > 0) mentioned before can be said as in the comparison made between *<sup>r</sup>δn*−*<sup>d</sup>* and *<sup>r</sup>n*−*d*+*<sup>i</sup>* (for *<sup>i</sup>* > 0) with respect to samples and predictions.

As the so-called local truncation error of the Euler method is bounded, it is for *v*

$$\mathfrak{a}\_0(\mathfrak{h}\_\prime \delta \mathfrak{y}\_{\mathfrak{t}\_i} \delta \mathfrak{v}\_{\mathfrak{t}\_i}) = \max\_{t\_i > 0} \left| \frac{\mathfrak{v}\_{\delta\_{\mathfrak{t}\_i}} - \mathfrak{v}\_{i+1}}{h} - \underline{\mathbf{M}}^{-1} \left( \mathfrak{r}\_{\delta\_i} + \mathfrak{r}\_i \right) \right|, \tag{17}$$

and since the Method is consistent, *α*0(*h*, **0**, **0**) goes to zero as *h* tends to zero, then global error *εvn*<sup>+</sup><sup>1</sup> has a bound

$$|\mathfrak{e}\_{\mathcal{O}\_{n+1}}| \le \left(\delta \mathfrak{v}\_{\mathfrak{t}\_{n-d}} - \frac{\mathfrak{a}\_0(\mathfrak{h}\_\nu \delta \mathfrak{q}\_{\mathfrak{t}\_\nu} \delta \mathfrak{v}\_{\mathfrak{t}\_l})}{\mathfrak{x}\_\mathcal{v}}\right) e^{\mathfrak{x}\_\mathbb{v}\left(\frac{\mathfrak{r}\_\mathbb{A}}{\hbar} + 1\right)\hbar}.\tag{18}$$

where *κ<sup>v</sup>* is the Lipshitz constant of *M*−<sup>1</sup> (*p*[*η*,*v*]+*τ*). The same is said for *η*, where there exists a Lipshitz constant *κη* of *q*[*η*,*v*] and it is valid

$$|\varepsilon\_{\eta\_{n+1}}| \le \left(\delta\eta\_{t\_{n-d}} - \frac{\beta\_0(h\_\nu\delta\eta\_{t\_l}\delta\sigma\_{t\_l})}{\kappa\_{\eta}}\right) e^{\kappa\_\eta\left(\frac{\tau\_d}{h}+1\right)h} \,\tag{19}$$

and

4 Advances in Discrete Time Systems

**4. Predictions**

order.

where *vδ<sup>t</sup>*

*M* and

*pδtn* = −

6 ∑ *i*=1

*Ci*. × *Cvin vδtn* −*Dlvδtn* −

then the samples, predictions and local errors all yield bounded.

perturbation is defined by the local model errors as

the unique support to predict at *tn*. We start with

*Ui*. × *Cvi j*

*n*−*d*

+*hM*<sup>−</sup><sup>1</sup>

*rj*= 6 ∑ *i*=1

*vn*−*d*+2=*vδ<sup>t</sup>*

*vn*−*d*+1=*vδ<sup>t</sup>*

*n*−*d*

*vj*+*U*7*vj*+

6 ∑ *i*=1

where *Cvin* means *Cvi* [*vδtn* ], *g*1*<sup>n</sup>* and *g*2*<sup>n</sup>* mean *g*1[*ηδtn* ] and *g*2[*ηδtn* ] respectively, *Jδtn* means *J*[*ηδtn* ] and *vitn* is an element of *vtn* . Additionally, the matricial product ".×" in (8) means an element-by-element product between the matrices to both sides. Besides, the control action *τ* is retained one sampling period *h* by a sample holder, so it is valid *τn*=*τtn* . We finally remark that since *p*, *q* and *r* are Lipschitz continuous in the attraction domains in *v* and *η*,

The accuracy of one-step-ahead predictions (6)-(7) with known perfect model and without

with *εηn*+<sup>1</sup> , *εvn*<sup>+</sup><sup>1</sup> ∈ O[*h*] and O being such a function that *f* [*x*] ∈ O[*x*] means that there exists a neighborhood of *x* around null such that *f* [*x*]/*x* is bounded inside the neighborhood.

We have also the goal to predict states counteracting the negative influence of a delay in them. In order to be able to produce a prediction of many steps in advance based upon the last past information known, we can employ (6)-(7) tied in succession in many links of first

So we attempt to construct the state predictions *ηn*+<sup>1</sup> and *vn*+<sup>1</sup> taken the sample at *tn*<sup>−</sup>*<sup>d</sup>* as

+*hM*−<sup>1</sup>

6 ∑ *i*=1

where the matrices *Ui* will account for every unknown system matrix in *pδtn* in (8) with some appropriate value. We will return to these matrices *Ui*´s later in the controller design.

As there is no information of the sample at *tn*<sup>−</sup>*d*<sup>+</sup>1, the next prediction is with (12) included

*<sup>n</sup>*−*<sup>d</sup>* is the last sample known at the current time, *<sup>M</sup>* is some known lower matrix of

*U*7+*i*|*vij*

(*rn*−*d*+1+*τn*−*d*+1) <sup>+</sup>*hM*<sup>−</sup><sup>1</sup>

*rδn*−*d*+*τn*−*<sup>d</sup>*


+*U*<sup>15</sup> *g*2*<sup>j</sup>*

*rδn*−*<sup>d</sup>* + *τn*−*<sup>d</sup>*

*<sup>ε</sup>vn*<sup>+</sup><sup>1</sup> = *<sup>v</sup>δtn*+<sup>1</sup>

*<sup>ε</sup>ηn*+<sup>1</sup> = *<sup>η</sup>δtn*+<sup>1</sup>

*qδtn* = *Jδtn vδtn* (9)

*Dqi* |*vi<sup>δ</sup>tn* |*vδtn* −*B*<sup>1</sup> *g*1*n*−*B*<sup>2</sup> *g*2*<sup>n</sup>* (8)

−*vn*+<sup>1</sup> (10)

−*ηn*+1. (11)

, (12)

, (13)

. (14)

$$\beta\_0(h, \delta \eta\_{l\_l} \delta \sigma\_{l\_l}) = \max\_{t\_l > 0} \left| \frac{\eta\_{\delta\_l} - \eta\_{i+1}}{h} - q\_{\delta\_l} \right| \,. \tag{20}$$

Clearly from (18) and (19), for any *Td* > 0, the convergence of the predictions is ensured for *h* tending to zero and with *δη*, *δv* uniformly null.
