Why does the output of IIR Band Pass filter have a huge spike when filtering a noisy sinusoid in Filter Design Toolbox 4.5 (R2009a)?

7 views (last 30 days)
I am generating a noisy sinusoid using the SIN and WGN functions. Next I design a band pass IIR Butterworth filter using FDATOOL. I export the SOS and G variables to workspace. I convert these to a transfer function using SOS2TF and apply this filter on the signal using the FILTER command.
I see the output has a huge spike. I am wondering what went wrong.

Accepted Answer

MathWorks Support Team
MathWorks Support Team on 27 Jun 2009
The unexpected output is due to the quantization errors occuring during conversion of a SOS filter into a transfer function.
To resolve this issue export the filter as an object. Apply this filter object on the input signal using the FILTER command. This way filter does not have to be converted to TF and therefore generates expected results.

More Answers (0)

Tags

No tags entered yet.

Community Treasure Hunt

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

Start Hunting!