Obtaining IIIR Filter coefficients

4 Ansichten (letzte 30 Tage)
h b
h b am 10 Apr. 2016
Kommentiert: Star Strider am 10 Apr. 2016
| |I am using MATLAB to design a filter specifically to obtain the transfer function coefficients a and b.When using fvtool to view the filter using the b and a coefficients the filter looks different than that of I plot it using the sos matrix or the actual filter f.If you try the below code you can understand better what I am saying. Is this a function problem coming from MATLAB and can I use substitutes to sos2tf which gives me the required filter coefficients? Any work around to obtain directly the filter coefficients will be appreciated.
H = fdesign.lowpass('Fp,Fst,Ap,Ast',60,75,1,60,10000);
f = design(H,'butter','MatchExactly','passband'); % Design an FIR BW filt
info(f) % View information about filter
fvtool(f);
[b,a] = sos2tf(f.sosMatrix);
fvtool(b,a);

Antworten (1)

Star Strider
Star Strider am 10 Apr. 2016
I’m not certain what you’re doing. If you are attempting system identification, MATLAB has the entire System Identification Toolbox for that. If you are attempting a somewhat less rigorous approach, use the invfreqz function.
Producing different Bode plots using transfer function coefficients and second-order-section representation is common. The second-order-section representation is more stable than the transfer function representation, so ‘believe’ the second-order-section representation. This is in the documentation for every filter design in the Signal Processing Toolbox.
Many areas of applied computation require experimentation to get everything working the way you want it to. Signal processing is one such. Keep experimenting.
  2 Kommentare
h b
h b am 10 Apr. 2016
Can I extract the b and a from the designed filter as shown in my code with better results than I got?
Star Strider
Star Strider am 10 Apr. 2016
I would use the invfreqz function instead of the approach you’re currently using. The invfreqz function will give you the transfer function (the ‘b’ and ‘a’ coefficient vectors).
If you then want to use them as a filter, first check the filter Bode plot with the freqz function, and if it appears to resemble the characteristic you want, use the tf2sos function to convert it to the second-order-section representation (check it as well with freqz before you use it), since it is much more stable than using the transfer function representation in your filtfilt call.
As I mentioned previously, you will have to experiment to get the result you want.

Melden Sie sich an, um zu kommentieren.

Community Treasure Hunt

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

Start Hunting!

Translated by