tree structure generator completed