the degree of the Butterworth filter

1 view (last 30 days)
Dear Sir or Madam,
I have some questions about the degree of the Butterworth filter. I want to filter our time-series data with the second-order Butterworth filter without any time lag. Therefore, I adopted the MATLAB function ‘filtfilt’, in which the variables ‘b’ and ‘a’ were calculated according to the following formula: [b, a]= butter (n, Wn). According to the explanation about ‘filtfilt’ on your website describing that the degree of the Butterworth filter obtained from the filtfilt’ function is a double of variable ‘n’. Therefore, I assigned 1 to ‘n’. Is this correct procedure? Can I say that I filtered our data with the second-order Butterworth filter? Thank you for your help in advance!
Sincerely yours, Satoshi Shimegi Graduate School of Medicine Osaka University

Accepted Answer

Walter Roberson
Walter Roberson on 11 Nov 2015
When you use butter() with two arguments instead of three arguments, then you need to pass the actual order desired, so you would pass 2 because you want an order 2 filter. However if you had used butter with three arguments, such as butter(n, Wn, 'stop') then the order is automatically doubled compared to what you pass, so in that case you would use n half of what your target was, such as butter(1, Wn, 'stop')
  1 Comment
Satoshi
Satoshi on 11 Nov 2015
Thank you for your quick reply. I would like to confirm some points. I’m using the function ‘filtfilt’ as low-pass filter because of preventing the time lag. I use the following formula: y = filtfilt(b,a,x), and the variables ‘b’ and ‘a’ were calculated according to the following formula: [b, a]= butter (n, Wn). Do you think that the above procedure, that is, the butter processing followed by the filtfilt processing correct?

Sign in to comment.

More Answers (0)

Community Treasure Hunt

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

Start Hunting!