$30
In communication systems, filters are widely used to demodulate the received signals in the receivers. Filters can be examined in four categories which are low pass, high pass, band pass and band stop filters. These filters pass or reject the signals according to the cut-off frequencies in frequency domain. An ideal filter has a sharp frequency response which does not pass the frequency components of the signals beyond the desired cut-off frequency. For example, ideal low pass filters only pass the frequency components between 0 Hz and the determined cut-off frequency or ideal band pass filters only pass the signals between the desired two frequencies. Nonideal filters do not have a sharp frequency response and have a transition band around the cut-off frequency. This transition band can cause to have undesired frequency components. The filtering operation can be accomplished by multiplication in frequency domain.
2.1 Construction of the Signals
a. Construct x2(t) = cos(120πt)+cos(500πt) where the sampling frequency fs = 1000 Hz and its duration is 2 s. Obtain the Fourier transform of x2(t) where the number of DFT points (N) is the length of the signal.
b. The magnitude of the frequency spectrum of x(t), i.e., |X(f)|, is given in Fig. 1. Construct |X(f)| which is a triangular signal between −50 Hz and 50 Hz. Hint: You can use find(.) function in Matlab to find and change the nonzero components of the signal.
Figure 1: The plot of |X(f)|.
Signals & Systems Review
c. Generate the signal |Y1(f)| by using the relation |Y1(f)| = |X(f)| + |X2(f)|.
d. Plot |X(f)|, |X2(f)| and |Y1(f)| in the same figure (by using subplot(3,1,.) command) where x-axis shows the frequency in Hz.
2.2 Filtering
a. As shown in Fig. 2, filter |Y1(f)| with an ideal low pass filter, which has the frequency response H1(f), to obtain the nonzero frequency components of |X(f)|.
Figure 2: Block diagram of the filtering operation for H1(f).
b. Plot |H1(f)| and the filtered signal |Y2(f)| in the same figure (by using subplot(2,1,.) command) where x-axis shows the frequency in Hz.
c. As shown in Fig. 3, filter |Y1(f)| with an ideal band pass filter, which has the frequency response H2(f), to obtain the frequency components of |X2(f)| stemming from cos(500πt). Hint: Do not forget to filter the negative frequency components!
Figure 3: Block diagram of the filtering operation for H2(f).
d. Plot |H2(f)| and the filtered signal |Y3(f)| in the same figure (by using subplot(2,1,.) command) where x-axis shows the frequency in Hz.
e. Using butter(.) function, design a nonideal band pass filter, which has the frequency response Hbpf(f) to obtain the frequency components of |X2(f)| stemming from cos(500πt). Filter x2(t) with Hbpf(f) as shown in Fig. 4.
x2(t)
Figure 4: Block diagram of the filtering operation for Hbpf(f).
f. Plot |Hbpf(f)| and the filtered signal |Ybpf(f)| in the same figure (by using subplot(2,1,.) command) where x-axis shows the frequency in Hz. You can use freqz(.) function which does not show the negative part of the frequency spectrum to plot only the filter response.