0% found this document useful (0 votes)
35 views

N 44 FC 1/4 (3.4+ (0.6/2) ) WN Hamming (N) HN Fir1 (N-1, FC, WN)

The document describes the design and implementation of a FIR filter with the following specifications: 1. Passband edge frequency of 3.4 kHz, stopband attenuation of 50dB, and transition width of 0.6 kHz with a sampling frequency of 8 kHz. A Hamming window is used to design the filter with 44 coefficients. 2. The coefficients are calculated using MATLAB's fir1 function and the symmetric coefficients are stored to reduce memory usage. 3. A flowchart for the direct software implementation of the filter is described in a referenced textbook.

Uploaded by

Ubaid Imtiaz
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
35 views

N 44 FC 1/4 (3.4+ (0.6/2) ) WN Hamming (N) HN Fir1 (N-1, FC, WN)

The document describes the design and implementation of a FIR filter with the following specifications: 1. Passband edge frequency of 3.4 kHz, stopband attenuation of 50dB, and transition width of 0.6 kHz with a sampling frequency of 8 kHz. A Hamming window is used to design the filter with 44 coefficients. 2. The coefficients are calculated using MATLAB's fir1 function and the symmetric coefficients are stored to reduce memory usage. 3. A flowchart for the direct software implementation of the filter is described in a referenced textbook.

Uploaded by

Ubaid Imtiaz
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

Question 7.

4
1. Filter specifications
- Stopband attenuation - 50dB
- Passband edge frequency – 3.4 kHz
- Transition width – 0.6 kHz
- Sampling frequency – 8 kHz

Hamming window method is used since it provides 53dB Stopband attenuation.

0.6
Normalized transition width ¿ ∆ f = =0.075
8
3.3
Number of coefficients ¿ N= =44
0.075
Coefficients are calculated using following Matlab program.
N=44;
fc=1/4*(3.4+(0.6/2));
wn=hamming(N);
hn=fir1(N-1,fc,wn);

Calculated Coefficients

h[0] -0.0004 h[43]


h[1] 0.0002 h[42]
h[2] 0.0002 h[41]
h[3] -0.0007 h[40]
h[4] 0.0016 h[39]
h[5] -0.0028 h[38]
h[6] 0.0044 h[37]
h[7] -0.0063 h[36]
h[8] 0.0085 h[35]
h[9] -0.0106 h[34]
h[10] 0.0123 h[33]
h[11] -0.0133 h[32]
h[12] 0.0129 h[31]
h[13] -0.0108 h[30]
h[14] 0.0062 h[29]
h[15] 0.0016 h[28]
h[16] -0.0135 h[27]
h[17] 0.0313 h[26]
h[18] -0.0581 h[25]
h[19] 0.1027 h[24]
h[20] -0.1970 h[23]
h[21] 0.6318 h[22]
2. Since the response of filter is symmetric therefore symmetric coefficients can be stored in one
memory location. The order in which coefficients can be stored is shown in the above table.
3. Flowchart for direct software implementation of filter is given in figure 7.2 in chapter 7 of
Digital Signal Processing: A Practical Approach 2nd Edition by Emmanuel Ifeachor, Barrie Jervis.

Question 7.5
1. The frequency response of the given symmetric FIR filter is
(N −1)/ 2
− jω(N −1)/2 N
H ( ω ) =e ∑ a( n)cos ⁡(ωn) , where a ( n )=2 h( −n)
n=0 2
Since its phase response satisfies the condition θ ( ω )=−αω , where α =(N−1)/ 2. Therefore it
has both constant group and contant phase delay.
2. Filter specifications
- Passband - 12-16 kHz
- Transition width – 3kHz
- Sampling frequency – 96 kHz
- Passband ripple - 0.01dB
- Stopband attenuation - 80dB

a) The number of filter coefficient, N, is calculated using following Matlab program.


deltap=0.00115;
deltas=0.0001;
Cinf=log10(deltas)*(0.01202*(log10(deltap))^2+0.09664*log10(deltap)-
0.51325)+ ...
((0.00203*(log10(deltap))^2)-0.5705*log10(deltap)-0.44314);
deltaF=0.03125;
g=-14.6*log10(deltap/deltas)-16.9;
N=Cinf/deltaF + g*deltaF + 1;

The calculated value is 128.7911 which is approximated to 130.

b) The ratio of δP to δs is 11.5. Therefore suitable weights for filter band can be [11.5 1 11.5] or
[23 2 23].
c) The vector of normalized bandedge frequencies is [0 0.09375 0.125 0.1667 0.1979 0.5]
The weighting function specifies the relative importance of each band. It allows a trade-off between
the passband ripple and stopband attenuation. The grid frequencies are the frequency points at
which the frequency response is checked to see whether the optimality condition has been satisfied.
The suitable grid density for above problem can be 32.

You might also like