MATLAB Answers

LinearFM Target Range Detection with Matched Filter Error

조회 수: 15(최근 30일)
Hi,
I have been working on learning how matched filters can be used in radar systems to improve SNR and detect targets at some particular range.
Following the example from: https://www.mathworks.com/help/phased/ug/matched-filtering.html, I can run and modify the "Matched Filtering to Improve SNR for Target Detection" without issue. However, when I try to replicate the result using a Linear FM Waveform, I cannot get the output figures to clearly show the same type of result as for the rectangular waveform.
I have tried varying bandwidths, pulse-widths, range resolution, prf, plot parameters, etc, but I am at a loss for what is going wrong at this point. Maybe there's something going on with the plot that I don't understand? When running the below, there is something that appears to be working, as there appears to be an unfilterd pulse at 1km, but that doesn't match up with the true range. The full .m file is below, and I greatly appreciate any help or suggestions that anyone can offer.
Running MATLAB Version: 9.3.0.713579 (R2017b)
clear all;
%Setting up radar/sim parameters
fc=10e9;
txloc = [0;0;0];
tgtloc = [2000;0000;10];
tgt_rcs = 1;
%tau = 1e-4;
%prf = 5e3;
c = physconst('LightSpeed');
%maxrange = c/(2*prf);
maxrange = 8000;
prf = c/(2*maxrange);
pfa = 1e-6;
SNR = npwgnthresh(pfa,1,'noncoherent');
Pg = 20; %Radar power gain
range_res = 50;
lambda = c/fc;
pulse_bw = c/(2*range_res);
tau = 20/pulse_bw;
fs = 2*pulse_bw;
%fs=1e6;
minrng = c*tau/2;
%Select waveform type - here is a Linear FMWaveform being set up
waveform = phased.LinearFMWaveform(...
'PulseWidth',tau,...
'PRF',prf,...
'SampleRate',fs,...
'OutputFormat','Pulses','NumPulses',1,'SweepBandwidth',pulse_bw);
%Antenna and transmitter parameters - isotropic
antenna = phased.IsotropicAntennaElement('FrequencyRange',[5e9 15e9]);
transmitter = phased.Transmitter('Gain',Pg,'InUseOutputPort',true);
%Target rcs and rcs model parameter
target = phased.RadarTarget('Model','Nonfluctuating',...
'MeanRCS',tgt_rcs,'OperatingFrequency',fc);
%Calculate required transmit power to meet max range parameter
Pt = radareqpow(c/fc,maxrange,SNR,...
tau,'RCS',target.MeanRCS,'Gain',transmitter.Gain);
transmitter.PeakPower = Pt;
%Setting up initial transmitter and target locations and angle
transmitterplatform = phased.Platform('InitialPosition',txloc);
targetplatform = phased.Platform('InitialPosition',tgtloc);
[tgtrng,tgtang] = rangeangle(targetplatform.InitialPosition,...
transmitterplatform.InitialPosition);
%Set up radiator and collector objects operating at 10GHz
radiator = phased.Radiator('PropagationSpeed',c,...
'OperatingFrequency',fc,'Sensor',antenna);
collector = phased.Collector('PropagationSpeed',c,...
'OperatingFrequency',fc,'Sensor',antenna);
%Create free-space path for propogation of the pulse to and from the
%target
channel = phased.FreeSpace('PropagationSpeed',c,...
'OperatingFrequency',fc,'TwoWayPropagation',false);
%Create receiver
receiver = phased.ReceiverPreamp('NoiseFigure',0,...
'EnableInputPort',true,'SeedSource','Property','Seed',2e3, 'SampleRate',fs);
%Generate the waveform
wf = waveform();
%Transmit the waveform
[wf,txstatus] = transmitter(wf);
%Radiate pulse toward target
wf = radiator(wf,tgtang);
%Propogate pulse toward target
wf = channel(wf,txloc,tgtloc,[0;0;0],[0;0;0]);
%Reflect it off the target
wf = target(wf);
%Propagate the pulse back to transmitter
wf = channel(wf,tgtloc,txloc,[0;0;0],[0;0;0]);
%Collect the echo
wf = collector(wf,tgtang);
%Receive target echo
rx_puls = receiver(wf,~txstatus);
wav = getMatchedFilter(waveform);
filter = phased.MatchedFilter('Coefficients',wav,...
'SpectrumWindow','Taylor','GainOutputPort',true);
[mf_puls,mfgain] = filter(rx_puls);
%Group delay of matched filter
Gd = length(filter.Coefficients)-1;
matchingdelay = size(wav,1)-1;
%shift the matched filter output and plot
mf_puls=[mf_puls(Gd+1:end); mf_puls(1:Gd)];
subplot(2,1,1)
t = unigrid(0,1/fs,1/prf,'[)');
rangegates = c.*t;
rangegates = rangegates/2;
%Plot graph
plot(rangegates,abs(rx_puls))
title('Received Pulse')
ylabel('Amplitude')
hold on
plot([tgtrng, tgtrng], [0 max(abs(rx_puls))],'r')
subplot(2,1,2)
plot(rangegates,abs(mf_puls))
title('With Matched Filtering')
xlabel('Meters')
ylabel('Amplitude')
hold on
plot([tgtrng, tgtrng], [0 max(abs(mf_puls))],'r')
hold off

  댓글 수: 0

로그인 to comment.

채택된 답변

Honglei Chen
Honglei Chen 31 Dec 2019
You forgot to set the sample rate in channel accordingly. Replace your channel definition as
channel = phased.FreeSpace('PropagationSpeed',c,...
'OperatingFrequency',fc,'TwoWayPropagation',false,'SampleRate',fs);
and you will have expected result.
HTH

  댓글 수: 0

로그인 to comment.

추가 답변(0개)

이 질문에 답변하려면 로그인을(를) 수행하십시오.


Translated by