dist_to_interval function

Computes the (absolute, pairwise) distance between the vector elements and an interval