Calculates normalized sum of distance of a ND Segment