How to design a FIR Filter

2 次查看(过去 30 天)
Hello, I am new to matlab. I want to design FIR,Butterworth and some RC filters in Matlab with GUIDE. Someone told me that I can design it using Signal Processing Toolbox. Is it possible to implement these filters without any toolboxes otherthan just matlab and GUIDE.

采纳的回答

Wayne King
Wayne King 2012-4-1
Yes, it is possible, but you will have to write a lot of code. The Signal Processing Toolbox (SPT) enables you to create these filters easily. Filter design code can be very complicated, so you will have to invest a lot of time to do it without SPT.

更多回答(1 个)

Tina
Tina 2019-12-22
not sure about rc filter but FIR and butterworth filter can be designed by the help of built in function fir1,Filter.
b = fir1(48,wc);
freqz(b,1,512)
for butterworth you use butter(L).
n=%order of filter
fs=%sampling frequency
fc= %your corner frequency
wc=fc/(fs/2);%cuttoff freq of filter
b=fir1(n,wc,'low',butter(n+1);
[H,w] = freqz(b,1);
plot(w/pi,20*log(abs(H)))
title('butterfilter')
and you can design simple filter by
d=designfilt('lowpassfir','filterorder',n,'cutoffFrequency',fc,'samplerate',fs);
Filtered=filter(d,signal)%signal is the signal you wont to filter

类别

Help CenterFile Exchange 中查找有关 Filter Analysis 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by