update the functions for measure the difference of the shape and size for polygons