First, we design a Linear Frequency Modulated (LFM) chirp for the desired time-bandwidth product amount (TW), oversampling amount p, and sampling frequency (fs) . The MATLAB program
"dchirp2" will build up a single pulse while "ctbuild4" will design a burst waveform consisting of L chirps, repeated over a period M.
[s,h,y,T,W,Ts] = dchirp2(TW,p,sampfreq) with outputs:
- s = single LFM chirp set to specified input paramters
- h = match filter impulse response
- y = (used for testing of original code) passing s through match filter
- T = time duration of LFM chirp (units: sec)
- W= swept bandwidth of LFM chirp (units: Hz)
- Ts= sampling period (1/fs)
[s,ssent,h,y,T,W,Ts] = ctbuild4(TW,p,sampfreq,M,L) with outputs:
- s = single chirp defined by TW,p
- ssent = noise-free burst waveform of L lfm chirps of the same TW, p
- h = match filter impulse response
- y = (used for testing of original code) passing s through match filter
- T = time duration of LFM chirp (units: sec)
- W= swept bandwidth of LFM chirp (units: Hz)
- Ts= sampling period (1/fs)
In order to simulate proper radar returns, we first simulate the noise of a channel. Thus, we add complex white Gaussian nosie, using the "crandn" command in MATLAB, to our complex train of chirps. We perform this opertion in our main MATLAB function called "burst4." Next, we then apply a time delay to our signal. The program accomplishes that by shifting a vector x of length N to the right by amount TD.
For the project we worked only with an assumed value of SNR = -10 dB (i.e. the std. deviation is the square root of 10 multiplied against the chirp's average amplitude). We did a visual comparison of these two values to make sure our value of n was correct. See MATLAB function "
burst4" for detailed commentary.
The TD value inputted by the user is in terms of how many elements the user wants to physically shift the transmitted wave form by and do not correspond to actual units of time.
The Maximum Range of our radar system is determiend by two things. First, how large the resting time is between consecutive falling and rising edges of chirps. Secondly, how long our signal is. The reason why these are important is that since this model for range processing is in discrete time, we can not simulate an infinite range for our targets. That would correspond to having to time delay our transmitted signal by a extremely large amount. If shifted by an amount greater than the signal's length, the simulated return would just be a flat line of value zero for the length of the signal. Basically, the signal can be time delayed only up until the first LFM chirp's falling edge. This location corresponds to the last value of the recieved signal to ensure getting a big enough spike in the match filter's output to use in calculating range. Thus, since we define the value for time period (Ts) of our chirp pulse train and the number of pulses, we can define the max range by finding the maximum amount we can shift our signal. Then by plugging in this max Td value into the discrete-time range equation below, the max range value is found.
MaxTD=ML−(M−N)
MaxTD
M
L
M
N
(1)
Basically M multiplied by L is the entire length of the signal and (M-N) is the last value of the first chirp right on the falling edge.
We characterize the match filter impulse response as being h(t)=s*(-t)=exp(-j*W/T*t^2) with t on the range of [-T/2,T/2]. See "Background" module under the section "Match Filter" for more details.
The approach taken now to analyze the corresponding range of the target for the received signal is the following:
- Process recieved signal through a match filter with impulse response described above and in "Backgrounds"
- Process originally transmitted signal through same match filter
- Pick out the peaks from outputs via setting a threshold value as a starting point
- Compare the location of the first peak from each output
- The difference in locations of the 1st peaks is the time delay (Td) value
- Plug Td into discrete time range equation to get approximate range
The reason why we only need to analyze the first peak is because we are assuming that the object is not moving. Also, for future work, if the range and velocity systems were to be integrated (i.e. can take into account a moving target ) an initial range would be calculated from the first returned pulse. Velocity would be calculated as well from the rest of the recieved signal. Then, a relationship could be found for the object's range as a function of time. More specifically R(t) = Ro - vt where assuming the target is approaching the radar and since the velocity was calculated the simple distance = rate x time relationship can be used ( where x = multiplication). Note, this is all assuming a constant velocity and that the target is still not at an angle to the radar's transmission path.
The matlab function "
rangecalc" does the above stated list and an exampe of how it is called follows. It is interesting to note that the "rangecalc" function calls a subfunction to actually pick out the peaks in the outputs of the matched filters. The subfunction is called "
pkpicker"" and was provided by the "Computer-Based Exerciese for Signal Processing Using MATLAB" book by Burrus [ et al.]. Given the number of peaks to look for, a threshold value to use, and a vector, the function will go through a vector and will output the locations of the highest peaks above the threshold as well as their values.
[timedelay,range,rsigmatchlocs] = rangecalc(rsig,tsig,h,number,thresh,Ts) with inputs:
with outputs:
- timedelay = difference in location of 1st peaks from outputs of both match filters
- range = corresponding real world target range (units: meters)
- rsigmatchlocs = vector containing locations of peaks from output of match filter of recieved signal
[peaks,locs] = pkpicker( x, thresh, number, sortem ) with inputs:
with outputs:
- peaks : peak values
- locs : location of peaks (index within a column)
The function that we designed to combine all of the previously mentioned functions is called "burst4".
[noisytestecho,noisyshifttestecho,rsigmatchlocs,timedelay,range,h] = burst4(L,TW,p,M,n,sampfreq,TD) with inputs:
with outputs:
- noisytestecho: noisy burst waveform of L lfm chirps of the same TW,p
- noisyshifttestecho: shifted (i.e. time-delayed) of noisy burst waveform
- rsigmatchlocs: vector containing locations of peaks from output of match filter of recieved signal
- timedelay: difference in location of 1st peaks from outputs of both match filters
- range: real world target range (units: meters)
- h: impulse response for match filter
Using the "radar" function provided by "Computer-Based Exerciese for Signal Processing Using MATLAB" by Burrus [ et al.] (see page 328 of book for full explanation of usage) we were able to compare our simulated returned signal.
"assafdf"