Some code cleanup; Introduce concept of shape as collection of polar coordinates;