updated calculation of subdivisions to make it more accurate