• 大小: 7KB
    文件类型: .m
    金币: 1
    下载: 0 次
    发布日期: 2021-06-04
  • 语言: Matlab
  • 标签: matlab  mti  mtd  

资源简介

雷达信号处理程序,包括线性调频,匹配滤波,产生目标回波加噪声,回波积累,时域脉压,频域脉压,加窗脉压,相干积累,mti对消,mtd检测,cfar检测,欢迎下载

资源截图

代码片段和文件信息

function y=maiya(PulseNumberrangeFsTargetVelocitySNR)

C=3e8;
Tr=800e-6;%单脉冲最大可测距离0.5*Tr*C=120000m
Tp=160e-6;
fr=1/Tr;
lamda=0.03;
B=1e6;
%% 产生线性调频信号 
number=fix(Fs*Tp);%单脉冲发射信号内采样点数
SampleNumber=fix(Fs*Tr);%一个脉冲采样点数800;则每个采样间距代表120000/799m
TotalNumber=SampleNumber*PulseNumber;
for i=-fix(number/2):fix(number/2)-1
    Chirp(i+fix(number/2)+1)=exp(j*(pi*(B/Tp)*(i/(Fs))^2)); 
end  
figure
plot(real(Chirp));
title(‘线性调频信号‘)
coeff=conj(fliplr(Chirp));%匹配滤波函数h
figure
plot(real(coeff))
title(‘匹配滤波函数h‘)


W = linspace(-pipi4096);    
[h1w0] = freqz(coeff1W);  
figure
plot(w0/pi20*log10(abs(h1/max(h1)))); 
title(‘匹配滤波函数H频率响应‘)
%-------
%% 产生目标回波
TargetDistance(1:2)=range;
DelayNumber(1:2)=fix(Fs*2*TargetDistance(1:2)/C);

TargetFd(1:2)=2*TargetVelocity(1:2)/lamda; %计算目标多卜勒

SignalAll=zeros(1TotalNumber);%所有脉冲的信号先填0
for k=1:2% 依次产生各个目标1 2 
    SignalTemp=zeros(1SampleNumber);% 一个脉冲
   
    SignalTemp(DelayNumber(k)+1:DelayNumber(k)+number)=(10^(SNR(k)/10))*Chirp;  %一个脉冲的1个目标(未加多普勒速度)
    Signal=zeros(1TotalNumber);
    for i=1:PulseNumber
        Signal((i-1)*SampleNumber+1:i*SampleNumber)=SignalTemp;
    end
    FreqMove=exp(j*2*pi*TargetFd(k)*(0:TotalNumber-1)/Fs);%目标的多普勒速度*时间=目标的多普勒相移
    Signal=Signal.*FreqMove;
    SignalAll=SignalAll+Signal;
end
figure
subplot(211);plot(real(SignalAll)‘r-‘);title(‘目标信号的实部‘);grid on;zoom on;
subplot(212);plot(imag(SignalAll));title(‘目标信号的虚部‘);
grid on;zoom on;
%% 产生噪声
SystemNoise=normrnd(010^(-12/10)1TotalNumber)+j*normrnd(010^(-12/10)1TotalNumber);
%% 回波+噪声
Echo=SignalAll+SystemNoise;   % +SeaClutter+TerraClutter;
for i=1:PulseNumber   %在接收机闭锁期接收的回波为0
    Echo((i-1)*SampleNumber+1:(i-1)*SampleNumber+number)=0;
end
figure
plot(real(Echo));title(‘总回波信号的实部闭锁期为0‘);
%subplot(212);plot(imag(Echo));title(‘总回波信号的虚部闭锁期为0‘);

%% 回波积累
Echoplus=zeros(1SampleNumber);
for i=1:PulseNumber
   Echoplus1(1:SampleNumber)=Echo((i-1)*SampleNumber+1:i*SampleNumber);
   Echoplus=Echoplus+Echoplus1(1:SampleNumber);
end
Echoplus=Echoplus/PulseNumber;
figure
plot(real(Echoplus));title(‘回波脉冲积累信号的实部闭锁期为0‘);


%% 时域脉压
pc_time0=conv(Echocoeff);
%figure
%plot(abs(pc_time0));title(‘时域脉压结果的幅度有暂态点‘);
%% 频域脉压
Echo_fft=fft(EchoTotalNumber+number-1);%进行TotalNumber+number-1点FFT
coeff_fft=fft(coeffTotalNumber+number-1);
pc_fft=Echo_fft.*coeff_fft;
pc_freq0=ifft(pc_fft);
pc_freq_abs=abs(pc_freq0);
figure
plot(pc_freq_abs);title(‘(不加窗)频域脉压结果的幅度(有暂态点)‘);

%%  数据重排到距离门
pc_freq1=pc_freq0(number:TotalNumber+number-1);
for i=1:PulseNumber
   pc(i1:SampleNumber)=pc_freq1((i-1)*SampleNumber+1:i*SampleNumber);
end


figure

%subplot(211)
%plot((0:SampleNumber-1)*(120000/(SampleNumber-1)) abs(pc(5:)) );
% title(‘不加窗脉压结果‘);xlabel(‘距离‘)ylabel(‘脉压输出‘);
 
plot((0:SampleNumber-1)*(120000/(SampleNumber-1)) 20*log10(abs(pc(1:))) );
xlabel(‘距离‘)ylabel(‘脉压输出/db‘);
axis([-infinf -1050]);
title(‘不加窗脉压结果‘)
%% 加窗处理 
win=chebw

评论

共有 条评论