?? correstimate.m
字號:
function r=correstimate(x,y)
%CORRESTIMATE(x,y) estimate the inter correlation of signal x and y;
%Use the following function estimation method:
% 1 N-m-1
% R(m)=- {<{ x(n)y'(n+m)
% N n=0
if(length(x)~=length(y))
error('The input vector x and y must have the same length');
end
N=length(x);
r=zeros(1,N);
temp=0;
for m=0:N-1
for n=0:(N-m-1)
temp=temp+x(n+1)*conj(y(n+m+1));
end
r(m+1)=temp/N;
temp=0;
end
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -