📄 cyclic_correlation_coefficient.m
字号:
function rho=cyclic_correlation_coefficient(S,tol)%% CYCLIC_CORRELATION_COEFFICIENT% % calculates the cyclic correlation coefficient for signal% from its spectral correlation density% % USAGE% rho=cyclic_correlation_coefficient(S,tol)%% Optional parameter tol can be used to set all% rho(x,y) to zero if S(x,y) is less than tol% of max(S)% File: cyclic_correlation_coefficient.m% Last Revised: 25/11/97% Created: 25/11/97% Author: Andrew C. McCormick% (C) University of Strathclyde[rows,cols]=size(S);rho=zeros(rows,cols);S=abs(S);mxs=max(max(S));scale_factor=2*cols/rows;for f=1:rows for a=1:cols fplus=f+floor(a/scale_factor); fminus=f-floor(a/scale_factor); if fplus>rows fplus=fplus-rows; end if fminus<1 fminus=fminus+rows; end rho(f,a)=S(f,a)/sqrt(S(fplus,1)*S(fminus,1)); endendif nargin==2 [i,j]=find(S<tol*mxs/100); for k=1:length(i) rho(i(k),j(k))=0; endend
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -