implemented rectangular torus chain
implemented rectangular torus chain
reimplemented path sort
fixed waists connection bug
implemented dangerous edge splitting