Cake: calculationg of polygon's center of mass