ccat_corr that works but needs checking in a simulator