electronics forum

Rules | Recent posts | topic RSS | Search | Register  | Log in

how to change matlab command


Post new topic  Reply to topic    EDAboard.com Forum Index -> Digital Signal Processing -> how to change matlab command
Author Message
awanis



Joined: 15 Sep 2009
Posts: 15
Location: malaysia


Post14 Oct 2009 1:17   

how to change matlab command


hello everybody...
can i ask something...
how ca i change this command to display the magnitude spectrum??
this command has show low pass filter..

case 1
if(wp>ws)
handle=errordlg('wp must be less than ws for lowpass filter','guifilter_design');
return;
end
[order,wn]=buttord(wp,ws,rp,rs,'s');
[num,den]=butter(order,wn,'s');
omega=[0:200:12000*pi];
h=freqs(num,den,omega);
gain=20*log10(abs(h));
an=angle(h);

push=get(handles.pushbutton1,'value');
global omega gain an;
if (push==1)
figure(2)
subplot(2,1,1);
plot(omega/(2*pi),gain);grid
ylabel('Gain in dB ----->');xlabel('(a)frequency in rad/sec----->');

subplot(2,1,2);
plot(omega/(2*pi),an);grid
ylabel('Phase in rad. ----->');xlabel('(b)frequency in rad/sec----->');
else
return;
end
global order;
str= sprintf('order:%d',order);
set(handles.edit9,'string',str);
Back to top
Google
AdSense
Google Adsense




Post14 Oct 2009 1:17   

Ads




Back to top
Arabic versionBulgarian versionCatalan versionCzech versionDanish versionGerman versionGreek versionEnglish versionSpanish versionFinnish versionFrench versionHindi versionCroatian versionIndonesian versionItalian versionHebrew versionJapanese versionKorean versionLithuanian versionLatvian versionDutch versionNorwegian versionPolish versionPortuguese versionRomanian versionRussian versionSlovak versionSlovenian versionSerbian versionSwedish versionTagalog versionUkrainian versionVietnamese versionChinese version
Post new topic  Reply to topic    EDAboard.com Forum Index -> Digital Signal Processing -> how to change matlab command
Page 1 of 1 All times are GMT + 1 Hour
Similar topics:
is there a matlab command or how to? (9)
How to change MATLAB polar plots radius axis limit (1)
how to use STOR or APPE command with AT command ? (3)
How to use the MATLAB command "rotate"? (2)
command in matlab (1)
undefine command/function in matlab (2)
MATLAB lpc command (linear Prediction) (3)
help,, ??? Undefined command/function 'mcc'. in matlab (1)
GSM AT Command for issuing service command (7)
GSM AT Command for issuing service command (1)


Abuse || Administrator || Moderators || Support us || sitemap
topic RSS