当前位置:文档之家› 数字信号处理课程设计

数字信号处理课程设计

山东工商学院数字信号处理课程设计题目:有限冲击响应数字滤波器设计姓名:李迎学号:联系方式:指导老师:目录目录 --------------------------------------------- 01 摘要 --------------------------------------------- 02 关键词 --------------------------------------------- 04 引言 --------------------------------------------- 05 正文1.常见窗体函数简介 -------------------------------- 06 1.1.海明窗函数 ---------------------------------- 06 1.2.布莱克曼窗函数 ------------------------------ 071.3.凯塞窗 --------------------------------- 082.数字滤波器设计的基本步骤 ------------------------- 113.窗函数法设计FIR滤波器的MATLAB仿真 -------------- 114.具体FIR低通滤波器的设计4.1.用海明窗设计 -------------------------------- 13 4.2.用布拉克曼窗设计 ---------------------------- 144.3.用凯塞窗设计 -------------------------------- 155.结论 --------------------------------------------- 166.参考文献 ----------------------------------------- 16摘要现代图像、语音、数据通信对线性相位的要求是普遍的。

正是因为如此,使得具有线性相位的FIR数字滤波器得到大力发展和广泛应用。

在实际进行数字信号处理时,往往需要把信号的观察时间限制在一定的时间间隔内,只需要选择一段时间信号对其进行分析。

这样,取用有限个数据,即将信号数据截断的过程,就等于将信号进行加窗函数操作。

而这样操作以后,常常会发生频谱分量从其正常频率扩展开来的现象,即所谓的“频率泄露”。

当其进行离散傅立叶变换时,时域中的截断是必需的,因此泄漏效应也是离散傅立叶变换所固有的,必须进行抑制。

而要对频谱泄漏进行抑制,可以通过窗函数加权抑制DFT的等效滤波器的振幅特性的副瓣,或用窗函数加权使有限长度的输入信号周期延拓后在边界上尽量减少不连续程度的方法实现。

而在后面的FIR滤波器的设计中,为获得有限长单位取样响应,需要用窗函数截断无限长单位取样响应序列。

另外,在功率谱估计中也要遇到窗函数加权问题。

由此可见,窗函数加权技术在数字信号处理中的重要地位。

AbstrackThe modern image, sound, and data communications to linear phase requirements are common. Because of this, that has linear phase FIR digital filters to get a development and the widespread application.In the practical digital signal processing, often need to signal observation time limit in a certain time intervals, only need to choose a time signal on the analysis. So, take with limited data, is the process of truncated signal data, as will signal is added a window function operation. And so after operation, often happen spectrum component from its normal frequency spread phenomenon, the so-called "frequency leak". When the discrete Fourier transform, the time domain truncation is necessary, so leakage effect is also the discrete Fourier transform the inherent, must be restrained. And to the frequency spectrum leakage control, can through the window function weighted inhibit the DFT equivalent of amplitude characteristics of filter vice disc, or with window function to the length of the weighted limited input signal period after the extension in the border to reduce as far as possible the degree of discontinuous method. And in the back of the FIR filters design, to acquire limited long unit sampling response, need to use the window function truncation infinite long unit sampling response sequence. In addition, in the power spectrum estimation to meet a window function and weighted problem. This shows, window function weighted technology in the digital signal processing to the important position.关键词:中文:有限冲击响应数字滤波器FIR低通滤波器窗函数设计法English:Limited shock response digital filter Window function design methodFIR low-pass filter引言MATLAB是矩阵实验室(Matrix Laboratory)的简称,是美国MathWorks公司出品的商业数学软件,用于算法开发、数据可视化、数据分析以及数值计算的高级技术计算语言和交互式环境,主要包括MATLAB和Simulink两大部分。

FIR(Finite Impulse Response)滤波器:有限长单位冲激响应滤波器,是数字信号处理系统中最基本的元件,它可以在保证任意幅频特性的同时具有严格的线性相频特性,同时其单位抽样响应是有限长的,因而滤波器是稳定的系统。

因此,FIR滤波器在通信、图像处理、模式识别等领域都有着广泛的应用。

1.常见窗函数简介1.1.海明窗函数海明窗函数的时域形式可以表示为⎪⎭⎫ ⎝⎛--=1π2cos 46.054.0)(N k k w N k ,,2,1 =它的频域特性为⎥⎦⎤⎢⎣⎡⎪⎭⎫ ⎝⎛-++⎪⎭⎫ ⎝⎛--+=1π21π223.0)(54.0)(N W N W W W R R R ωωωω 其中,)(ωRW 为矩形窗函数的幅度频率特性函数。

海明窗函数的最大旁瓣值比主瓣值低41dB ,但它和汉宁窗函数的主瓣宽度是一样大的。

Hamming 函数:生成海明窗调用方式(1) w = hamming(n):输入参数n 是窗函数的长度;输出参数w 是由窗函数的值组成的n 阶向量。

(2) w = hamming(n,sflag):参数sflag 用来控制窗函数首尾的两个元素值;其取值为symmetric 或periodic ;默认值为symmetric 。

应用说明例:生成一个长度为50的海明窗,并观察其频率特性(使用归一化的幅值和频率),结果如图5-5所示。

程序n=51; window=hamming(n); [h,w]=freqz(window,1); subplot(1,2,1)stem(window); subplot(1,2,2);plot(w/pi,20*log(abs(h)/abs(h(1))));1.2.布莱克曼窗函数布莱克曼窗函数的时域形式可以表示为⎪⎭⎫ ⎝⎛--+⎪⎭⎫ ⎝⎛---=11π4cos 08.011π2cos 5.042.0)(N k N k k w N k ,,2,1 =它的频域特性为=)(ωW 42.0()ωR W +25.0+⎥⎦⎤⎢⎣⎡⎪⎭⎫ ⎝⎛-++⎪⎭⎫ ⎝⎛--1212N W N W R R πωπω ⎥⎦⎤⎢⎣⎡⎪⎭⎫ ⎝⎛-++⎪⎭⎫ ⎝⎛--1π41π404.0N W N W R R ωω 其中,)(ωRW 为矩形窗函数的幅度频率特性函数。

布莱克曼窗函数的最大旁瓣值比主瓣值低57dB ,但是主瓣宽度是矩形窗函数的主瓣宽度的3倍,为12π/N 。

Blackman 函数:生成海明窗调用方式(1) w = blackman (n):输入参数n 是窗函数的长度;输出参数w 是由窗函数的值组成的n 阶向量。

(2) w = blackman (n,sflag):参数sflag 用来控制窗函数首尾的两个元素值;其取值为symmetric 或periodic ;默认值为symmetric 。

应用说明例:生成一个长度为50的布莱克曼窗,并观察其频率特性(使用归一化的幅值和频率),结果如图5-6所示。

程序n=51; window=blackman(n); [h,w]=freqz(window,1); subplot(1,2,1) stem(window); subplot(1,2,2); plot(w/pi,20*log(abs(h)/abs(h(1))));1.3 .凯 塞 窗上面所讨论的几种窗函数,在获得旁瓣抑制的同时却增加了主瓣的宽度。

相关主题