资源描述:
《信号与系统实验指导——————matlab.docx》由会员上传分享,免费在线阅读,更多相关内容在工程资料-天天文库。
1、y=cos(2clear,closeall,dt=0.01;t=-2:dt:2;x=sin(2*pi*t);plot(t.x)%Clearallvariables%Closeallfigurewindows%Specifythestepoftimevariable%Specifytheintervaloftime%Generatethesignal%Openafigurewindowanddrawtheplotofx(t)titleC^inusoidalsignalx(t)1)xlabel(Timet(sec)*)tfunctiony=delta(t)dt=O.Ol;y=(u(t)-u(t
2、-dt))/dt;产生单位阶跃信号的扩展函数为:%Unitstepfunctionfunctiony=u(t)y=(t>=0);%y=1fort>0,elsey=0rriEzzwnrw1匚100So90807060a40302010£-6-202810y=sin(2t)Sinusoidalsignalx(t)Timet(sec)Figure1-inlxiFileEditViewInsertToolsDesktopWindowHelpD^HSD0BQSinusoidalsignalx(t)Timet(sec)y=2sin(2t)IJFigure1■-ln
3、x
4、FileEditViewInse
5、rtToolsDesktopWindowHelp、□01□QSinusoidalsignalx(t)Jnlxi♦>Figure1FieEditViewInsertToolsDesktopWndowHelpLDgSSSfe致Q甥®f00agy=sa(t/t)I."Figure1FileEdiViewhsertToolsDesktopWndowHelp■■MB■Sinusoidalsignalx(t)3.93.83.73.63.400」0.20.30.40.50.60.70.80.9Timet(sec)•■\\・\\\—•—■■\11111113.533y=4sa(t/t)
6、3-1Timet(sec).rcc・7”F・c2CULOFigure1-ln
7、xiFileEditViewInsertToolsDesktopWindowHelpMMMM•MBd致毘□s□□Sinusoidalsignalx(t)4-35-1t=-2:0.001:2f=2*exp((j*(pi/4)*t);subplot(2,2,l),plot(t,f);subplot(2?2,2),plot(tjeal(f));subplot(2,2,3),plot(t4mag(f));subplot(2,2,4),plot(t,abs(f));FieEcttVtewinsertTootsDesttop
8、iWidowHe<3%DQ口昌[n[致◎耀□sn222•10-505106t=-20:0.001:20f=2*exp((-1+j*10)*t);subplot(2,2,2),plot(tjeal(f));subplot(2,2,3),plot(t,imag(f));subplot(224),plot(t,abs(f));on;axis(卜3,3,・3、3])(=5:0.001:5;x=square(4*t,75);plot(t,x);grid•■•••••—•••MM•••••••■••••••■•10=5:0.001:5;x=tripuls(t,2,0);plot(t,x);gridon
9、;axis(卜3,3,・3,3])358MicrosoftWord文件宅)觸©fflS©献『2佝'主和匕切小•丿Figure1©■■2g24680SrU3RZO^QSkQQO©10、)*<)t^0.00t5;x“qum(30也75);plotSt);gridon;axis(HOJO,-10...£)functiony-u(t)y-(M);1节14/14li§4777g536列二二泮辽崩翹)。•••寵…要献昱示此任务窗备辭击嚼即棘下的“Off】"B6CtrlK踊次.