Designing a lowpass filter with lesser filter coefficients with the required parameters

11 ビュー (過去 30 日間)
Gova ReDDy
Gova ReDDy 2014 年 1 月 21 日
コメント済み: nam bui 2021 年 2 月 12 日
Hi,
I am currently using a lowpass fitler as below
d = fdesign.lowpass('Fp,Fst,Ap,Ast',3,8,1,20,500);
Hd1 = design(d);
length=length(Hd1.Numerator);
data1 = filtfilt(Hd1.Numerator,1,data1);
The response of the filter when the input of square pulse is shown below
But the filter coefficients are of a length of 104 but I want to use lesser filter coefficients(say <20 or some other lesser coefficients) such that the filter perforamnce should be good enough. can someone explain if there is a way of doing it. Thanks.

回答 (1 件)

AJ von Alt
AJ von Alt 2014 年 1 月 21 日
編集済み: AJ von Alt 2014 年 1 月 21 日
This example article gives a great run down of designing low pass filters using MATLAB.
If you do not specify the order of a filter, the design tool will try to minimize the order while satisfying the specified constraints. If you have a specific filter order in mind, I recommend consulting the fdesign.lowpass documentation and selecting a specification that includes N, the filter order.
Here is a simple design adapted from the example article to help you get started.
Fc = 0.4;
N = 20; % FIR filter order
Hf = fdesign.lowpass('N,Fc',N,Fc);
Hd1 = design(Hf,'window','window',@hamming,'SystemObject',true);
hfvt = fvtool(Hd1,'Color','White');
  1 件のコメント
nam bui
nam bui 2021 年 2 月 12 日
Hello sir,
I tried to implement the piece of code you provided above but it said I need a DSP system toolbox license but I still have the signal processing toolbox under my matlab license. I'm wondering is there like an alternative way to do it?
Thank you

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeFilter Analysis についてさらに検索

製品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by