zero phase filter in simulink

19 visualizzazioni (ultimi 30 giorni)
John Mark Odongo
John Mark Odongo il 24 Gen 2019
Risposto: Rafael Cordero il 17 Giu 2020
I am trying to run a zero phase low pass filter in Simulink in MATLAB however I can't find a zero phase filter block. The function filtfilt() works however when i use a self defined function block in Simulink with the same code that works in MATLAB it doesn't seem to work in Simulink. I have attached an image of the Simulink model and the code itself.2019-01-24 09_28_13-lowpass_test _ use.png
function y = test_lp(u)
Wn = 0.01*5;
[b,a] = butter( 3, Wn, 'low');
data=u(:,2);
y= filtfilt(b,a,u(:,2));
%y=filtfilt(b,a,u);
end

Risposte (2)

Sameer Gadekar
Sameer Gadekar il 11 Apr 2019
Any filter will introduce and has to introduce delay in the output else filter will become instable it wll become non causal.

Rafael Cordero
Rafael Cordero il 17 Giu 2020
Im having the same problem. Did you ever figure out how to fix this?

Categorie

Scopri di più su Filter Design and Analysis in Help Center e File Exchange

Prodotti


Release

R2018a

Community Treasure Hunt

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

Start Hunting!

Translated by