Applied trick for avoiding var() in cross-correlation function too