ArrayList layer1 = halfcomb(g, levels);
ArrayList layer2 = halfcomb(g, levels);
for ( int i=0; i<(levels<<1); ++i ) {
Node n1 = (Node)layer1.get(i);
Node n2 = (Node)layer2.get(i);
g.addEdge(n1, n2);
}
return g;
}
private static ArrayList halfcomb(Graph g, int levels) {