# How to define Passband and Stopband Attenuation of an IIR Butterworth Filter?

43 vues (au cours des 30 derniers jours)
EB le 12 Fév 2018
Modifié(e) : Shashank le 15 Fév 2018
I want to filter real acceleration data. I have to remove the very low frequencies <1Hz that are dominating my frequency plot. I have designed a HighPass Butterworth IIR Filter usign designfilt, but I don't understand the meaning of stopband and passband attenuation. I know that attenuation at cuttoff is 3db, but how can I calculate the passband and stopband attenuation if I have defined the bandpass frequency and cutoff frequency.
My way of defining the Astop and Apass until now was by guessing, but I guess this is not the correct way of defining these. I would like to know how they can be calculated properly?
This is the PSD of raw acceleration data.
This is the PSD of the filtered data.
Also, this is the code I have used to define the filter
% Sampling frequency in Hz
Fs = 5000;
% Filter order
Nf = 1;
% Band-pass frequency in Hz
Fpass = 1000;
% Cut-off frequency in Hz
Fstop = 0.6;
% Passband attenuation in dB
Apass = 1;
% Stopband attenuation in dB
Astop = 10;
% Design the filter using designfilt
HighPassIIRButterworth = designfilt('highpassiir','PassbandFrequency',Fpass,...
'StopbandFrequency',Fstop,'PassbandRipple',Apass,'StopbandAttenuation',...
Astop,'SampleRate',Fs,'DesignMethod','butter');
% View the filter
fvtool(HighPassIIRButterworth)
##### 0 commentairesAfficher -2 commentaires plus anciensMasquer -2 commentaires plus anciens

Connectez-vous pour commenter.

### Réponses (1)

Shashank le 15 Fév 2018
Modifié(e) : Shashank le 15 Fév 2018
This depends on the filter that you are designing. Generally, it is called Passband ripple and stopband attenuation.
The passband ripple is the amount of variation in the amplitude, within the designated passband of the filter, and stopband attenuation is the minimum attenuation level with the designated rejection band of the filter.
##### 0 commentairesAfficher -2 commentaires plus anciensMasquer -2 commentaires plus anciens

Connectez-vous pour commenter.

### Catégories

En savoir plus sur Filter Design dans Help Center et File Exchange

### Community Treasure Hunt

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

Start Hunting!

Translated by