Graphics Programs Reference
In-Depth Information
out =xcorr(replica, y);
out = out ./ n;
s = taup * c /2;
Npoints = ceil(rrec * n /s);
dist =linspace(0, rrec, Npoints);
delr = c/2/b
figure(3)
plot(dist,abs(out(n:n+Npoints-1)),'k')
xlabel ('Target relative position in meters')
ylabel ('Compressed echo')
grid
Listing 5.3. MATLAB Function Ðpower_integer_2.mÑ
function n = power_integer_2 (x)
m = 0.;
for j = 1:30
m = m + 1.;
delta = x - 2.^m;
if(delta < 0.)
n = m;
return
else
end
end
Listing 5.4. MATLAB Function Ðstretch.mÑ
function [y] = stretch(nscat,taup,f0,b,rrec,scat_range,scat_rcs,winid)
eps = 1.0e-16;
htau = taup / 2.;
c = 3.e8;
trec = 2. * rrec / c;
n = fix(2. * trec * b);
m = power_integer_2(n);
nfft = 2.^m;
x(nscat,1:n) = 0.;
y(1:n) = 0.;
if(winid == 0.)
win(1:n) = 1.;
win =win';
else
if(winid == 1.)
win = hamming(n);
else
Search WWH ::




Custom Search