© Springer International Publishing AG, part of Springer Nature 2019
Victor Manuel Hernández-Guzmán and Ramón Silva-OrtigozaAutomatic Control with ExperimentsAdvanced Textbooks in Control and Signal Processinghttps://doi.org/10.1007/978-3-319-75804-6_7

7. The State Variables Approach

Victor Manuel Hernández-Guzmán1  and Ramón Silva-Ortigoza2
(1)
Universidad Autonoma de Queretaro, Facultad de Ingenieria, Querétaro, Querétaro, Mexico
(2)
Instituto Politécnico Nacional, CIDETEC, Mexico City, Mexico
 

The design methods presented in Chaps. 5 and 6 constitute what is now known as classical control. One of the features of classical control is that it relies on the so-called input–output approach, i.e., the use of a transfer function. This means that a transfer function is like a black box receiving an input and producing an output, i.e., nothing is known about what happens inside the black box. On the contrary, the state variable approach allows us to study what happens inside the system.

The study of the state variable approach is a complex subject involving the use of advanced mathematical tools. However, the aim in this chapter is not to present a detailed formal exposition of this approach, but merely to present the basic concepts allowing its application to control simple plants. Thus, only controllable and observable, single-input single-output plants are considered.

7.1 Definition of State Variables

Consider the following linear, constant coefficients differential equations:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} L\;\frac{di}{dt}&\displaystyle =&\displaystyle u-R\;i-n\;k_e\;\dot\theta,{} \end{array} \end{aligned} $$
(7.1)
 $$\displaystyle \begin{aligned} \begin{array}{rcl} J\ddot \theta&\displaystyle =&\displaystyle - b\;\dot \theta+n\;k_{m}\;i.{} \end{array} \end{aligned} $$
(7.2)
Note that each one of these differential equations has an effect on the other. It is said that these differential equations must be solved simultaneously. One useful way of studying this class of differential equations is the state variables approach. The state variables are defined as follows.

Definition 7.1 ([1], pp. 83)

If the input u(t) is known for all t ≥ t 0, the state variables are the set of variables the knowledge of which at t = t 0 allows us to compute the solution of the differential equations for all t ≥ t 0.

Note that this definition of the state variables is ambiguous. Although this may seem to be a drawback, it becomes an advantage because this allows us to select the state variables that are most convenient. According to this, although several criteria are proposed in the literature to select the state variables, it must be understood that no matter how they are selected they must be useful in solving the corresponding differential equations at any future time. In this chapter, the state variables are selected using the following criterion.

Criterion 7.1

Identify the unknown variable in each one of the differential equations involved. Identify the order of each differential equation and designate it as r. Select the state variables as the unknown variable and its first r − 1 time derivatives in each one of the differential equations involved. It is also possible to select some of these variables multiplied by some nonzero constant.

It is common to use n to designate the number of state variables. On the other hand, the state is a vector whose components are given by each one of the state variables. Hence, the state is a vector with n components. According to this criterion, the state variables selected for equations (7.1), (7.2) are i, θ,  $$\dot \theta $$ , i.e., n = 3 and the state is given as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} x=\left[\begin{array}{c}x_1\\ x_2\\ x_3 \end{array}\right]=\left[\begin{array}{c}i\\ \theta\\ \dot\theta \end{array}\right]. \end{array} \end{aligned} $$
Using this nomenclature, the differential equations in (7.1), (7.2), can be written as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} L\;\dot x_1&\displaystyle =&\displaystyle u-R\;x_1-n\;k_e\;x_3,\\ J\dot x_3&\displaystyle =&\displaystyle - b\;x_3 +n\;k_{m}\;x_1, \end{array} \end{aligned} $$
i.e.,:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \frac{d}{dt}\left[\begin{array}{c}x_1\\ x_2\\ x_3 \end{array}\right]=\left[\begin{array}{c} (u-R\;x_1-n\;k_e\;x_3)/L \\ x_3\\ (- b\;x_3 +n\;k_{m}\;x_1)/J \end{array}\right], \end{array} \end{aligned} $$
, which can be rewritten in a compact form as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x&\displaystyle =&\displaystyle Ax+Bu,\\ A&\displaystyle =&\displaystyle \left[\begin{array}{ccc} -\frac{R}{L}&\displaystyle 0 &\displaystyle -\frac{n\;k_e}{L}\\ 0 &\displaystyle 0 &\displaystyle 1\\ \frac{n\;k_{m}}{J} &\displaystyle 0 &\displaystyle - \frac{b}{J} \end{array}\right], B=\left[\begin{array}{c} \frac{1}{L}\\ 0\\ 0 \end{array}\right]. \end{array} \end{aligned} $$
On the other hand, it is common to use y to represent the output to be controlled. It must be stressed that the state x consists variables that are internal to the system; hence, in general, they cannot be measured. On the contrary, the output y is a variable that can always be measured. If the output is defined as the position, i.e., if y = θ = x 2, then:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} y=Cx, C=[0\; 1 \;0]. \end{array} \end{aligned} $$
The set of equations:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x&\displaystyle =&\displaystyle Ax+Bu,{} \end{array} \end{aligned} $$
(7.3)
 $$\displaystyle \begin{aligned} \begin{array}{rcl} y&\displaystyle =&\displaystyle Cx,{} \end{array} \end{aligned} $$
(7.4)
is known as a linear, time invariant, dynamical equation (A, B, and C are constant matrices and vectors). The expression in (7.3) is known as the state equation and the expression in (7.4) is known as the output equation .

Although the state equation in (7.3) has been obtained from a single input differential equation, i.e., u is an scalar, it is very easy to extend (7.3) to the case where there are p inputs: it suffices to define u as a vector with p components, each one of them representing a different input, and B must be defined as a matrix with n rows and p columns. On the other hand, it is also very easy to extend the output equation in (7.4) to the case where there are q outputs: merely define y as a vector with q components, each one representing a different output, and C must be defined as a matrix with q rows and n columns.

Note that a state equation is composed of n first-order differential equations. A property of (7.3), (7.4), i.e., of a linear, time invariant dynamical equation, is that the right-hand side of each one of the differential equations involved in (7.3) is given as a linear combination of the state variables and the input using constant coefficients. Also note that the right-side of (7.4) is formed as the linear combination of the state variables using constant coefficients.

A fundamental property of linear, time invariant dynamical equations is that they satisfy the superposition principle , which is reasonable as this class of state equations is obtained, as explained above, from linear, constant coefficients differential equations, which, according to Sect. 3.​7, also satisfy the superposition principle.

Example 7.1

Consider the mechanical system shown in Fig. 7.1. The corresponding mathematical model was obtained in Example 2.​4, Chap. 2, and it is rewritten here for ease of reference:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} &\displaystyle &\displaystyle \ddot x_1 +\frac{b}{m_1}(\dot x_{1}-\dot x_{2}) +\frac{K_1}{m_1}x_{1}+\frac{K_2}{m_1}(x_1-x_2) =\frac{1}{m_1}F(t),{} \end{array} \end{aligned} $$
(7.5)
 $$\displaystyle \begin{aligned} \begin{array}{rcl} &\displaystyle &\displaystyle \ddot x_2-\frac{b}{m_2}(\dot x_{1}-\dot x_{2})+\frac{K_3}{m_2}x_{2} -\frac{K_2}{m_2}(x_1-x_2) =0.{} \end{array} \end{aligned} $$
(7.6)
Note that there are two second-order differential equations. This means that only four state variables exist: the unknown variable in each one of these differential equations, i.e., x 1 and x 2, and the first time derivative of each one of these unknown variables, i.e.,  $$\dot x_1$$ and  $$\dot x_2$$ :
/epubstore/G/V-M-Guzman/Automatic-Control-With-Experiments/OEBPS/images/454499_1_En_7_Chapter/454499_1_En_7_Fig1_HTML.png
Fig. 7.1

Mechanical system

 $$\displaystyle \begin{aligned} \begin{array}{rcl} x=\left[\begin{array}{c}x_1\\ x_2\\ x_3\\ x_4 \end{array}\right]=\left[\begin{array}{c}x_1\\ x_2\\ \dot x_1\\ \dot x_2 \end{array}\right],u=F(t). \end{array} \end{aligned} $$
Using this nomenclature, the differential equations in (7.5), (7.6), can be rewritten as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} &\displaystyle &\displaystyle \ddot x_1=\dot x_3 =-\frac{b}{m_1}( x_{3}-x_{4}) -\frac{K_1}{m_1}x_{1}-\frac{K_2}{m_1}(x_1-x_2) +\frac{1}{m_1}u,\\ &\displaystyle &\displaystyle \ddot x_2=\dot x_4=\frac{b}{m_2}(x_{3}- x_{4})-\frac{K_3}{m_2}x_{2} +\frac{K_2}{m_2}(x_1-x_2),\end{array} \end{aligned} $$
i.e.,:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \frac{d}{dt}\left[\begin{array}{c}x_1\\ x_2\\ x_3\\ x_4 \end{array}\right]=\left[\begin{array}{c} x_3\\ x_4\\ -\frac{b}{m_1}( x_{3}-x_{4}) -\frac{K_1}{m_1}x_{1}-\frac{K_2}{m_1}(x_1-x_2) +\frac{1}{m_1}u\\ \frac{b}{m_2}(x_{3}- x_{4})-\frac{K_3}{m_2}x_{2} +\frac{K_2}{m_2}(x_1-x_2) \end{array}\right].{} \end{array} \end{aligned} $$
(7.7)
Hence, the following state equation is obtained:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x&=&Ax+Bu,\\ A&=&\left[\begin{array}{cccc} 0& 0 &1 & 0\\ 0 & 0 & 0 &1\\ -\frac{K_1}{m_1}-\frac{K_2}{m_1} & \frac{K_2}{m_1} &- \frac{b}{m_1}&\frac{b}{m_1}\\ \frac{K_2}{m_2} & -\frac{K_2}{m_2}-\frac{K_3}{m_2} & \frac{b}{m_2}&-\frac{b}{m_2}\\ \end{array}\right], B=\left[\begin{array}{c} 0\\ 0\\ \frac{1}{m_1}\\ 0 \end{array}\right].{} \end{array} \end{aligned} $$
(7.8)
On the other hand, the output equation depends on the variable to be controlled. For instance, if it is desired to control the position of mass 1, then:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} y=Cx=x_1, C=[1\; 0 \;0 \; 0], \end{array} \end{aligned} $$
but, if it is desired to control position of mass 2, then:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} y=Cx=x_2, C=[0\; 1 \;0 \; 0]. \end{array} \end{aligned} $$

Example 7.2

A mechanism known as ball and beam is studied in Chap. 14. In that chapter, the corresponding mathematical model is obtained and presented in (14.​8). This model is rewritten here for ease of reference:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \frac{X(s)}{\theta(s)}=\frac{\rho}{s^2}, \theta(s)=\frac{k}{s(s+a)}I^*(s). \end{array} \end{aligned} $$
Using the inverse Laplace transform, the corresponding differential equations can be obtained, i.e.,:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \ddot x=\rho\theta, \ddot\theta+a\dot\theta=k i^*.{} \end{array} \end{aligned} $$
(7.9)
As there are two second-order differential equations, then there are four state variables: the unknown variable in each differential equation, i.e., x and θ, and the first time derivative of each unknown variable, i.e.,  $$\dot x$$ and  $$\dot \theta $$ :
 $$\displaystyle \begin{aligned} \begin{array}{rcl} z=\left[\begin{array}{c}z_1\\ z_2\\ z_3\\ z_4 \end{array}\right]=\left[\begin{array}{c}x\\ \dot x\\ \theta\\ \dot \theta \end{array}\right],u=i^*. \end{array} \end{aligned} $$
Using this nomenclature, the differential equations in (7.9) can be rewritten as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \ddot x=\dot z_2 =\rho z_3,\ddot \theta=\dot z_4=-az_4+ku,\end{array} \end{aligned} $$
i.e.,:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \frac{d}{dt}\left[\begin{array}{c}z_1\\ z_2\\ z_3\\ z_4 \end{array}\right]=\left[\begin{array}{c} z_2\\ \rho z_3\\ z_4\\ -az_4+ku \end{array}\right].{} \end{array} \end{aligned} $$
(7.10)
Hence, the following state equation is obtained:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot z&=&Az+Bu\\ A&=&\left[\begin{array}{cccc} 0& 1 & 0 & 0\\ 0 & 0 & \rho & 0\\ 0 & 0 & 0 & 1\\ 0 & 0 & 0 & -a \end{array}\right], B=\left[\begin{array}{c} 0\\ 0\\ 0\\ k \end{array}\right].{} \end{array} \end{aligned} $$
(7.11)
As explained in Chap. 14, the variable to be controlled is x; thus, the output equation is given as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} y=Cz=x=z_1, C=[1\; 0 \;0 \; 0]. \end{array} \end{aligned} $$

7.2 The Error Equation

Consider a linear state equation of the form:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x&\displaystyle =&\displaystyle Ax+Bu. \end{array} \end{aligned} $$
The control objective for this plant can be stated by defining a constant desired state vector x and ensuring that lim t x(t) = x . This means that x(t) must converge to the constant x , which implies that  $$\lim _{t\to \infty }\dot x(t)=\dot x^*=0$$ , i.e., the control problem has a solution if, and only if, there is a pair (x , u ) such that:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x^*&\displaystyle =&\displaystyle Ax^*+Bu^*=0,{} \end{array} \end{aligned} $$
(7.12)
where u  =lim t u(t) is also a constant. The pair (x , u ) is known as the operation point. The error state vector is defined as e = x − x and it is clear that the control objective can be restated as lim t e(t) = 0. To analyze the evolution of e(t), i.e., to find the conditions ensuring that the above limit is satisfied, it is important to have a state equation in terms of the state error. In the following examples, it is shown how to proceed to obtain this equation, which is known as the error equation.

Example 7.3

Consider the ball and beam system studied in Example 7.2. The system state equation is given in (7.11). However, to obtain the error equation, the expression in (7.10) is more convenient, i.e.,:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \frac{d}{dt}\left[\begin{array}{c}z_1\\ z_2\\ z_3\\ z_4 \end{array}\right]=\left[\begin{array}{c} z_2\\ \rho z_3\\ z_4\\ -az_4+ku \end{array}\right]. \end{array} \end{aligned} $$
Mimicking (7.12), to obtain the possible operation points, find all possible solutions of:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \left[\begin{array}{c}0\\ 0\\ 0\\ 0 \end{array}\right]=\left[\begin{array}{c} z_2^*\\ \rho z_3^*\\ z_4^*\\ -az_4^*+ku^* \end{array}\right]. \end{array} \end{aligned} $$
It is clear that:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} z^*=\left[\begin{array}{c} z_1^*\\ z_2^*\\ z_3^*\\ z_4^* \end{array}\right]=\left[\begin{array}{c} c\\ 0\\ 0\\ 0 \end{array}\right], u^*=0, \end{array} \end{aligned} $$
where c is any real constant because no constraint is imposed on  $$z_1^*$$ . Once the operation points (z , u ) are defined, the error state is given as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} e=\left[\begin{array}{c}e_1\\ e_2\\ e_3\\ e_4 \end{array}\right]=z-z^*=\left[\begin{array}{c}z_1-c\\ z_2\\ z_3\\ z_4 \end{array}\right].{} \end{array} \end{aligned} $$
(7.13)
The error equation is obtained differentiating the error state once, i.e.,:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot e=\left[\begin{array}{c}\dot e_1\\ \dot e_2\\ \dot e_3\\ \dot e_4 \end{array}\right]=\left[\begin{array}{c}\dot z_1-\dot z_1^*\\ \dot z_2-\dot z_2^*\\ \dot z_3-\dot z_3^*\\ \dot z_4-\dot z_4^* \end{array}\right]=\left[\begin{array}{c}\dot z_1\\ \dot z_2\\ \dot z_3\\ \dot z_4 \end{array}\right]=\left[\begin{array}{c} z_2\\ \rho z_3\\ z_4\\ -az_4+ku \end{array}\right]. \end{array} \end{aligned} $$
From the last expression, u  = 0, and (7.13), we have:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot e=\left[\begin{array}{c}e_2\\ \rho e_3\\ e_4\\ -ae_4+k(u-u^*) \end{array}\right]. \end{array} \end{aligned} $$
Thus, defining v = u − u , the error equation can be written as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot e&\displaystyle =&\displaystyle Ae+Bv, \end{array} \end{aligned} $$
with matrix A and vector B defined in (7.11).

Example 7.4

Consider the mechanical system in Example 7.1. The corresponding state equation is given in (7.8). However, to obtain the error equation, it is preferable to consider (7.7), i.e.,:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \frac{d}{dt}\left[\begin{array}{c}x_1\\ x_2\\ x_3\\ x_4 \end{array}\right]=\left[\begin{array}{c} x_3\\ x_4\\ -\frac{b}{m_1}( x_{3}-x_{4}) -\frac{K_1}{m_1}x_{1}-\frac{K_2}{m_1}(x_1-x_2) +\frac{1}{m_1}u\\ \frac{b}{m_2}(x_{3}- x_{4})-\frac{K_3}{m_2}x_{2} +\frac{K_2}{m_2}(x_1-x_2) \end{array}\right]. \end{array} \end{aligned} $$
Mimicking (7.12), to obtain the possible operation points find all the possible solutions of:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \left[\begin{array}{c}0\\ 0\\ 0\\ 0 \end{array}\right]=\left[\begin{array}{c} x_3^*\\ x_4^*\\ -\frac{b}{m_1}( x_{3}^*-x_{4}^*) -\frac{K_1}{m_1}x_{1}^*-\frac{K_2}{m_1}(x_1^*-x_2^*) +\frac{1}{m_1}u^*\\ \frac{b}{m_2}(x_{3}^*- x_{4}^*)-\frac{K_3}{m_2}x_{2}^* +\frac{K_2}{m_2}(x_1^*-x_2^*) \end{array}\right], \end{array} \end{aligned} $$
i.e.,  $$x_3^*=0$$ ,  $$x_4^*=0$$ , and the solutions of:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} -\frac{K_1}{m_1}x_{1}^*-\frac{K_2}{m_1}(x_1^*-x_2^*) +\frac{1}{m_1}u^*&\displaystyle =&\displaystyle 0,\\ -\frac{K_3}{m_2}x_{2}^* +\frac{K_2}{m_2}(x_1^*-x_2^*)&\displaystyle =&\displaystyle 0. \end{array} \end{aligned} $$
Solving these expressions, it is found that the operation points are given as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} x^*=\left[\begin{array}{c} x_1^*\\ x_2^*\\ x_3^*\\ x_4^* \end{array}\right]=\left[\begin{array}{c} \frac{K_2+K_3}{K_2}x_2^*\\ c\\ 0\\ 0 \end{array}\right], u^*=\left(\frac{(K_1+K_2)(K_2+K_3)}{K _2}-K_2\right)x_2^*,\\ {} \end{array} \end{aligned} $$
(7.14)
where c is any real constant. Once the operation points (x , u ) are defined, the error state is given as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} e=\left[\begin{array}{c}e_1\\ e_2\\ e_3\\ e_4 \end{array}\right]=x-x^*=\left[\begin{array}{c}x_1-x_1^*\\ x_2-x_2^*\\ x_3\\ x_4 \end{array}\right].{} \end{array} \end{aligned} $$
(7.15)
The error equation is obtained differentiating the error state once, i.e.,:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot e&\displaystyle =&\displaystyle \left[\begin{array}{c}\dot e_1\\ \dot e_2\\ \dot e_3\\ \dot e_4 \end{array}\right]=\left[\begin{array}{c}\dot x_1-\dot x_1^*\\ \dot x_2-\dot x_2^*\\ \dot x_3\\ \dot x_4 \end{array}\right]=\left[\begin{array}{c}\dot x_1\\ \dot x_2\\ \dot x_3\\ \dot x_4 \end{array}\right]\\ &\displaystyle =&\displaystyle \left[\begin{array}{c} x_3\\ x_4\\ -\frac{b}{m_1}( x_{3}-x_{4}) -\frac{K_1}{m_1}x_{1}-\frac{K_2}{m_1}(x_1-x_2) +\frac{1}{m_1}u\\ \frac{b}{m_2}(x_{3}- x_{4})-\frac{K_3}{m_2}x_{2} +\frac{K_2}{m_2}(x_1-x_2) \end{array}\right]. \end{array} \end{aligned} $$
Adding and subtracting terms  $$\frac {K_1}{m_1}x_1^*,\frac {K_2}{m_1}x_2^*,\frac {K_2}{m_1}x_1^*$$ and  $$\frac {K_3}{m_2}x_2^*,\frac {K_2}{m_2}x_2^*,\frac {K_2}{m_2}x_1^*$$ in the third row and fourth row respectively of the last expression and using (7.14), (7.15), yields:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot e&\displaystyle =&\displaystyle \left[\begin{array}{c} e_3\\ e_4\\ -\frac{b}{m_1}( e_{3}-e_{4}) -\frac{K_1}{m_1}e_{1}-\frac{K_2}{m_1}(e_1-e_2) +\frac{1}{m_1}(u-u^*)\\ \frac{b}{m_2}(e_{3}- e_{4})-\frac{K_3}{m_2}e_{2} +\frac{K_2}{m_2}(e_1-e_2) \end{array}\right]. \end{array} \end{aligned} $$
Thus, defining v = u − u , the error equation can be written as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot e&\displaystyle =&\displaystyle Ae+Bv, \end{array} \end{aligned} $$
with A and B defined in (7.8).

7.3 Approximate Linearization of Nonlinear State Equations

Nonlinear state equations are frequently found. These are state equations given as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x&=&f(x,u),{}\\ f&=&\left[\begin{array}{c} f_1(x,u)\\ f_2(x,u)\\ \vdots\\ f_n(x,u) \end{array}\right], x=\left[\begin{array}{c} x_1\\ x_2\\ \vdots\\ x_n \end{array}\right], u=\left[\begin{array}{c} u_1\\ u_2\\ \vdots\\ u_p \end{array}\right], \end{array} \end{aligned} $$
(7.16)
where at least one the of functions f i (x, u), i = 1, …, n, is a scalar nonlinear function of x or u, i.e., this function cannot be written as a linear combination of the components of x or u. For instance, in a state equation with three state variables and two inputs:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} f_i(x,u)&\displaystyle =&\displaystyle 3\sin{}(x_3)+x_1u_2,\\ f_i(x,u)&\displaystyle =&\displaystyle \frac{e^{x_1}}{5x_2},\\ f_i(x,u)&\displaystyle =&\displaystyle u_1^2. \end{array} \end{aligned} $$
It is important to stress that the notation f i (x, u) means that the i −th component of vector f is in general a function of the components of the state vector x and the input vector u. However, as shown in the previous examples, it is not necessary for f i (x, u) to be a function of all the state variables and all the inputs. Moreover, it is also possible that f i (x, u) is not a function of any state variable, but it is a function of some of the inputs and vice versa. A state equation of the form (7.16) possessing the above features is known as a nonlinear time invariant state equation , i.e., it has no explicit dependence on time.

The study of nonlinear state equations is much more complex than the study of linear state equations. However, most physical systems are inherently nonlinear, i.e., their models have the form given in (7.16). Hence, suitable analysis and design methodologies must be developed for this class of state equations. One of the simplest methods is to find a linear state equation, such as that in (7.3), which is approximately equivalent to (7.16). The advantage of this method is that the linear state equations such as that in (7.3) can be studied much more easily. Hence, the analysis and design of controllers for (7.16) are performed on the basis of the much simpler model in (7.3). Although this method is very useful, it must be stressed that its main drawback is that the results obtained are only valid in a small region around the point where the linear approximation is performed. These ideas are clarified in the following sections.

7.3.1 Procedure for First-order State Equations Without Input

Consider a nonlinear first-order differential equation without input:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x=f(x),{} \end{array} \end{aligned} $$
(7.17)
where x is a scalar and f(x) is a scalar nonlinear function of x. It is desired to obtain a linear differential equation representing (7.17), at least approximately. Define an equilibrium point x of (7.17) as that value of x satisfying f(x ) = 0. According to (7.17), this means that at an equilibrium point  $$\dot x^*=f(x^*)=0$$ , i.e., the system can remain at rest at that point forever.
Suppose that f(x) is represented by the curve shown in Fig. 7.2. The dashed straight line h(x) is tangent to f(x) at the point x . Because of this feature, h(x) and f(x) are approximately equal for values of x that are close to x , i.e., if x − x ≈ 0. However, the difference between h(x) and f(x) increases as x and x become far apart, i.e., for large values of x − x . Hence, h(x) can be employed instead of f(x) if x is constrained to only take values that are close to x . In Fig. 7.2, it is observed that:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} m=\frac{h(x)-f(x^*)}{x-x^*}, m=\left.\frac{d f(x)}{d x}\right|{}_{x=x^*}, \end{array} \end{aligned} $$
where the constant m represents the slope of h(x), i.e., the derivative of f(x) evaluated at the equilibrium point x . Then, from the first expression:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} h(x)=m(x-x^*)+f(x^*),{} \end{array} \end{aligned} $$
(7.18)
and, as h(x) ≈ f(x), it is possible to write:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} f(x)\approx m(x-x^*)+f(x^*). \end{array} \end{aligned} $$
As x is an equilibrium point, then f(x ) = 0 and:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} f(x)\approx m(x-x^*). \end{array} \end{aligned} $$
Hence, (7.17) can be approximated by:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x=m(x-x^*). \end{array} \end{aligned} $$
Defining the new variable z = x − x , then  $$\dot z=\dot x$$ , because  $$\dot x^*=0$$ . Hence, the linear approximation of (7.17) is given by:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot z=m\; z,{} \end{array} \end{aligned} $$
(7.19)
, which is valid only if x − x ≈ 0. Once (7.19) is employed to compute z, the definition z = x − x can be used to obtain x as the equilibrium point x is known. Finally, note that the only requirement for all the above to stand is that  $$\frac {d f(x)}{dx}$$ exists and is continuous, i.e., that f(x) is, at least once, continuously differentiable.
/epubstore/G/V-M-Guzman/Automatic-Control-With-Experiments/OEBPS/images/454499_1_En_7_Chapter/454499_1_En_7_Fig2_HTML.png
Fig. 7.2

Approximation of a nonlinear function f(x) using a straight line h(x)

7.3.2 General Procedure for Arbitrary Order State Equations with an Arbitrary Number of Inputs

Now consider the state equation:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x=f(x,u),{} \end{array} \end{aligned} $$
(7.20)
where x ∈ R n is a vector with n components and u ∈ R p is a vector with p components standing for the state equation input. Note that f(x, u) must be a vectorial function with n components. This means that (7.20) has the form defined in (7.16). In this case, it is preferable to employ the concept of operation point instead of equilibrium point because the latter concept is only defined for state equations without inputs. An operation point is defined as the pair (x , u ) satisfying f(x , u ) = 0. This means that the solution of the state equation can remain at rest at x , because  $$\dot x^*=f(x^*,u^*)=0$$ , if the suitable inputs u (p inputs) are applied, which are also constant.
Note that f(x, u) depends on n + p variables. Define the following vector:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} y=\left[\begin{array}{c}x \\u\end{array}\right], \end{array} \end{aligned} $$
with n + p components. Then (7.20) can be written as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x=f(y).{} \end{array} \end{aligned} $$
(7.21)
Following the ideas in the previous section, it is desired to approximate the nonlinear function f(y) by a function h(y) that is tangent to f(y) at the operation point y defined as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} y^*=\left[\begin{array}{c}x^* \\u^*\end{array}\right]. \end{array} \end{aligned} $$
Extending the expression in (7.18) to the case of n + p variables, it is possible to write:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} h(y)=M(y-y^*)+f(y^*), \end{array} \end{aligned} $$
where  $$M=\left .\frac {\partial f(y)}{\partial y}\right |{ }_{y=y^*}$$ is a constant matrix defined as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} M=\left[ \begin{array}{cccccccc} \frac{\partial f_1(x,u)}{\partial x_1}&\displaystyle \frac{\partial f_1(x,u)}{\partial x_2}&\displaystyle \dots&\displaystyle \frac{\partial f_1(x,u)}{\partial x_n}&\displaystyle \frac{\partial f_1(x,u)}{\partial u_1}&\displaystyle \frac{\partial f_1(x,u)}{\partial u_2}&\displaystyle \dots&\displaystyle \frac{\partial f_1(x,u)}{\partial u_p}\\ \frac{\partial f_2(x,u)}{\partial x_1}&\displaystyle \frac{\partial f_2(x,u)}{\partial x_2}&\displaystyle \dots&\displaystyle \frac{\partial f_2(x,u)}{\partial x_n}&\displaystyle \frac{\partial f_2(x,u)}{\partial u_1}&\displaystyle \frac{\partial f_2(x,u)}{\partial u_2}&\displaystyle \dots&\displaystyle \frac{\partial f_2(x,u)}{\partial u_p}\\ \vdots&\displaystyle \vdots&\displaystyle \ddots&\displaystyle \vdots&\displaystyle \vdots&\displaystyle \vdots&\displaystyle \ddots&\displaystyle \vdots\\ \frac{\partial f_n(x,u)}{\partial x_1}&\displaystyle \frac{\partial f_n(x,u)}{\partial x_2}&\displaystyle \dots&\displaystyle \frac{\partial f_n(x,u)}{\partial x_n}&\displaystyle \frac{\partial f_n(x,u)}{\partial u_1}&\displaystyle \frac{\partial f_n(x,u)}{\partial u_2}&\displaystyle \dots&\displaystyle \frac{\partial f_n(x,u)}{\partial u_p} \end{array} \right]_{x=x^*,u=u^*}. \end{array} \end{aligned} $$
Taking advantage of f(y) ≈ h(y), (7.21) can be approximated as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x=M(y-y^*)+f(y^*). \end{array} \end{aligned} $$
As f(y ) = f(x , u ) = 0 and  $$\dot x-\dot x^*=\dot x$$ , because  $$\dot x^*=0$$ , the following is found:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot z&=&A z+Bv,{} \end{array} \end{aligned} $$
(7.22)
 $$\displaystyle \begin{aligned} \begin{array}{rcl} A&=&\left[ \begin{array}{cccc} \frac{\partial f_1(x,u)}{\partial x_1}&\frac{\partial f_1(x,u)}{\partial x_2}&\dots&\frac{\partial f_1(x,u)}{\partial x_n}\\ \frac{\partial f_2(x,u)}{\partial x_1}&\frac{\partial f_2(x,u)}{\partial x_2}&\dots&\frac{\partial f_2(x,u)}{\partial x_n}\\ \vdots&\vdots&\ddots&\vdots\\ \frac{\partial f_n(x,u)}{\partial x_1}&\frac{\partial f_n(x,u)}{\partial x_2}&\dots&\frac{\partial f_n(x,u)}{\partial x_n} \end{array} \right]_{x=x^*,u=u^*},{} \end{array} \end{aligned} $$
(7.23)
 $$\displaystyle \begin{aligned} \begin{array}{rcl} B&=&\left[ \begin{array}{cccc} \frac{\partial f_1(x,u)}{\partial u_1}& \frac{\partial f_1(x,u)}{\partial u_2}&\dots&\frac{\partial f_1(x,u)}{\partial u_p}\\ \frac{\partial f_2(x,u)}{\partial u_1}& \frac{\partial f_2(x,u)}{\partial u_2}&\dots&\frac{\partial f_2(x,u)}{\partial u_p}\\ \vdots&\vdots&\ddots&\vdots\\ \frac{\partial f_n(x,u)}{\partial u_1}& \frac{\partial f_n(x,u)}{\partial u_2}&\dots&\frac{\partial f_n(x,u)}{\partial u_p} \end{array} \right]_{x=x^*,u=u^*},{} \end{array} \end{aligned} $$
(7.24)
where z = x − x and v = u − u have been defined. The expressions in (7.22), (7.23), (7.24) constitute the linear approximate model employed in the analysis and design of controllers for the nonlinear system in (7.20). Note that this linear approximate model is valid only if the state x and the input u remain close to the operation point (x , u ), i.e., only if z = x − x ≈ 0 and v = u − u ≈ 0. From a practical point of view, it is commonly difficult to determine the values of x and u satisfying these conditions; hence, they are employed heuristically. Finally, note that the only requirement for all the above to stand is that all the partial derivatives defining the matrices A and B exist and are continuous, i.e., that f(x, u) is, at least once, continuously differentiable.

Example 7.5

In Fig. 7.3, a simple pendulum is shown. In Example 2.​6, Chap. 2, it was found that the corresponding mathematical model is given by the following nonlinear differential equation:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} ml^2\ddot \theta +b\dot\theta+mgl\sin{}(\theta) &\displaystyle =&\displaystyle T(t).{} \end{array} \end{aligned} $$
(7.25)
The feature that renders this differential equation nonlinear is the function  $$\sin {}(\theta )$$ representing the effect of gravity. As it is a second-order differential equation, then only two state variables exist: the unknown θ and its first-time derivative  $$\dot \theta $$ :
 $$\displaystyle \begin{aligned} \begin{array}{rcl} x=\left[\begin{array}{c}x_1\\ x_2 \end{array}\right]=\left[\begin{array}{c}\theta\\ \dot\theta \end{array}\right],u=T(t). \end{array} \end{aligned} $$
Using this nomenclature, the differential equation in (7.25) can be written as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \ddot \theta =\dot x_2=-\frac{b}{ml^2}x_2-\frac{g}{l}\sin{}(x_1)+\frac{1}{ml^2}u, \end{array} \end{aligned} $$
i.e.,
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \frac{d}{dt}\left[\begin{array}{c}x_1\\ x_2 \end{array}\right]=\left[\begin{array}{c} x_2\\ -\frac{b}{ml^2}x_2-\frac{g}{l}\sin{}(x_1)+\frac{1}{ml^2}u\end{array}\right]. \end{array} \end{aligned} $$
Hence, the following state equation is found:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x&\displaystyle =&\displaystyle f(x,u)\\ f(x,u)&\displaystyle =&\displaystyle \left[\begin{array}{c} f_1(x,u)\\ f_2(x,u) \end{array}\right]=\left[\begin{array}{c} x_2\\ -\frac{b}{ml^2}x_2-\frac{g}{l}\sin{}(x_1)+\frac{1}{ml^2}u \end{array}\right]. \end{array} \end{aligned} $$
Note that in this case, it is not possible to obtain the linear form  $$\dot x=Ax+Bu$$ because of the function  $$\sin {}(\theta )$$ . To obtain a linear approximation for this nonlinear state equation, the operation points are first obtained, i.e., those pairs (x , u ) satisfying f(x , u ) = [0 0] T :
 $$\displaystyle \begin{aligned} \begin{array}{rcl} f(x^*,u^*)&\displaystyle =&\displaystyle \left[\begin{array}{c} x_2^*\\ -\frac{b}{ml^2}x_2^*-\frac{g}{l}\sin{}(x_1^*)+\frac{1}{ml^2}u^* \end{array}\right]=\left[\begin{array}{c} 0\\ 0 \end{array}\right]. \end{array} \end{aligned} $$
From this, the following is found:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} x_2^*=0,u^*= -mgl\sin{}(x_1^*). \end{array} \end{aligned} $$
This means that the input at the operation point depends on the pendulum position at the operation point. This is because, to maintain the pendulum at rest, it is necessary to have an input that exactly compensates for the effect of gravity. To continue, a particular value for  $$x_1^*$$ must be selected. Two cases are considered here:
  • When  $$x_1^*=0$$ ,  $$x_2^*=0$$ , u  = 0. Using (7.22), (7.23), (7.24), the following is found:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot z&\displaystyle =&\displaystyle Az+Bv,\\ A&\displaystyle =&\displaystyle \left[ \begin{array}{cc} \frac{\partial f_1(x,u)}{\partial x_1}&\displaystyle \frac{\partial f_1(x,u)}{\partial x_2}\\ \frac{\partial f_2(x,u)}{\partial x_1}&\displaystyle \frac{\partial f_2(x,u)}{\partial x_2} \end{array} \right]_{x=x^*,u=u^*}=\left[ \begin{array}{cc} 0&\displaystyle 1\\ -\frac{g}{l} \cos{}(x_1)&\displaystyle -\frac{b}{ml^2} \end{array} \right]_{x_1=x_2=u=0},\\ &\displaystyle =&\displaystyle \left[ \begin{array}{cc} 0&\displaystyle 1\\ -\frac{g}{l} &\displaystyle -\frac{b}{ml^2} \end{array} \right],\\ B&\displaystyle =&\displaystyle \left[ \begin{array}{c} \frac{\partial f_1(x,u)}{\partial u}\\ \frac{\partial f_2(x,u)}{\partial u} \end{array} \right]_{x=x^*,u=u^*}=\left[ \begin{array}{c} 0\\ \frac{1}{ml^2} \end{array} \right], \end{array} \end{aligned} $$
    where z = x − x  = x and v = u − u  = u have been defined. Note that, according to this state equation:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot z_1=z_2, \dot z_2=-\frac{g}{l}z_1-\frac{b}{ml^2}z_2+\frac{1}{ml^2}v. \end{array} \end{aligned} $$
    Combining these first-order differential equations the following linear, second-order differential equation with constant coefficients is obtained:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} \ddot z_1+\frac{b}{ml^2}\dot z_1+\frac{g}{l}z_1=\frac{1}{ml^2}v.{} \end{array} \end{aligned} $$
    (7.26)
    This differential equation can be analyzed using the concepts studied in Sects. 3.​3 (complex conjugate roots with a negative or zero real part), 3.​4.​2 (real and repeated negative roots) and 3.​4.​1 (real, different and negative roots), Chap. 3, as it corresponds to a differential equation with the form:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} \ddot y+2\zeta\omega_n\dot y+\omega_n^2y=k\omega_n^2v, \end{array} \end{aligned} $$
    where:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} y=z_1, 2\zeta\omega_n=\frac{b}{ml^2}, \omega_n^2=\frac{g}{l}, k=\frac{1}{mgl}, \end{array} \end{aligned} $$
    with ζ ≥ 0, ω n  > 0 and k > 0 because m > 0, g > 0, l > 0 and b ≥ 0.
  • When  $$x_1^*=\pm \pi $$ ,  $$x_2^*=0$$ , u  = 0. Using (7.22), (7.23), (7.24), the following is found:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot z&\displaystyle =&\displaystyle Az+Bv,\\ A&\displaystyle =&\displaystyle \left[ \begin{array}{cc} \frac{\partial f_1(x,u)}{\partial x_1}&\displaystyle \frac{\partial f_1(x,u)}{\partial x_2}\\ \frac{\partial f_2(x,u)}{\partial x_1}&\displaystyle \frac{\partial f_2(x,u)}{\partial x_2} \end{array} \right]_{x=x^*,u=u^*}=\left[ \begin{array}{cc} 0&\displaystyle 1\\ -\frac{g}{l} \cos{}(x_1)&\displaystyle -\frac{b}{ml^2} \end{array} \right]_{x_1=\pm\pi,x_2=u=0},\\ &\displaystyle =&\displaystyle \left[ \begin{array}{cc} 0&\displaystyle 1\\ \frac{g}{l} &\displaystyle -\frac{b}{ml^2} \end{array} \right],\\ B&\displaystyle =&\displaystyle \left[ \begin{array}{c} \frac{\partial f_1(x,u)}{\partial u}\\ \frac{\partial f_2(x,u)}{\partial u} \end{array} \right]_{x=x^*,u=u^*}=\left[ \begin{array}{c} 0\\ \frac{1}{ml^2} \end{array} \right], \end{array} \end{aligned} $$
    where  $$z=x-x^*=[x_1-x_1^*,\;x_2]^T$$ and v = u − u  = u have been defined. Note that this state equation implies:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot z_1=z_2, \dot z_2=\frac{g}{l}z_1-\frac{b}{ml^2}z_2+\frac{1}{ml^2}v. \end{array} \end{aligned} $$
    Combining these first-order differential equations the following linear, second-order differential equation with constant coefficients is obtained:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} \ddot z_1+\frac{b}{ml^2}\dot z_1-\frac{g}{l}z_1=\frac{1}{ml^2}v.{} \end{array} \end{aligned} $$
    (7.27)
    This differential equation can be analyzed using the concepts studied in Sect. 3.​4.​1, Chap. 3 (real, different roots, one positive and the other negative, see Example 3.​11) as it corresponds to a differential equation of the form:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} \ddot y+c \dot y+d y=e v, \end{array} \end{aligned} $$
    where:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} y=z_1, c=\frac{b}{ml^2}\geq 0, d=-\frac{g}{l}<0, e=\frac{1}{ml^2}. \end{array} \end{aligned} $$
Note that, according to (7.26) and Sect. 3.​3, Chap. 3, the pendulum oscillates with a natural frequency given as  $$\omega _n=\sqrt {\frac {g}{l}}$$ when operating around  $$x_1^*=0$$ ,  $$x_2^*=0$$ , u  = 0. This means that a longer pendulum oscillates slower whereas a shorter pendulum oscillates faster. These observations are useful, for instance, when it is desired to adjust the rate of a clock that leads or lags in time. Moreover, rearranging (7.26) the following is found:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} ml^2 \ddot z_1+b\dot z_1+mgl z_1=v.{} \end{array} \end{aligned} $$
(7.28)
According to Example 2.​5, Chap. 2, which analyzes the rotative spring-mass-damper system shown in Fig. 7.4, (7.28) means that factor K = mgl > 0 is equivalent to the stiffness constant of a spring because of the effect of gravity.
/epubstore/G/V-M-Guzman/Automatic-Control-With-Experiments/OEBPS/images/454499_1_En_7_Chapter/454499_1_En_7_Fig3_HTML.png
Fig. 7.3

Simple pendulum

/epubstore/G/V-M-Guzman/Automatic-Control-With-Experiments/OEBPS/images/454499_1_En_7_Chapter/454499_1_En_7_Fig4_HTML.png
Fig. 7.4

A rotative spring-mass-damper system

On the other hand, using similar arguments, it is observed that, rearranging (7.27):
 $$\displaystyle \begin{aligned} \begin{array}{rcl} ml^2\ddot z_1+b\dot z_1-mglz_1=v. \end{array} \end{aligned} $$
When the pendulum operates around  $$x_1^*=\pm \pi $$ ,  $$x_2^*=0$$ , u  = 0, it behaves as a mass-spring-damper system possessing a negative stiffness constant K = −mgl < 0. This can be seen as follows. A positive stiffness constant K > 0 indicates that the force exerted by the spring is always in the opposite sense to its deformation and, because of that, the spring forces the body to move back to the point where the spring is not deformed. This is the reason why the pendulum oscillates around  $$x_1^*=0$$ ,  $$x_2^*=0$$ , u  = 0. On the other hand, because of the sign change, in a spring with a negative stiffness constant K < 0, the opposite must occur, i.e., the force exerted by the spring must now be directed in the same sense as the deformation. This means that the deformation of a spring with K < 0 forces the deformation to increase further, i.e., the body moves away from the point where the spring deformation is zero (i.e., where z 1 = 0). This is exactly what happens to a pendulum around  $$x_1^*=\pm \pi $$ ,  $$x_2^*=0$$ , u  = 0: if z 1 ≠ 0 then the gravity forces the pendulum to fall; hence, to move away from z 1 = 0, i.e., where  $$x_1=x_1^*=\pm \pi $$ . This behavior is the experimental corroboration of what is analytically demonstrated by a characteristic polynomial with a positive root: the operation points  $$x_1^*=\pm \pi $$ ,  $$x_2^*=0$$ , u  = 0 are unstable.

Note that using the above methodology, a linear approximate model of a nonlinear system is already given in terms of the equation error introduced in Sect. 7.2. The reader is referred to Sect. 13.​2, Chaps. 13, Sect. 15.​3, Chap. 15, and Sect. 16.​4, Chap. 16, to see some other examples of how to employ (7.22), (7.23), (7.24), to find linear approximate state equations for nonlinear state equations.

7.4 Some Results from Linear Algebra

Some results that are useful for studying the state variables approach are presented in this section.

Fact 7.1 ([1], chapter 2)

Let w 1, w 2, …, w n , be n vectors with n components. These vectors are linearly dependent if, and only if, there exist n scalars α 1, α 2, …, α n , not all zero such that:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \alpha_1w_1+\alpha_2w_2+\dots+\alpha_nw_n=0,{} \end{array} \end{aligned} $$
(7.29)

where zero at the right represents a vector with n zero components. If the only way of satisfying the latter expression is that α 1 = α 2 = ⋯ = α n  = 0, then it is said that w 1, w 2, …, w n , are linearly independent vectors .

In the simplest version of the linear dependence of vectors, two vectors with two components are linearly dependent if they are parallel. This can be shown as follows. Let w 1 and w 2 be two vectors, each one having n = 2 components. These vectors are linearly dependent if there are two constants α 1 ≠ 0 and α 2 ≠ 0 such that:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \alpha_1w_1+\alpha_2w_2=0, \end{array} \end{aligned} $$
which means that:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} w_1=-\frac{\alpha_2}{\alpha_1}w_2. \end{array} \end{aligned} $$
Note that α 1 cannot be zero for obvious reasons. On the other hand, if α 2 is zero, then w 1 = 0 is the only solution in this case that is not of interest. Hence, it is assumed that both α 1 ≠ 0 and α 2 ≠ 0. Thus, as the factor  $$-\frac {\alpha _2}{\alpha _1}$$ is a scalar (positive or negative), the above means that w 1 and w 2 are vectors with the same direction, i.e., they are parallel.1
In the case of three or more vectors, linear dependence means that one of vectors can be computed as the addition of the other vectors when suitably affected by factors α i (this is what is known as a linear combination of vectors), i.e.,:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} w_1=-\frac{\alpha_2}{\alpha_1}w_2-\frac{\alpha_3}{\alpha_1}w_3, \end{array} \end{aligned} $$
is directly obtained from (7.29) when n = 3 and α 1 ≠ 0. As n = 3, the above means that w 1, w 2 and w 3 are in the same plane, which is embedded in a volume (in R 3), i.e., that the linear combination of w 1, w 2 and w 3 does not allow another vector to be obtained that is not contained in the same plane. According to this, three vectors with three components are linearly independent if their linear combination spans three dimensions. Thus, the linear combination of n linearly independent vectors (with n components) spans an n −dimensional space. The linear combination of n linearly dependent vectors (with n components) spans a space with fewer than n dimensions.

Fact 7.2 ([1], chapter 2, [2], chapter 10)

Consider the following n × n matrix:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} E=\left[ \begin{array}{cccc} w_1 &amp;\displaystyle w_2 &amp;\displaystyle \dots&amp;\displaystyle w_n \end{array} \right], \end{array} \end{aligned} $$

where w 1, w 2, …, w n , are n column with n components. The vectors w 1, w 2, …, w n are linearly independent if, and only if, matrix E is nonsingular , i.e., if, and only if, the determinant of E is different from zero (  $$\det (E)\neq 0$$ ).

To explain this result, the following is employed.

Fact 7.3 ([1], chapter 2)

Consider an n × n matrix E. The only solution of Ew = 0, where w represents an n dimensional vector, is w = 0 if, and only if, matrix E is nonsingular.

Note that (7.29) can be written as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \alpha_1w_1+\alpha_2w_2+\dots+\alpha_nw_n=\left[ \begin{array}{cccc} w_1 &amp;\displaystyle w_2 &amp;\displaystyle \dots&amp;\displaystyle w_n \end{array} \right]\left[ \begin{array}{c} \alpha_1 \\ \alpha_2 \\ \vdots\\ \alpha_n \end{array} \right]=\left[ \begin{array}{c} 0\\ 0\\ \vdots\\ 0 \end{array} \right]. \end{array} \end{aligned} $$
According to Fact 7.3, the vector [α 1 α 2α n ] = [0 0 … 0] is the only solution of this homogeneous system if, and only if, the matrix E = [w 1 w 2w n ] is nonsingular. This implies that the vectors w 1, w 2, …, w n are linearly independent if, and only if,  $$\det (E)\neq 0$$ .

Fact 7.4 ([1], chapter 2)

The rank of an n × n matrix E is the order of the largest nonzero determinant obtained as submatrices of E. The rank of E is n if, and only if, E is nonsingular. The inverse matrix E −1 exists if, and only if, the matrix E is nonsingular [ 2 ], chapter 10.

Fact 7.5 ([1], chapter 2)

The eigenvalues of an n × n matrix E are those scalars λ satisfying:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \det(\lambda I-E)=0, \end{array} \end{aligned} $$

where I stands for the n × n identity matrix. The expression  $$\det (\lambda I-E)$$ is a n degree polynomial in the variable λ and it is known as the characteristic polynomial of the matrix E. The eigenvalues of a matrix E can be either real or complex numbers. Matrix E has exactly n eigenvalues, which can be repeated.

Fact 7.6 ([3], chapter 7)

Suppose that two n × n matrices, E and  $$\bar E$$ , are related as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \bar E&amp;\displaystyle =&amp;\displaystyle PEP^{-1},{} \end{array} \end{aligned} $$
(7.30)
where P is an n × n constant and nonsingular matrix, then both matrices, E and  $$\bar E$$ , possess identical eigenvalues. This means that:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \det(\lambda I-E)=\det(\lambda I-\bar E){} \end{array} \end{aligned} $$
(7.31)

The following is useful for explaining the above.

Fact 7.7 ([4], pp. 303)

Let D and G be two n × n matrices. Then:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \det(DG)=\det(D)\det(G).{} \end{array} \end{aligned} $$
(7.32)
As PP −1 = I and  $$\det (I)=1$$ , then (7.32) can be used to find that  $$\det (P)\det (P^{-1})=1$$ , i.e.,  $$\det (P^{-1})=\frac {1}{\det (P)}$$ . On the other hand, according to (7.30), (7.32), the characteristic polynomial of  $$\bar E$$ is:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \det(\lambda I-\bar E)&amp;\displaystyle =&amp;\displaystyle \det(\lambda I-PEP^{-1})=\det(P[\lambda I-E]P^{-1}),\\ &amp;\displaystyle =&amp;\displaystyle \det(P)\det(\lambda I-E)\det(P^{-1})=\det(\lambda I-E). \end{array} \end{aligned} $$
Note that (7.31) has been retrieved in the last expression, which verifies that result.

Fact 7.8 ([4], pp. 334))

Let E and F be two n × n matrices with F = E T . The eigenvalues of F are identical to eigenvalues of E.

The following is useful for explaining the above.

Fact 7.9 ([2], pp. 504)

The determinant of a matrix E is equal to the addition of the products of the elements of any row or column of E and their corresponding cofactors.

Fact 7.10 ([2], pp. 507)

If  $$\det (D)$$ is any determinant and  $$\det (G)$$ is the determinant whose rows are the columns of  $$\det (D)$$ , then  $$\det (D)=\det (G)$$ .

According to the above,  $$\det (\lambda I-E)$$ can be computed using, for instance, the first column of matrix λI − E, whereas  $$\det (\lambda I-F)$$ can be computed using, for instance, the first row of matrix λI − F. Note that the first column of λI − E is equal to the first row of λI − F as (λIE) T  = λI − F because F = E T . Similarly, the rows of the cofactor of entry at row i and column 1 in matrix λI − E are equal to the columns of the cofactor of entry at row 1 and column i in matrix λI − F. This shows that E and F have the same characteristic polynomial, i.e.,:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \det(\lambda I-E)=\det(\lambda I-F) \end{array} \end{aligned} $$
; thus, the eigenvalues of F are identical to those of E.

7.5 Solution of a Linear Time Invariant Dynamical Equation

Finding the solution of the dynamical equation:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x&amp;\displaystyle =&amp;\displaystyle Ax+Bu,x\in R^n, u\in R,{} \end{array} \end{aligned} $$
(7.33)
 $$\displaystyle \begin{aligned} \begin{array}{rcl} y&amp;\displaystyle =&amp;\displaystyle Cx,y\in R,{} \end{array} \end{aligned} $$
(7.34)
is a complex problem requiring the knowledge of advanced linear algebra and calculus concepts that are outside the scope of this book. However, the fundamental ideas that are involved in the corresponding procedure can be understood if resorting to the solution procedure of the following first-order differential equation:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x=ax+bu, x,u\in R. \end{array} \end{aligned} $$
Use of the Laplace transform yields:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} s X(s)-x(0)=aX(s)+bU(s), \end{array} \end{aligned} $$
where X(s), U(s), stand for Laplace transforms of x and u respectively. This can be written as follows:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} X(s)=\frac{b}{s-a}U(s)+\frac{x(0)}{s-a}.{} \end{array} \end{aligned} $$
(7.35)
Using the transformed pairs [5]:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \mathcal{L}\left\{e^{at}\right\}&amp;\displaystyle =&amp;\displaystyle \frac{1}{s-a}=G(s),{}\\ \mathcal{L}\left\{\int_0^t g(t-\tau) b u(\tau)d\tau\right\}&amp;\displaystyle =&amp;\displaystyle \frac{b}{s-a}U(s), \text{(convolution)},\\ g(t)&amp;\displaystyle =&amp;\displaystyle \mathcal{L}^{-1}\left\{G(s)\right\}, \end{array} \end{aligned} $$
(7.36)
it is found that, applying the inverse Laplace transform to (7.35), yields:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} x(t)=\int_0^t g(t-\tau) b u(\tau)d\tau+\text{e}^{at}x(0). \end{array} \end{aligned} $$
Finally, using (7.36) again:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} x(t)=\text{e}^{at}x(0)+\int_0^t \text{e}^{a(t-\tau)} b u(\tau)d\tau,x,u,a,b\in R. \end{array} \end{aligned} $$
The solution of the state equation in (7.33) is similar to this last equation and we just need to use matrix notation, i.e., the solution of (7.33) is [1], pp. 142:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} x(t)=\text{e}^{At}x(0)+\int_0^t \text{e}^{A(t-\tau)} B u(\tau)d\tau,x\in R^n,\ u\in R,{} \end{array} \end{aligned} $$
(7.37)
where e At is an n × n matrix2 and it is explained in the following how it is given.
  • If λ is a (positive, negative or zero) real nonrepeated eigenvalue of matrix A, then at least one of the entries of matrix e At includes the following function of time:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} c\,\text{e}^{\lambda t}, \end{array} \end{aligned} $$
    where c is a real constant.
  • If λ is a (positive, negative or zero) real and r times repeated eigenvalue of matrix A, then each one of the following functions of time:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} c_0\text{e}^{\lambda t},c_1t\text{e}^{\lambda t},c_2t^2\text{e}^{\lambda t}, \dots,c_{r-1}t^{r-1}\text{e}^{\lambda t}, \end{array} \end{aligned} $$
    where c k , k = 1, 2, …, r − 1, are real constants, are included in at least one of the entries of matrix e At .
  • If λ = a ± jb is a nonrepeated complex eigenvalue of matrix A, where  $$j=\sqrt {-1}$$ , a is a (positive, negative or zero) real number and b is a strictly positive real number, then each one of the following functions of time:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} c\, \text{e}^{a t}\sin{}(bt),d\,\text{e}^{a t}\cos{}(bt), \end{array} \end{aligned} $$
    where c and d are real constants, are included in at least one of the entries of matrix e At .
  • If λ = a ± jb is a complex eigenvalue of matrix A that repeats r times, where  $$j=\sqrt {-1}$$ , a is a (positive, negative or zero) real number and b is a strictly positive real number, then each one of the following functions of time:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} c_0\text{e}^{a t}\sin{}(bt), ,c_1t\text{e}^{a t}\sin{}(bt),c_2t^2\text{e}^{a t}\sin{}(bt), \dots,c_{r-1}t^{r-1}\text{e}^{a t}\sin{}(bt),\\ d_0\text{e}^{a t}\cos{}(bt), ,d_1t\text{e}^{a t}\cos{}(bt),d_2t^2\text{e}^{a t}\cos{}(bt), \dots,d_{r-1}t^{r-1}\text{e}^{a t}\cos{}(bt),\\ \end{array} \end{aligned} $$
    (7.38)

    where c k and d k , k = 1, 2, …, r − 1, are real constants, and included in at least one of the entries of matrix e At .

Finally, the output of the dynamical equation in (7.33), (7.34), is computed using (7.37), i.e.,:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} y(t)=C\text{e}^{At}x(0)+C\int_0^t \text{e}^{A(t-\tau)} B u(\tau)d\tau.{} \end{array} \end{aligned} $$
(7.39)

7.6 Stability of a Dynamical Equation

It is important to study the stability of the following dynamical equation without input:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x&amp;\displaystyle =&amp;\displaystyle Ex,{}\\ y&amp;\displaystyle =&amp;\displaystyle Cx, \end{array} \end{aligned} $$
(7.40)
where x ∈ R n , y ∈ R, E is an n × n constant matrix and C is a constant row vector with n components. Although a dynamical equation without input may seem unrealistic, it is shown in Sect. 7.11 that a closed-loop dynamical equation can be written as in (7.40), because in a feedback system the input is chosen as a function of the state, i.e., u = −Kx where K is a row vector with n components. Then, replacing this input in (7.33) and defining E = A − BK, (7.40) is retrieved. This is the main motivation for studying this dynamical equation without input.
Although a formal definition of stability of (7.40) is elaborated, it can be simplified, stating that the dynamical equation (7.40) is stable if lim t x(t) = 0 (hence, lim t y(t) = 0) for any initial state x(0) ∈ R n . This means that, if:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} x(t)=\left[\begin{array}{c} x_1(t)\\ x_2(t)\\ \vdots\\ x_n(t) \end{array}\right], \end{array} \end{aligned} $$
then lim t x i (t) = 0 for all i = 1, 2, …, n, for any initial state. According to the solution in (7.37), the solution of (7.40) is obtained by defining u = 0 and A = E in (7.37), i.e.,:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} x(t)=\text{e}^{Et}x(0). \end{array} \end{aligned} $$
As x(0) is a constant vector, the latter expression implies that, to satisfy lim t x(t) = 0, then lim t e Et  = 0 where “0” stands for an n × n matrix all of whose entries are equal to zero. Recalling how the entries of matrix e At , A = E, are given (see the the previous section) the following is proven:

Theorem 7.1 ([1], pp. 409)

The solution of (7.40) satisfies lim t x(t) = 0, no matter what the initial state x(0) is, if, and only if, all eigenvalues of matrix E have a strictly negative real part. Under these conditions, it is said that the origin x = 0 of (7.40) is globally asymptotically stable.

Recall that in Sect. 3.​4.​2, Chap. 3, it has been proven that:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \lim_{t\to\infty}t^j\;e^{pt}&amp;\displaystyle =&amp;\displaystyle 0, \end{array} \end{aligned} $$
for any integer j > 0 and any real number p < 0.

The reader may wonder why it is of interest to ensure that lim t x(t) = 0 in a practical control problem. To answer this question is important to stress that the above result is very important if the dynamical equation without input given in (7.40) represents the error equation (see Sect. 7.2) of the closed-loop system. In such a case, the state x represents the error state and, as explained in Sect. 7.2, ensuring that the state error converges to zero implies that the plant state converges to its desired value.

7.7 Controllability and Observability

Two important properties of the dynamical equation:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x&amp;\displaystyle =&amp;\displaystyle Ax+Bu,x\in R^n, u\in R,{} \end{array} \end{aligned} $$
(7.41)
 $$\displaystyle \begin{aligned} \begin{array}{rcl} y&amp;\displaystyle =&amp;\displaystyle Cx, y\in R,{} \end{array} \end{aligned} $$
(7.42)
that are employed throughout this chapter are controllability and observability.

7.7.1 Controllability

Definition 7.2 ([1], pp. 176)

A state equation is controllable at t 0 if there exists a finite time t 1 > t 0 such that given any states x 0 and x 1 exists and input u that is applied from t = t 0 to t = t 1 transfers the state from x 0 at t = t 0 to x 1 at t = t 1. Otherwise, the state equation is not controllable.

Note that this definition does not specify the trajectory to be tracked to transfer the state from x 0 to x 1. Furthermore, it is not necessary for the state to stay at x 1 for all t > t 1. Also note that controllability is a property that is only concerned with the input, i.e., with the state equation, and the output equation is not considered. Finally, this definition is very general as it also considers the possibility that the state equation is time variant, i.e., that the entries of A and B are functions of time.

In the case of a time-invariant state equation, such as that shown in (7.41), i.e., when all entries of A and B are constant, if the state equation is controllable then it is controllable for any t 0 ≥ 0 and t 1 is any value such that t 1 > t 0. This means that the transference from x 0 to x 1 can be performed in any nonzero time interval. This allows us to formulate a simple way of checking whether a state equation is controllable:

Theorem 7.2 ([6], pp. 145)

The state equation in (7.41) is controllable if, and only if , any of the following equivalent conditions are satisfied (see Exercises 10 and 11 at the end of this Chapter):
  1. 1.
    The following n × n matrix:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} W_c(t)=\int_0^t\mathit{\text{e}}^{A\tau}BB^T\left(\mathit{\text{e}}^{A\tau}\right)^Td\tau = \int_0^t\mathit{\text{e}}^{A(t-\tau)}BB^T\left(\mathit{\text{e}}^{A(t-\tau)}\right)^Td\tau,\\ {} \end{array} \end{aligned} $$
    (7.43)
    is nonsingular for any t > 0.
     
  2. 2.
    The n × n controllability matrix:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} \left[ \begin{array}{ccccc} B &amp; AB &amp; A^2B &amp;\cdots &amp;A^{n-1}B \end{array} \right],{} \end{array} \end{aligned} $$
    (7.44)
    has rank n, i.e., its determinant is different from zero.
     
The reason for this result can be explained as follows. The following input:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} u(t)=-B^T\left(\text{e}^{A(t_1-t)}\right)^TW_c^{-1}(t_1)[\text{e}^{At_1}x_0-x_1]{} \end{array} \end{aligned} $$
(7.45)
transfers the system state from x 0 = x(0) at t 0 = 0 to x 1 at t 1 > 0. This can be verified by replacing in the solution shown in (7.37) but evaluated at t = t 1, i.e.,:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} x(t_1)=\text{e}^{At_1}x(0)+\int_0^{t_1} \text{e}^{A(t_1-\tau)} B u(\tau)d\tau, \end{array} \end{aligned} $$
the input in (7.45) but evaluated at t = τ, i.e.,:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} u(\tau)=-B^T\left(\text{e}^{A(t_1-\tau)}\right)^TW_c^{-1}(t_1)[\text{e}^{At_1}x_0-x_1], \end{array} \end{aligned} $$
to obtain:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} x(t_1)&amp;\displaystyle =&amp;\displaystyle \text{e}^{At_1}x(0)\\ &amp;\displaystyle &amp;\displaystyle +\int_0^{t_1} \text{e}^{A(t_1-\tau)} B \left\{-B^T\left(\text{e}^{A(t_1-\tau)}\right)^TW_c^{-1}(t_1)[\text{e}^{At_1}x_0-x_1]\right\}d\tau,\\ &amp;\displaystyle =&amp;\displaystyle \text{e}^{At_1}x(0)\\ &amp;\displaystyle &amp;\displaystyle -\underbrace{\left\{\int_0^{t_1} \text{e}^{A(t_1-\tau)} B B^T\left(\text{e}^{A(t_1-\tau)}\right)^Td\tau \right\}}_{W_c(t_1)} W_c^{-1}(t_1)[\text{e}^{At_1}x_0-x_1],\\ &amp;\displaystyle =&amp;\displaystyle x_1. \end{array} \end{aligned} $$
Note that this result needs the n × n matrix W c (t), defined in (7.43), to be nonsingular, which is true for any t 1 = t > 0 if the state equation is controllable. The fact that t 1 is any positive time means that the state may go from x 0 to x 1 in any nonzero time interval.
On the other hand, the equation in (7.43) can be corroborated as follows. Defining v = t − τ:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \int_0^t\text{e}^{A(t-\tau)}BB^T\left(\text{e}^{A(t-\tau)}\right)^Td\tau &amp;\displaystyle =&amp;\displaystyle \int_{\tau=0}^{\tau=t}\text{e}^{A(t-\tau)}BB^T\left(\text{e}^{A(t-\tau)}\right)^Td\tau,\\ &amp;\displaystyle =&amp;\displaystyle \int_{v=t}^{v=0}\text{e}^{Av}BB^T\left(\text{e}^{Av}\right)^T(-dv),\\ &amp;\displaystyle =&amp;\displaystyle \int_{v=0}^{v=t}\text{e}^{Av}BB^T\left(\text{e}^{Av}\right)^Tdv, \end{array} \end{aligned} $$
which corroborates equation in (7.43) if τ is used instead of v in last integral, which is valid because the use of v or τ as the integration variable in the last integral does not affect the result.

Finally, the fact that the rank of matrix in (7.44) is n and the nonsingularity of W c (t) are equivalent conditions is very useful because it is easier to verify that (7.44) has rank n than the nonsingularity of W c (t).

7.7.2 Observability

Definition 7.3 ([1], pp. 193)

A dynamical equation is observable at t 0 if there is a finite t 1 > t 0 such that for any unknown state x 0 at t = t 0, the knowledge of the input u and the output y on the time interval [t 0, t 1] suffices to uniquely determine the state x 0. Otherwise the dynamical equation is not observable.

Note that observability is a property that is concerned with the possibility of knowing the system state (a variable that is internal to the system) only from measurements of the variables that are external to the system, i.e., the input and the output. Also note that this definition is very general as it also considers the possibility that the dynamical system is time variant, i.e., that the entries of A, B, and C are functions of time. In the case of a time invariant dynamical equation, such as that shown in (7.41), (7.42), with constant entries of A, B and C, if the dynamical equation is observable, then it is observable for all t 0 ≥ 0 and t 1 is any time such that t 1 > t 0. This means that the determination of the initial state can be performed in any nonzero time interval. This allows us to obtain a very simple way of checking whether a dynamical equation is observable:

Theorem 7.3 ([6], pp. 155, 156)

The dynamical equation in (7.41), (7.42), is observable if, and only if, any of the following equivalent conditions are satisfied:
  1. 1.
    The following n × n matrix:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} W_o(t)=\int_0^t\left(\mathit{\text{e}}^{A\tau}\right)^TC^TC\mathit{\text{e}}^{A\tau}d\tau, {} \end{array} \end{aligned} $$
    (7.46)
    is nonsingular for any t > 0.
     
  2. 2.
    The n × n observability matrix:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} \left[ \begin{array}{c} C\\ CA\\ CA^2\\ \vdots \\ CA^{n-1} \end{array} \right],{} \end{array} \end{aligned} $$
    (7.47)
    has a rank n, i.e., its determinant is different from zero.
     
The reason for this result is explained as follows. Consider the solution given in (7.39) and define:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \overline{y}(t)&amp;\displaystyle =&amp;\displaystyle C\text{e}^{At}x(0),{} \end{array} \end{aligned} $$
(7.48)
 $$\displaystyle \begin{aligned} \begin{array}{rcl} &amp;\displaystyle =&amp;\displaystyle y(t)-C\int_0^t \text{e}^{A(t-\tau)} B u(\tau)d\tau.{} \end{array} \end{aligned} $$
(7.49)
Note that, according to (7.49), the function  $$\overline {y}(t)$$ can be computed from the exclusive knowledge of the input and the output. Multiplying both sides of (7.48) by  $$\left (\text{e}^{At}\right )^TC^T$$ and integrating on [0, t 1] it is found that:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \underbrace{\left\{\int_0^{t_1}\left(\text{e}^{At}\right)^TC^TC\text{e}^{At}dt\right\}}_{W_o(t_1)}x(0)=\int_0^{t_1}\left(\text{e}^{At}\right)^TC^T\overline{y}(t)dt. \end{array} \end{aligned} $$
If the matrix W o (t 1) is nonsingular, which is true if the system is observable, then the initial state x(0) = x 0 can be uniquely computed as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} x_0=W_o^{-1}(t_1)\int_0^{t_1}\left(\text{e}^{At}\right)^TC^T\overline{y}(t)dt. \end{array} \end{aligned} $$
Note that this result needs the n × n matrix W o (t) defined in (7.46) to be nonsingular, which is true for any t 1 = t > 0 if the dynamical equation is observable. The fact that t 1 is any positive time means that the state x 0 can be computed with information obtained from the input and the output in any nonzero time interval.

Finally, the fact that the rank of matrix in (7.47) is n and the nonsingularity of W o (t) are equivalent conditions is very useful, as it is easier to check (7.47) to have rank n than the nonsingularity of W o (t).

Example 7.6

One way of estimating the actual state x(t) (not the initial state x(0)) is using input and output measurements in addition to some of their time derivatives. It is shown in the following that a necessary condition for this is, again, that the matrix in (7.47) has the rank n. Consider the dynamical equation in (7.41), (7.42). The first n − 1 time derivatives of the output are computed as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} y&amp;\displaystyle =&amp;\displaystyle Cx, \\ \dot y&amp;\displaystyle =&amp;\displaystyle C\dot x=CAx+CBu, \\ \ddot y&amp;\displaystyle =&amp;\displaystyle CA\dot x+CB\dot u=CA^2 x+CABu+CB\dot u, \\ y^{(3)}&amp;\displaystyle =&amp;\displaystyle CA^2 \dot x+CAB\dot u+CB\ddot u=CA^3 x+CA^2Bu+CAB\dot u+CB\ddot u, \\ &amp;\displaystyle \vdots&amp;\displaystyle \\ y^{(i)}&amp;\displaystyle =&amp;\displaystyle CA^i x+CA^{i-1}B u+CA^{i-2}B\dot u+\cdots+CB u^{(i-1)}, \\ &amp;\displaystyle \vdots&amp;\displaystyle \\ y^{(n-1)}&amp;\displaystyle =&amp;\displaystyle CA^{n-1} x+CA^{n-2}B u+CA^{n-3}B\dot u+\cdots+CB u^{(n-2)},\end{array} \end{aligned} $$
where the exponent between brackets stands for the order of a time derivative. Using matrix notation:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot Y&amp;\displaystyle =&amp;\displaystyle Dx(t)+\dot U, \end{array} \end{aligned} $$
where:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot Y&amp;\displaystyle =&amp;\displaystyle \left[\begin{array}{c}y\\ \dot y\\ \ddot y\\ y^{(3)}\\ \vdots\\ y^{(n-1)} \end{array}\right],D=\left[\begin{array}{c}C\\ CA\\ CA^2\\ CA^3\\ \vdots\\ CA^{n-1} \end{array}\right],\\ \dot U&amp;\displaystyle =&amp;\displaystyle \left[\begin{array}{c} 0\\ CBu\\ CABu+CB\dot u\\ CA^2Bu+CAB\dot u+CB\ddot u\\ \vdots\\ CA^{n-2}B u+CA^{n-3}B\dot u+\cdots+CB u^{(n-2)} \end{array}\right]. \end{array} \end{aligned} $$
Thus, if the matrix in (7.47) has the rank n, then the n × n matrix D is invertible and the actual state can be computed as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} x(t)=D^{-1}(\dot Y-\dot U),{} \end{array} \end{aligned} $$
(7.50)
i.e., by only employing input and output measurements in addition to some of their time derivatives. A drawback of (7.50) is that measurements of any variable have significant noise content in practice and this problem becomes worse as higher order time derivatives are computed from these measurements. This is the reason why (7.50) is not actually employed in practice to compute x(t) and asymptotic methods such as that presented in Sect. 7.12 are preferred.

7.8 Transfer Function of a Dynamical Equation

Consider the following single-input single-output dynamical equation:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x&amp;\displaystyle =&amp;\displaystyle Ax+Bu,{}\\ y&amp;\displaystyle =&amp;\displaystyle Cx, \end{array} \end{aligned} $$
(7.51)
where x ∈ R n , u ∈ R, y ∈ R, are functions of time, A is an n × n constant matrix, B is a constant column vector with n components and C is a constant row vector with n components. Applying the Laplace transform to (7.51), the following is obtained:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} sX(s)-x(0)&amp;\displaystyle =&amp;\displaystyle AX(s)+BU(s),{} \end{array} \end{aligned} $$
(7.52)
 $$\displaystyle \begin{aligned} \begin{array}{rcl} Y(s)&amp;\displaystyle =&amp;\displaystyle CX(s),{} \end{array} \end{aligned} $$
(7.53)
where X(s), Y (s), U(s) represent the Laplace transform of the state vector x, the scalar output y, and the scalar input u respectively, whereas x(0) is the initial value of the state x. Recall that, given a vectorial function of time x = [x 1, x 2, …, x n ] T , its Laplace transform is obtained by applying this operation to each entry of the vector, i.e., [3], chapter 4:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} X(s)=\left[\begin{array}{c} \mathcal{L}\left\{x_1\right\}\\ \mathcal{L}\left\{x_2\right\}\\ \vdots\\ \mathcal{L}\left\{x_n\right\} \end{array}\right]. \end{array} \end{aligned} $$
A transfer function is always defined assuming zero initial conditions. Replacing x(0) = 0 in (7.52) and solving for X(s):
 $$\displaystyle \begin{aligned} \begin{array}{rcl} X(s)&amp;\displaystyle =&amp;\displaystyle (sI-A)^{-1}BU(s),{} \end{array} \end{aligned} $$
(7.54)
where I represents the n × n identity matrix. Replacing (7.54) in (7.53) it is found that:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \frac{Y(s)}{U(s)}&amp;\displaystyle =&amp;\displaystyle G(s)=C(sI-A)^{-1}B.{} \end{array} \end{aligned} $$
(7.55)
Note that the transfer function G(s) given in (7.55) is a scalar. Now, proceed to analyze this transfer function. In the following, it is assumed that n = 3 for ease of exposition of ideas, i.e., that A is an 3 × 3 matrix, I is the 3 × 3 identity matrix, and B and C are column and row vectors respectively, with 3 components:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} A=\left[ \begin{array}{ccc} a_{11} &amp;\displaystyle a_{12} &amp;\displaystyle a_{13}\\ a_{21} &amp;\displaystyle a_{22} &amp;\displaystyle a_{23}\\ a_{31} &amp;\displaystyle a_{32} &amp;\displaystyle a_{33} \end{array} \right], B=\left[ \begin{array}{c} b_{1} \\ b_{2} \\ b_{3} \end{array} \right],C=\left[ \begin{array}{ccc} c_{1} &amp;\displaystyle c_{2} &amp;\displaystyle c_{3} \end{array} \right]. \end{array} \end{aligned} $$
The reader can verify that the same procedure is valid from any arbitrary n. First, compute the matrix:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} sI-A=\left[ \begin{array}{ccc} s-a_{11} &amp;\displaystyle -a_{12} &amp;\displaystyle -a_{13}\\ -a_{21} &amp;\displaystyle s-a_{22} &amp;\displaystyle -a_{23}\\ -a_{31} &amp;\displaystyle -a_{32} &amp;\displaystyle s-a_{33} \end{array} \right], \end{array} \end{aligned} $$
whose inverse matrix is given as  $$(sI-A)^{-1}=\frac {Adj(sI-A)}{\det (sI-A)}$$ where [2], chapter 10:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} Adj(sI-A)=Cof^T(sI-A)=\left[ \begin{array}{ccc} Cof_{11} &amp; Cof_{12} &amp; Cof_{13}\\ Cof_{21} &amp; Cof_{22} &amp; Cof_{23}\\ Cof_{31} &amp; Cof_{32} &amp; Cof_{33} \end{array} \right]^T,{} \end{array} \end{aligned} $$
(7.56)
with Cof(sI − A) the cofactors matrix of sI − A, and Cof ij  = (−1) i+j M ij with M ij the (n − 1) × (n − 1) determinant (2 × 2 in this case) resulting when eliminating the i −th row and the j −th column from the determinant of matrix sI − A [2], chapter 10. Explicitly computing these entries, it is realized that Cof ij is a polynomial in s whose degree is strictly less than n = 3. On the other hand, solving through the first row it is found that:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \det(sI-A)&amp;\displaystyle =&amp;\displaystyle (s-a_{11})\left| \begin{array}{cc} s-a_{22} &amp;\displaystyle -a_{23} \\ -a_{32} &amp;\displaystyle s-a_{33} \end{array} \right|+a_{12}\left| \begin{array}{cc} -a_{21} &amp;\displaystyle -a_{23} \\ -a_{31} &amp;\displaystyle s-a_{33} \end{array} \right|\\ &amp;\displaystyle &amp;\displaystyle -a_{13}\left| \begin{array}{cc} -a_{21} &amp;\displaystyle s-a_{22} \\ -a_{31} &amp;\displaystyle -a_{32} \end{array} \right|, \end{array} \end{aligned} $$
i.e.,  $$\det (sI-A)$$ is a polynomial in s whose degree equals n = 3. From these observations, it is concluded that all entries of the matrix:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} (sI-A)^{-1}=\frac{Adj(sI-A)}{\det(sI-A)}=\left[ \begin{array}{ccc} Inv_{11} &amp; Inv_{12} &amp; Inv_{13} \\ Inv_{21} &amp; Inv_{22} &amp; Inv_{23} \\ Inv_{31} &amp; Inv_{32} &amp; Inv_{33} \end{array} \right],{} \end{array} \end{aligned} $$
(7.57)
are given as the division of two polynomials in s such that the degree of the polynomial at the numerator is strictly less than n = 3 and the polynomial at the denominator is  $$\det (sI-A)$$ , which has the degree n = 3.
On the other hand, the product (sIA)−1 B is a column vector with n = 3 components. Each one of these components is obtained as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} (sI-A)^{-1}B=\left[ \begin{array}{c} d_{1} \\ d_{2}\\ d_{3} \end{array} \right]=\left[ \begin{array}{c} Inv_{11}\;b_1 + Inv_{12}\;b_2 + Inv_{13}\;b_3 \\ Inv_{21}\;b_1 + Inv_{22}\;b_2 + Inv_{23}\;b_3 \\ Inv_{31}\;b_1 + Inv_{32}\;b_2 + Inv_{33}\;b_3 \end{array} \right]. \end{array} \end{aligned} $$
According to the previous discussion on the way in which the entries Inv ij of matrix (sIA)−1 are given, and resorting to the addition of fractions with the same denominator, it is concluded that each one of the entries d i of the column vector (sIA)−1 B is also given as a division of two polynomials in s such that the polynomial at the numerator has a degree strictly less than n = 3 whereas the polynomial at the denominator is  $$\det (sI-A)$$ , whose degree equals n = 3. Finally, the following is found:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} C(sI-A)^{-1}B= c_1d_{1} + c_2d_{2}+ c_3d_{3}.\end{array} \end{aligned} $$
Reasoning as before, the following is concluded, which is valid for any arbitrary n:

Fact 7.11 ([1], chapters 6, 7)

The transfer function in (7.55) is a scalar, which is given as the division of two polynomials in s such that the degree of the polynomial at the numerator is strictly less than n and the polynomial at the denominator, given as  $$\det (sI-A)$$ , has the degree n, i.e.,
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \frac{Y(s)}{U(s)}&amp;\displaystyle =&amp;\displaystyle G(s)=C(sI-A)^{-1}B=\frac{b_ms^m+b_{m-1}s^{m-1}+\cdots+b_1s+b_0}{s^n+a_{n-1}s^{n-1}+\cdots+a_1s+a_0},\\ {} \\ \det(sI-A)&amp;\displaystyle =&amp;\displaystyle s^n+a_{n-1}s^{n-1}+\cdots+a_1s+a_0, \end{array} \end{aligned} $$
(7.58)

for some real constants b k , a l , k = 0, 1, …, m, l = 0, 1, …, n − 1, with n > m.

However, this statement is completely true if the following is satisfied [1], chapter 7:

Condition 7.1

The dynamical equation in (7.51) must be controllable, i.e., the determinant of the matrix in (7.44) must be different from zero.

Moreover, if the following is also true, then the polynomials b m s m  + b m−1 s m−1 + ⋯ + b 1 s + b 0 and s n  + a n−1 s n−1 + ⋯ + a 1 s + a 0 have no common roots [1], chapter 6:

Condition 7.2

The dynamical equation in (7.51) is observable, i.e., the determinant of the matrix in (7.47) is different from zero.

Finally, the reader can revise the discussion presented above to verify that:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \frac{Y(s)}{U(s)}&amp;\displaystyle =&amp;\displaystyle G(s)+D, \end{array} \end{aligned} $$
is the transfer function of the dynamical equation:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x&amp;\displaystyle =&amp;\displaystyle Ax+Bu,\\ y&amp;\displaystyle =&amp;\displaystyle Cx+Du, \end{array} \end{aligned} $$
where x ∈ R n , u ∈ R, y ∈ R, are functions of time, A is an n × n constant matrix, B is a constant column vector with n components, C is a constant row vector with n components, and D is a constant scalar. This means that the polynomials at the numerator and the denominator of  $$\frac {Y(s)}{U(s)}$$ have the same degree in this case.

Example 7.7

According to Chap. 10, the mathematical model of a permanent magnet brushed DC motor is given as (see (10.​8)):
 $$\displaystyle \begin{aligned} J\ddot{\theta}+ b\dot{\theta}=n\;k_{m}\;i^*, \end{aligned} $$
when no external disturbance is present. Furthermore, the electric current i can be considered to be the input signal if an internal high-gain electric current loop is employed. Defining the state variables as the position and the velocity, it is not difficult to realize that the following dynamical equation is obtained:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x&amp;=&amp;Ax+Bu,y=Cx,{}\\ x&amp;=&amp;\left[ \begin{array}{c} x_1\\ x_2 \end{array} \right]=\left[ \begin{array}{c} \theta\\ \dot\theta \end{array} \right],A=\left[ \begin{array}{cc} 0&amp;1\\ 0&amp;-\frac{b}{J} \end{array} \right],B=\left[ \begin{array}{c} 0\\ \frac{nk_m}{J} \end{array} \right],u=i^*, \end{array} \end{aligned} $$
(7.59)
where C is a row vector to be defined later depending on the output to be considered. Note that the following matrix:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \left[ \begin{array}{cc} B &amp;\displaystyle AB \end{array} \right]= \left[ \begin{array}{cc} 0 &amp;\displaystyle \frac{nk_m}{J}\\ \frac{nk_m}{J}&amp;\displaystyle -\frac{nk_m}{J}\frac{b}{J} \end{array} \right], \end{array} \end{aligned} $$
has the rank n = 2 because its determinant is equal to  $$-\left (\frac {nk_m}{J}\right )^2\neq 0$$ . From the definitions in (7.59) the following results are obtained:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} sI-A&amp;\displaystyle =&amp;\displaystyle \left[ \begin{array}{cc} s &amp;\displaystyle -1\\ 0&amp;\displaystyle s+\frac{b}{J} \end{array} \right], \det(sI-A)=s\left(s+\frac{b}{J}\right),\\ Cof(sI-A)&amp;\displaystyle =&amp;\displaystyle \left[ \begin{array}{cc} s+\frac{b}{J}&amp;\displaystyle 0\\ 1&amp;\displaystyle s \end{array} \right],Adj(sI-A)=Cof^T(sI-A)=\left[ \begin{array}{cc} s+\frac{b}{J}&amp;\displaystyle 1\\ 0&amp;\displaystyle s \end{array} \right],\\ (sI-A)^{-1}&amp;\displaystyle =&amp;\displaystyle \frac{Adj(sI-A)}{\det(sI-A)}=\frac{1}{s(s+\frac{b}{J})}\left[ \begin{array}{cc} s+\frac{b}{J}&amp;\displaystyle 1\\ 0 &amp;\displaystyle s \end{array} \right]. \end{array} \end{aligned} $$
To obtain the corresponding transfer function, the following cases are considered:
  • The output is the position, i.e., y = θ = x 1 = Cx, where C = [1 0]. Then:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} G(s)&amp;\displaystyle =&amp;\displaystyle C(sI-A)^{-1}B=\left[ \begin{array}{cc} 1 &amp;\displaystyle 0 \end{array} \right]\frac{1}{s(s+\frac{b}{J})}\left[ \begin{array}{cc} s+\frac{b}{J}&amp;\displaystyle 1\\ 0 &amp;\displaystyle s \end{array} \right]\left[ \begin{array}{c} 0\\ \frac{nk_m}{J} \end{array} \right],\\ G(s)&amp;\displaystyle =&amp;\displaystyle \frac{\frac{nk_m}{J}}{s(s+\frac{b}{J})}. \end{array} \end{aligned} $$
    In this case, the matrix:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} \left[ \begin{array}{c} C\\ CA \end{array} \right]= \left[ \begin{array}{cc} 1 &amp;\displaystyle 0\\ 0&amp;\displaystyle 1 \end{array} \right], \end{array} \end{aligned} $$
    has the rank n = 2 because its determinant is unity, i.e., it is different from zero.
  • The output is velocity, i.e.,  $$y=\dot \theta =x_2=Cx$$ , where C = [0 1]. Then:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} G(s)&amp;\displaystyle =&amp;\displaystyle C(sI-A)^{-1}B=\left[ \begin{array}{cc} 0 &amp;\displaystyle 1 \end{array} \right]\frac{1}{s(s+\frac{b}{J})}\left[ \begin{array}{cc} s+\frac{b}{J}&amp;\displaystyle 1\\ 0 &amp;\displaystyle s \end{array} \right]\left[ \begin{array}{c} 0\\ \frac{nk_m}{J} \end{array} \right],\\ G(s)&amp;\displaystyle =&amp;\displaystyle \frac{\frac{nk_m}{J}s}{s(s+\frac{b}{J})}. \end{array} \end{aligned} $$
    The following matrix:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} \left[ \begin{array}{c} C\\ CA \end{array} \right]= \left[ \begin{array}{cc} 0 &amp;\displaystyle 1\\ 0&amp;\displaystyle -\frac{b}{J} \end{array} \right], \end{array} \end{aligned} $$
    has a rank less than n = 2 because its determinant is zero.
Note that in both cases the transfer function obtained satisfies what was established in (7.58): the polynomial at the denominator is equal to  $$\det (sI-A)$$ . Also note that this is true because matrix [B AB] has the rank n = 2 in both cases. Finally, the effect due to the fact that the system is not observable is also present: in the second case the system is not observable; hence, the corresponding transfer function has one pole and one zero, which cancel each other out and this does not occur in the first case because the system is observable. Such pole-zero cancellation in the second case results in a first-order transfer function, which means that only one of the states (velocity) is described by this transfer function. This implies that the motor position has no effect when velocity is the variable to control.
The above results are useful for giving an interpretation of observability in the following. When the output is the position, the system is observable because, once the position is known, the velocity can be computed (the other state variable) by position differentiation, for instance. But, if the output is velocity, the knowledge of this variable does not suffice to compute the position (the other state variable): although it may be argued that the position θ(t) can be computed by simple velocity integration, note that:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \theta(t)-\theta(0)=\int_0^t\dot\theta(r)dr, \end{array} \end{aligned} $$
means that besides the knowledge of velocity, it is necessary to know the initial position θ(0), which is also unknown. Thus, the system is not observable when the output is velocity. However, as previously stated, if controlling the velocity is the only thing that matters, then this can be performed without any knowledge of the position. Observability is important in other classes of problems that are studied later in Sects. 7.12 and 7.13.

Finally, the reader can verify the correctness of the above results by comparing the transfer functions obtained with those in Chaps. 10 and 11.

7.9 A Realization of a Transfer Function

The realization of a transfer function consists in finding a dynamical equation that describes the transfer function in an identical way. The importance of this problem arises, for instance, when a controller is given that is expressed as a transfer function. Then, expressing a transfer function in terms of a dynamical equation is important for practical implementation purposes because the latter can be solved numerically, for instance.

An important property of the state variables representation is that it is not unique. This means that several dynamical equations exist correctly describing the same physical system. This also means that given a transfer function, several dynamical equations exist correctly describing this transfer function. In the following, a way of obtaining one of these dynamical equations is presented. Consider the following transfer function:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \frac{Y(s)}{U(s)}&amp;\displaystyle =&amp;\displaystyle G(s)=\frac{b_ms^m+b_{m-1}s^{m-1}+\cdots+b_1s+b_0} {s^n+a_{n-1}s^{n-1}+\cdots+a_1s+a_0}.{} \end{array} \end{aligned} $$
(7.60)
Solving for the output:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} Y(s)=\frac{b_ms^m+b_{m-1}s^{m-1}+\cdots+b_1s+b_0} {s^n+a_{n-1}s^{n-1}+\cdots+a_1s+a_0}\;U(s). \end{array} \end{aligned} $$
Define the following variable:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} V(s)=\frac{1} {s^n+a_{n-1}s^{n-1}+\cdots+a_1s+a_0}\;U(s), {} \end{array} \end{aligned} $$
(7.61)
to write:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} Y(s)=(b_ms^m+b_{m-1}s^{m-1}+\cdots+b_1s+b_0)V(s).{} \end{array} \end{aligned} $$
(7.62)
Applying the inverse Laplace transform to (7.61) and solving for the highest order time derivative:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} v^{(n)}=-a_{n-1}v^{(n-1)}-\cdots-a_1\dot v-a_0 v+u,{} \end{array} \end{aligned} $$
(7.63)
where  $$V(s)=\mathcal {L}\left \{v\right \}$$ . According to Sect. 7.1, define the state variables as the unknown variable in (7.63), v, and its first n − 1 time derivatives:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \bar x_1=v, \bar x_2=\dot v, \bar x_3=\ddot v, \dots , \bar x_n=v^{(n-1)}.{} \end{array} \end{aligned} $$
(7.64)
Then, (7.63) can be written as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot {\bar x}_n=-a_{n-1}\bar x_n-\cdots-a_1\bar x_2-a_0 \bar x_1+u.{} \end{array} \end{aligned} $$
(7.65)
On the other hand, using the inverse Laplace transform in (7.62), the following is obtained:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} y=b_mv^{(m)}+b_{m-1}v^{(m-1)}+\cdots+b_1\dot v+b_0 v. \end{array} \end{aligned} $$
If it is assumed that m takes its maximal value, i.e., m = n − 1 (recall that n > m) then (7.64) can be used to write:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} y=b_{n-1}\bar x_n+b_{n-2}\bar x_{n-1}+\cdots+b_1\bar x_2+b_0 \bar x_1.{} \end{array} \end{aligned} $$
(7.66)
Using (7.64), (7.65) and (7.66), the following can be written:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot{\bar x}&amp;=&amp;\bar A\bar x+\bar B u,{}\\ y&amp;=&amp;\bar C\bar x,\\ \bar A&amp;=&amp;\left[\begin{array}{ccccccc} 0 &amp; 1 &amp; 0 &amp; 0 &amp;\cdots &amp; 0&amp; 0\\ 0 &amp; 0 &amp; 1 &amp; 0 &amp;\cdots &amp; 0&amp;0\\ 0 &amp; 0 &amp; 0 &amp; 1 &amp;\cdots &amp; 0&amp;0\\ 0 &amp; 0 &amp; 0 &amp; 0 &amp;\cdots &amp; 0&amp;0\\ \vdots &amp; \vdots &amp; \vdots&amp; \vdots &amp;\ddots &amp; \vdots&amp;\vdots\\ 0 &amp; 0 &amp; 0 &amp; 0 &amp;\cdots &amp; 0&amp;1\\ -a_{0} &amp; -a_{1} &amp; -a_{2} &amp; -a_{3} &amp;\cdots &amp; -a_{n-2}&amp;-a_{n-1} \end{array}\right],\bar B=\left[\begin{array}{c} 0 \\ 0 \\ 0 \\ 0 \\ \vdots\\ 0\\ 1 \end{array}\right],\\ \bar C&amp;=&amp;\left[\begin{array}{ccccccc} b_0 &amp; b_1 &amp; b_2 &amp; b_3 &amp;\cdots &amp; b_{n-2}&amp;b_{n-1} \end{array}\right],\\ \bar x&amp;=&amp;\left[\begin{array}{ccccccc} \bar x_1 &amp; \bar x_2 &amp; \bar x_3 &amp; \bar x_4 &amp;\cdots &amp; \bar x_{n-1}&amp; \bar x_{n} \end{array}\right]^T. \end{array} \end{aligned} $$
(7.67)
The dynamical equation in (7.67) represents identically the transfer function in (7.60) and it is said that it is written in the controllability canonical form . As is shown later, the controllability canonical form is very useful for finding a procedure for designing a state feedback controller.

7.10 Equivalent Dynamical Equations

It has been shown in Sect. 7.8 that any controllable single-input single-output dynamical equation (7.51) can be written as the transfer function in (7.58). Note that requiring observability is merely to ensure that no pole-zero cancellation is present in (7.58). On the other hand, it has been shown in Sect. 7.9 that the transfer function in (7.58) can be written as the dynamical equation in (7.67). This means that any of the dynamical equations in (7.51) or (7.67) can be obtained from the other, i.e., these dynamical equations are equivalent.

In the following, it is shown how to obtain (7.51) from (7.67) and vice versa, without the necessity of the intermediate step of a transfer function. Consider the single-input single-output dynamical equation in (7.51) and define the following linear transformation :
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \bar x&amp;\displaystyle =&amp;\displaystyle Px,{} \end{array} \end{aligned} $$
(7.68)
where P is an n × n constant matrix defined from its inverse matrix as [1], chapter 7:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} P^{-1}&amp;=&amp;\left[ \begin{array}{ccccc} q_1 &amp; \cdots&amp;q_{n-2}&amp;q_{n-1} &amp;q_n \end{array} \right],{}\\ q_n&amp;=&amp;B, \\ q_{n-1}&amp;=&amp;AB+a_{n-1}B, \\ q_{n-2}&amp;=&amp;A^2B+a_{n-1}AB+a_{n-2}B, \\ &amp;\vdots&amp; \\ q_1&amp;=&amp;A^{n-1}B+a_{n-1}A^{n-2}B+\cdots+a_{1}B, \\ \det(sI-A)&amp;=&amp;s^n+a_{n-1}s^{n-1}+\cdots+a_1s+a_0. \end{array} \end{aligned} $$
(7.69)
It is important to stress that the matrix P −1 is invertible, i.e., its inverse matrix P always exists if the matrix defined in (7.44) has the rank n [1], chapter 7, or equivalently if (7.51) is controllable. This can be explained as follows. If the matrix defined in (7.44) has the rank n, i.e., all its columns are linearly independent, then when adding its columns as in the previous expressions defining vectors q 1, …, q n−2, q n−1, q n , the columns q 1, …, q n−2, q n−1, q n are linearly independent (see fact 7.1). This means that the determinant of P −1 is different from zero; hence, its inverse matrix P exists.
Using (7.68) in (7.51), i.e.,  $$\dot {\bar x}=P\dot x$$ , it is found that:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot{\bar x}&amp;\displaystyle =&amp;\displaystyle \bar A\bar x+\bar B u,\\ y&amp;\displaystyle =&amp;\displaystyle \bar C\bar x,\\ \bar A&amp;\displaystyle =&amp;\displaystyle PAP^{-1}, \bar B=PB, \bar C=CP^{-1}.{} \end{array} \end{aligned} $$
(7.70)
The matrix  $$\bar A$$ and the vectors  $$\bar B$$ ,  $$\bar C$$ in (7.70) are given as in the controllability canonical form (7.67) no matter what the particular form of A, B and C is, as long as the matrix defined in (7.44) has the rank n. A formal proof for this latter statement requires mathematical tools that are outside of the scope of this book; hence, it is not presented. The reader is advised to see [1] for a complete solution to this problem. The reader can also verify these ideas by proposing numerical values for the matrices A, B, and C, and performing the corresponding computations. The above means that each one of the dynamical equations (7.51) and (7.67) can be obtained from the other and the relationship among the matrices involved is given in (7.70), i.e., these dynamical equations are equivalent. Note that the fundamental condition for the existence of this equivalence is that the matrix defined in (7.44) has the rank n [1], chapter 5. This is summarized as follows:

Theorem 7.4 ([1], chapter 7)

If (7.51) is controllable, then this dynamical equation is equivalent to (7.67) through the linear transformation (7.68), (7.69), i.e., through (7.70).

Example 7.8

The linear approximate model of a mechanism known as the Furuta pendulum is obtained in Chap. 15. This model is presented in (15.​17), (15.​18), and it is rewritten here for ease of reference:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot z&amp;=&amp;Az+\mathcal{B}v,{}\\ A&amp;=&amp;\left[ \begin{array}{cccc} 0 &amp; 1 &amp;0&amp;0\\ 0&amp;0&amp;\frac{-gm_1^2l_1^2L_0}{I_0(J_1+m_1l_1^2)+J_1m_1L_0^2}&amp;0\\ 0 &amp; 0 &amp;0&amp;1\\ 0&amp;0&amp;\frac{(I_0+m_1L_0^2)m_1l_1g}{I_0(J_1+m_1l_1^2)+J_1m_1L_0^2}&amp;0 \end{array} \right],\mathcal{B}=\left[ \begin{array}{c} 0\\ \frac{J_1+m_1l_1^2}{I_0(J_1+m_1l_1^2)+J_1m_1L_0^2}\\ 0\\ \frac{-m_1l_1L_0}{I_0(J_1+m_1l_1^2)+J_1m_1L_0^2} \end{array} \right]\frac{k_m}{r_a}. \end{array} \end{aligned} $$
(7.71)
To render the algebraic manipulation easier, the following constants are defined:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} a&amp;\displaystyle =&amp;\displaystyle \frac{-gm_1^2l_1^2L_0}{I_0(J_1+m_1l_1^2)+J_1m_1L_0^2}, b=\frac{(I_0+m_1L_0^2)m_1l_1g}{I_0(J_1+m_1l_1^2)+J_1m_1L_0^2},\\ c&amp;\displaystyle =&amp;\displaystyle \frac{J_1+m_1l_1^2}{I_0(J_1+m_1l_1^2)+J_1m_1L_0^2}\frac{k_m}{r_a},d= \frac{-m_1l_1L_0}{I_0(J_1+m_1l_1^2)+J_1m_1L_0^2}\frac{k_m}{r_a}. \end{array} \end{aligned} $$
The following matrix has the form:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} C_o=\left[ \begin{array}{cccc} \mathcal{B} &amp;\displaystyle A\mathcal{B} &amp;\displaystyle A^2\mathcal{B}&amp;\displaystyle A^3\mathcal{B} \end{array} \right] =\left[ \begin{array}{cccc} 0 &amp;\displaystyle c &amp;\displaystyle 0&amp;\displaystyle ad\\ c&amp;\displaystyle 0&amp;\displaystyle ad&amp;\displaystyle 0\\ 0 &amp;\displaystyle d &amp;\displaystyle 0&amp;\displaystyle bd\\ d&amp;\displaystyle 0&amp;\displaystyle bd&amp;\displaystyle 0 \end{array} \right]. \end{array} \end{aligned} $$
After a straightforward but long algebraic procedure, it is found that:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \det(C_o)=\frac{m_1^4l_1^4L_0^2g^2}{[I_0(J_1+m_1l_1^2)+J_1m_1L_0^2]^4}\frac{k_m^4}{r_a^4}\neq 0. \end{array} \end{aligned} $$
Thus, the dynamical equation in (7.71) is controllable for any set of the Furuta pendulum parameters. This result does not change if the mechanism is large or small, heavy or light. This also means that the matrix P introduced in (7.68) is nonsingular and it is computed in the following using (7.69). To simplify the computations, the following numerical values are employed:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} I_{0}&amp;\displaystyle =&amp;\displaystyle 1{.}137\times 10^{-3}\text{[kgm}^2\text{]},J_1=0{.}38672\times 10^{-3}\text{[kgm}^2\text{]},g=9{.}81\text{[m/s}^2\text{]}\\ l_1&amp;\displaystyle =&amp;\displaystyle 0{.}1875\text{[m]},m_1=0{.}033\text{[kg]}, L_0=0{.}235\text{[m]},\frac{k_m}{r_a}=0{.}0215\text{[Nm/V]}. \end{array} \end{aligned} $$
Hence:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} A&amp;\displaystyle =&amp;\displaystyle \left[ \begin{array}{cccc} 0 &amp;\displaystyle 1 &amp;\displaystyle 0&amp;\displaystyle 0\\ 0&amp;\displaystyle 0&amp;\displaystyle -35{.}81&amp;\displaystyle 0\\ 0 &amp;\displaystyle 0 &amp;\displaystyle 0&amp;\displaystyle 1\\ 0&amp;\displaystyle 0&amp;\displaystyle 72{.}90&amp;\displaystyle 0 \end{array} \right], \mathcal{B}=\left[ \begin{array}{c} 0\\ 13{.}4684\\ 0\\ -12{.}6603 \end{array} \right]. \end{array} \end{aligned} $$
With these data, the roots of the characteristic polynomial  $$\det (\lambda I-A)$$ are found to be:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \lambda_1= 0,\lambda_2= 0,\lambda_3=8{.}5381,\lambda_4= -8{.}5381. \end{array} \end{aligned} $$
Then the following product is computed:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} (\lambda-\lambda_1)(\lambda-\lambda_2)(\lambda-\lambda_3)(\lambda-\lambda_4)=\lambda^4+a_3\lambda^3+a_2\lambda^2+a_1\lambda+a_0, \end{array} \end{aligned} $$
to find, by equating coefficients on both sides:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} a_3= 0,a_2=-72{.}9,a_1=0,a_0=0.{} \end{array} \end{aligned} $$
(7.72)
Using these values in (7.69) the following is found:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} P^{-1}=\left[ \begin{array}{cccc} -528{.}481 &amp;\displaystyle 0 &amp;\displaystyle 13{.}4684 &amp;\displaystyle 0\\ 0 &amp;\displaystyle -528{.}481&amp;\displaystyle 0 &amp;\displaystyle 13{.}4684 \\ 0 &amp;\displaystyle 0 &amp;\displaystyle -12{.}6603 &amp;\displaystyle 0\\ 0 &amp;\displaystyle 0 &amp;\displaystyle 0 &amp;\displaystyle -12{.}6603 \end{array} \right], \end{array} \end{aligned} $$
hence:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} P=\left[ \begin{array}{cccc} -0{.}0019 &amp; 0 &amp; -0{.}0020 &amp; 0\\ 0 &amp; -0{.}0019 &amp; 0 &amp;-0{.}0020\\ 0 &amp; 0 &amp; -0{.}0790 &amp; 0\\ 0 &amp; 0 &amp; 0 &amp;-0{.}0790 \end{array} \right].{} \end{array} \end{aligned} $$
(7.73)
Finally, to verify (7.70), the following products are performed:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} PAP^{-1}=\left[ \begin{array}{cccc} 0 &amp;\displaystyle 1{.}0000 &amp;\displaystyle 0 &amp;\displaystyle 0\\ 0 &amp;\displaystyle 0 &amp;\displaystyle 1{.}0000 &amp;\displaystyle 0\\ 0 &amp;\displaystyle 0 &amp;\displaystyle 0 &amp;\displaystyle 1{.}0000\\ 0 &amp;\displaystyle 0 &amp;\displaystyle 72{.}9 &amp;\displaystyle 0 \end{array} \right],PB=\left[ \begin{array}{c} 0\\ 0\\ 0\\ 1 \end{array} \right]. \end{array} \end{aligned} $$
Note that these matrices have exactly the same form as that presented in (7.67) for  $$\bar A=PAP^{-1}$$ and  $$\bar B=PB$$ . The above computations have been performed by executing the following MATLAB code in an m-file:
clc
A=[0 1 0 0;
0 0 -35.81 0;
0 0 0 1;
0 0 72.90 0];
B=[0;
13.4684;
0;
-12.6603];
U=[B A∗B Aˆ2∗B Aˆ3∗B];
det(U)
v=eig(A)
f=conv([1 -v(1)],[1 -v(2)]);
g=conv(f,[1 -v(3)]);
h=conv(g,[1 -v(4)]);
a3=h(2);
a2=h(3);
a1=h(4);
a0=h(5);
q4=B;
q3=A∗B+a3∗B;
q2=Aˆ2∗B+a3∗A∗B+a2∗B;
q1=Aˆ3∗B+a3∗Aˆ2∗B+a2∗A∗B+a1∗B;
invP=[q1 q2 q3 q4]
P=inv(invP)
Ab=P∗A∗invP
Bb=P∗B

7.11 State Feedback Control

In this section, it is assumed that the plant to be controlled is given in terms of the error equation (see Sect. 7.2), i.e., given a plant as in (7.51), it is assumed that the state x stands for the state error. Hence, the control objective is defined as ensuring that the state error tends toward zero as time increases, i.e., lim t x(t) = 0.

Consider the single-input state equation in (7.51), in closed-loop with the following controller:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} u&amp;=&amp;-Kx=-(k_1 x_1+ k_2x_2 +\dots+ k_nx_n),{}\\ K&amp;=&amp;\left[ \begin{array}{cccc} k_1 &amp; k_2 &amp; \dots&amp; k_n \end{array} \right], \end{array} \end{aligned} $$
(7.74)
where k i , i = 1, …, n, are n constant scalars. Substituting (7.74) in (7.51), it is found that:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x&amp;\displaystyle =&amp;\displaystyle (A-BK)x.{} \end{array} \end{aligned} $$
(7.75)
This state equation has no input like that in (7.40). Hence, the stability criterion for (7.40) can be applied to (7.75). This means that the vector x(t), the solution of (7.75), satisfies lim t x(t) = 0 if, and only if, all eigenvalues of the matrix A − BK have a strictly negative real part. However, from the point of view of a practical application, this is not enough as a good closed-loop performance is also required. It is important to stress that the waveform of the solution x(t) of (7.75) depends on the exact location of the eigenvalues of the matrix A − BK. Hence, it must be possible to arbitrarily assign the eigenvalues of the matrix A − BK. As the row vector K can be chosen as desired, it is of interest to know how to choose K such that the eigenvalues of A − BK are assigned as desired. The solution to this problem is presented in the following.
Consider the linear transformation (7.68), (7.69), and substitute it in (7.75) to obtain:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot{\bar x}&amp;\displaystyle =&amp;\displaystyle \bar A\bar x-\bar B\bar K\bar x,{}\\ \bar K&amp;\displaystyle =&amp;\displaystyle KP^{-1}, \end{array} \end{aligned} $$
(7.76)
where  $$\bar A$$ and  $$\bar B$$ are given as in (7.70) and (7.67). Note that  $$\bar K\bar x$$ is a scalar given as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \bar K\bar x&amp;\displaystyle =&amp;\displaystyle \bar k_1 \bar x_1+ \bar k_2 \bar x_2 + \dots+ \bar k_n \bar x_n ,\\ \bar K&amp;\displaystyle =&amp;\displaystyle \left[ \begin{array}{cccc} \bar k_1 &amp;\displaystyle \bar k_2 &amp;\displaystyle \dots&amp;\displaystyle \bar k_n \end{array} \right], \end{array} \end{aligned} $$
, which, according to (7.67), only affects the last row of (7.76); hence, the following can be written:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot{\bar x}&amp;\displaystyle =&amp;\displaystyle (\bar A-\bar B\bar K)\bar x,\\ &amp;\displaystyle &amp;\displaystyle \bar A-\bar B\bar K=\\ &amp;\displaystyle &amp;\displaystyle \left[\begin{array}{ccccccc} 0 &amp;\displaystyle 1 &amp;\displaystyle 0 &amp;\displaystyle 0 &amp;\displaystyle \cdots &amp;\displaystyle 0&amp;\displaystyle 0\\ 0 &amp;\displaystyle 0 &amp;\displaystyle 1 &amp;\displaystyle 0 &amp;\displaystyle \cdots &amp;\displaystyle 0&amp;\displaystyle 0\\ 0 &amp;\displaystyle 0 &amp;\displaystyle 0 &amp;\displaystyle 1 &amp;\displaystyle \cdots &amp;\displaystyle 0&amp;\displaystyle 0\\ 0 &amp;\displaystyle 0 &amp;\displaystyle 0 &amp;\displaystyle 0 &amp;\displaystyle \cdots &amp;\displaystyle 0&amp;\displaystyle 0\\ \vdots &amp;\displaystyle \vdots &amp;\displaystyle \vdots&amp;\displaystyle \vdots &amp;\displaystyle \ddots &amp;\displaystyle \vdots&amp;\displaystyle \vdots\\ 0 &amp;\displaystyle 0 &amp;\displaystyle 0 &amp;\displaystyle 0 &amp;\displaystyle \cdots &amp;\displaystyle 0&amp;\displaystyle 1\\ -\bar k_1-a_{0} &amp;\displaystyle -\bar k_2 -a_{1} &amp;\displaystyle -\bar k_3 -a_{2} &amp;\displaystyle -\bar k_4-a_{3} &amp;\displaystyle \cdots &amp;\displaystyle -\bar k_{n-1}-a_{n-2}&amp;\displaystyle -\bar k_{n}-a_{n-1} \end{array}\right]. \end{array} \end{aligned} $$
If the following is chosen:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \bar K&amp;=&amp;\left[ \begin{array}{cccc} \bar a_0-a_0 &amp; \bar a_1-a_1 &amp; \dots&amp; \bar a_{n-1}-a_{n-1} \end{array} \right],{} \end{array} \end{aligned} $$
(7.77)
the following is obtained:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \bar A-\bar B\bar K&amp;\displaystyle =&amp;\displaystyle \left[\begin{array}{ccccccc} 0 &amp;\displaystyle 1 &amp;\displaystyle 0 &amp;\displaystyle 0 &amp;\displaystyle \cdots &amp;\displaystyle 0&amp;\displaystyle 0\\ 0 &amp;\displaystyle 0 &amp;\displaystyle 1 &amp;\displaystyle 0 &amp;\displaystyle \cdots &amp;\displaystyle 0&amp;\displaystyle 0\\ 0 &amp;\displaystyle 0 &amp;\displaystyle 0 &amp;\displaystyle 1 &amp;\displaystyle \cdots &amp;\displaystyle 0&amp;\displaystyle 0\\ 0 &amp;\displaystyle 0 &amp;\displaystyle 0 &amp;\displaystyle 0 &amp;\displaystyle \cdots &amp;\displaystyle 0&amp;\displaystyle 0\\ \vdots &amp;\displaystyle \vdots &amp;\displaystyle \vdots&amp;\displaystyle \vdots &amp;\displaystyle \ddots &amp;\displaystyle \vdots&amp;\displaystyle \vdots\\ 0 &amp;\displaystyle 0 &amp;\displaystyle 0 &amp;\displaystyle 0 &amp;\displaystyle \cdots &amp;\displaystyle 0&amp;\displaystyle 1\\ -\bar a_{0} &amp;\displaystyle -\bar a_{1} &amp;\displaystyle -\bar a_{2} &amp;\displaystyle -\bar a_{3} &amp;\displaystyle \cdots &amp;\displaystyle -\bar a_{n-2}&amp;\displaystyle -\bar a_{n-1} \end{array}\right]. \end{array} \end{aligned} $$
Note that, according to (7.70) and (7.76), the following can be written:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \bar A-\bar B\bar K= PAP^{-1}-PBKP^{-1}=P(A-BK)P^{-1}, \end{array} \end{aligned} $$
i.e., the matrices  $$\bar A-\bar B\bar K$$ and A − BK satisfy (7.30); hence, they possess identical eigenvalues. According to previous sections, the eigenvalues λ of  $$\bar A-\bar B\bar K$$ satisfy:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \det(\lambda I-[\bar A-\bar B\bar K])&amp;\displaystyle =&amp;\displaystyle \lambda^n+\bar a_{n-1} \lambda^{n-1}+\cdots+\bar a_1 \lambda+\bar a_0,\\ &amp;\displaystyle =&amp;\displaystyle \prod_{i=1}^{n}(\lambda-\bar\lambda_i), \end{array} \end{aligned} $$
where  $$\bar \lambda _i$$ , i = 1, …, n stand for the desired eigenvalues and these are proposed by the designer. It is stressed that when a complex conjugate desired eigenvalue is proposed, then its corresponding complex conjugate pair must also be proposed. This is to ensure that all the coefficients  $$\bar a_i$$ , i = 0, 1, …, n − 1 are real, which also ensures that all the gains  $$\bar K$$ and K are real. The following is the procedure [1], chapter 7, suggested to compute the vector of the controller gains K, which assigns the desired eigenvalues for the closed-loop matrix A − BK.
  • Check that the state equation in (7.51) is controllable. If this is the case, proceed as indicated in the remaining steps. Otherwise, it is not possible to proceed.

  • Find the polynomial:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} \det(\lambda I-A)&amp;\displaystyle =&amp;\displaystyle \lambda^n+a_{n-1}\lambda^{n-1}+\cdots+a_1\lambda+a_0. \end{array} \end{aligned} $$
  • Propose the desired closed-loop eigenvalues  $$\bar \lambda _1,\bar \lambda _2,\dots ,\bar \lambda _n$$ . If some of them are complex, then also propose its corresponding complex conjugate pair as one of the desired eigenvalues.

  • Compute:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} \prod_{i=1}^{n}(\lambda-\bar\lambda_i) &amp;\displaystyle =&amp;\displaystyle \lambda^n+\bar a_{n-1}\lambda^{n-1}+\cdots+ \bar a_1\lambda+\bar a_0. \end{array} \end{aligned} $$
  • Compute:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} \bar K &amp;\displaystyle =&amp;\displaystyle \left[ \begin{array}{cccc} \bar a_0-a_0 &amp;\displaystyle \bar a_1-a_1 &amp;\displaystyle \dots&amp;\displaystyle \bar a_{n-1}-a_{n-1} \end{array} \right]. \end{array} \end{aligned} $$
  • Compute the vectors q 1, …, q n−2, q n−1, q n according to (7.69), obtain the matrix P −1 defined in that expression and obtain its inverse matrix P.

  • Compute the vector of controller gains in (7.74) as  $$K=\bar K P$$ .

Example 7.9

Let us continue with the Example 7.8, in which the Furuta pendulum is studied. It is desired, now, to find the vector of controller gains K, which, when used in the controller (7.74) (with x = z), assigns the eigenvalues of matrix A − BK at:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \bar\lambda_1= -94,\bar\lambda_2= -18,\bar\lambda_3= -0{.}5, \bar\lambda_4=-1. \end{array} \end{aligned} $$
To this aim, the coefficients of the following polynomial:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} (\lambda-\bar\lambda_1)(\lambda-\bar\lambda_2)(\lambda-\bar\lambda_3)(\lambda-\bar\lambda_4)=\lambda^4+\bar a_3\lambda^3+\bar a_2\lambda^2+\bar a_1\lambda+\bar a_0, \end{array} \end{aligned} $$
are found to be:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \bar a_3= 113{.}5,\bar a_2=1860{.}5,\bar a_1=2594,\bar a_0=846. \end{array} \end{aligned} $$
Using these values and those obtained in (7.72),  $$\bar K$$ is computed according to (7.77), i.e.,:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \bar K= \left[ \begin{array}{cccc} 846 &amp;\displaystyle 2594 &amp;\displaystyle 1933{.}3&amp;\displaystyle 113{.}5 \end{array} \right].\end{array} \end{aligned} $$
Finally, using this and matrix P shown in (7.73) the vector of the controller gains K is computed using  $$ K=\bar K P$$ :
 $$\displaystyle \begin{aligned} \begin{array}{rcl} K= \left[ \begin{array}{cccc} -1{.}5997&amp;\displaystyle -4{.}9138 &amp;\displaystyle -154{.}4179 &amp;\displaystyle -14{.}1895 \end{array}\right].\end{array} \end{aligned} $$
The above computations are performed by executing the following MATLAB code after executing the MATLAB code at the end of Example 7.8:
lambda1d=-94;
lambda2d=-18;
lambda3d=-0.5;
lambda4d=-1;
fd=conv([1 -lambda1d],[1 -lambda2d]);
gd=conv(fd,[1 -lambda3d]);
hd=conv(gd,[1 -lambda4d]);
a3b=hd(2);
a2b=hd(3);
a1b=hd(4);
a0b=hd(5);
Kb=[a0b-a0 a1b-a1 a2b-a2 a3b-a3];
K=Kb∗P
eig(A-B∗K)
The command “eig(A-B*K)” is employed to verify that matrix A-B*K has the desired eigenvalues. Some simulation results are presented in Figs. 7.5 and 7.6 when controlling the Furuta pendulum using the vector gain K = [−1.5997  − 4.9138  − 154.4179  − 14.1895] and z 1(0) = z 2(0) = z 4(0) = 0, z 3(0) = 0.3 as initial conditions. Note that all the state variables converge to zero, as expected. These simulations were performed using the MATLAB/Simulink diagram in Fig. 7.7. Block Furuta has the following parameters:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} A\Rightarrow A,B\Rightarrow B, [1\; 0\;0\;0;0\; 1\;0\;0;0\;\;0\;1\;0;0\;\;0\;0\;1]\Rightarrow C,[0;0;0;0]\Rightarrow D, \end{array} \end{aligned} $$
and [0 0 0.3 0] as initial conditions. To obtain these results, one has to proceed as follows: (1) Execute the above MATLAB code to compute all the required parameters. (2) Run the simulation in Fig. 7.7. (3) Execute the following MATLAB code in an m-file:
/epubstore/G/V-M-Guzman/Automatic-Control-With-Experiments/OEBPS/images/454499_1_En_7_Chapter/454499_1_En_7_Fig5_HTML.png
Fig. 7.5

Simulation result for the state z 1 of the Furuta pendulum

/epubstore/G/V-M-Guzman/Automatic-Control-With-Experiments/OEBPS/images/454499_1_En_7_Chapter/454499_1_En_7_Fig6_HTML.png
Fig. 7.6

Simulation results for the Furuta pendulum. Top: z 2. Middle: z 3. Bottom: z 4

/epubstore/G/V-M-Guzman/Automatic-Control-With-Experiments/OEBPS/images/454499_1_En_7_Chapter/454499_1_En_7_Fig7_HTML.png
Fig. 7.7

MATLAB/Simulink diagram for the Furuta pendulum

nn=length(States(:,1));
n=nn-1;
Ts=1/n;
t=0:Ts:1;
figure(1)
subplot(3,1,1)
plot(t,States(:,1),'b-');
ylabel('rad')
figure(2)
subplot(3,1,1)
plot(t,States(:,2),'b-');
ylabel('rad/s')
subplot(3,1,2)
plot(t,States(:,3),'b-');
ylabel('rad')
subplot(3,1,3)
plot(t,States(:,4),'b-');
ylabel('rad/s')
xlabel('t [s]')

At this point, Figs. 7.5 and 7.6 are drawn.

7.12 State Observers

In this section, it is assumed again that the plant to be controlled is given in terms of the error equation (see Sect. 7.2), i.e., given a plant as in (7.51), it is assumed that the state x stands for the error state. Hence, the control objective is defined as ensuring that the state error tends toward zero as time increases, i.e., lim t x(t) = 0.

As pointed out in Sect. 7.1, the state x is composed of variables that are internal to the system; hence, they are not known in general. On the other hand, the output y represents a variable that is always known. This means that the practical implementation of the controller (7.74) is only possible if the complete state is measured. Because of this, it is important to know an estimate of the state x(t), which is represented by  $$\widehat x(t)$$ , allowing a controller to be constructed of the form:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} u&amp;=&amp;-K\widehat x=-(k_1 \widehat x_1+ k_2\widehat x_2 +\dots+ k_n\widehat x_n),{}\\ K&amp;=&amp;\left[ \begin{array}{cccc} k_1 &amp; k_2 &amp; \dots&amp; k_n \end{array} \right],\widehat x=\left[ \begin{array}{cccc} \widehat x_1 &amp; \widehat x_2 &amp; \dots&amp; \widehat x_n \end{array} \right]^T. \end{array} \end{aligned} $$
(7.78)
The estimate  $$\widehat x$$ is computed using a state observer or, simply, an observer. An observer must compute  $$\widehat x$$ exclusively employing information provided by the system input and output. On the other hand, if the controller (7.78) has to replace the controller in (7.74), then a fundamental property that an observer must satisfy is that the estimate  $$\widehat x$$ converges to x as fast as possible or, at least, asymptotically, i.e., such that:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \lim_{t\to\infty}\widehat x(t)&amp;\displaystyle =&amp;\displaystyle x(t). \end{array} \end{aligned} $$
An observer satisfying this property is the following:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot{\widehat x}=(A-LC)\widehat x+Ly+Bu,{} \end{array} \end{aligned} $$
(7.79)
where L = [L 1, L 2, …, L n ] T is a constant column vector. This can be explained as follows. Define the estimation error as  $$\tilde x=x-\widehat x$$ . Then, subtracting (7.79) from (7.51) the following is obtained:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot{\tilde x}&amp;\displaystyle =&amp;\displaystyle Ax-(A-LC)\widehat x-Ly. \end{array} \end{aligned} $$
Using y = Cx:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot{\tilde x}&amp;\displaystyle =&amp;\displaystyle A\tilde x-LC\tilde x,\\ &amp;\displaystyle =&amp;\displaystyle (A-LC)\tilde x. \end{array} \end{aligned} $$
Using the results in Sect. 7.6, it is concluded that  $$\lim _{t\to \infty }\tilde x(t)=0$$ ; hence,  $$\lim _{t\to \infty }\widehat x(t)=x(t)$$ if, and only if, all the eigenvalues of matrix A − LC have strictly negative real parts. Hence, the only problem that remains is how to select the gain column vector L such that all the eigenvalues of matrix A − LC have strictly negative real parts and that they can be arbitrarily assigned. This problem is solved as follows:

Theorem 7.5 ([1], pp. 358)

The state of the dynamical equation in (7.51) can be estimated using the observer in (7.79) and all the eigenvalues of matrix A  LC can be arbitrarily assigned, if, and only if, (7.51) is observable.

Again, the complex eigenvalues must appear as complex conjugate pairs. To explain the above result, the following theorem is useful.

Theorem 7.6 ([1], pp. 195)

Consider the following dynamical equations:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x&amp;\displaystyle =&amp;\displaystyle Ax+Bu,{}\\ y&amp;\displaystyle =&amp;\displaystyle Cx, \end{array} \end{aligned} $$
(7.80)
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot z&amp;\displaystyle =&amp;\displaystyle -A^Tz+C^Tu,{}\\ \gamma&amp;\displaystyle =&amp;\displaystyle B^Tz, \end{array} \end{aligned} $$
(7.81)

where u, y, γ  R, whereas x, z  R n . The dynamical equation in (7.80) is controllable (observable) if, and only if, the dynamical equation in (7.81) is observable (controllable).

Hence, going back to the observer problem, as the pair (A, C) is observable, then the pair (−A T , C T ) and the pair (A T , C T ) are controllable (because sign “−” of matrix A T does not affect the linear independence of the columns of the matrix in (7.44), see Sect. 7.4). From this, it is concluded that, following the procedure introduced in Sect. 7.11, it is always possible to find a constant row vector K such that the matrix A T  − C T K has any desired set of eigenvalues (arbitrary eigenvalues). As the eigenvalues of any matrix are identical to those of its transposed matrix (see Sect. 7.4), then the matrix A − K T C has the same eigenvalues as matrix A T  − C T K (the desired eigenvalues). Defining L = K T , the gain column vector required to design the observer in (7.79) is computed.

It is stressed that assigning the eigenvalues to the matrix A − LC arbitrarily means that they can be located where desired by the designer. It is obvious that all eigenvalues must have strictly negative real parts; however, they must be located on regions of the complex plane ensuring a fast convergence of  $$\widehat x(t)$$ to x(t). To determine where the eigenvalues of matrix A − LC must be located, the concepts of the transient response studied in Chap. 3, where a relationship has been established with a location of poles of the transfer function in (7.58), are very important.

Finally, note that given the plant  $$\dot x=Ax+Bu$$ we can try to construct an observer as  $$\dot {\widehat x}=A\widehat x+Bu$$ , which results in the following estimation error dynamics:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot{\tilde x}&amp;\displaystyle =&amp;\displaystyle A\tilde x, \tilde x=x-\widehat x. \end{array} \end{aligned} $$
If all the eigenvalues of the matrix A have negative real parts, then  $$\lim _{t\to \infty }\tilde x(t)=0$$ is ensured and the observer works. However, this result is very limited because it is constrained to be used only with plants that are open-loop asymptotically stable. Moreover, even in such a case, the convergence speed of  $$\tilde x\to 0$$ depends on the eigenvalue locations of the open-loop plant, i.e., it is not possible to render such a convergence arbitrarily fast. Note that, according to the previous arguments in this section, these drawbacks are eliminated when using the observer in (7.79). Also see Example 7.6.

7.13 The Separation Principle

When a dynamical equation (plant):
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x&amp;\displaystyle =&amp;\displaystyle Ax+Bu,{}\\ y&amp;\displaystyle =&amp;\displaystyle Cx, \end{array} \end{aligned} $$
(7.82)
and an observer:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot{\widehat x}&amp;\displaystyle =&amp;\displaystyle (A-LC)\widehat x+Ly+Bu,{} \end{array} \end{aligned} $$
(7.83)
are connected using the following controller (see Fig. 7.8):
 $$\displaystyle \begin{aligned} \begin{array}{rcl} u&amp;\displaystyle =&amp;\displaystyle -K\widehat x=-(k_1 \widehat x_1+ k_2\widehat x_2 +\dots+ k_n\widehat x_n),{} \end{array} \end{aligned} $$
(7.84)
the question arises regarding how the stability of the closed-loop system (7.82), (7.83), (7.84), is affected, i.e., it is important to verify whether ensuring that  $$\lim _{t\to \infty }\widehat x(t)=x(t)$$ and lim t x(t) = 0 are enough to ensure stability of the complete closed-loop system. The answer to this question is known as the separation principle , which claims the following:
/epubstore/G/V-M-Guzman/Automatic-Control-With-Experiments/OEBPS/images/454499_1_En_7_Chapter/454499_1_En_7_Fig8_HTML.png
Fig. 7.8

A feedback system employing an observer to estimate the state

Fact 7.12 ([1], pp. 367)

The eigenvalues of the closed-loop system (7.82), (7.83), (7.84), are the union of the eigenvalues of matrices A  BK and A  LC.

This means that the eigenvalues of the observer are not affected by the feedback in (7.84) and, at least in what concerns the eigenvalues, there is no difference between feeding back the estimate  $$\widehat x(t)$$ and feeding back the actual state x(t). However, the reader must be aware that the system’s transient response is often different if x(t) is employed or  $$\widehat x(t)$$ is employed to compute the input. The important fact is that both  $$\lim _{t\to \infty }\widehat x(t)=x(t)$$ and lim t x(t) = 0 are still true and the complete closed-loop system is stable. Thus, the design of the vector of controller gains K and the vector of gains L for the observer can be performed independently of each other.

Example 7.10

Consider the DC motor in Example 7.7, i.e., consider the dynamical equation:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x&amp;=&amp;Ax+Bu,y=Cx,{}\\ x&amp;=&amp;\left[ \begin{array}{c} x_1\\ x_2 \end{array} \right]=\left[ \begin{array}{c} \theta\\ \dot\theta \end{array} \right],A=\left[ \begin{array}{cc} 0&amp;1\\ 0&amp;-\frac{b}{J} \end{array} \right],B=\left[ \begin{array}{c} 0\\ \frac{nk_m}{J} \end{array} \right],C=[1 \ 0],u=i^*, \end{array} \end{aligned} $$
(7.85)
where it is assumed that the output is the position whereas velocity cannot be measured; hence, it shall be estimated using an observer. Suppose that it is desired to control the motor to reach a constant position, i.e., the desired values of the position and velocity are:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} x_{1d}=\theta_d,x_{2d}=0, \end{array} \end{aligned} $$
where θ d is a constant representing the desired position and the desired velocity is zero because the desired position is constant. Defining the state variables as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \tilde x_1=x_1-x_{1d},\tilde x_2=x_2, \end{array} \end{aligned} $$
and computing  $$\dot {\tilde x}_1=\dot x_1-\dot x_{1d}=x_2=\tilde x_2$$ ,  $$\dot { \tilde x}_2=\dot x_2=\ddot \theta $$ , the following dynamical equation is obtained:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot{\tilde x}&amp;\displaystyle =&amp;\displaystyle A\tilde x+Bu,{}\\ \gamma&amp;\displaystyle =&amp;\displaystyle C\tilde x, \end{array} \end{aligned} $$
(7.86)
where γ is the new output and the matrix A and vectors B, C, are defined as in (7.85). Note that the measured output is now the position error  $$\gamma =\tilde x_1$$ . From this point on, the numerical values of the motor controlled in Chap. 11 are considered, i.e.,:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} k=\frac{nk_m}{J}=675{.}4471,a=\frac{b}{J}=2{.}8681.{} \end{array} \end{aligned} $$
(7.87)
The corresponding observer is designed in the following. In the Example 7.7, it was shown that the dynamical equation in (7.85) is observable; hence, the dynamical equation in (7.86) is also observable. According to theorem 7.6, this implies that pairs (−A T , C T ) and (A T , C T ) are controllable, i.e., that the following matrices have the rank n = 2:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \left[ \begin{array}{cc} C^T &amp;\displaystyle -A^TC^T \end{array} \right],\left[ \begin{array}{cc} C^T &amp;\displaystyle A^TC^T \end{array} \right],\end{array} \end{aligned} $$
because the sign “−” of the matrix A does not affect the linear independence of these columns (see Sect. 7.4). Using the numerical values in (7.87), the roots of the polynomial  $$\det (\lambda I-A^T)$$ are computed:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \lambda_1= 0,\lambda_2=-2{.}8681. \end{array} \end{aligned} $$
Then, the following product is performed:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} (\lambda-\lambda_1)(\lambda-\lambda_2)=\lambda^2+a_1\lambda+a_0, \end{array} \end{aligned} $$
and equating coefficients:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} a_1=2{.}8681 ,a_0= 0. {} \end{array} \end{aligned} $$
(7.88)
Using B = C T and A T , instead of A, (7.69) becomes:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} P^{-1}&amp;\displaystyle =&amp;\displaystyle \left[ \begin{array}{ccccc} q_1 &amp;\displaystyle q_2 \end{array} \right],\\ q_2&amp;\displaystyle =&amp;\displaystyle C^T, \\ q_{1}&amp;\displaystyle =&amp;\displaystyle A^TC^T+a_{1}C^T.\end{array} \end{aligned} $$
Using the numerical values in (7.87), (7.88), in addition to the matrix A and vector C defined in (7.85) the following is obtained:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} P^{-1}= \left[ \begin{array}{cc} 2{.}8681 &amp;\displaystyle 1{.}0000\\ 1{.}0000 &amp;\displaystyle 0 \end{array} \right], \end{array} \end{aligned} $$
hence:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} P=\left[ \begin{array}{cc} 0 &amp; 1{.}0000\\ 1{.}0000 &amp; -2{.}8681 \end{array} \right].{} \end{array} \end{aligned} $$
(7.89)
Suppose that it is desired to assign the following eigenvalues to matrix A − LC:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \bar\lambda_1= -150,\bar\lambda_2= -100. {} \end{array} \end{aligned} $$
(7.90)
Then, the following polynomial is computed:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} (\lambda-\bar\lambda_1)(\lambda-\bar\lambda_2)=\lambda^2+\bar a_1\lambda+\bar a_0, \end{array} \end{aligned} $$
to find, equating coefficients, that:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \bar a_1=250,\bar a_0=15000. \end{array} \end{aligned} $$
Using these data and values in (7.88), the vector of gains  $$\bar K$$ is computed according to (7.77):
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \bar K= \left[ \begin{array}{cc} 15000 &amp;\displaystyle 247 \end{array} \right].\end{array} \end{aligned} $$
Using this and the matrix P shown in (7.89), the vector of the controller gains K is computed as  $$K=\bar K P$$ and it is assigned L = K T :
 $$\displaystyle \begin{aligned} \begin{array}{rcl} L= \left[ \begin{array}{c} 247\\ 14291 \end{array}\right]. {} \end{array} \end{aligned} $$
(7.91)
On the other hand, using a similar procedure to those in examples 7.14.1 and 7.14.2, it is found that the vector of the controller gains:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} K= \left[ \begin{array}{cc} 1{.}6889 &amp; 0{.}0414\\ \end{array} \right], {} \end{array} \end{aligned} $$
(7.92)
assigns at:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} -15{.}4+30{.}06j,-15{.}4-30{.}06j,{} \end{array} \end{aligned} $$
(7.93)
the eigenvalues of the matrix A − BK. Note that the gains in (7.92) are identical to the proportional and velocity feedback gains for the controller designed and experimentally tested in Sect. 11.​2.​1 Chap. 11, where the closed-loop poles are assigned at the values in (7.93). The above computations have been performed by executing the following MATLAB code in an m-file:
clc
k=675.4471;
a=2.8681;
A=[0 1;
0 -a];
B=[0;
k];
C=[1 0];
v=eig(A');
h=conv([1 -v(1)],[1 -v(2)]);
a0=h(3);
a1=h(2);
q2=C';
q1=A'∗C'+a1∗C';
invP=[q1 q2]
P=inv(invP)
lambda1d=-150;
lambda2d=-100;
hd=conv([1 -lambda1d],[1 -lambda2d]);
a0b=hd(3);
a1b=hd(2);
Kb=[a0b-a0 a1b-a1];
K=Kb∗P;
L=K'
v=eig(A);
h=conv([1 -v(1)],[1 -v(2)]);
a0=h(3);
a1=h(2);
q2=B;
q1=A∗B+a1∗B;
invP=[q1 q2]
P=inv(invP)
lambda1d=-15.4+30.06∗j;
lambda2d=-15.4-30.06∗j;
hd=conv([1 -lambda1d],[1 -lambda2d]);
a0b=hd(3);
a1b=hd(2);
Kb=[a0b-a0 a1b-a1];
K=Kb∗P
F=[L B];
Finally, it is stressed that the observer to construct is given as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot{ z}=(A-LC) z+L\gamma+Bu,{} \end{array} \end{aligned} $$
(7.94)
where z = [z 1 z 2] T is the estimate of vector  $$\tilde x=[\tilde x_1\ x_2]^T$$ y u = i . The controller is given as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} u=-K\left[\begin{array}{c}z_1 \\ z_2\end{array}\right],{} \end{array} \end{aligned} $$
(7.95)
where L and K take the values indicated in (7.91) and (7.92). Note that the controller must employ z 1, i.e., the estimate of  $$\tilde x_1$$ , despite  $$\tilde x_1$$ being a known measured variable. This is because the theory above assumes that the whole state is to be estimated and fed back. In this respect, it is worth saying that the so-called reduced-order observers also exist that estimate only the unknown part of the estate if the other states are known. The reader is referred to [1] for further details.
In Fig. 7.9, some simulation results are shown when using the observer in (7.94) and the feedback in (7.95) together with the gains in (7.91) and (7.92) to control a DC motor whose parameters are shown in (7.87). The desired position is θ d  = 2, the observer initial conditions are z(0) = [0 0] T , whereas θ(0) = 0 (i.e.,  $$\tilde x_1(0)=-2$$ ) and  $$\dot \theta (0)=2$$ . It is observed that the estimates z 1 and z 2 asymptotically converge to the real values  $$\tilde x_1$$ and x 2 and that both  $$\tilde x_1$$ and x 2 converge to zero, i.e., θ converges to θ d . It is interesting to realize that this convergence is achieved before the motor finishes responding. This has been accomplished by selecting the eigenvalues of the matrix A − LC (shown in (7.90)) to be much faster than the eigenvalues assigned to the matrix A − BK (shown in (7.93)). This is a criterion commonly used to assign the eigenvalues for an observer.
/epubstore/G/V-M-Guzman/Automatic-Control-With-Experiments/OEBPS/images/454499_1_En_7_Chapter/454499_1_En_7_Fig9_HTML.png
Fig. 7.9

Simulation results. Use of the observer in (7.94) to control a DC motor Top figure: continuous  $$\tilde x_1$$ , dashed z 1 Bottom figure: continuous  $$\tilde x_2=x_2$$ , dashed z 2

In Fig. 7.10 the MATLAB/Simulink diagram used to perform the above simulations is presented. Block step represents θ d  = 2. Block DC motor has the following parameters:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} A\Rightarrow A,B\Rightarrow B, [1\; 0;0\; 1]\Rightarrow C,[0;0]\Rightarrow D, \end{array} \end{aligned} $$
and [0 2] as initial conditions. The observer block has the following parameters:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} A-L*[1\;0]\Rightarrow A,F\Rightarrow B, [1\; 0;0\; 1]\Rightarrow C,[0\; 0;0\; 0]\Rightarrow D, \end{array} \end{aligned} $$
and [0 0] as initial conditions, where the matrix F is computed at the end of the last MATLAB code above in an m-file. The simulation must be performed following these steps: (1) Execute last MATLAB code above in an m-file. (2) Run the simulation in Fig. 7.10. (3) Execute the following MATLAB code in an m-file:
nn=length(Estados(:,1));
n=nn-1;
Ts=0.5/n;
t=0:Ts:0.5;
figure(1)
subplot(2,1,1)
plot(t,Estados(:,1),'b-',t,Estados(:,3),'r--');
axis([0 0.3 -2.5 1])
ylabel('rad')
subplot(2,1,2)
plot(t,Estados(:,2),'b-',t,Estados(:,4),'r--');
axis([0 0.3 -100 100])
xlabel('t [s]')
ylabel('rad/s')
/epubstore/G/V-M-Guzman/Automatic-Control-With-Experiments/OEBPS/images/454499_1_En_7_Chapter/454499_1_En_7_Fig10_HTML.png
Fig. 7.10

MATLAB/Simulink diagram for use of the observer in (7.94) to control a DC motor

At this point, Fig. 7.9 is drawn.

7.14 Case Study: The Inertia Wheel Pendulum

7.14.1 Obtaining Forms in (7.67)

In Chap. 16 the linear approximate model of a mechanism known as the inertia wheel pendulum is obtained. This model is shown in (16.​25), (16.​28), and it is rewritten here for ease of reference:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot z&amp;=&amp;Az+\mathcal{B}w,{}\\ A&amp;=&amp; \left[\begin{array}{ccc} 0 &amp; 1 &amp; 0 \\ \overline{d}_{11}\overline{m}g &amp; 0 &amp; 0 \\ \overline{d}_{21}\overline{m}g &amp; 0 &amp; 0 \end{array}\right],\mathcal{B}= \left[\begin{array}{c} 0\\ \overline{d}_{12}\\ \overline{d}_{22}\\ \end{array}\right]\frac{k_m}{R}. \end{array} \end{aligned} $$
(7.96)
To simplify the algebraic manipulation, the following constants are defined:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} a&amp;\displaystyle =&amp;\displaystyle \overline{d}_{11}\overline{m}g, b=\overline{d}_{21}\overline{m}g,\\ c&amp;\displaystyle =&amp;\displaystyle \overline{d}_{12}\frac{k_m}{R},d= \overline{d}_{22}\frac{k_m}{R}. \end{array} \end{aligned} $$
The following matrix has the form:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} C_o=\left[ \begin{array}{ccc} \mathcal{B} &amp;\displaystyle A\mathcal{B} &amp;\displaystyle A^2\mathcal{B} \end{array} \right] =\left[ \begin{array}{cccc} 0 &amp;\displaystyle c &amp;\displaystyle 0\\ c&amp;\displaystyle 0&amp;\displaystyle ac\\ d&amp;\displaystyle 0&amp;\displaystyle bc \end{array} \right]. \end{array} \end{aligned} $$
After a straightforward procedure, the following is found:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \det(C_o)=(\overline{d}_{12})^2\left(\frac{k_m}{R}\right)^3\overline{m}g(\overline{d}_{11}\overline{d}_{22}-\overline{d}_{12}\overline{d}_{21})\neq 0, \end{array} \end{aligned} $$
because  $$\overline {d}_{11}\overline {d}_{22}-\overline {d}_{12}\overline {d}_{21}\neq 0$$ is a property of the mechanism, as explained in Chap. 16. Hence, the dynamical equation in (7.96) is controllable for any set of the inertia wheel parameters. This means that the result does not change whether the mechanism is large or small, heavy or light. The matrix P introduced in (7.68) is nonsingular and it is obtained in the following using (7.69). To simplify the computations, the following numerical values are considered:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} d_{11}&amp;\displaystyle =&amp;\displaystyle 0{.}0014636, d_{12}= 0{.}0000076,\\ d_{21}&amp;\displaystyle =&amp;\displaystyle 0{.}0000076, d_{22}= 0{.}0000076, \\ \overline{m}g&amp;\displaystyle =&amp;\displaystyle 0{.}12597, \end{array} \end{aligned} $$
where:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} D^{-1}&amp;\displaystyle =&amp;\displaystyle \left[\begin{array}{cc} \overline{d}_{11} &amp;\displaystyle \overline{d}_{12}\\ \overline{d}_{21} &amp;\displaystyle \overline{d}_{22} \end{array}\right]= \frac{1}{d_{11}d_{22}-d_{12}d_{21}} \left[\begin{array}{cc} d_{22} &amp;\displaystyle -d_{12}\\ -d_{21} &amp;\displaystyle d_{11} \end{array}\right], \end{array} \end{aligned} $$
, which correspond to parameters of the inertia wheel pendulum that is built and experimentally controlled in Chap. 16. Thus:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} A&amp;\displaystyle =&amp;\displaystyle \left[ \begin{array}{ccc} 0 &amp;\displaystyle 1{.}0000 &amp;\displaystyle 0\\ 86{.}5179 &amp;\displaystyle 0 &amp;\displaystyle 0\\ -86{.}5179 &amp;\displaystyle 0 &amp;\displaystyle 0 \end{array} \right], \mathcal{B}=\left[ \begin{array}{c} 0\\ -1{.}2758\\ 245{.}6998 \end{array} \right]. \end{array} \end{aligned} $$
Using these data, the roots of the polynomial  $$\det (\lambda I-A)$$ are found to be:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \lambda_1= 0,\lambda_2= 9{.}3015,\lambda_3= -9{.}3015. \end{array} \end{aligned} $$
Then, the following product is performed:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} (\lambda-\lambda_1)(\lambda-\lambda_2)(\lambda-\lambda_3)=\lambda^3+a_2\lambda^2+a_1\lambda+a_0, \end{array} \end{aligned} $$
and, equating coefficients, the following is found:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} a_2=0,a_1=-86{.}5179,a_0=0.{} \end{array} \end{aligned} $$
(7.97)
Use of this in (7.69) yields:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} P^{-1}= \left[ \begin{array}{ccc} 0 &amp;\displaystyle -1{.}275 &amp;\displaystyle 0\\ 5{.}467\times 10^{-5} &amp;\displaystyle 0 &amp;\displaystyle -1{.}275\\ -21147{.}049 &amp;\displaystyle 0 &amp;\displaystyle 245{.}6998 \end{array} \right], \end{array} \end{aligned} $$
i.e.,
 $$\displaystyle \begin{aligned} \begin{array}{rcl} P=10^{-5}\times\left[ \begin{array}{ccc} 0 &amp; -910{.}6662 &amp; -4{.}7287\\ -78379{.}7677 &amp; 0 &amp; 0\\ 0 &amp; -78379{.}8067&amp; -0{.}0002 \end{array} \right].{} \end{array} \end{aligned} $$
(7.98)
Finally, to verify the expressions in (7.70), the following products are performed:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} PAP^{-1}=\left[ \begin{array}{ccc} 0 &amp;\displaystyle 1{.}0000 &amp;\displaystyle 0\\ -0{.}0000 &amp;\displaystyle 0 &amp;\displaystyle 1{.}0000\\ 0 &amp;\displaystyle 86{.}5179 &amp;\displaystyle 0 \end{array} \right],PB=\left[ \begin{array}{c} 0\\ 0\\ 1 \end{array} \right]. \end{array} \end{aligned} $$
Note that these matrices have exactly the forms shown in (7.67) for  $$\bar A=PAP^{-1}$$ and  $$\bar B=PB$$ .

7.14.2 State Feedback Control

Now, the vector of controller gains K is computed. It is desired that using the controller (7.74) (with x = z and u = w), the eigenvalues of matrix A − BK are assigned at:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \bar\lambda_1= -5{.}8535+17{.}7192j,\bar\lambda_2= -5{.}8535-17{.}7192j,\bar\lambda_3= -0{.}5268. \end{array} \end{aligned} $$
Hence, these values are used to compute the polynomial:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} (\lambda-\bar\lambda_1)(\lambda-\bar\lambda_2)(\lambda-\bar\lambda_3)=\lambda^3+\bar a_2\lambda^2+\bar a_1\lambda+\bar a_0, \end{array} \end{aligned} $$
and, equating coefficients:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \bar a_2=12{.}2338,\bar a_1=354{.}4008,\bar a_0=183{.}4494. \end{array} \end{aligned} $$
These data and the values obtained in (7.97) are employed to compute the vector of the gains  $$\bar K$$ according to (7.77):
 $$\displaystyle \begin{aligned} \begin{array}{rcl} \bar K= \left[ \begin{array}{ccc} 183{.}44 &amp;\displaystyle 440{.}91 &amp;\displaystyle 12{.}23 \end{array} \right].\end{array} \end{aligned} $$
Finally, using this and the matrix P shown in (7.98) the vector of the controller gains K is computed using  $$ K=\bar K P$$ as:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} K= \left[ \begin{array}{ccc} -345{.}5910&amp;\displaystyle -11{.}2594 &amp;\displaystyle -0{.}0086 \end{array}\right],\end{array} \end{aligned} $$
which, except for some rounding errors, is the vector of the controller gains used to experimentally control the inertia wheel pendulum in Chap. 16. Some simulation results are presented in Fig. 7.11 where z 1(0) = 0.3 and z 2(0) = z 3(0) = 0 were set as initial conditions. It is observed that the state variables converge to zero, as desired. These simulations were performed using the MATLAB/Simulink diagram shown in Fig. 7.12. The inertia wheel pendulum block has the following parameters:
 $$\displaystyle \begin{aligned} \begin{array}{rcl} A\Rightarrow A,B\Rightarrow B,[1\;0\;0;0\;1\;0;0\;0\;1]\Rightarrow C, [0;0;0]\Rightarrow D, \end{array} \end{aligned} $$
and [0.3 0 0] as initial conditions. The results in Fig. 7.11 were obtained following these steps: 1) Execute the following MATLAB code in an m-file to obtain all the above computations:
/epubstore/G/V-M-Guzman/Automatic-Control-With-Experiments/OEBPS/images/454499_1_En_7_Chapter/454499_1_En_7_Fig11_HTML.png
Fig. 7.11

Simulation results when using the gain vector K = [−345.5910  − 11.2594  − 0.0086] to control the inertia wheel pendulum. Top: z 1. Middle: z 2. Bottom: z 3

/epubstore/G/V-M-Guzman/Automatic-Control-With-Experiments/OEBPS/images/454499_1_En_7_Chapter/454499_1_En_7_Fig12_HTML.png
Fig. 7.12

MATLAB/Simulink diagram used to simulate the control of the inertia wheel pendulum

clc
A=[0 1 0;
86.5179 0 0;
-86.5179 0 0];
B=[0;
-1.2758;
245.6998];
U=[B A∗B Aˆ2∗B];
det(U)
v=eig(A);
f=conv([1 -v(1)],[1 -v(2)]);
h=conv(f,[1 -v(3)]);
a2=h(2);
a1=h(3);
a0=h(4);
q3=B;
q2=A∗B+a2∗B;
q1=Aˆ2∗B+a2∗A∗B+a1∗B;
invP=[q1 q2 q3]
P=inv(invP)
Ab=P∗A∗invP
Bb=P∗B
lambda1d=-5.8535+17.7192∗j;
lambda2d=-5.8535-17.7192∗j;
lambda3d=-0.5268;
fd=conv([1 -lambda1d],[1 -lambda2d]);
hd=conv(fd,[1 -lambda3d]);
a2b=hd(2);
a1b=hd(3);
a0b=hd(4);
Kb=[a0b-a0 a1b-a1 a2b-a2];
K=Kb∗P
eig(A-B∗K)
2) Run the simulation in Fig. 7.12. 3) Execute the following MATLAB code in an m-file:
nn=length(States(:,1));
n=nn-1;
Ts=1/n;
t=0:Ts:1;
figure(1)
subplot(3,1,1)
plot(t,States(:,1),'b-');
ylabel('rad')
subplot(3,1,2)
plot(t,States(:,2),'b-');
ylabel('rad/s')
subplot(3,1,3)
plot(t,States(:,3),'b-');
ylabel('rad/s')
xlabel('t [s]')

At this point, Fig. 7.11 is drawn.

7.15 Summary

The mathematical models used in the state variable approach are sets of first-order differential equations that must be solved simultaneously. Hence, the analysis and design are performed in the time domain and the Laplace transform is no longer used. This allows the study of nonlinear control systems, i.e., those systems represented by nonlinear differential equations (see Chap. 16 for an example of such applications). Recall that the Laplace transform cannot be employed when the differential equations are nonlinear.

Although an equivalence exists between the state space representation and the transfer function, the former is more general. This can be seen in the fact that the transfer function only represents the controllable and observable part of a state space representation. This means that there are some parts of a system that cannot be described by the transfer function. However, if a system is controllable and observable, the analysis and the design of the control system are simplified. In fact, there are powerful results for this case, which are presented in Sects. 7.11 and 7.12.

An advantage of the state space approach is that it gives simple solutions to problems that have a more complicated result when using the transfer function approach. Two examples of this situation are the experimental prototypes that are controlled in Chaps. 15 and 16, where two variables have to be controlled simultaneously: the arm and the pendulum positions (in Chap. 15) and the pendulum position and the wheel velocity (in Chap. 16). Another advantage of the state space approach is that it allows us to develop a general methodology to obtain a linear approximate model of nonlinear systems (see Sect. 7.3 and Chaps. 13, 15 and 16).

7.16 Review Questions

  1. 1.

    What is a controllable state equation?

     
  2. 2.

    What is an observable dynamical equation?

     
  3. 3.

    How can you check controllability and observability?

     
  4. 4.

    How useful is a controllable dynamical equation?

     
  5. 5.

    How useful is an observable dynamical equation?

     
  6. 6.

    What is the difference between the system state and the system output?

     
  7. 7.

    Suppose that a dynamical equation is controllable and observable. What is the relationship between the poles of the corresponding transfer function and the eigenvalues of matrix A?

     
  8. 8.

    What does global asymptotic stability of the origin mean?

     
  9. 9.

    What are the conditions required for the origin to be globally asymptotically stable?

     
  10. 10.

    Why is it important for the origin of a dynamical equation without input to be globally asymptotically stable?

     
  11. 11.

    What does state feedback control mean?

     
  12. 12.

    What is a state observer and what is it employed for?

     

7.17 Exercises

  1. 1.

    Say what you understand by state and propose a physical system to indicate its state.

     
  2. 2.
    Verify that the following dynamical equations are controllable:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} A=\left[\begin{array}{ccc} 2 &amp;\displaystyle 1&amp;\displaystyle 3\\ 5 &amp;\displaystyle 9 &amp;\displaystyle 7\\ 0 &amp;\displaystyle 2&amp;\displaystyle 8 \end{array} \right],B=\left[\begin{array}{c}0\\0\\2\end{array}\right],C=\left[\begin{array}{ccc}4&amp;\displaystyle 7&amp;\displaystyle 2\end{array}\right], \end{array} \end{aligned} $$
     $$\displaystyle \begin{aligned} \begin{array}{rcl} A=\left[\begin{array}{ccc} 0 &amp;\displaystyle 1&amp;\displaystyle 0\\ 0 &amp;\displaystyle -20 &amp;\displaystyle 50\\ 0 &amp;\displaystyle -5&amp;\displaystyle -250 \end{array} \right],B=\left[\begin{array}{c}0\\0\\100\end{array}\right],C=\left[\begin{array}{ccc}1&amp;\displaystyle 0&amp;\displaystyle 0\end{array}\right], \end{array} \end{aligned} $$
     $$\displaystyle \begin{aligned} \begin{array}{rcl} A=\left[\begin{array}{cccc} 0 &amp;\displaystyle 1&amp;\displaystyle 0 &amp;\displaystyle 0\\ 0 &amp;\displaystyle 0 &amp;\displaystyle -0{.}5 &amp;\displaystyle 0\\ 0 &amp;\displaystyle 0&amp;\displaystyle 0&amp;\displaystyle 1 \\ 0 &amp;\displaystyle 0 &amp;\displaystyle 50 &amp;\displaystyle 0\end{array} \right],B=\left[\begin{array}{c}0\\1\\0\\-5\end{array}\right],C=\left[\begin{array}{cccc}1&amp;\displaystyle 0&amp;\displaystyle 1&amp;\displaystyle 0\end{array}\right], \end{array} \end{aligned} $$
    • Compute the matrix P defined in (7.69).

    • Compute the matrices and vectors  $$\bar A=PAP^{-1}$$ ,  $$\bar B=PB$$ ,  $$\bar C=CP^{-1}$$ defined in (7.70).

    • Corroborate that these matrices and vectors have the forms defined in (7.67).

    • Using these results, find the transfer function corresponding to each dynamical equation.

    • Employ the MATLAB “tf(⋅)” command to compute the transfer function corresponding to each dynamical equation. Verify that this result and that in the previous item are identical.

    • Use MATLAB/Simulink to simulate the response of the dynamical equation and the corresponding transfer function when the input is a unit step. Plot both outputs and compare them. What can be concluded?

     
  3. 3.

    Elaborate a MATLAB program to execute the procedure at the end of Sect. 7.11 to compute the vector of controller gains K assigning the desired eigenvalues to the closed-loop matrix A − BK. Employ this program to compute the gains of the state feedback controllers in Chaps. 15 and 16. Note that this program is intended to perform the same task as MATLAB’s “acker(⋅)” command.

     
  4. 4.

    Modify the MATLAB program in the previous item to compute the observer vector gain L, assigning the desired eigenvalues to the observer matrix A − LC. Employ this program to design an observer for the system in Chap. 15. Define the system output as the addition of the pendulum and the arm positions.

     
  5. 5.
    The following expression constitutes a filter where y(t) is intended to replace the time derivative of u(t).
     $$\displaystyle \begin{aligned} \begin{array}{rcl} Y(s)=\frac{bs}{s+a}U(s), b&gt;0,\;a&gt;0. \end{array} \end{aligned} $$
    In fact, y(t) is known as the dirty derivative of u(t) and it is often employed to replace velocity measurements in mechanical systems. To implement this filter in practice, the corresponding dynamical equation is obtained. Find such a dynamical equation. Recall that u(t) must be the input. Can you use frequency response arguments to select a value for a?
     
  6. 6.
    Find a dynamical equation useful for implementing the lead controller:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} \frac{U(s)}{E(s)}=\frac{s+b}{s+c},\ 0&lt;b&lt;c, \end{array} \end{aligned} $$
    where U(s) is the plant input and E(s) is the system error. Compare with the result in Sect. F.3.
     
  7. 7.
    Consider the following system without input:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x=Ax,\ x\in R^n, \end{array} \end{aligned} $$
    Applying the Laplace transform to both sides, it is possible to find that:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} x(t)=\mathcal{L}^{-1}\left\{ (sI-A)^{-1}\right\}x(0),\text{ i.e., e}^{At}=\mathcal{L}^{-1}\left\{ (sI-A)^{-1}\right\}. \end{array} \end{aligned} $$
    Recall (7.57) and (7.56) to explain that, in general, the following stands for the solution of the closed-loop state equation:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x=(A-BK)x,\ x\in R^n, \ K=[k_1,\dots,k_n], \end{array} \end{aligned} $$
    • x i (t), for any i = 1, …, n, depends on all the initial conditions x i (0), i = 1, …, n, i.e., the system is coupled.

    • x i (t), for any i = 1, …, n, depends on all the eigenvalues of the matrix A − BK.

    • A particular k i does not affect only a particular x i (t), i = 1, …, n.

    • A particular k i does not affect only a particular eigenvalue of the matrix A − BK.

     
  8. 8.
    Given an n × n matrix A, an eigenvector w is an n −dimensional vector such that Aw = λw where the scalar λ is known as the eigenvalue associated with w. From this definition (λI − A)w = 0 follows, where I is the n × n identity matrix. Hence, a nonzero w is ensured to exist if, and only if,  $$\det (\lambda I-A)=0$$ . As  $$\det (\lambda I-A)$$ is an n degree polynomial in λ, the matrix A has n eigenvalues that can be real, complex, different or repeated. In the case of n real and different eigenvalues, λ i , i = 1, …, n, n linearly independent eigenvectors w i , i = 1, …, n exist. Thus, an invertible n × n matrix:
     $$\displaystyle \begin{aligned} \begin{array}{rcl}Q^{-1}=[w_1\;w_2 \dots w_n], \end{array} \end{aligned} $$
    and a linear coordinate transformation:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} z=Qx, \end{array} \end{aligned} $$
    can be defined such that:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} \dot x=Ax,\dot z=Ez, \end{array} \end{aligned} $$
    where x, z ∈ R n , are related by E = QAQ −1. Show that the matrix E is given as:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} E=\left[\begin{array}{cccc} \lambda_1&amp;\displaystyle 0 &amp;\displaystyle \cdots&amp;\displaystyle 0\\ 0&amp;\displaystyle \lambda_2&amp;\displaystyle \cdots&amp;\displaystyle 0\\ \vdots&amp;\displaystyle \vdots&amp;\displaystyle \ddots&amp;\displaystyle \vdots\\ 0&amp;\displaystyle 0&amp;\displaystyle \cdots&amp;\displaystyle \lambda_n\end{array}\right], \end{array} \end{aligned} $$
    i.e., that:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} z(t)=\left[\begin{array}{c} \text{e}^{\lambda_1t}z_1(0)\\ \text{e}^{\lambda_2t}z_2(0)\\ \vdots\\ \text{e}^{\lambda_nt}z_n(0)\end{array}\right], \end{array} \end{aligned} $$
    and:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} x(t)=Q^{-1}\left[\begin{array}{cccc} \text{e}^{\lambda_1t}&amp;\displaystyle 0&amp;\displaystyle \cdots&amp;\displaystyle 0\\ 0&amp;\displaystyle \text{e}^{\lambda_2t}&amp;\displaystyle \cdots&amp;\displaystyle 0\\ \vdots&amp;\displaystyle \vdots&amp;\displaystyle \ddots&amp;\displaystyle \vdots\\ 0&amp;\displaystyle 0&amp;\displaystyle \cdots&amp;\displaystyle \text{e}^{\lambda_nt}\end{array}\right]Qx(0). \end{array} \end{aligned} $$
     
  9. 9.
    Consider the matrix  $$\bar A$$ and the vector  $$\bar B$$ , defined in (7.67), when n = 5.
    • Suppose that  $$\bar a_i=0$$ for i = 0, 1, …, 4. Show that:
       $$\displaystyle \begin{aligned} \begin{array}{rcl} \bar B=\left[\begin{array}{c} 0\\ 0\\ 0\\ 0\\ 1 \end{array} \right], \bar A\bar B=\left[\begin{array}{c} 0\\ 0\\ 0\\ 1\\ 0 \end{array} \right],\bar A^2\bar B=\left[\begin{array}{c} 0\\ 0\\ 1\\ 0\\ 0 \end{array} \right],\bar A^3 \bar B=\left[\begin{array}{c} 0\\ 1\\ 0\\ 0\\ 0 \end{array} \right],\bar A^4 \bar B=\left[\begin{array}{c} 1\\ 0\\ 0\\ 0\\ 0 \end{array} \right], \end{array} \end{aligned} $$
      i.e., these vectors are linearly independent, the matrix  $$[\bar B, \ \bar A\bar B,\ \bar A^2\bar B, \ \bar A^3\bar B,$$  $$\bar A^4\bar B]$$ has a determinant that is different from zero, and, thus, the system in (7.67) is controllable.
    • Suppose that  $$\bar a_i\neq 0$$ for i = 0, 1, …, 4. Show that:
       $$\displaystyle \begin{aligned} \begin{array}{rcl} \bar B=\left[\begin{array}{c} 0\\ 0\\ 0\\ 0\\ 1 \end{array} \right], \bar A\bar B=\left[\begin{array}{c} 0\\ 0\\ 0\\ 1\\ * \end{array} \right],\bar A^2\bar B=\left[\begin{array}{c} 0\\ 0\\ 1\\ *\\ * \end{array} \right],\bar A^3 \bar B=\left[\begin{array}{c} 0\\ 1\\ *\\ *\\ * \end{array} \right],\bar A^4 \bar B=\left[\begin{array}{c} 1\\ *\\ *\\ *\\ * \end{array} \right], \end{array} \end{aligned} $$
      where the symbol “∗” stands for some numerical values depending on  $$\bar a_i$$ for i = 0, 1, …, 4. Show that these vectors are still linearly independent, i.e., that the matrix  $$[\bar B, \ \bar A\bar B,\ \bar A^2\bar B, \ \bar A^3\bar B, \ \bar A^4\bar B]$$ has a determinant that is different from zero; thus, the system in (7.67) is controllable.
     
  10. 10.
    (Taken from [1]) A set of n functions of time f i (t), i = 1, …, n, is said to be linearly dependent on the interval [t 1, t 2] if there are numbers α 1, α 2, …, α n , not all zero such that:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} \alpha_1f_1(t)+\alpha_2f_2(t)+ \cdots+\alpha_n f_n(t)=0, \end{array} \end{aligned} $$
    for all t ∈ [t 1, t 2]. Otherwise, the set of functions is said to be linearly independent of [t 1, t 2]. Use these arguments to explain why the following functions:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} f_1(t)=t,\ t\in[-1,1], \text{and }f_2(t)=\left\{\begin{array}{ll} t,&amp;\displaystyle \ t\in[0,1]\\ -t,&amp;\displaystyle \ t\in[-1,0]\end{array}\right., \end{array} \end{aligned} $$
    are linearly dependent on [0, 1] and on [−1, 0]. However, they are linearly independent of [−1, 1].
     
  11. 11.
    Consider the results in Example 7.7.
    • Recalling that e $$^{At}=\mathcal {L}^{-1}\left \{ (sI-A)^{-1}\right \}$$ show that:
       $$\displaystyle \begin{aligned} \begin{array}{rcl} \text{e}^{At}=\left[\begin{array}{cc} 1 &amp;\displaystyle \frac{J}{b}\left(1-\text{e}^{-\frac{b}{J}t}\right)\\ 0 &amp;\displaystyle \text{e}^{-\frac{b}{J}t}\end{array}\right]. \end{array} \end{aligned} $$
    • Show that  $$\det \left (\text{e}^{At}\right )\neq 0$$ for all t ∈ R, i.e., that e At is nonsingular for all t ∈ R.

    • Define:
       $$\displaystyle \begin{aligned} \begin{array}{rcl} F(t)=\left[\begin{array}{c} f_1(t)\\ f_2(t) \end{array}\right]=\text{e}^{At}B.{} \end{array} \end{aligned} $$
      (7.99)
      Use the definition in the previous exercise to prove that f 1(t) and f 2(t) are linearly independent for all t ∈ R.
    • The following theorem is taken from [1]. Let f i (t), i = 1, 2, …, n, be 1 × p continuous functions defined on [t 1, t 2]. Let F(t) be the n × p matrix with f i (t) as its i −th row. Define:
       $$\displaystyle \begin{aligned} \begin{array}{rcl} W(t_1,t_2)=\int_{t_1}^{t_2}F(t)F^T(t)dt. \end{array} \end{aligned} $$
      Then, f 1(t), f 2(t), …, f n ((t), are linearly independent of [t 1, t 2] if, and only if, the n × n constant matrix W(t 1, t 2) is nonsingular.

      Use this theorem to prove that the two scalar functions defining the two rows of matrix e At B defined in the previous item are linearly independent of t ∈ R.

    • The following theorem is taken from [1]. Assume that for each i, f i is analytic on [t 1, t 2]. Let F(t) be the n × p matrix with f i as its i −th row, and let F (k)(t) be the k −th derivative of F(t). Let t 0 be any fixed point in [t 1, t 2]. Then, the f i s are linearly independent of [t 1, t 2] if, and only if, the rank of the following matrix, with an infinite number of columns, is n:
       $$\displaystyle \begin{aligned} \begin{array}{rcl} \left[F(t_0)\ \vdots\ F^{(1)}(t_0)\ \vdots\ \cdots\ \vdots\ F^{(n-1)}(t_0)\ \vdots\ \cdots\right]. \end{array} \end{aligned} $$
      Using the definition in (7.99), show that  $$\left [F(t_0)\ \vdots \ F^{(1)}(t_0)\right ]$$ , n = 2, t 0 = 0, has rank 2.
    • Using the facts that all the entries of e At B are analytic functions,  $$\frac {d}{dt}$$ e At  =  e At A, A m , for m ≥ n, can be written as a linear combination of I, A, …, A n−1 (Cayley–Hamilton theorem), and e At | t=0 = I (see [1] for an explanation of all these properties), show that the theorems in the two previous items establish the equivalence between the two conditions in theorem 7.2 to conclude controllability.

     
  12. 12.
    Consider the ball and beam system studied in Example 7.2, in this chapter, together with the following numerical values:
     $$\displaystyle \begin{aligned} \begin{array}{rcl} k=16{.}6035,a=3{.}3132,\rho=5. \end{array} \end{aligned} $$
    • Obtain the corresponding dynamical equation when the state is defined as  $$\tilde z=[x-x_d,\dot x,\theta ,\dot \theta ]^T$$ and the output is γ = x − x d , where x d is a constant standing for the desired value for x.

    • Design a state feedback controller to stabilize the system at x = x d ,  $$\dot x=\theta =\dot \theta =0$$ . Choose the desired eigenvalues as follows. Propose two pairs of desired rise time and overshoot. Using the expression in (3.​71), Chap. 3, determine two pairs of complex conjugate eigenvalues such that the two pairs of desired rise time and overshoot are achieved.

    • Design an observer to estimate the complete system state. Recall that the eigenvalues of the matrix A − LC must be several times faster than those for the matrix A − BK.

    • Fix all initial conditions to zero, except for x(0) − x d  ≠ 0. Test the closed-loop system employing the above observer and the above state feedback controller to stabilize the system at x = x d ,  $$\dot x=\theta =\dot \theta =0$$ . Verify through simulations whether the desired transient response characteristics have been accomplished.