correlation function codes in C and Python (being developed)