1
////////////////////////
2
//WINDOWED FIR FILTERS//
3
////////////////////////
6
//Low pass filter (length 33, Kaiser window, cut-off .2)
7
[wft,wfm,fr]=wfir('lp',33,[.2 0],'kr',[5.6 0]);
9
xtitle(' ','frequency','magnitude');
10
xtitle(['Windowed FIR Low pass Filter';...
11
'Kaiser window,cut-off:0.2';...
16
//Stop band filter (length 127, Hamming window, cut-offs .2 and .3)
17
[wft,wfm,fr]=wfir('sb',127,[.2 .3],'hm',[0 0]);
19
xtitle(' ','frequency','magnitude')
20
xtitle(['Windowed FIR Low pass Filter';...
21
'Hamming window,cut-off:0.2,0.3';...
25
//Band pass filter (length 55, Chebyshev window, cut-offs .15 and .35)
26
[wft,wfm,fr]=wfir('bp',55,[.15 .35],'ch',[.001 -1]);
28
xtitle(' ','frequency','magnitude')
29
xtitle(['Windowed FIR Band pass Filter';...
30
'Chebyshev window,cut-off:0.15,0.35';...