Added max-space clustering and union find.