Generate Filters coeffitients using *.m file
3 次查看(过去 30 天)
显示 更早的评论
I have made a FIR filter without filterDesigner tool
Fs = 48000; % Sampling rate
T = 1/Fs;
L = 320;
t = (0:L-1)*T;
x = sin(2*pi*1000*t) + 0.5*sin(2*pi*15000*t);
h = fir1(28, 6/24);
y = filter (h, (1), x);
How can I generate the list of filter coeffitients?
Or I should convert it somehow to *.fda file (don't know)?
3 个评论
Mathieu NOE
2022-12-7
your code works fine
what's the problem ?

Fs = 48000; % Sampling rate
T = 1/Fs;
L = 320;
t = (0:L-1)*T;
x = sin(2*pi*1000*t) + 0.5*sin(2*pi*15000*t);
h = fir1(28, 6/24);
y = filter(h,1,x);
plot(t,x,t,y);
采纳的回答
Star Strider
2022-12-7
If I understand your question correctly, the filter coefficients are the ‘h’ vector.
0 个评论
更多回答(1 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Digital and Analog Filters 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!