I have question about automatic graphs drawing with latex. So I want to use
\usegdlibrary
To generate my graphs layout automatically without my interruption where to put states and nodes. Is it possible to use this library with xelatex? Or I should use Luatex. Where you offer to get luatex and what is the difference between luatex and xelatex?
\documentclass{article}
\usetikzlibrary{graphdrawing}
\usetikzlibrary{graphs}
\usegdlibrary{trees}
\begin{document}
\begin{tikzpicture}[>=stealth, every node/.style={circle, draw, minimum size=0.75cm}]
\graph [tree layout, grow=down, fresh nodes, level distance=0.5in, sibling distance=0.5in]
{
4 -> {
3 -> { 1 -> { 5, " " }, 2,2 },
3 -> { 1, 2, 2 },
3 -> { 1, 2, 2 }
}
};
\end{tikzpicture}
\end{document}
Thanks in advance.
\usegdlibrary
is not a standard command so presumably it is defined in some package somewhere, you should at least state that much and preferably fix the example so people can test any answers.! Undefined control sequence. <recently read> \usetikzlibrary
\tikz \graph [random seed=10, spring layout] { a -- {b, c, d} -- e -- f -- {g,h} -- {a,b,e}; }
, But it is throwing errors for unknown command.\usetikzlibrary
is not defined. Your initial version didn't even give any indication that you were using tikz at all.