\chapter{Systems and Control Problem}
\section{What Is a System?}
In this book we are concerned with the analysis and control of dynamical systems. A {\em system} can be viewed as a collection of interacting components. The word system can be used to describe a physical, biological, or economical unit. An electric motor, an airplane, as well as a biological unit such as the human arm are examples of systems. A system is characterized by two properties. They are:
\begin{enumerate}
\item interrelations between the components that are contained within the system, and
\item the system boundaries that separate the components within the system from the components outside.
\end{enumerate}
The system boundaries can be real or imagined. They are elastic in the sense that we may choose, at any stage of the system analysis, to consider only a part of the original system as a system on its own. We call it a {\em subsystem} of the original system. On the other hand, we may decide to expand the boundaries of the original system to include new components. The interactions between the system components are governed by physical laws. Thus, we can characterize the system by its physical quantities. In dealing with systems, we will be interested in the effects of external quantities upon the behavior of the system quantities. We refer to the external quantities acting on the system as the {\em inputs} to the system. The condition or the state of the system are described by the {\em state variables}. The state variables provide the information that together with the knowledge of the system inputs enables us to determine the future state of the system. A {\em dynamical system} is one whose state changes with time. In practice it is often not possible or too expensive to measure or determine the values of all of the state variables. Instead, only their subset or combination can be measured. The system quantities whose behavior can be measured or observed are referred to as the system {\em outputs}. In Figure~\ref{fig:system}, we schematically represent system's boundaries using a box. The input signal is processed by the system to provide an output signal variable.
\begin{figure}
\setlength{\unitlength}{.1in}
\begin{center}
\begin{picture}(60,20)
\thicklines
\put(14,9){\vector(1,0){8}}
\put(16,10){Input}
\put(22,5){\framebox(10,8){System}}
\put(32,9){\vector(1,0){9}}
\put(33,10){Output}
\end{picture}
\end{center}
\caption{Schematic representation of a system.}
\label{fig:system}
\end{figure}

In dealing with dynamic systems, we are interested in specifying the system inputs that force the system states or outputs to behave with time in some prespecified manner. That is, we are interested in {\em controlling} the system states or outputs. This is accomplished by means of a {\em controller\/} whose task is to produce the required system's inputs. An interconnection of the system and a controller is called a {\em control system}. Constructing a controller is a part of the {\em control problem}. We discuss the basic elements of the control problem in the next section.

\section{Formulation of the Control Problem}
The basic elements of the control design problem are:
\begin{enumerate}
\item a specified objective for the system,
\item a model of a dynamic system to be controlled,
\item a set of admissible controllers, and
\item a means of measuring the performance of any given control strategy to evaluate its effectiveness.
\end{enumerate}
We now examine these elements one by one. The objective of a control system is to complete some specified task. This can be expressed as a combination of constraints on the output or state variables and limits on the time available to complete the control objective. For example, the objective of a controller might be to force the output, of a single output system, to settle within a certain percentage of the given value after prespecified time.

To design a controller, we need a model of the controlled system. A common model of a dynamic system is the finite set of ordinary differential equations of the form:
\begin{eqnarray*}
\dot{\mb{\bm$x$}}(t) &=& \mb{\bm$f$}(t,\mb{\bm$x$}(t),\mb{\bm$u$}(t)),\quad \mb{\bm$x$}(t_0)=\mb{\bm$x$}_0\\
\mb{\bm$y$}(t) &=& \mb{\bm$h$}(t,\mb{\bm$x$}(t),\mb{\bm$u$}(t)),
\end{eqnarray*}
where $\mb{\bm$x$}\in \mb{\Bb R}^n$, $\mb{\bm$u$}\in \mb{\Bb R}^m$, $\mb{\bm$y$}\in \mb{\Bb R}^p$, $\mb{\bm$f$}$
and $\mb{\bm$h$}$ are vector valued functions with $\mb{\bm$f$}:\mb{\Bb R} \times \mb{\Bb R}^n \times
\mb{\Bb R}^m \rightarrow \mb{\Bb R}^n$ and $\mb{\bm$h$}:\mb{\Bb R} \times \mb{\Bb R}^n \times \mb{\Bb R}^m \rightarrow \mb{\Bb R}^p$. Another common model of a dynamic system is the finite set of difference equations
\begin{eqnarray*}
\mb{\bm$x$}_{k+1} &=& \mb{\bm$f$}(k,\mb{\bm$x$}_k,\mb{\bm$u$}_k), \quad \mb{\bm$x$}(k_0)=\mb{\bm$x$}_0\\
{\b y}_k &=& {\b h}(k,{\b x}_k,{\b u}_k),
\end{eqnarray*}
where $\mb{\bm$x$}_k=\mb{\bm$x$}(kh)$, $\mb{\bm$u$}_k=\mb{\bm$u$}(kh)$, $h$ is the sampling interval, and $k\ge 0$ is an integer.

In our subsequent discussion we regard the dynamic system and its model as equivalent. During the modeling process, properties of the system, physical constraints, and technical requirements should be taken into account. By itself the pair $(\mb{\bm$f$}(t,\mb{\bm$x$},\mb{\bm$u$}), \mb{\bm$h$}(t,\mb{\bm$x$},\mb{\bm$u$}))$ has little engineering significance until constraints on the state $\mb{\bm$x$}$, the control $\mb{\bm$u$}$, and the output $\mb{\bm$y$}$ are also given. Control input signals are obtained from physical devices capable of providing only a limited amount of energy. We term the class of controllers that can be considered for the given control design problem as the set of admissible controllers.

We can evaluate the performance of any given control law by visual inspection of the transient characteristics of the closed-loop system after the design is complete. But this means of assessment of the effectiveness of the given control strategy is highly inaccurate. We therefore try to quantify the means of evaluating performance in the form of a performance index or cost functional at the beginning of the design process. We construct a numerical index of performance whose value reflects the quality of any admissible controller in accomplishing the system objective. This performance index is assumed to have the property that its numerical value decreases as the quality of the controller increases. This is the reason why we sometimes refer to the performance index as the penalty functional. The ``best'' controller then is the one that produces the smallest value of the performance index. We call an admissible controller that simultaneously ensures the completion of the system objective and the minimization of the performance index an optimal controller for the system.

\section{Open-Loop Versus Closed-Loop}
We distinguish between two types of control systems. They are:
\begin{itemize}
\item open-loop control systems, and
\item closed-loop control systems.
\end{itemize}
An open-loop control system usually contains:
\begin{enumerate}
\item A process to be controlled, labeled {\em plant},
\item The controlling variable of the plant, called the {\em plant input}, or just {\em input} for short,
\item The controlled variable of the plant, called the {\em plant output}, or just {\em output} for short,
\item A {\em reference input}, which dictates the desired value of the output,
\item A {\em controller} that acts upon the reference input in order to form the system input which would force the behavior of the output in accordance with the reference signal.
\end{enumerate}
Note that the plant and controller themselves can be considered as systems on their own. A schematic representation of an open-loop system is depicted in Figure~\ref{op-loop}.
\begin{figure}
\setlength{\unitlength}{.08in}
\begin{center}
\begin{picture}(60,20)
\thicklines
\put(15,5){\framebox(10,8){Controller}}
\put(5,9){\vector(1,0){10}}
\put(5,10){\shortstack{Reference\\input}}
\put(6,5){\shortstack{Desired\\output}}
\put(25,9){\vector(1,0){12}}
\put(26,10){\shortstack{Controller\\output}}
\put(28,5){\shortstack{Plant\\input}}
\put(37,5){\framebox(10,8){Plant}}
\put(47,9){\vector(1,0){5}}
\put(48,10){\shortstack{Actual\\output}}
\end{picture}
\end{center}
\caption{Open-loop control system.}
\label{op-loop}
\end{figure}
In an open-loop control system the output has no influence on the input or reference signal. The controller operates without taking into account the output. Thus, the plant input is formed with no influence of the output. A household appliance such as an iron is a simple example of an open-loop control system. In this example we consider the iron itself as the plant or process to be controlled. Here we set the temperature control mechanism for the desired temperature. This setting, for example very hot, is the reference input. We can view the potentiometer, inside the iron, as a controller, or a control actuator. It regulates the temperature of the iron by allowing the necessary amount of resistance to produce the desired temperature. The plant's output is the temperature of the heated iron. Not every control system is an open-loop system. Another type of a control system is a closed-loop system. We can convert an open-loop system into a closed-loop system by adding to an open-loop system the following components:
\begin{enumerate}
\setcounter{enumi}{5}
\item The {\em feedback loop} where the output signal is measured with a sensor and then the measured signal is fed back to the {\em summing junction},
\item The summing junction, where the measured output signal is subtracted from the reference, command, input signal in order to generate an {\em error signal}, also labeled as an {\em actuating signal}.
\end{enumerate}
\begin{figure}
\setlength{\unitlength}{.08in}
\begin{center}
\begin{picture}(70,25)
\thicklines
\put(0,18){\vector(1,0){11}}
\put(0,19){\shortstack{Desired\\output}}
\put(0,14){\shortstack{Reference\\input}}
\put(14,18){\circle{6}}
\put(14,18){\line(1,1){2.12}}
\put(14,18){\line(-1,-1){2.12}}
\put(14,18){\line(-1,1){2.12}}
\put(14,18){\line(1,-1){2.12}}
\put(11,17){$+$}
\put(13,16){$-$}
\put(17,18){\vector(1,0){11}}
\put(17,19){\shortstack{Actuating\\signal}}
\put(28,14){\framebox(10,8){Controller}}
\put(38,18){\vector(1,0){12}}
\put(39,19){\shortstack{Controller\\output}}
\put(41,14){\shortstack{Plant\\input}}
\put(50,14){\framebox(10,8){Plant}}
\put(60,18){\vector(1,0){10}}
\put(61,19){\shortstack{Actual\\output}}
\put(65,18){\vector(0,-1){4}}
\put(65,14){\line(0,-1){8}}
\put(65,6){\line(-1,0){20}}
\put(35,2){\framebox(10,8){Sensor}}
\put(14,6){\line(1,0){21}}
\put(24,7){\shortstack{Measured\\output}}
\put(14,6){\vector(0,1){9}}
\end{picture}
\end{center}
\caption{Closed-loop control system.}
\label{cl-loop}
\end{figure}
A schematic of a closed-loop control system is shown in Figure~\ref{cl-loop}. In a closed-loop system the error signal causes an appropriate action of the controller, which in turn ``instructs'' the plant to behave in a certain way in order to approach the desired output, as specified by the reference input signal. Thus, in the closed-loop system,
output information is fed back to the controller, and the controller then appropriately modifies the plant output behavior. A controller, also called a {\em compensator}, can be placed either in the {\em forward loop}, or in the {\em feedback loop\/}.

If the goal of the controller is to maintain the output at a constant value, then we have a {\em regulator} control system. A ``centrifugal speed regulator'' known as Watt's governor can be considered as the starting point for the development of automatic control as the science. It is shown in Figure~\ref{fig:watts}.
\begin{figure}
\vspace{4.5in}
\special{bmp:c:/mybook/watts.bmp x=6in y=4.5in}
\caption{A simplified diagram of Watt's governor.}
\label{fig:watts}
\end{figure}
The task of Watt's governor is to control setting of a throttle valve automatically to maintain the desired engine speed. The nominal speed is set by adjusting the valve in the throttle. As the engine speeds up the weights are thrown outwards, the throttle partially closes and the engine slows down. As the engine slows down below its nominal speed, the throttle is opened up and the engine gains its speed. The operation of an engine equipped with a centrifugal speed regulator can be represented using the block diagram of Figure~\ref{cl-loop}. The reference input to the closed-loop system is the nominal engine speed. The system output is the actual engine speed. Watt's governor is our controller, while the engine represents the plant. The control signal generated by the controller is the setting of the throttle valve.

If the goal of the controller is to force the
output to follow a desired trajectory, then we have a {\em servomechanism\/} or {\em tracking\/} control system. To design a controller, we need first to analyze the system quantitatively. The analysis requires a mathematical description of the interrelations between the system quantities themselves as well as the interrelations between system quantities and system inputs. The mathematical description of these interrelations is called {\em mathematical modeling}. As we mentioned before, the process of mathematical modeling is one of the basic elements of the control problem. We devote the next chapter to mathematical modeling.

\section{Axiomatic Definition of a Dynamic System}
Following Kalman~\cite{kalman63}, we can define a dynamic system formally using the following axioms:
\begin{enumerate}
\item There is given a state space $\mb{\bm$X$}$, and $T$, an interval in the real line representing time;
\item There is given a space $\mb{\bm$U$}$ of functions on $T$ that represent the inputs to the system;
\item For any initial time $t_0$ in $T$, any initial state $\mb{\bm$x$}_0$ in $\mb{\bm$X$}$, and any input $\mb{\bm$u$}$ in $\mb{\bm$U$}$ defined for $t \ge t_0$, the future states of the system are determined by the {\em transition mapping}
\[
\mb{\bm$\Phi$}:T \times \mb{\bm$X$} \times \mb{\bm$U$} \to \mb{\bm$X$}
\]
written as
\[
\mb{\bm$\Phi$}(t_1;t_0,\mb{\bm$x$}(t_0),\mb{\bm$u$}(t))=\mb{\bm$x$}(t_1).
\]
\end{enumerate}
Moreover the following axioms are satisfied:
\begin{enumerate}
\setcounter{enumi}{3}
\item The identity property of the transition mapping, that is,
\[
\mb{\bm$\Phi$}(t_0;t_0,\mb{\bm$x$}(t_0),\mb{\bm$u$}(t_0))=\mb{\bm$x$}(t_0);
\]
\item The semigroup property of the transition mapping, that is,
\[
\mb{\bm$\Phi$}(t_2;t_0,\mb{\bm$x$}(t_0),\mb{\bm$u$}(t))=\mb{\bm$\Phi$}(t_2;t_1,\mb{\bm$\Phi$}(t_1;t_0,\mb{\bm$x$}(t_0),\mb{\bm$u$}(t)),\mb{\bm$u$}(t)).
\]
The semigroup property axiom states that is irrelevant whether the system arrives at the state at time $t_2$ by a direct transition from the state at time $t_0$, or by first going to an intermediate state at time $t_1$, and then having been restarted from the state at time $t_1$, and moving to the state at time $t_2$. In either case the system, satisfying the semigroup axiom, will arrive at the same state at time $t_2$. This property is illustrated in Figure~\ref{fig:semigr}.
\begin{figure}
\vspace{3in}
\hskip1.25in\special{bmp:c:/windows/semigr.bmp x=4in y=3in}
\caption{Illustration of the semigroup axiom.}
\label{fig:semigr}
\end{figure}
\item The causality property, that is,
\[
\mb{\bm$\Phi$}(t;t_0,\mb{\bm$x$}(t_0),\mb{\bm$u$}_1(t))=\mb{\bm$\Phi$}(t;t_0,\mb{\bm$x$}(t_0),\mb{\bm$u$}_2(t)) \quad \mbox{ for } t_0,t \in T
\]
\hspace{.75in} if, and only if, $\mb{\bm$u$}_1(t)=\mb{\bm$u$}_2(t)$ for all $t \in T$;
\item Every output of the system is a function of the form
\[
\mb{\bm$h$}:T \times \mb{\bm$X$} \to \mb{\bm$Y$},
\]
where $\mb{\bm$Y$}$ is the output space;
\item The transition mapping $\mb{\bm$\Phi$}$ and the output mapping $\mb{\bm$h$}$ are continuous functions.
\end{enumerate}
If in addition the system satisfies the following axiom, then it is said to be {\em time-invariant}:
\begin{enumerate}
\setcounter{enumi}{8}
\item \label{t-invar}
\[
\mb{\bm$\Phi$}(t_1;t_0,\mb{\bm$x$}(t_0),\mb{\bm$u$}(t))=\mb{\bm$\Phi$}(t_1+\tau;t_0+\tau ,\mb{\bm$x$}(t_0),\mb{\bm$u$}(t)),
\]
where $t_0,t_1 \in T$.
\end{enumerate}
Thus, a dynamic system can be defined formally as a quintuple
\[
\{ T,\mb{\bm$X$}, \mb{\bm$U$}, \mb{\bm$\Phi$}, \mb{\bm$Y$} \}
\]
satisfying the above axioms. Our attention will be focused on dynamic systems modeled by a set of ordinary differential equations
\[
\dot{x}_i=f_i(t,x_1,x_2,\ldots,x_n,u_1,u_2,\ldots,u_m),\quad x_i(t_0)=x_{i0},\quad i=1,2,\ldots,n,
\]
together with $p$ functions
\[
y_j=h_j(t,x_1,x_2,\ldots,x_n,u_1,u_2,\ldots,u_m),\quad j=1,2,\ldots,p.
\]
The system model state is $\mb{\bm$x$}=[\begin{array}{cccc}
x_1 & x_2 & \cdots & x_n
\end{array}]^T \in \mb{\Bb R}^n$. The system input is $\mb{\bm$u$}=[\begin{array}{cccc}
u_1 & u_2 & \cdots & u_m
\end{array}]^T\in \mb{\Bb R}^m$, and the system output is $\mb{\bm$y$}=[\begin{array}{cccc}
y_1 & y_2 & \cdots y_p
\end{array}]^T\in \mb{\Bb R}^p$. In vector notation the above system model has the form
\begin{eqnarray*}
\dot{\mb{\bm$x$}}&=&\mb{\bm$f$}(t,\mb{\bm$x$},\mb{\bm$u$}), \quad \mb{\bm$x$}(t_0)=\mb{\bm$x$}_0 \\
{\b y}&=&{\b h}(t,{\b x,\b u}),
\end{eqnarray*}
where $\mb{\bm$f$}:\mb{\Bb R} \times \mb{\Bb R}^n \times \mb{\Bb R}^m \to \mb{\Bb R}^n$ and $\mb{\bm$h$}:\mb{\Bb R} \times \mb{\Bb R}^n \times \mb{\Bb R}^m \to \mb{\Bb R}^p$ are vector valued functions. In further considerations, we regard a dynamic system under considerations and its model represented by the above equations as equivalent. We now illustrate dynamic system axioms on a simple example.
\begin{example} \rm
We consider a dynamic system with no external inputs modeled by the first order linear differential equation
\begin{equation}
\dot{x}(t)=ax(t), \quad x_0=x(t_0),
\label{eq:simple_mo}
\end{equation}
where $a$ is a constant, $x \in X=\mb{\Bb R}$, and $T=\mb{\Bb R}$.
The solution to the above differential equation has the form
\[
x(t)=e^{a(t-t_0)}x(t_0).
\]
The above system model can be described as a triple
\[
\{ T, X, \Phi \},
\]
where
\[
\Phi :T \times X \to X
\]
is the transition mapping. In this example
\[
\Phi (t;t_0,x(t_0))=e^{a(t-t_0)}x(t_0).
\]
It is clear that $\Phi$ is a continuous function. The transition function $\Phi = e^{a(t-t_0)}x(t_0)$ satisfies the semigroup property because
\begin{eqnarray*}
\Phi (t_2;t_1,\Phi(t_1;t_0,x(t_0))) &=& (e^{a(t_2-t_1)})(e^{a(t_1-t_0)}x(t_0))\\
&=& e^{a(t_2-t_0)}x(t_0)\\
&=& \Phi (t_2;t_0,x(t_0)).
\end{eqnarray*}
The identity property axiom is also satisfied since
\begin{eqnarray*}
\Phi (t_0;t_0,x(t_0)) &=& e^{a(t_0-t_0)}x(t_0)\\
&=& x(t_0).
\end{eqnarray*}
Finally, observe that the system model given by~(\ref{eq:simple_mo}) is time invariant since
\begin{eqnarray*}
\Phi (t_1;t_0,x(t_0)) &=& e^{a(t_1-t_0)}x(t_0)\\
&=& \Phi (t_1+\tau ;t_0+\tau ,x(t_0))\\
&=& e^{a(t_1+\tau -(t_0+\tau ))}x(t_0)\\
&=& e^{a(t_1-t_0)}x(t_0).
\end{eqnarray*}
\end{example}
