I have problem with drawing trees with tikz.
The tree is correct, but 'rightarrows' wrongly indicate to text, which is related to each tree-level (it doesn't look good). Of course, the text should by shown also without circles.
Could anyone can help with that?
I wrote the tree, based on this example: http://www.texample.net/tikz/examples/merge-sort-recursion-tree
My code:
\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{trees}
\begin{document}
\begin{tikzpicture}[level distance=1.5cm,
level 1/.style={sibling distance=3.5cm},
level 2/.style={sibling distance=1cm}]
\tikzstyle{every node}=[circle,draw]
\node [red] {1}
child [red] {
node {3}
child { node {4} }
child [black] { node {5} }
child [black] { node {5} }
}
child {
node {3}
child { node {4} }
child { node {5} }
child { node {5} }
}
child {
node {3}
child { node {4} }
child { node {5} }
child { node {5}
child [grow=right] { node (q) {$\Rightarrow$} edge from parent [draw=none]
child [grow=right] {node (q) {$\textrm{2nd level arrow indicates here}$} edge from parent[draw=none]
child [grow=up] {node (q) {$\Rightarrow$} edge from parent[draw=none]
child [grow=right] {node (r) {$\textrm{1st level arrow indicates here}$} edge from parent[draw=none]
child [grow=up] {node (s) {$\Rightarrow$} edge from parent[draw=none]
child [grow=right] {node (r) {$\textrm{1st level arrow indicates here}$} edge from parent[draw=none]
}
}
}
}
}
}
}
};
\end{tikzpicture}
\end{document}