Rename correlation functions to be more descriptive and add tests