Can I use filtfilt with a Highpass filter?

11 views (last 30 days)
Hello,
I am wondering if it is okay to use the filtfilt function with a Highpass-Filter since the filtfilt documentation states "Do not use filtfilt with differentiator ..." and a Highpass-Filter has a differentiator-control-element (right?) in it? The problem occurred to me because I discovered that I get very different result using my filter that also has Highpass characteristics.
Best regards Philipp

Accepted Answer

Grant Sellers
Grant Sellers on 29 Jan 2018
Hello Philipp,
If you look at the code of the filtfilt function, using "edit filtfilt", you will notice a slightly different description for the warning found in the documentation:
"Note that FILTFILT should not be used when the intent of a filter is to modify signal phase, such as differentiators and Hilbert filters. "
The high pass filter, while it has differentiator elements, has a more stable phase response than a pure differentiator, and its end goal is not to phase the signal. High pass filters should still work with this function.
It may make sense that you still get different results when using your filter with filtfilt. Zero-phase filters respond differently, since they are a-causal and because the startup and ending transients are minimized by matching initial conditions.

More Answers (0)

Community Treasure Hunt

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

Start Hunting!