Numerator frac. length in Filter Designer

2 views (last 30 days)
JL
JL on 26 Jul 2023
Answered: Adeline on 18 Aug 2023
I made a Direct Form I Elliptic IIR filter using Filter Designer. Then I changed to Fixed-point with frac. length equal to 14.
I set it to 14 because: 2^{-14} = 0.000061< 0.0001, which means the coefficients can have four decimal place accuracy. The accuracy should not be higher than four too much, if I understand correctly.
However, showing the coefficients, I still see high accuracy coefficients. May I know why?
Update 2023-07-25 23:37:27:
I am thinking about this:
1 / 2^-14 = 0.00006103515625.
That is, the precision goes to at most 0.0001, while the true value can still have long digits after "0.0001", in base 10.
That is why the stored coefficients still have very long digits with limited fraction length.

Answers (1)

Adeline
Adeline on 18 Aug 2023
The filter coefficients calculated by MATLAB Filter Designer are specified in base 10. To have only four decimal places you can specify the “Numerator frac. length:” field as 4 instead of 14.

Community Treasure Hunt

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

Start Hunting!