MATLAB Answers

JOB
0

Why autocorr(x) and xcorr(x,x) give different results?

Asked by JOB
on 13 Sep 2019 at 10:46
Latest activity Edited by JOB
on 14 Sep 2019 at 1:26
I was trying to find the autocorrelation of a matrix 'x' using autocorr, however cross correlation function (xcorr) is giving me the expected results. The code used is given below, what could be the reason? is there a method by which they can be made equal?
x=randi([0 1],1,64); %Random values 0 & 1
aut_x=autocorr(x); % autocorrelation function of x
crs_x=xcorr(x,x); % cross correlation function of x with itself

  0 Comments

Sign in to comment.

Products


Release

R2014b

1 Answer

Answer by KALYAN ACHARJYA on 13 Sep 2019 at 12:59

Please read here (Difference between autocorr & xcorr)

  0 Comments

Sign in to comment.