1
function [dt, prf, pav, ep, ru] = pulse_train(tau, pri, p_peak)
% computes duty cycle(占空因子), average transmitted power, pulse energy, and pulse repetition frequency
% Inputs:
% tau == Pulsewidth in seconds 脉冲宽度
% pri == Pulse repetition interval in seconds 脉冲重复间隔
% p_peak == Peak power in Watts 峰值功率
%
% Outputs:
% dt == Duty cycle - unitless
% prf == Pulse repetition frequency in Hz
% pa == Average power in Watts
% ep == Pulse energy in Joules 脉冲能量
% ru == Unambiguous range in Km 非模糊距离
%
c = 3e8; % speed of light
dt = tau / pri;
prf = 1. / pri;
pav = p_peak * dt;
ep = p_peak * tau;
ru = 1.e-3 * c * pri /2.0;
return
2
function [delta_R] = range_resolution(var)
% This function computes radar range resolution in meters 距离分辨率
%
% Inputs:
% var can be either
% var == Bandwidth in Hz
% var == Pulsewidth in seconds 脉冲宽度
%
% Outputs:
% delta_R == range resolution in meters
%
% Bandwidth may be equal to (1/pulse width)==> indicator = seconds
%
c = 3.e+8; % speed of light
indicator = input('Enter 1 for var == Bandwidth, OR 2 for var == Pulsewidth \n');
switch(indicator)
case 1
delta_R = c / 2.0 / var; % del_r = c/2B
case 2
delta_R = c * var / 2.0; % del_r = c*tau/2
end
return
3
function [fd, tdr] = doppler_freq (freq, ang, tv)
% This function computes Doppler frequency and time dilation factor ratio
% tau_prime / tau 时间扩张因子
%
% Inputs:
% freq == radar operating frequency in Hz
% ang == target aspect angle in degrees 姿态角
% tv == target velocity in m/sec 目标速度
%
% Outputs:
% fd == Doppler frequency in Hz
% tdr == time dilation factor; unitless 时间扩张因子
%靠近目标 后退目标
format long
indicator = input('Enter 1 for closing target, OR 2 for opening target \n');
c = 3.0e+8;
ang_rad = ang * pi /180;
lambda = c / freq;
switch(indicator)
case 1
fd = 2.0 * tv * cos(ang_rad) / lambda;
tdr = (c - tv) / (c + tv);
case 2
fd = -2.0 * c * tv * cos(and_rad) / lambda;
tdr = (c + tv) / (c -tv);
end
return
4 $(SNR)_o=(P_tG^2\lambda^2\sigma)/((4\pi)^3kT_oBFLR^4)$
function [snr] = radar_eq(pt, freq, g, sigma, b, nf, loss, range)
% This function implements Eq. (2.22) of textbook
%
% Inputs:
% pt == input peak power in Watts
% freq == radar operating frequency in Hz
% g == antenna gain in dB
% sigma == radar cross section in meter squared 目标截面积
% b == radar bandwidth in Hz
% nf == noise Figure in dB
% loss == total radar losses in dB 雷达损耗
% range == range to target (single value or vector) in Km 目标距离
%
% Outputs:
% snr == SNR in dB
%
c = 3.0e+8; % speed of light
lambda = c / freq; % wavelength
p_peak = 10*log10(pt); % convert peak power to dB
lambda_sqdb = 10*log10(lambda^2); % compute wavelength square in dB
sigmadb = 10*log10(sigma); % convert sigma to dB
four_pi_cub = 10*log10((4.0 * pi)^3); % (4pi)^3 in dB
k_db = 10*log10(1.38e-23); % Boltzman's constant in dB
to_db = 10*log10(290); % noise temp. in dB
b_db = 10*log10(b); % bandwidth in dB
range_pwr4_db = 10*log10(range.^4); % vector of target range^4 in dB
% Implement Equation (2.22)
num = p_peak + g + g + lambda_sqdb + sigmadb;
den = four_pi_cub + k_db + to_db + b_db + nf + loss + range_pwr4_db;
snr = num - den;
return
5 低PRF雷达—-相干脉冲积累数$n_p$ 波束照射目标的时间较长
$(SNR)_{n_p}=(P_tG^2\lambda^2\sigma n_p)/((4\pi)^3kT_oBFLR^4)$
6 高PRF雷达—-不可忽略接受占空因子$t_r$
$SNR=(P_tG^2\lambda^2\sigma d_t^2)/((4\pi)^3kT_oBFLR^4d_r)$
$d_r=d_t=\tau f_r$ $B=1/T_i$ $T_i$目标上的时间
$SNR=(P_t\tau f_r T_iG^2\lambda^2\sigma )/((4\pi)^3kT_oFLR^4)$
$SNR=(P_{av}T_iG^2\lambda^2\sigma )/((4\pi)^3kT_oFLR^4)$
% Generates Figure 3.6 of text
%线性调频波LFM
close all
clear all
LFM_BW = 15e6; %带宽
tau = 1e-6; %脉冲宽度
ts = 1e-9; % 1000 samples per PW
beta = LFM_BW/tau; %线性调频系数
t = 0: ts: +tau;
S = exp(j*pi*beta*(t.^2));
figure
subplot(2,1,1), plot(t*1e6,imag(S),'linewidth',1.5), grid
ylabel('Up-chirp LFM')
% The matched filter for S(t) is S*(-t)
t = -tau: ts: 0;
Smf = exp(-j*pi*beta*(t.^2));
subplot(2,1,2), plot(t*1e6,imag(Smf),'linewidth',1.5), grid
xlabel('time in microseconds')
ylabel('Down-chirp LFM')