centers.interval function

Compute centers of the interval