new, faster version for the computation of the correlograms