Хабр Курсы для всех
РЕКЛАМА
Практикум, Хекслет, SkyPro, авторские курсы — собрали всех и попросили скидки. Осталось выбрать!
\subsection{Looking up ``s*ng''}
In this case we need to lookup terms with a wildcard in a middle of a term. Hence, we need to permutate it to the form with a trailing wildcard. Process of searching for such permutation is shown in Figure~\ref{fig:perm_sng}.
\begin{figure}[h]
\begin{center}
\begin{tikzpicture}[thick,
node distance=2cm,
text height=1.5ex,
text depth=.25ex]
\node[format] (sng) {\texttt{s*ng}};
\node[format, right of=sng] (sng1) {\texttt{s*ng\$}};
\node[format, right of=sng1] (sng2){\texttt{*ng\$s}};
\node[format, right of=sng2] (sng3){\texttt{ng\$s*}};
\path[->] (sng) edge (sng1);
\path[->] (sng1) edge (sng2);
\path[->] (sng2) edge (sng3);
\path[->, draw] (sng1) -- ++(0,1) -- ++(3,0) -- (sng3);
\end{tikzpicture}
\end{center}
\caption{Permutations for wildcard query \texttt{s*ng}}\label{fig:perm_sng}
\end{figure}
Диаграммы в LaTeX