资源预览内容
第1页 / 共4页
第2页 / 共4页
第3页 / 共4页
第4页 / 共4页
亲,该文档总共4页全部预览完了,如果喜欢就下载吧!
资源描述
实验一 MATLAB环境认识实验1、 单位采样序列function x,n=impseq(n0,n1,n2)%Generates x(n)=delta(n-n0);n1=n0=n2;n=n1:n2;x=(n-n0)=0;序列程序:x,n=impseq(0,-5,5); stem(n,x)序列的移位:x,n=impseq(1,-5,5); stem(n,x)2、 单位阶跃序列function x,n=dwjyxl(n0,n1,n2)%Generates x(n)=delta(n-n0);n1=n0=0;序列程序:x,n=dwjyxl(0,-5,5);stem(n,x)3、 矩形序列序列的移位:x,n=dwjyxl(1,-5,5); stem(n,x)实指数序列a=2n=0:5xn=a.n;stem(n,xn)(2)n=-2:10;x=1:7,6:-1:1;x11,n11=lspy(x,n,5);x12,n12=lspy(x,n,-4);y,n=lsadd(2*x11,-3*x12,n11,n12);stem(n,y)n=-2:10;x=1:7,6:-1:1;x21,n21=lsfz(x,n);x21,n21=lspy(x21,n21,3);x22,n22=lspy(x,n,2);x22,n22=lsxch(x,x22,n,n22);y,n=lsadd(x21,x22,n21,n22);stem(n,y)(3)x=3 11 7 0 -1 4 2;nx=-3:3;h=2 3 0 -5 2 1;nh=-1:4;y,ny=conv_m(x,nx,h,nh);stem(ny,y)
收藏 下载该资源
网站客服QQ:2055934822
金锄头文库版权所有
经营许可证:蜀ICP备13022795号 | 川公网安备 51140202000112号