📄 dha.tex
字号:
\chapter{Discrete Hybrid Automata}\index{DHA|see{Discrete Hybrid Automata}}%\index{SAS|see{Switched Affine System}}%\index{EG|see{Event Generator}}%\index{FSM|see{Finite State Machine}}%\index{MS|see{Mode Selector}}%\label{sect::DHA} \emph{Discrete hybrid automata}\index{DiscreteHybrid Automata} (DHA) are the interconnection of a finite statemachine and a switched linear dynamic system through a modeselector and an event generator (see Figure~\ref{fig:dha}).\figuraeps{model}{t}{.90\textwidth}{A discrete hybrid automaton(DHA) is the connection of a finite state machine (FSM) and aswitched affine system (SAS), through a mode selector (MS) and anevent generator (EG). The output signals are omitted forclarity}{fig:dha}In the following we will use the fact that any discrete variable$\alpha \in \{\alpha_1,\ldots,\alpha_j\}$, admits a Booleanencoding $a \in \bol^{d(j)}$. From now on we will refer to either the variable or its encoding withthe same name.\section{Switched Affine System \emph{(SAS)}} \index{Switched Affine System}A switched affinesystem is a collection of linear affine systems:\begin{subequations}\begin{eqnarray} x'_r(k) &=& A_{i(k)}x_r(k) + B_{i(k)}u_r(k) + f_{i(k)}\label{eq:sas-x}\\ y_r(k) &=& C_{i(k)}x_r(k) + D_{i(k)}u_r(k) + g_{i(k)}\label{eq:sas-y}{\rm ,}\end{eqnarray}%\label{eq::sas}%\end{subequations}%where $k\in \Z^+$ is the time indicator, $'$ denotes the successoroperator ($x'_r(k) = x_r(k+1)$), $x_r \in \XX_r\subseteq\rr^{n_r}$is the continuous state vector, $u_r \in \UU_r\subseteq\rr^{m_r}$is the exogenous continuous input vector, $y_r \in\YY_r\subseteq\rr^{p_r}$ is the continuous output vector,$\{A_{i},B_{i},f_{i},C_{i},D_{i},g_{i}\}_{i\in\II}$ is acollection of matrices of suitable dimensions, and the mode $i(k)\in \II$ is an input signal that chooses the linear state updatedynamics. We denote by $\sharp\II = s$ the number of elements in$\II$. A SAS of the form~(\ref{eq::sas}) preserves the value ofthe state when a switch occurs, however it is possible toimplement reset maps on a SAS, as we will show later in thissection. A SAS can be rewritten as the combination of linear termsand \emph{if-then-else} rules: the state-updateEquation~(\ref{eq:sas-x}) is equivalent to\begin{subequations}\label{eq::z-transform} \beqar z_1(k) &=& \left\{ \begin{array}{ll} A_1 x_r(k) + B_1 u_r(k) + f_1, & {\rm if~} (i(k) = 1), \\ 0, & {\rm otherwise}, \end{array} \right. \label{eq::z-transform-a}\\ & \vdots & \nonumber \\ z_s(k) &=& \left\{ \begin{array}{ll} A_s x_r(k) + B_s u_r(k) + f_s & {\rm if~} (i(k) = s), \\ 0 & {\rm otherwise}, \\ \end{array} \right. \label{eq::z-transform-b}\\ x'_r(k) &=& \sum_{i=1}^s z_i(k) \label{eq::z-transform-c} \eeqar\end{subequations}where $z_i(k)\in \rr ^{n_r},i = 1,\ldots,s$, and~(\ref{eq:sas-y})admits a similar transformation.\section{Event Generator \emph{(EG)}} \index{Event Generator} An event generator is amathematical object that generates a logic signal according to thesatisfaction of a linear affine constraint:\begin{equation}\label{eq::eventgenerator} \delta_e(k)= f_{\rm H}(x_r(k),u_r(k),k){\rm ,}\end{equation}where $f_{\rm H}: \rr^{n_r} \times \rr^{m_r} \times \Z_{\ge 0}\rightarrow \DE \subseteq \bol^{n_e}$ is a vector of descriptivefunctions of a linear hyperplane, and $\Z_{\geq0}\eqdef\{0,1,\ldots\}$ is the set of nonnegative integers. Inparticular, {\em time events} are modeled as: $[\delta^i_e(k) = 1]\leftrightarrow [kT_s \ge t_0]$, where $T_s$ is the sampling time,while {\em threshold events} are modeled as: $[\delta^i_e(k) = 1]\leftrightarrow [a^Tx_r(k) + b^Tu_r(k) \le c]$, where thesuperscript $i$ denotes the $i$-th component of a vector.\section{Finite State Machine (\emph{FSM})} \index{Finite State Machine}A finite state machine\footnote{In this paper we will only referto synchronous finite state machines, where the transitions mayhappen only at sampling times. The adjective synchronous will beomitted for brevity.} (or automaton) is a discrete dynamic processthat evolves according to a logic state update function:\begin{subequations}\begin{equation} x_b'(k) = f_{\rm B}(x_b(k),u_b(k),\delta_e(k)){\rm ,}\end{equation}where $x_b \in \XX_b \subseteq \bol^{n_b}$ is the Boolean state,$u_b \in \UU_b \subseteq \bol^{m_b}$ is the exogenous Booleaninput, $\delta_e(k)$ is the endogenous input coming from the EG,and $f_{\rm B}: \XX_b \times \UU_b \times \DE \rightarrow \XX_b$is a deterministic logic function. A FSM can be convenientlyrepresented using an oriented graph. A FSM may also have anassociated Boolean output\begin{equation} y_b(k) = g_{\rm B}(x_b(k),u_b(k),\delta_e(k)){\rm ,}\end{equation}\end{subequations}where $y_b \in \YY_b \subseteq \bol^{p_b}$.\figuraeps{fsm1}{t}{.4\textwidth}{Example of finite statemachine}{fig:fsm}\begin{example}\label{ex:automa} Figure~\ref{fig:fsm} shows a finite statemachine where $u_b=[u_{b1}~u_{b2}]^T$ is the input vector, and$\delta = [\delta_1 \ldots \delta_4]^T$ ia a vector of signalscoming from the event generator. The state transition function is:\begin{equation} x_b'(k) = \left\{ \begin{array}{lcl} {\sf Red} & {\rm if } & ((x_b(k) = {\sf Green}) \ANd d_4) \OR ((x_b(k) = {\sf Red}) \ANd \NOT u_{b2} \ANd \NOT \delta_1), \\ {\sf Green} & {\rm if } & ((x_b(k) = {\sf Red}) \ANd u_{b2}) \OR ((x_b(k) = {\sf Blue}) \ANd \delta_2) \OR \\ & & ((x_b(k) = {\sf Green}) \ANd \NOT \delta_4 \ANd \NOT (u_{b1}\ANd\delta_3)), \\ {\sf Blue} & {\rm if } & ((x_b(k) = {\sf Red}) \ANd \delta_1) \OR ((x_b(k) = {\sf Green}) \ANd (u_{b1}\ANd\delta_3)) \OR\\ && ((x_b(k) = {\sf Blue}) \ANd \NOT \delta_2))\mbox{\rm .} \\ \end{array} \right. \label{eq:exauto}\end{equation}By associating a Boolean vector $x_b = \smallmat{x_{b1}\\x_{b2}}$to each state (${\sf Red} = \smallmat{0\\0}$, ${\sf Green} =\smallmat{0\\1}$, and ${\sf Blue} = \smallmat{1\\0}$), one canrewrite~(\ref{eq:exauto}) as:\begin{eqnarray*} x_{b1}' &=& \NOT ((\NOT x_{b1} \ANd x_{b2} \ANd d_4) \OR (\NOT x_{b1} \ANd \NOT x_{b2} \ANd \NOT u_{b2} \ANd \NOT \delta_1))\\ && \OR \NOT ((\NOT x_{b1} \ANd \NOT x_{b2} \ANd u_{b2}) \OR (x_{b1} \ANd \NOT x_{b2} \ANd \delta_2) \OR (\NOT x_{b1} \ANd x_{b2} \ANd \NOT \delta_4 \ANd \NOT (u_{b1}\ANd\delta_3)))\\ && \OR ((\NOT x_{b1} \ANd \NOT x_{b2} \ANd \delta_1) \OR (\NOT x_{b1} \ANd x_{b2} \ANd (u_{b1}\ANd\delta_3)) \OR (x_{b1} \ANd \NOT x_{b2} \ANd \NOT \delta_2)), \\ x_{b2}' &=& \NOT ((\NOT x_{b1} \ANd x_{b2} \ANd d_4) \OR (\NOT x_{b1} \ANd \NOT x_{b2} \ANd \NOT u_{b2} \ANd \NOT \delta_1)) \\ && \OR ((\NOT x_{b1} \ANd \NOT x_{b2} \ANd u_{b2}) \OR (x_{b1} \ANd \NOT x_{b2} \ANd \delta_2) \OR (\NOT x_{b1} \ANd x_{b2} \ANd \NOT \delta_4 \ANd \NOT (u_{b1}\ANd\delta_3)))\\ && \OR \NOT ((\NOT x_{b1} \ANd \NOT x_{b2} \ANd \delta_1) \OR (\NOT x_{b1} \ANd x_{b2} \ANd (u_{b1}\ANd\delta_3)) \OR (x_{b1} \ANd \NOT x_{b2} \ANd \NOT \delta_2)){\rm ,}\end{eqnarray*}\end{example}where the time index, $k$, has been omitted for brevity.\section{Mode Selector (\emph{MS})} \index{Mode Selector}The logic state $x_b(k)$, the Boolean inputs $u_b(k)$, and the events$\delta_e(k)$ select the dynamic mode $i(k)$ of the SAS through aBoolean function $f_{\rm M}: \XX_b \times \UU_b \times \DE\rightarrow \II$, which is therefore called {\em mode selector}.The output of this function\begin{equation} i(k)=f_{\rm M}(x_b(k),u_b(k),\delta_e(k)) \label{eq:MS}\end{equation}is called {\em active mode}. We say that a {\em mode switch}occurs at step $k$ if $i(k)\neq i(k-1)$. Note that contrarily tocontinuous time hybrid models, where switches can occur at anytime, in our discrete-time setting a mode switch can only occur atsampling instants.\section{Reset Maps}\index{Reset Maps} In correspondence with a mode switch $i(k)=j$,$i(k-1)=h\neq j$, $h,j\in\II$, instead of evolving$x'_r(k)=A_jx_r(k)+B_ju_r(k)+f_j$ it is possible to associate areset of the continuous state vector\begin{equation} x_r'(k)=\phi_{\overrightarrow{hj}}(x_r(k),u_r(k))=A_{\overrightarrow{hj}}x_r(k)+B_{\overrightarrow{hj}}u_r(k)+f_{\overrightarrow{hj}}\end{equation}the function $\phi_{\overrightarrow{hj}}$ is called \emph{resetmap}. The reset can be considered as a special dynamics that onlyacts for one sampling step. Figure~\ref{fig:reset-a} shows how areset affects the state evolution: At time $k=5$ the system is inmode $i(5)=1$, at time $k=6$ the state$x_r(6)=A_1x_r(5)+B_1u_r(5)+f_1$ enters the region $x_r\ge 0$.This generates an event $\delta_e(6)$ through the EG, which inturn causes the MS to change the system dynamics to $i(6)=2$. Themode switch $1\rightarrow 2$ resets$x_r(7)=A_{\overrightarrow{12}}x_r(6)+B_{\overrightarrow{12}}u_r(6)+ f_{\overrightarrow{12}}$. If thestate $x_r(7)$ after reset belongs again to the region where themode $2$ is active, $i(7)=2$, the successor state is$x_r(8)=A_2x_r(7)+B_2u_r(7)+f_2$. It might even happen that$x_r(7)$ belongs to another region, say a region where mode $3$ isactive, $i(7)=3$: In this case, since $i(6)\neq i(7)$, a furtherreset $2\rightarrow 3$ is applied,$x_r(8)=A_{\overrightarrow{23}}x_r(7)+B_{\overrightarrow{23}}u_r(7)+f_{\overrightarrow{23}}$.\newcommand{\res}{{\rm a}}\begin{proposition}A DHA $\Sigma^{\res}$ with reset conditions can be rewritten as aDHA $\Sigma$ without reset conditions. \label{prop:resets}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -