Create a plot of a signal
古いコメントを表示
Hey guys thanks in advance,
Basically I have this code, that for two signals( reference and surveillance) with 30 million samples each one, correlates them in doppler and delay.
But this correlation is very heavy, so I want to correlate a thousand samples individually , spaced between 3000 samples.
This means first I want to correlate reference_signal(1:1000) and surveillance_signal(1:1000), and save the plot. Next iteration, reference_signal(4000:5000) and surveillance_signal(4000:5000), and save the plot, and so on till the end of the samples.
Is there a way of doing this in MATLAB with a good matlab way?
nRef = numel(Reference_signal)/Fs;
nSurv = numel(Surveillance_signal)/Fs;
pulse_size = 500000;
for k = 1:nRef
Reference_signal_samples =Reference_signal((k-1)*pulse_size+(1:pulse_size));
for kk =1:nSurv
Surveillance_signal_samples=Surveillance_signal((kk-1)*pulse_size+(1:pulse_size));
[afmag3,delay3,doppler3] = ambgfun(Reference_signal_samples,Surveillance_signal_samples,Fs,[250000 250000]);
afmag3(afmag3>1 )= 1;
end
end
figure;
subplot(3,2,3)
surf(delay3,doppler3,afmag3,'LineStyle','-.');
shading interp;
axis([-0.5e-5 0.5e-5 -10000 10000]);
grid on;
view([140,35]);
colorbar;
xlabel('Doppler (Hz)');
ylabel('Ambiguity Function Magnitude');
title('Ambiguity Function Sref');
採用された回答
その他の回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で MATLAB についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!