minimum distance of three points