matlab离散信号的产生与运算实验报告材料

上传人:小** 文档编号:88214934 上传时间:2019-04-21 格式:DOC 页数:10 大小:179.51KB
返回 下载 相关 举报
matlab离散信号的产生与运算实验报告材料_第1页
第1页 / 共10页
matlab离散信号的产生与运算实验报告材料_第2页
第2页 / 共10页
matlab离散信号的产生与运算实验报告材料_第3页
第3页 / 共10页
matlab离散信号的产生与运算实验报告材料_第4页
第4页 / 共10页
matlab离散信号的产生与运算实验报告材料_第5页
第5页 / 共10页
点击查看更多>>
资源描述

《matlab离散信号的产生与运算实验报告材料》由会员分享,可在线阅读,更多相关《matlab离散信号的产生与运算实验报告材料(10页珍藏版)》请在金锄头文库上搜索。

1、实验一 离散信号的产生与运算实验任务:1、在Matlab中运行各例题程序,理解时域离散信号的产生方法和离散序列的运算性质,了解各条语句的意义。2、完成以下习题:(1)编写程序产生下列离散序列: n1 = -3; n2 = 4; n0 = 0; n = n1:n2; x = n=n0; % x在n=n0时为1,其余为0 stem(n,x,filled); %filled:序列圆心处用实心圆表示 axis(n1,n2,0,1.1*max(x) title(单位抽样序列) xlabel(time(n) ylabel(Amplitude:x(n) n1 = -5; n2 = 5; n0 = 0; n

2、= n1:n2; x = n=n0; % x在n=n0时为1,其余为0 stem(n,x,filled); axis(n1,n2,0,1.1*max(x) title(单位阶跃序列) xlabel(time(n) ylabel(Amplitude:x(n) n1 = 16;sigma = 0.1;omega = 1.6;n = 0:n1;x = exp(sigma+i*omega)*n);subplot(2,2,1),plot(n,real(x);title(复指数信号的实部)subplot(2,2,3),stem(n,real(x),filled);title(复指数序列的实部)subplo

3、t(2,2,2),plot(n,imag(x);title(复指数信号的虚部)subplot(2,2,4),stem(n,imag(x),filled);title(复指数序列的虚部) f = 1/8;Um = 3;nt = 2;N = 20;T = 1/f;dt = T/N;n = 0:nt*N-1;tn = n*dt;x = Um*sin(2*f*pi*tn);subplot(2,1,1),plot(tn,x);title(连续时间正弦信号和离散正弦序列)ylabel(x(t)subplot(2,1,2),stem(tn,x);ylabel(x(n)n = -20:20;f = sinc(

4、n/5);subplot(2,1,1),plot(n,f);title(sinc信号)subplot(2,1,2),stem(n,f);title(sinc序列)(2)一个连续的周期性三角波信号频率为50Hz,信号幅度在0+2V之间,在窗口上显示2个周期的信号波形,对信号的一个周期进行16点采样来获得离散信号。试显示连续信号和采样获得的离散信号波形。(用sawtooth产生三角波)f = 50;Um = 1;nt = 2;N = 16;T = 1/f;dt = T/N;n = 0:nt*N-1;tn = n*dt;x = (Um+1)*sawtooth (2*f*pi*tn);subplot(

5、2,1,1),plot(tn,x);title(连续时间三角信号和离散三角序列)ylabel(x(t)subplot(2,1,2),stem(tn,x);ylabel(x(n)(3) 用Matlab实现下列信号序列:n1 = -5; n2 = 5; n = n1:n2; x1= n=-3; % x在n=-3时为1,其余为0 x2= n=4; % x在n=4时为1,其余为0 x=x1+2*(x2)stem(n,x,filled); %filled:序列圆心处用实心圆表示 axis(n1,n2,0,1.1*max(x) title(单位抽样序列) xlabel(time(n) ylabel(Amp

6、litude:x(n)(4) 已知,显示、和在区间的波形。f = 1/10;Um = 3;nt = 2;N = 20;T = 1/f;dt = T/N;n = 0:nt*N-1;tn = n*dt;x = Um*cos(2*f*pi*tn);subplot(3,1,1),plot(tn,x);title(连续时间余弦信号X(n)ylabel(x(t)n=n+3;subplot(3,1,2),plot(tn-3,x);title(连续时间余弦信号X(n-3)ylabel(x(t)n=n-6;subplot(3,1,3),plot(tn+3,x);title(连续时间余弦信号X(n+3)ylabe

7、l(x(t)(5) 已知,试显示、和在区间的波形。n=0:20;x=n.*sin(n);x1=fliplr(x);n1=-fliplr(n);x2=n/2.*sin(n/2);subplot(4,1,1),plot(n,x);title( X(n)ylabel(x(n)subplot(4,1,2),plot(n1,x1);title(X(-n)ylabel(x(n)subplot(4,1,3),plot(n,-x);title(-X(n)ylabel(x(n)subplot(4,1,4),plot(n,x2);title(X(n/2)ylabel(x(n)(6) 编写Matlab程序,描绘下列信号序列的卷积波形: n = 0:10x1 = n=0; x2 = exp(0.2*n).*x1;subplot(2,1,1), plot(n,x1); title(x1(n)subplot(2,1,2), plot(n,x2); title(x2(n) (7)已知一个IIR系统的转移函数为 输入矩形序列可用以下指令产生:x=square(n/5) (-2n10*pi) 画出该系统单位抽样相应以及输入、输出序列的波形。提示:求出系统的单位抽样响应h(n),再利用y(n)=x(n)*h(n)得出输出序列。

展开阅读全文
相关资源
相关搜索

当前位置:首页 > 商业/管理/HR > 管理学资料

电脑版 |金锄头文库版权所有
经营许可证:蜀ICP备13022795号 | 川公网安备 51140202000112号