Normalized Cross correlation, Normalized autocorrelation
8 ビュー (過去 30 日間)
古いコメントを表示
Hey everybody, I have these Golay Sequences: GolaySeq=[+1 +1 -1 -1 -1 -1 -1 -1 -1 +1 -1 +1 +1 -1 -1 +1]; Vec=[ repmat(GolaySeq,1,16) -GolaySec]; SNR=20; Vec2 = awgn(Vec,SNR); Now I want to have Normalized Cross correlation and Normalized autocorrelation of it like attached file. Could anybody help me out of this? Tnx a lot.
0 件のコメント
回答 (2 件)
zainab alsaffar
2013 年 10 月 26 日
corr2(A,B) u can use it for cross and auto normalized correlation
2 件のコメント
Greg Heath
2013 年 10 月 27 日
What 128 ?
Isn't corr2 already scaled?
corr2(zscore(A,1),zscore(B,1))= corr2(A,B)
Wayne King
2013 年 10 月 27 日
If you have the Signal Processing Toolbox, use xcorr(). I'll assume your -GolaySec above is a typo and should read -Golayseq
GolaySeq=[+1 +1 -1 -1 -1 -1 -1 -1 -1 +1 -1 +1 +1 -1 -1 +1];
Vec=[ repmat(GolaySeq,1,16) -GolaySeq];
SNR=20;
Vec2 = awgn(Vec,SNR);
% normalized autocorrelation
[ac,lags] = xcorr(Vec2,'coef');
% cross correlation
[xc,lags] = xcorr(Vec,Vec2,'coef');
Choose the appropriate number of lags for your purposes.
0 件のコメント
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!