⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 second_order_hp.m

📁 声音过滤器工具大集合.
💻 M
字号:
function [b, a] = second_order_HP(fc, fs, d)
%SECOND_ORDER_HP - Second-Order IIR Butterworth High-Pass Filter Design Routine
%
%     usage:  [b, a] = second_order_HP(fc, fs, d)
%     
%           b = Three column vector, numerator coefficients
%           a = Three column vector, denominator coefficients
%          fc = Scalar, cutoff frequency (in Hz)
%          fs = Scalar, sampling frequency (in Hz)
%           d = Scalar, damping factor (default: square root of 2)

%  NOTICE: MATLAB's filter.m function implements the standard 
%          difference equation with subtracting the weighted
%          previous outputs:
%
%          a(1)*y(n) = b(1)*x(n) + b(2)*x(n-1) + b(3)*x(n-2)
%                                - a(2)*y(n-1) - a(3)*y(n-2) 
%
%          Therefore this routine negates the calculated a(2) and 
%          a(3) coefficients in order to accomodate this. However,
%          if the difference equation of your implementation adds 
%          the weighted previous outputs rather than subtracting 
%          them then you should use conv_coeff.m function to
%          obtain the original coefficients.
%   References:
%      [1]  John Lane, Jayant Datta, Brent Karley, Jay Norwood, "DSP Filters", 
%           PROMPT Publications(an imprint of Sams Technical Publishing), 
%           Indianapolis, IN, 2001, page 74.
%           Book's website: www.dspaudiocookbook.com

%  Copyright (c) 2005 Bo餫

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -