teststrategien-anschaulich.tex 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. \documentclass{article}
  2. \usepackage[utf8]{inputenc} % this is needed for umlauts
  3. \usepackage[ngerman]{babel} % this is needed for umlauts
  4. \usepackage[T1]{fontenc} % this is needed for correct output of umlauts in pdf
  5. \usepackage[pdftex,active,tightpage]{preview}
  6. \setlength\PreviewBorder{2mm}
  7. \usepackage{tikz}
  8. \usetikzlibrary{shapes, calc, shapes,snakes, automata}
  9. \usepackage{amsmath,amssymb}
  10. \tikzstyle{midnode}=[
  11. draw=blue!70, % draw the border with 70% transparent blue
  12. rectangle, % the shape of the node is a rectangle
  13. fill=blue!10, % fill the box with 20% blue
  14. text width=1cm,
  15. text centered]
  16. \tikzstyle{smallnode}=[
  17. draw=blue!70, % draw the border with 70% transparent blue
  18. rectangle, % the shape of the node is a rectangle
  19. fill=blue!10, % fill the box with 20% blue
  20. text width=0.4cm,
  21. text centered]
  22. \begin{document}
  23. \begin{preview}
  24. \begin{tikzpicture}[->,>=stealth,auto, very thick, scale=5]
  25. % Draw the vertices.
  26. \node[midnode] (s) {Start};
  27. \node[smallnode, right of=s, node distance=1.8cm] (a) {1};
  28. \node[smallnode, below of=a] (b) {2};
  29. \node[smallnode, right of=a, node distance=1.8cm] (c) {3};
  30. \node[smallnode, below of=c] (d) {4};
  31. \node[smallnode, right of=c, node distance=1.8cm] (e) {5};
  32. \node[midnode, below of=e] (x) {Stopp};
  33. % Connect vertices with edges
  34. \path (s) edge node {} (a);
  35. \path (a) edge node {} (c);
  36. \path (a) edge node {} (b);
  37. \path (b) edge node {} (c);
  38. \path (c) edge node {} (d);
  39. \path (c) edge node {} (e);
  40. \path (d) edge node {} (e);
  41. \path (e) edge node {} (x);
  42. \end{tikzpicture}
  43. \end{preview}
  44. \end{document}