paper/src/paper.tex
author Eugen Sawin <sawine@me73.com>
Tue, 28 Jun 2011 14:45:02 +0200
changeset 15 8a3d0605adf5
parent 14 68fff3a1453e
child 16 23c4bc2af0b1
permissions -rw-r--r--
Multicolumn lists.
     1 \documentclass[a4paper, pagesize, DIV=calc, smallheadings]{article}  
     2 \usepackage{graphicx}
     3 %\usepackage[latin1]{inputenc}
     4 \usepackage{amsmath, amsthm, amssymb, amsfonts, verbatim}
     5 \usepackage{typearea}
     6 \usepackage{algorithm}
     7 \usepackage{algorithmic}
     8 \usepackage{multicol}
     9 %\usepackage{fullpage}
    10 %\usepackage[T1]{fontenc}
    11 %\usepackage{arev}
    12 
    13 %\pagestyle{headings}
    14 \renewcommand{\familydefault}{\sfdefault}
    15 \title{\uppercase{\textbf{\Large{A}\large{lgorithmic} \Large{V}\large{erification of} \Large{R}\large{eactive} \Large{S}\large{ystems}}\\
    16 \tiny{Draft}
    17 }}
    18 \author{
    19 \uppercase{{\small{E}\scriptsize{UGEN} \small{S}\scriptsize{AWIN}}\\
    20 {\em \small{U}\scriptsize{NIVERSITY OF} \small{F}\scriptsize{REIBURG}}\\
    21 %{\em \small{C}\scriptsize{omputer} \small{S}\scriptsize{cience} \small{D}\scriptsize{epartment}}\\
    22 {\em \small{G}\scriptsize{ERMANY}}}\\
    23 %\texttt{\footnotesize{sawine@informatik.uni-freiburg.de}}
    24 }
    25 \date{\textsc{\hfill}}
    26 
    27 \theoremstyle{definition} %plain, definition, remark, proposition, proof, corrolary
    28 \newtheorem*{def:finite words}{Finite words}
    29 \newtheorem*{def:infinite words}{Infinite words}
    30 \newtheorem*{def:regular languages}{Regular languages}
    31 \newtheorem*{def:regular languages closure}{Regular closure}
    32 \newtheorem*{def:omega regular languages}{$\omega$-regular languages}
    33 \newtheorem*{def:omega regular languages closure}{$\omega$-regular closure}
    34 \newtheorem*{def:buechi automata}{Automata}
    35 \newtheorem*{def:automata runs}{Runs}
    36 \newtheorem*{def:automata acceptance}{Acceptance}
    37 \newtheorem*{def:vocabulary}{Vocabulary}
    38 
    39 \theoremstyle{proposition}
    40 \newtheorem{prop:vocabulary sat}{Proposition}
    41 
    42 \begin{document}
    43 
    44 \maketitle
    45 \thispagestyle{empty}
    46 %\itshape
    47 %\renewcommand\abstractname{Abstract} 
    48 \begin{abstract}
    49 Over the past two decades, temporal logic has become a very basic tool for spec-
    50 ifying properties of reactive systems. For finite-state systems, it is possible to use
    51 techniques based on B\"uchi automata to verify if a system meets its specifications.
    52 This is done by synthesizing an automaton which generates all possible models of
    53 the given specification and then verifying if the given system refines this most gen-
    54 eral automaton. In these notes, we present a self-contained introduction to the basic
    55 techniques used for this automated verification. We also describe some recent space-
    56 efficient techniques which work on-the-fly.
    57 \end{abstract}
    58 %\normalfont
    59 \newpage
    60 \section{Introduction}
    61 Program verification is a fundamental area of study in computer science. The broad goal
    62 is to verify whether a program is ``correct''--i.e., whether the implementation of a program
    63 meets its specification. This is, in general, too ambitious a goal and several assumptions
    64 have to be made in order to render the problem tractable. In these lectures, we will focus
    65 on the verification of finite-state reactive programs. For specifying properties of programs,
    66 we use linear time temporal logic.
    67 
    68 What is a reactive program? The general pattern along which a conventional program
    69 executes is the following: it accepts an input, performs some computation, and yields an
    70 output. Thus, such a program can be viewed as an abstract function from an input domain
    71 to an output domain whose behaviour consists of a transformation from initial states to
    72 final states.
    73 
    74 In contrast, a reactive program is not expected to terminate. As the name suggests, such
    75 systems “react” to their environment on a continuous basis, responding appropriately to
    76 each input. Examples of such systems include operating systems, schedulers, discrete-event
    77 controllers etc. (Often, reactive systems are complex distributed programs, so concurrency
    78 also has to be taken into account. We will not stress on this aspect in these lectures—we
    79 take the view that a run of a distributed system can be represented as a sequence, by
    80 arbitrarily interleaving concurrent actions.)
    81 
    82 To specify the behaviour of a reactive system, we need a mechanism for talking about
    83 the way the system evolves along potentially infinite computations. Temporal logic 
    84 has become a well-established formalism for this purpose. Many varieties of temporal logic
    85 have been defined in the past twenty years—we focus on propositional linear time temporal
    86 logic (LTL).
    87 
    88 There is an intimate connection between models of LTL formulas and languages of
    89 infinite words—the models of an LTL formula constitute an ω-regular language over an
    90 appropriate alphabet. As a result, the satisfiability problem for LTL reduces to checking
    91 for emptiness of ω-regular languages. This connection was first explicitly pointed out in.
    92 
    93 \section{$\omega$-regular languages}
    94 \begin{def:finite words}
    95 Let $\Sigma$ be a non-empty set of symbols, called the alphabet. $\Sigma^*$ is the set of all \emph{finite} words over $\Sigma$. A \emph{finite} word $w \in \Sigma^*$ is a \emph{finite} sequence $v_0,...,v_{n-1}$ of symbols from alphabet $\Sigma$ with length $n = |w|$. $\varepsilon$ denotes the empty word with length $|\varepsilon| = 0$.
    96 \end{def:finite words}
    97 
    98 \begin{def:regular languages}
    99 The class of regular languages is defined recursively over an alphabet $\Sigma$:
   100 \begin{multicols}{2}
   101 \begin{itemize}
   102 \item $\emptyset$ is regular
   103 \item $\{\varepsilon\}$ is regular
   104 \item $\forall_{a \in \Sigma}:\{a\}$ is regular
   105 \end{itemize}
   106 \end{multicols}
   107 \end{def:regular languages}
   108 
   109 \begin{def:regular languages closure}
   110 Let $L_{R_1}, L_{R_2} \in \Sigma^*$ be regular. The class of regular languages is closed under following operations:
   111 \begin{multicols}{2}
   112 \begin{itemize}
   113 \item $L_{R_1}^*$
   114 \item $L_{R_1} \circ L_{R_2}$
   115 \item $L_{R_1} \cup L_{R_2}$
   116 \item $L_{R_1} \cap L_{R_2}$
   117 \item $\overline{L}_{R_1}$ and therefore $L_{R_1} - L_{R_2}$
   118 \end{itemize}
   119 \end{multicols}
   120 \end{def:regular languages closure}
   121 
   122 \begin{def:infinite words}
   123 $\Sigma^\omega$ is the set of all \emph{infinite} words over $\Sigma$. An \emph{infinite} word $w \in \Sigma^\omega$ is an \emph{infinite} sequence $v_0,...,v_\infty$ with length $\infty$. To address the elements of the infinite sequence $w$, we view the word as a function $w : \mathbb{N}_0 \to \Sigma$ with $w(i) = v_i$; thus $w(i)$ denotes the symbol at sequence position $i$ of word $w$; another notation used for $w(i)$ is $w_i$.
   124 \end{def:infinite words}
   125 
   126 \begin{def:omega regular languages}
   127 Set $L$ is an $\omega$-language over alphabet $\Sigma$ iff $L \subseteq \Sigma^\omega$. Let $L_R \subseteq \Sigma^*$ be a non-empty regular finite language and $\varepsilon \notin L_R$. A set $L$ is $\omega$-regular iff $L$ is an $\omega$-language and $L = L_R^\omega$.
   128 \end{def:omega regular languages}
   129 
   130 \begin{def:omega regular languages closure}
   131 Let $L_{\omega_1}, L_{\omega_2} \subseteq \Sigma^\omega$ be $\omega$-regular languages. The class of $\omega$-regular languages is closed under following operations:
   132 \begin{itemize}
   133 \item $L_R \circ L_{\omega_1}$, but \emph{not} $L_{\omega_1} \circ L_R$
   134 \item $L_{\omega_1} \cup L_{\omega_2}$, but only \emph{finitely} many times
   135 \end{itemize}
   136 \end{def:omega regular languages closure}
   137 
   138 
   139 \section{B\"uchi automata}
   140 \begin{def:buechi automata}
   141 A non-deterministic B\"uchi automaton is a tuple $A = (\Sigma, S, S_0, \Delta, F)$, where $\Sigma$ is a finite non-empty \emph{alphabet}, $S$ is a finite non-empty set of \emph{states}, $S_0 \subseteq S$ is the set of \emph{initial states}, $F \subseteq S$ is the set of \emph{accepting states} and $\Delta: S \times \Sigma \times S$ is a \emph{transition relation}. When suitable we will use the arrow notation for the transitions, where $s \xrightarrow{a} s'$ iff $(s, a, s') \in \Delta$.
   142 
   143 A deterministic B\"uchi automaton is a specialisation where the \emph{transition relation} $\Delta$ is a \emph{transition function} $\delta: S \times \Sigma \to S$ and the set $S_0$ of \emph{initial states} contains only a single state $s_0$.
   144 
   145 Within this text \emph{automata/automaton} will refer to non-deterministic B\"uchi automata/automaton, unless otherwise noted. 
   146 \end{def:buechi automata}
   147 
   148 \begin{def:automata runs}
   149 Let $A = (\Sigma, S, S_0, \Delta, F)$ be an automaton, a run $\rho$ of $A$ on an infinite word $w = a_0,a_1,...$ over alphabet $\Sigma$ is a sequence $\rho = s_0,s_1,...$, where $s_0 \in S_0$ and $(s_i, a_i, s_{i+1}) \in \Delta$, for all $i \geq 0$. Again we may view the run sequence as a function $\rho : \mathbb{N}_0 \to S$, where $\rho(i) = s_i$ denotes the state at the $i^{th}$ sequence position.
   150 \end{def:automata runs}
   151 
   152 \begin{def:automata acceptance}
   153 Let $A = (\Sigma, S, S_0, \Delta, F)$ be an automaton and let $\rho$ be a run of $A$, we define $inf(\rho) = \{s \in S \mid \exists^\omega{n \in \mathbb{N}_0}: \rho(n) = s\}$, where $\exists^\omega$ denotes the existential quantifier for infinitely many occurances, i.e., $s$ occurs infinitely often in $\rho$.
   154 
   155 The run $\rho$ is \emph{accepting} iff $inf(\rho) \cap F \neq \emptyset$, i.e., there exists an \emph{accepting state} which occurs infinitely often in the run $\rho$. The automaton $A$ \emph{accepts} an input word $w$, iff there exists a run $\rho$ of $A$ on $w$, such that $\rho$ is \emph{accepting}. The language $L_\omega(A)$ recognised by automaton $A$ is the set of all infinite words accepted by $A$.
   156 \end{def:automata acceptance}
   157 
   158 \section{Linear temporal logic}
   159 \subsection*{Sytnax}
   160 Let $P$ be the countable set of \emph{atomic propositions}. The \emph{alphabet} of the language $L_{LTL}(P)$ is $P \cup \{\neg, \lor, X, U\}$. We define the $L_{LTL}(P)$-\emph{formulae} $\varphi$ using following productions:
   161 \[\varphi ::= p \in P \,|\, \neg \varphi \,|\, \varphi \lor \varphi \,|\, X \varphi \,|\, \varphi U \varphi\]
   162 
   163 \subsection*{Interpretation}
   164 The intuition should go as follows: $\neg$ and $\lor$ correspond to the Boolean \emph{negation} and \emph{disjunction}, the unary temporal operator $X$ reads as \emph{next} and the binary temporal operator $U$ reads as \emph{until}.
   165 
   166 LTL is interpreted over \emph{computation paths}, where a computation corrensponds to a model over a \emph{Kripke-frame} constructed by the order of natural numbers.
   167 
   168 \subsection*{Semantics}
   169 A \emph{model} is a function $M: \mathbb{N}_0 \to 2^P$ over \emph{frame} $F$. The frame constitutes a linear order over $\mathbb{N}_0$, which corresponds to the linear progression of time from the \emph{present/past} into the \emph{future}. Therefore $M(i)$ assigns a set of \emph{positive atomic propositions} to each state of time instant $i$. Intuitively we say $p \in P$ is \emph{true} at time instant $i$ iff $p \in M(i)$.
   170 
   171 A model $M$ \emph{satisfies} an LTL-formula $\varphi$ at time instant $i$ is denoted by $M,i \models \varphi$. Satisfaction of a formula $\varphi$ is defined inductively over the structure of $\varphi$:
   172 \begin{itemize}
   173 \item $M,i \models p$ for $p \in P$ iff $p \in M(i)$
   174 \item $M,i \models \neg \varphi$ iff not $M,i \models \varphi$
   175 \item $M,i \models \varphi \lor \psi$ iff $M,i \models \varphi$ or $M,i \models \psi$
   176 \item $M,i \models X \varphi$ iff $M,i+1 \models \varphi$
   177 \item $M,i \models \varphi U \psi$ iff $\exists{k \geq i}: M,k \models \psi$ and $\forall{i \leq j < k}: M,j \models\varphi$
   178 \end{itemize}
   179 
   180 \begin{def:vocabulary}
   181 Let $\varphi$ be a LTL-formula over atomic propositions $P$, we define the \emph{vocabulary} $Voc(\varphi)$ of $\varphi$ inductively:
   182 \begin{multicols}{2}
   183 \begin{itemize}
   184 \item $Voc(p) = \{p\}$ for $p \in P$
   185 \item $Voc(\neg \varphi) = Voc(\varphi)$
   186 \item $Voc(\varphi \lor \psi) = Voc(\varphi) \cup Voc(\psi)$
   187 \item $Voc(X \varphi) = Voc(\varphi)$
   188 \item $Voc(\varphi U \psi) = Voc(\varphi) \cup Voc(\psi)$
   189 \end{itemize}
   190 \end{multicols}
   191 
   192 Let $M$ be a model and $\varphi$ a LTL-formula, we define model $M_{Voc(\varphi)}$:
   193 \[\forall{i \in \mathbb{N}_0}: M_{Voc(\varphi)} = M(i) \cap Voc(\varphi)\]
   194 \end{def:vocabulary}
   195 
   196 \begin{prop:vocabulary sat}
   197 Let $M$ be a model and $\varphi$ a LTL-formula, then following holds:
   198 \[\forall{i \in \mathbb{N}_0}: M,i \models \varphi \iff M_{Voc(\varphi)},i \models \varphi\] 
   199 \end{prop:vocabulary sat}
   200 
   201 \subsection*{Derived connectives}
   202 For a more convenient description of system specifications we present some derived symbols to be used in LTL-formulae. At first we introduce the notion of \emph{truth} and \emph{falsity} using constants $\top$ and $\bot$. Then we expand our set of connectives with the Boolean \emph{and}, \emph{implication} and \emph{equivalence}. And at last we derive the commonly used modal operators \emph{eventually} and \emph{henceforth}. Let $\varphi$ and $\psi$ be $L_{LTL}(P)$-formulae:
   203 \begin{multicols}{2}
   204 \begin{itemize}
   205 \item $\top \equiv p \lor \neg p$ for $p \in P$
   206 \item $\bot \equiv \neg \top$
   207 \item $\varphi \land \psi \equiv \neg (\neg \varphi \lor \neg \psi)$
   208 \item $\varphi \rightarrow \psi \equiv \neg \varphi \lor \psi$
   209 \item $\varphi \leftrightarrow \psi \equiv (\varphi \rightarrow \psi) \land (\psi \rightarrow \varphi)$
   210 \item $\Diamond \varphi \equiv \top U \varphi$
   211 \item $\Box \varphi \equiv \neg \Diamond \neg \varphi$
   212 \end{itemize}
   213 \end{multicols}
   214 
   215 \section{Model checking}
   216 
   217 \begin{thebibliography}{99}
   218 \bibitem{ref:ltl&büchi} 
   219 \uppercase{M{\footnotesize adhavan} M{\footnotesize ukund}.}
   220 {\em Linear-Time Temporal Logic and B\"uchi Automata}.
   221 Winter School on Logic and Computer Science, Indian Statistical Institute, Calcutta, 1997.
   222 
   223 \bibitem{ref:handbook} 
   224 \uppercase{P{\footnotesize atrick} B{\footnotesize lackburn}, 
   225 F{\footnotesize rank} W{\footnotesize olter and} J{\footnotesize ohan van} B{\footnotesize enthem}.}
   226 {\em Handbook of Modal Logic (Studies in Logic and Practical Reasoning)}.
   227 3rd Edition, Elsevier, Amsterdam, 2007.
   228 
   229 \bibitem{ref:infpaths}
   230 \uppercase{P{\footnotesize ierre} W{\footnotesize olper}, 
   231 M{\footnotesize oshe} Y. V{\footnotesize ardi and}
   232 A. P{\footnotesize rasad} S{\footnotesize istla}.}
   233 {\em Reasoning about Infinite Computation Paths}.
   234 In Proceedings of the 24th IEEE FOCS, 1983.
   235 
   236 \end{thebibliography}
   237 \end{document}