Pole-zero plot with blackman window, FIR filter - GUI

Hi everyone,
I'm working on a GUI and I want to make pole-zero plot with blackman window (together with fir1 function) but it doesn't work. Other windows works good, however blackman plot not. I used pzplot, pzmap and zplane functions. What should I do?
b = fir1(rzad,Wn,blackman(rzad+1));
Hz=tf(b,1);
axes(handles.axes6)
h = pzplot(Hz);
%pzmap(Hz)
%zplane(b,1)
grid on

 채택된 답변

Star Strider
Star Strider 2017년 5월 26일
The Signal Processing Toolbox tf function requires as its argument a digital filter object created by the designfilt function. It will not give you the result you want, since you have already calculated the numerator of your transfer function as ‘b’.
There is also nothing wrong with the use of the Blackman window.
this works for me:
rzad = 21; % Create Data
Wn = [0.3 0.7]; % Create Data
b = fir1(rzad,Wn,blackman(rzad+1));
zplane(b,1)
grid on
I cannot determine the problem with this plot and your GUI. Your filter design and the plot work.

댓글 수: 2

Thank for your answer. Yes, the plot work but when I click once more on the button then chart increases to the entire window and all of controlls disappear.
My pleasure.
I cannot comment on your GUI problems.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Community Treasure Hunt

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

Start Hunting!

Translated by