\documentclass{article} \usepackage{tikz} \usetikzlibrary{automata,positioning,arrows.meta} \usepackage{amssymb} \usepackage[graphics,tightpage,active,pdftex]{preview} \setlength{\PreviewBorder}{5pt} \PreviewEnvironment{tikzpicture} \begin{document} \begin{tikzpicture}[>={Stealth[width=6pt,length=9pt]}, accepting/.style={double distance = 2pt, outer sep = 1pt + \pgflinewidth}, shorten >=1pt] \draw (350.0pt, -100.0pt)node[state](2){$q_{2}$}; \draw (100.0pt, -400.0pt)node[state](7){$q_{7}$}; \draw (500.0pt, -300.0pt)node[state](5){$q_{5}$}; \draw (250.0pt, -250.0pt)node[state](0){$q_{0}$}; \draw (500.0pt, -150.0pt)node[state](3){$q_{3}$}; \draw (50.0pt, -300.0pt)node[state, initial, initial text =](9){$q_{9}$}; \draw (150.0pt, -250.0pt)node[state](10){$q_{10}$}; \draw (400.0pt, -250.0pt)node[state](4){$q_{4}$}; \draw (250.0pt, -150.0pt)node[state](1){$q_{1}$}; \draw (250.0pt, -400.0pt)node[state, accepting](8){$q_{8}$}; \draw (400.0pt, -400.0pt)node[state](6){$q_{6}$}; \path[->] (5) edge node[sloped,anchor=north]{c : $\Box$, L}(6); \path[->] (10) edge[loop above] node[align=center]{a : a, L\\ b : b, L\\ c : c, L}(10); \path[->] (6) edge[loop above] node[align=center]{a : a, L\\ b : b, L\\ c : c, L\\ \# : \#, L}(6); \path[->] (10) edge node[sloped,anchor=south]{$\Box$ : $\Box$, R}(0); \path[->] (4) edge[loop above] node{c : c, R}(4); \path[->] (3) edge[loop above] node{b : b, R}(3); \path[->] (2) edge[loop above] node{\# : \#, R}(2); \path[->] (1) edge[loop above] node{a : a, R}(1); \path[->] (7) edge[loop above] node{\# : \#, R}(7); \path[->] (9) edge[loop above] node[align=center]{c : c, R\\ b : b, R\\ a : a, R}(9); \path[->] (1) edge node[sloped,anchor=south]{\# : \#, R}(2); \path[->] (6) edge node[sloped,anchor=north]{$\Box$ : $\Box$, R}(0); \path[->] (9) edge node[sloped,anchor=south]{$\Box$ : $\Box$, L}(10); \path[->] (0) edge node[sloped,anchor=north]{a : $\Box$, R}(1); \path[->] (1) edge node[sloped,anchor=south]{b : \#, R}(3); \path[->] (0) edge node[sloped,anchor=north]{\# : \#, R}(7); \path[->] (7) edge node[sloped,anchor=south]{$\Box$ : $\Box$, L}(8); \path[->] (3) edge node[sloped,anchor=north]{c : c, R}(4); \path[->] (2) edge node[sloped,anchor=south]{b : \#, R}(3); \path[->] (0) edge node[sloped,anchor=north]{$\Box$ : $\Box$, S}(8); \path[->] (4) edge node[sloped,anchor=south]{$\Box$ : $\Box$, L}(5); \end{tikzpicture} \end{document}