134 lines
4.6 KiB
TeX
134 lines
4.6 KiB
TeX
\begin{tikzpicture}
|
|
\input{src/tikz/alsk}
|
|
|
|
\tikzset{split/.style={alsk/scheme/split,minimum width=8mm}}
|
|
\tikzset{task/.style={alsk/scheme/task,minimum width=6mm}}
|
|
\tikzset{join/.style={alsk/scheme/join,minimum width=8mm}}
|
|
\tikzset{loop/.style={alsk/scheme/loop,minimum width=6mm}}
|
|
\tikzset{frame/.style={alsk/scheme/frame=#1,inner sep=.5mm}}
|
|
|
|
% GRASP nodes
|
|
\matrix[row sep=2.5mm, column sep=-1mm] {
|
|
& \node[split,minimum width=8mm] (grasp split) {}; \\
|
|
\\
|
|
\node[task] (grasp ch0) {\scriptsize CH}; & \node[alsk/label] (grasp chi) {\scriptsize\dots}; &
|
|
\node[task] (grasp chn) {\scriptsize CH}; \\
|
|
\node[task] (grasp ls0) {}; & \node[alsk/label] (grasp lsi) {\scriptsize\dots}; &
|
|
\node[task] (grasp lsn) {}; \\
|
|
\\
|
|
& \node[join] (grasp merge) {}; \\
|
|
& \node[task] (grasp select) {\scriptsize Sel\textsubscript{1}}; \\
|
|
};
|
|
|
|
\node[above=3mm of grasp split] (grasp entry) {};
|
|
\node[below=3mm of grasp select] (grasp return) {};
|
|
|
|
% Frames
|
|
\node[frame=colStruct,fit margins={top=1.5mm,bottom=1.5mm},
|
|
fit=(grasp ch0)(grasp ls0)] (grasp serial0) {};
|
|
\node[frame=colStruct,fit margins={top=1.5mm,bottom=1.5mm},
|
|
fit=(grasp chn)(grasp lsn)] (grasp serialn) {};
|
|
|
|
\node[frame=colStruct,fit margins={top=1.5mm,bottom=1.5mm},
|
|
fit=(grasp split)(grasp select)(grasp serial0)(grasp serialn)] {};
|
|
|
|
% GRASP Links
|
|
\begin{scope}[alsk/scheme/link]
|
|
\draw (grasp entry) -- (grasp split);
|
|
|
|
\draw (grasp split.210) -- (grasp serial0.north);
|
|
\draw (grasp split.330) -- (grasp serialn.north);
|
|
|
|
\draw (grasp serial0.north) -- (grasp ch0);
|
|
\draw (grasp serialn.north) -- (grasp chn);
|
|
|
|
\draw (grasp ch0) -- (grasp ls0);
|
|
\draw (grasp chn) -- (grasp lsn);
|
|
|
|
\draw (grasp ls0) -- (grasp serial0.south);
|
|
\draw (grasp lsn) -- (grasp serialn.south);
|
|
|
|
\draw (grasp serial0.south) -- (grasp merge.150);
|
|
\draw (grasp serialn.south) -- (grasp merge.30);
|
|
|
|
\draw (grasp merge) -- (grasp select);
|
|
|
|
\draw (grasp select) -- (grasp return);
|
|
\end{scope}
|
|
|
|
% ELS
|
|
\begin{scope}[common/overlay,spy using outlines={circle,magnification=.095,size=6.0mm}]
|
|
\begin{scope}[every node/.append style={transform shape,scale=.7}]
|
|
\matrix[row sep=1.5mm, column sep=-1mm] (els) at (5, 0) {
|
|
& \node[task] (els init ls) {\scriptsize iLS}; \\
|
|
& \node[loop] (els loopbegin) {}; \\
|
|
& \node[split] (els split) {}; \\
|
|
\\
|
|
\node[task] (els m0) {\scriptsize M}; & \node[alsk/label] (els mi) {\dots}; &
|
|
\node[task] (els mn) {\scriptsize M}; \\
|
|
\node[task] (els ls0) {\scriptsize LS}; & \node[alsk/label] (els lsi) {\dots}; &
|
|
\node[task] (els lsn) {\scriptsize LS}; \\
|
|
\\
|
|
& \node[join] (els merge) {}; \\
|
|
& \node[task] (els select2) {\scriptsize Sel\textsubscript{2}}; \\
|
|
& \node[task] (els select3) {\scriptsize Sel\textsubscript{3}}; \\
|
|
& \node[task] (els accept) {\scriptsize A}; \\
|
|
& \node[loop] (els loopend) {}; \\
|
|
};
|
|
|
|
\node[above=1.5mm of els init ls] (els entry) {};
|
|
\node[below=1.5mm of els loopend] (els return) {};
|
|
|
|
% Frames
|
|
\node[frame=colStruct,fit margins={top=2mm,bottom=2mm,left=1.2mm,right=1.2mm},
|
|
fit=(els m0)(els ls0)] (els serial0) {};
|
|
\node[frame=colStruct,fit margins={top=2mm,bottom=2mm,left=1.2mm,right=1.2mm},
|
|
fit=(els mn)(els lsn)] (els serialn) {};
|
|
|
|
\node[frame=colStruct,fit margins={top=4.4mm,bottom=4mm,left=2.8mm,right=2.8mm},
|
|
fit=(els split)(els select2)(els serial0)(els serialn)] {};
|
|
|
|
% Links
|
|
\begin{scope}[alsk/scheme/link]
|
|
\draw (els entry) -- (els init ls);
|
|
|
|
\draw (els init ls) -- (els loopbegin);
|
|
|
|
\draw (els loopbegin) -- (els split);
|
|
|
|
\draw (els split.210) -- (els serial0.north);
|
|
\draw (els split.330) -- (els serialn.north);
|
|
|
|
\draw (els serial0.north) -- (els m0);
|
|
\draw (els serialn.north) -- (els mn);
|
|
|
|
\draw (els m0) -- (els ls0);
|
|
\draw (els mn) -- (els lsn);
|
|
|
|
\draw (els ls0) -- (els serial0.south);
|
|
\draw (els lsn) -- (els serialn.south);
|
|
|
|
\draw (els serial0.south) -- (els merge.150);
|
|
\draw (els serialn.south) -- (els merge.30);
|
|
|
|
\draw (els merge) -- (els select2);
|
|
|
|
\draw (els select2) -- (els select3);
|
|
\draw (els select3) -- (els accept);
|
|
\draw (els accept) -- (els loopend);
|
|
\end{scope}
|
|
|
|
\draw[alsk/scheme/link] (els loopend) -| +(-12mm, 0) |- ([xshift=-6mm]els loopbegin.west)
|
|
-- (els loopbegin);
|
|
|
|
\draw[alsk/scheme/link] (els loopend) -- (els return);
|
|
\end{scope}
|
|
|
|
\spy[densely dotted,thick,colMuscle] on (els) in node at (grasp ls0);
|
|
\spy[densely dotted,thick,colMuscle,connect spies] on (els) in node at (grasp lsn);
|
|
\end{scope}
|
|
|
|
% Bounding box adjustments
|
|
\node[rectangle,fit=(els)(els entry)(els return),fit margins={right=3mm}]{};
|
|
\end{tikzpicture}
|