Skip to main content
Made title clearer
Link
Baddioes
  • 2.5k
  • 1
  • 2
  • 14

Why does the unbiased sample autocorrelation sequence sometimes not peak at lag 0?

Source Link
Baddioes
  • 2.5k
  • 1
  • 2
  • 14

Why does the unbiased sample autocorrelation sequence not peak at lag 0?

When using the "unbiased" sample autocorrelation sequence estimate, i.e., \begin{equation} \bar{r}(k) = \begin{cases} \frac{1}{N-k}\sum_{n=0}^{N-k-1}x[n]x^{*}[n-k]& k \geq 0 \\ \bar{r}^{*}(-k) & k<0\end{cases} \end{equation} I sometimes do not get $\bar{r}(0) \geq \left\lvert \bar{r}(k) \right\rvert$. Why is this? Is there a bug in my code or in the Matlab/Python implementation of the autocorrelation function?