algorithm to find the closest pair in an array of points in a plane; does not work yet