www.pudn.com > stepsyn2.rar > stepsyn2.m, change:2011-11-22,size:2904b


%验证步进频率压缩后拼接与拼接后压缩,最后再逆傅里叶效果一样 
close all;clear;clc; 
%——————————————参数设置 
C=3e8; 
Tp=2e-6; 
Msub=4; 
Tpc=Msub*Tp; 
Bsub=2e8; 
B=Msub*Bsub; 
K=Bsub/Tp; 
fs=2*Bsub; 
Fs=2*B; 
Fc=1e10; 
Nc=ceil(fs*(Tp+Tp*0.2)); 
Nd=Msub*Nc; 
Ns=Msub*Nd; 
t=linspace(-Tp/2,Tp*0.2+Tp/2,Nc);          %子带时间轴 
T=linspace(-Tpc/2,Tpc*0.2+Tpc/2,Ns);        %合成信号时间轴 
trn=[0,5,10]/2/B; 
S_echo=zeros(Msub,Nc); 
Sf_echo=zeros(Msub,Nd); 
St=zeros(1,Ns); 
%——————————————目标回波与子带匹配函数 
Gsub=exp(j*pi*K*t.^2).*(abs(t)<=Tp/2);              
Gf_sub=fftshift(fft(Gsub,Nd)); 
Gf_sub= Gf_sub./max(Gf_sub); 
Ntarget=1; 
for k=1:Msub 
    fc=Fc+(k-1/2-Msub/2)*Bsub; 
    for i=1:Ntarget 
        S_echo(k,:)=S_echo(k,:)+exp(j*2*pi*fc*(t-trn(i))).*exp(j*pi*K*(t-trn(i)).^2).*(abs(t-trn(i))<=Tp/2); 
    end 
    S_echo(k,:)=S_echo(k,:).*exp(-j*2*pi*fc*t); 
    Sf_echo(k,:)=fftshift(fft(S_echo(k,:),Nd)); 
    Sf_echo(k,:)=Sf_echo(k,:)./max(Sf_echo(k,:)); 
        SF_echo(k,:)=Sf_echo(k,:).*conj(Gf_sub); 
%     SF_echo(k,:)=fftshift(ifft(Sf_echo(k,:).*conj(Gf_sub))); 
%     SF_echo(k,:)=20*log10(abs(SF_echo(k,:))./max(abs(SF_echo(k,:)))); 
    figure 
    plot(abs(SF_echo(k,:))) 
end 
% figure 
% plot(abs(Sf_echo(1,:))) 
figure 
plot(abs(Gf_sub)) 
%——————————————理想回波与理想参考函数 
%理想回波信号 
for i=1:Ntarget 
    St=St+exp(j*2*pi*Fc*(T-trn(i))).*exp(j*pi*K*(T-trn(i)).^2).*(abs(T-trn(i))<=Tpc/2);  
end 
St=St.*exp(-j*2*pi*Fc*T); 
Sf=fftshift(fft(St)); 
Sf=Sf./max(Sf); 
plot(abs(Sf)) 
 
SSf=Sf; 
Gt=exp(j*pi*K*T.^2).*(abs(T)<=Tpc/2);  
Gf=fftshift(fft(Gt)); 
Gf=Gf./max(Gf); 
Sf=Sf.*conj(Gf); 
St=fftshift(ifft(Sf)); 
St=20*log10(abs(St)./max(abs(St))); 
%——————————————子带信号频移与合成脉冲压缩 
Nsub=Bsub/fs*Nd; 
Nstop=Nd/2-Nsub/2; 
Nstart=(Ns-(Msub-1)*Nsub-Nd)/2; 
Sf_com=zeros(1,Ns); 
St_com=zeros(1,Ns); 
Gf_com=zeros(1,Ns); 
for k=1:Msub 
    %     Sf_com(Nstart+(k-1)*Nsub+1:Nstart+(k-1)*Nsub+Nd)=Sf_com(Nstart+(k-1)*Nsub+1:Nstart+(k-1)*Nsub+Nd)+Sf_echo(k,:); 
      St_com(Nstart+(k-1)*Nsub+1:Nstart+(k-1)*Nsub+Nd)=St_com(Nstart+(k-1)*Nsub+1:Nstart+(k-1)*Nsub+Nd)+SF_echo(k,:); 
      Gf_com(Nstart+(k-1)*Nsub+1:Nstart+(k-1)*Nsub+Nd)=Gf_com(Nstart+(k-1)*Nsub+1:Nstart+(k-1)*Nsub+Nd)+Gf_sub; 
%     figure 
%     plot(abs(Gf_com)) 
%     title('合成匹配信号幅度谱') 
%     grid 
end 
figure 
plot(abs(St_com)) 
% St_com=fftshift(ifft(Sf_com.*conj(Gf_com))); 
St_com=fftshift(ifft(St_com)); 
St_com=20*log10(abs(St_com)./max(abs(St_com))); 
%——————————————输出图像 
figure 
plot(1:Ns,St,'g',1:Ns,St_com,'r:'); 
legend('理想脉压','合成脉压'); 
grid 
% figure 
% plot(1:Ns,abs(Sf),'g',1:Ns,abs(Sf_com),'r:'); 
% legend('理想回波幅度谱','合成回波幅度谱'); 
% grid 
 
 
% figure 
% plot(1:Ns,angle(Gf_com),'g',1:Ns,angle(Sf_com),'r:'); 
% legend('理想回波幅度谱','合成回波幅度谱'); 
% grid