diff --git a/content/applying-automata-learning.tex b/content/applying-automata-learning.tex index 3cb425d..cd280de 100644 --- a/content/applying-automata-learning.tex +++ b/content/applying-automata-learning.tex @@ -41,7 +41,29 @@ The most efficient such techniques use the set-up of \emph{active learning,} ill \startplacefigure [title={Active learning of reactive systems.}, reference=fig:learning] -\externalfigure[Learner.pdf][width=0.6\textwidth] +\hbox{\starttikzpicture + [comp/.style={draw, minimum height=3.5cm, minimum width=2.25cm}, + intcomp/.style={draw, inner sep=5pt}, + conn/.style={at end, anchor=west, align=left, font=\tfx}] +% https://tex.stackexchange.com/questions/103198/make-straight-line-between-two-nodes +\node (l) [comp] {}; +\node [below] at (l.north) {Learner}; + +\node (t) [comp, right=4.5cm of l] {}; +\node (t1) [below] at (t.north) {Teacher}; + +\node (sut) [intcomp, below=.8cm of t.north] {SUT}; +\node (mbt) [intcomp, above=.8cm of t.south] {MBT tool}; + +\draw[<-] ([yshift=2pt]sut.west) -- node[above=6pt, conn] {Membership Query} ([yshift=2pt]sut -| l.east); +\draw[->] ([yshift=-2pt]sut.west) -- node[below=7pt, conn] {Output} ([yshift=-2pt]sut -| l.east); + +\draw[<-] ([yshift=2pt]mbt.west) -- node[above=6pt, conn] {Equivalence Query} ([yshift=2pt]mbt -| l.east); +\draw[->] ([yshift=-2pt]mbt.west) -- node[below=7pt, conn] {\kw{yes} or \kw{no} with counterexample} ([yshift=-2pt]mbt -| l.east); + +\draw[->] ([xshift=2pt]sut.south) -- ([xshift=2pt]mbt.north); +\draw[->] ([xshift=-2pt]mbt.north) -- ([xshift=-2pt]sut.south); +\stoptikzpicture} \stopplacefigure The core of the teacher is a \emph{System Under Test} (SUT), a reactive system to which one can apply inputs and whose outputs one may observe. @@ -118,7 +140,31 @@ Other products can be connected to an engine that pre- or postprocess the paper, \startplacefigure [title={Global overview of the engine software.}, reference=fig:esra-overview] -\externalfigure[ESRAOverview.pdf][width=0.5\textwidth] +\hbox{\switchtobodyfont[small]\starttikzpicture + [comp/.style={draw, align=center, text width=2.2cm, fill=white, minimum height=13pt}, + conn/.style={<->}] +\forgetall +\node (eia) [comp] {External Interface Adapters}; +\node (m) [comp, below=11pt of eia] {Managers}; +\node (f) [comp, below=11pt of m] {Functions}; +\node (os) [comp, fit=(eia) (m) (f), inner sep=0pt, xshift=3.5cm] {}; +\node at (os) (ost) [align=center, text width=2.2cm] {OS Facilities and Services}; +\node (c) [left=22pt of eia] {Controller}; + +\draw + (eia) edge[conn] (m) + (m) edge[conn] (f) + (eia) edge[conn] (os.west |- eia) + (m) edge[conn] (os.west |- m) + (f) edge[conn] (os.west |- f) + (eia) edge[conn] (c); + +\startscope[on background layer] + \node (es) [rounded corners, fit=(eia) (m) (f) (os), inner sep=11pt, fill=black!10] {}; + \node at (es.north) [rounded corners, fill=black!10] {Engine Software}; +\stopscope +\stoptikzpicture} +%\externalfigure[ESRAOverview.pdf][width=0.5\textwidth] \stopplacefigure \in{Figure}[fig:esra-overview] gives an overview of the software in a printer or copier. @@ -151,7 +197,28 @@ Finally, it handles status transitions when an error occurs. \startplacefigure [title={Overview of the managers and clients connected to the ESM.}, reference=fig:esm-protocols] -\externalfigure[ESMProtocols.pdf][width=0.5\textwidth] +\hbox{\switchtobodyfont[small]\starttikzpicture + [comp/.style={draw, align=center, text width=1.7cm, minimum width=1.8cm, minimum height=1.8cm, inner sep=0pt, fill=white}, + coms/.style={comp, double copy shadow}, + conn/.style={<->}, + node distance=2.5cm] +\forgetall +\node (ehm) [comp] {Error Handling Manager}; +\node (acm) [comp, right of=ehm] {Action Control Manager}; +\node (oc) [coms, right of=acm] {Other Client}; +\node (tc) [comp, below of=ehm] {Top Capsule}; +\node (esm) [comp, below of=acm, fill=black!10] {Engine Status Manager}; +\node (im) [comp, below of=oc] {Information Manager}; +\node (fn) [coms, below of=esm] {Function}; + +\path[conn] + (ehm) edge (esm) + (acm) edge (esm) + (oc) edge (esm) + (tc) edge (esm) + (im) edge (esm) + (fn) edge (esm); +\stoptikzpicture} \stopplacefigure \in{Figure}[fig:esm-protocols] shows the different components to which the ESM is connected. diff --git a/environment/tikz.tex b/environment/tikz.tex index 9f0c5b8..6e997ca 100644 --- a/environment/tikz.tex +++ b/environment/tikz.tex @@ -1,12 +1,12 @@ \startenvironment tikz \usemodule[tikz] -\usetikzlibrary[automata, arrows, positioning, matrix, fit, decorations.pathreplacing] +\usetikzlibrary[automata, arrows, positioning, matrix, fit, decorations.pathreplacing, shapes.geometric, shadows, backgrounds] \usemodule[pgfplots] % defaults -\tikzset{node distance=2cm} % 'shorten >=2pt' only for automata +\tikzset{node distance=2cm} \tikzset{/pgfplots/table/search path={data,../data}} \tikzset{initial text=, every initial by arrow/.style={shorten >=1pt}}