centroid module and other stuff