How to choose stopband ripple and passband ripple of filter for High pass filter
現在この質問をフォロー中です
- フォローしているコンテンツ フィードに更新が表示されます。
- コミュニケーション基本設定に応じて電子メールを受け取ることができます。
エラーが発生しました
ページに変更が加えられたため、アクションを完了できません。ページを再度読み込み、更新された状態を確認してください。
古いコメントを表示
I am using high pass filter.
Data known:
Cutoff 10Hz. Sampling frequency 50KHz.
How can I choose stopband ripple and passband ripple ? Based on what criteria?
採用された回答
hello
why not start with simpler filters like butterworth or bessel filters ?
. If you don't have any specific requirement for stopband ripple and passband ripple , here you can start play with that :
Fs = 50e3;
samples = 5000;
dt = 1/Fs;
t = (0:samples-1)*dt;
y = 3*sign(sin(2*pi*50*t)); % signal - adjust amplitude to your needs
% high pass filter : Butterworth filter
NN = 2; % filter order
fc = 10; % cut off frequency (Hz)
Wn = fc/(Fs/2); % normalized cut off frequency
[B,A] = butter(NN,Wn,'high');
y_filtered = filter(B,A,y); % signal (after HP filtering)
figure(1)
plot(t,y,t,y_filtered);legend('signal','HP filtered signal');
12 件のコメント
Can you please alter for fir filters with the same requirements
You have a very low cut off frequency (10 Hz) compared to the sampling frequency (50 kHz)
this will generate a very long FIR flters (> 5,000 coefficients) wich is not very efficient . Why not stick with an low order IIR filter ?
do you really need a 50 kHz sampling rate ?
How does sampling and cutoff related (50KHz is less or more?) ...
What makes the difference if i choose IIR in this case?(though this is related to DSP please clear my doubts)
For a FIR filter , the lower the (normalized) frequency , the longer the filter (in this examlple we are talking about coefficients length in thousands ! )
for a IIR filter , the amount of coefficient is much less , but as we have poles , we must be carefull in DSP implementation (instabilities dues to accumulation of round off errors)
the best method is to convert any filter into "biquad" sections - there are plenty of publications about biquad implementation on DSP
my pleasure
I know desired cut-off frequency(10Hz).
How do I select the fpass and fstop frequencies?
hello
what filter are we talking ? FIR / IIR ?
for a bessel or butterworth IIR filter , there is only 2 parameters (order and cut off frequency)
IIR filter,
Order also not known
Only cutoff and sampling frequency are known.
ok , so why not use bessel or butterworth IIR filter ?
yes, going with butterworth filter design order to be set.
How to choose that
well, choosing a filter means you know what portion of the spectrum should be attenuated ... what is the goal here ? are you not able to do your code based on my first suggestion ?
Fs = 50e3;
samples = 5000;
dt = 1/Fs;
t = (0:samples-1)*dt;
y = 3*sign(sin(2*pi*50*t)); % signal - adjust amplitude to your needs
% high pass filter : Butterworth filter
NN = 2; % filter order
fc = 10; % cut off frequency (Hz)
Wn = fc/(Fs/2); % normalized cut off frequency
[B,A] = butter(NN,Wn,'high');
y_filtered = filter(B,A,y); % signal (after HP filtering)
figure(1)
plot(t,y,t,y_filtered);legend('signal','HP filtered signal');
その他の回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で Analog Filters についてさらに検索
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Web サイトの選択
Web サイトを選択すると、翻訳されたコンテンツにアクセスし、地域のイベントやサービスを確認できます。現在の位置情報に基づき、次のサイトの選択を推奨します:
また、以下のリストから Web サイトを選択することもできます。
最適なサイトパフォーマンスの取得方法
中国のサイト (中国語または英語) を選択することで、最適なサイトパフォーマンスが得られます。その他の国の MathWorks のサイトは、お客様の地域からのアクセスが最適化されていません。
南北アメリカ
- América Latina (Español)
- Canada (English)
- United States (English)
ヨーロッパ
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)
