calculate area, perimeter, and volume (when applicable) of polygons