Internal use. For now it only supports euclidean distance. (May import parallelDist in the future).
distmat(my_mat)
my_mat
a matrix representing a grid of points.