求教GUI设计中的问题
我用GUI设计了一个滤波器设计界面,我编写的程序如下:radioValue=get(handles.FIR_radio8, 'Value');
if (radioValue==0)
popup_sel_index3= get(handles.plot_popup3, 'Value');
wp=30;ws=35;Fs=100;Rp=0.5;Rs=40
switch popup_sel_index3
case 1
[n1,Wn1]=buttord(wp/(Fs/2),ws/(Fs/2),Rp,Rs,'z');
[num1,den1]=butter(n1,Wn1);
[H1,W1]=freqz(num1,den1);
plot(W1*Fs/(2*pi),abs(H1));
xlabel('频率/Hz')
ylabel('幅值')
figure
zplane(num1,den1);
figure
imp=[1;zeros(20,1)];
h=filter(num1,den1,imp);
stem(h);
case 2
[n2,Wn2]=cheb1ord(wp/(Fs/2),ws/(Fs/2),Rp,Rs);
[num2,den2]=cheby1(n2,Rp,Wn2);
[H2,W2]=freqz(num2,den2,100,Fs);
plot(W2,20*log10(abs(H2)));
figure
zplane(num2,den2);
figure
imp=[1;zeros(20,1)];
h=filter(num2,den2,imp);
stem(h);
........
........
怎样才能把红线标出的参数可以用选择用界面上控件输入(就是怎么样附件中输入数据来得到不同的波形),谢谢大家的帮助哈!!
[此贴子已经被作者于2006-6-11 11:21:14编辑过]