Got Questions? Get Answers.
Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
filtfilt function

Subject: filtfilt function

From: Florian

Date: 19 Oct, 2009 14:34:03

Message: 1 of 2

Hi,

I want to create a 4th order zero-phase digital butterworth filter with a cutoff frequency of 10Hz. Sofar I was using:

Fs=1000; % sample frequency
Fc=10; %cutoff frequency
[B,A]=butter(4,Fc/(Fs/2));
signal_filt=filtfilt(B,A,signal);

Now, I have two questions:
1. I just read in the help function that the "filter order is double the order of the filter specified by B and A".
Does that mean that I am currently using a 8th order zero-phase digital butterworth filter with a cutoff of 10Hz??

2. Talking about the cutoff frequency. Filtering also in the reverse direction, does this process decrease the defined cutoff fc (10Hz)?

Your help for clarification is much appreciated.
Thanks

Subject: filtfilt function

From: Javier Lopez-Calderon

Date: 27 Apr, 2010 21:03:04

Message: 2 of 2

"Florian " <sppgwff@brunel.ac.uk> wrote in message <hbhtcr$b1$1@fred.mathworks.com>...
> Hi,
>
> I want to create a 4th order zero-phase digital butterworth filter with a cutoff frequency of 10Hz. Sofar I was using:
>
> Fs=1000; % sample frequency
> Fc=10; %cutoff frequency
> [B,A]=butter(4,Fc/(Fs/2));
> signal_filt=filtfilt(B,A,signal);
>
> Now, I have two questions:
> 1. I just read in the help function that the "filter order is double the order of the filter specified by B and A".
> Does that mean that I am currently using a 8th order zero-phase digital butterworth filter with a cutoff of 10Hz??

Yes. And also your cutoff (10 Hz) is at -6db (half-amplitude), not -3db as using filter.m

>
> 2. Talking about the cutoff frequency. Filtering also in the reverse direction, does this process decrease the defined cutoff fc (10Hz)?
>
> Your help for clarification is much appreciated.
> Thanks

Tags for this Thread

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us