doesn't this example work because?

\LinkNodes doesn't work

\documentclass[a4paper,11pt]{article}
\usepackage[utf8]{inputenc}
\usepackage[upright]{fourier}
\usepackage{tikz}

\begin{document}
\begin{NodesList}
\begin{displaymath}
\begin{aligned}
\end{aligned}
\end{displaymath}

\LinkNodes{$3\cdot 2a$}%
\LinkNodes{$3\cdot(-5b)$}%
\LinkNodes{$-7a\cdot(2a)$}%
\LinkNodes{$-7a\cdot(3b)$}%
\LinkNodes{$5\cdot(a^2)$}%
\LinkNodes{$5\cdot(3b)$}%

\end{NodesList}
\end{document}

-
Could you clarify your question- at the moment it isn't very clear... – cmhughes Apr 25 '12 at 19:57
Seems to work here (I think). Did you compile twice? – Torbjørn T. Apr 25 '12 at 20:29
What is your problem exactly ? – Alain Matthes Apr 25 '12 at 21:59
You need to remove amsmath and tikz because tkz-linknodes loads these packages. You need to have a recent xkeyval package and the last thing, tkz-linknodes loads etex.sty. But it will be interesting to know what is going wrong ! – Alain Matthes Apr 26 '12 at 6:39

You need to compile twice Update : I added \AddNode[i] before the last &

\documentclass[a4paper,11pt]{article}
\usepackage[utf8]{inputenc}
\usepackage[upright]{fourier}
\usepackage{tikz}

\begin{document}

\begin{NodesList}
\begin{displaymath}
\begin{aligned}
\end{aligned}
\end{displaymath}
\tikzset{LabelStyle/.style = {left=0.1cm,pos=.5,text=red,fill=white}}
\LinkNodes[margin=3cm]{$3\cdot 2a$}%
\LinkNodes[margin=2cm]{$3\cdot(-5b)$}%
\LinkNodes[margin=1cm]{$-7a\cdot(2a)$}%
\LinkNodes[margin=0cm]{$-7a\cdot(3b)$}%
\LinkNodes[margin=-1cm]{$5\cdot(a^2)$}%
\LinkNodes[margin=-2cm]{$5\cdot(3b)$}%

\end{NodesList}
\end{document}


Another possibility :

\begin{NodesList}
\begin{displaymath}
\begin{aligned}
\end{aligned}
\end{displaymath}
\tikzset{LabelStyle/.style = {pos=0,above,text=red}}
\LinkNodes[margin=1.5cm]{$3\cdot (2a)$}%
\LinkNodes[margin=0cm]{$3\cdot(-5b)$}%
\LinkNodes[margin=-1.5cm]{$-7a\cdot(2a)$}%
\LinkNodes[margin=-3cm]{$-7a\cdot(3b)$}%
\LinkNodes[margin=-4.5cm]{$5\cdot(a^2)$}%
\LinkNodes[margin=-6cm]{$5\cdot(3b)$}%
\end{NodesList}


This is a little package to make simple tasks, perhaps I would be more easy for you to use TikZ directly to get exactly what you want.

-
the solution of the problem is this. correct? \tikzset{LabelStyle/.style = {left=0.1cm,pos=.5,text=red,fill=white}} – user13225 Apr 26 '12 at 5:34
@user13225 But what is your problem ? You can't get the same result ? – Alain Matthes Apr 26 '12 at 5:53
@user13225 No the style is only to avoid to mixt texts and lines. The most important is to add correct margin. – Alain Matthes Apr 26 '12 at 6:35
the writings in red, they were not correctly lined up, now all ok – user13225 Apr 26 '12 at 9:26
You want align the writings in red with what ? You can modify pos but here the different lines don't have the same length. – Alain Matthes Apr 26 '12 at 9:48