bipartit-algorithm.tex 602 B

12345678910111213141516171819202122
  1. \documentclass[varwidth=true, border=2pt]{standalone}
  2. \usepackage{tikz}
  3. \usetikzlibrary{arrows,positioning}
  4. \tikzset{
  5. %Define standard arrow tip
  6. >=stealth',
  7. % Define arrow style
  8. pil/.style={->,thick}
  9. }
  10. \begin{document}
  11. \begin{tikzpicture}
  12. \node (a)[vertex] at (0,8) {$a$};
  13. \node (b)[vertex] at (0,4) {$b$};
  14. \node (c)[vertex] at (0,0) {$c$};
  15. \node (d)[vertex] at (4,4) {$d$};
  16. \foreach \from/\to/\pos in {a/b/20,a/b/-20,a/d/0,b/c/20,b/c/-20,b/d/0,c/d/0}
  17. \draw[line width=2pt] (\from) to [bend left=\pos] (\to);
  18. \end{tikzpicture}
  19. \end{document}