started writing autocorrelation