//merge cyclic nodes
ArrayList<Node> acyclicNodes = new ArrayList<Node>();
for (List<? extends Node> conSubGraph : GraphUtils.tarjan(nodes)) {
if (conSubGraph.length() > 1) {
Node root = conSubGraph.head;
root.mergeWith(conSubGraph.tail);
for (Node n : conSubGraph) {
notifyUpdate(n, root);
}
}
acyclicNodes.add(conSubGraph.head);