信号与系统实验教程(只有问题详解)

上传人:仙*** 文档编号:86023570 上传时间:2022-05-06 格式:DOC 页数:57 大小:810.50KB
返回 下载 相关 举报
信号与系统实验教程(只有问题详解)_第1页
第1页 / 共57页
信号与系统实验教程(只有问题详解)_第2页
第2页 / 共57页
信号与系统实验教程(只有问题详解)_第3页
第3页 / 共57页
点击查看更多>>
资源描述
word信号与系统实验教程(只有答案)(实验报告)这么玩!目录实验一信号与系统的时域分析2三、实验容及步骤2实验二连续时间信号的频域分析14三、实验容及步骤14实验三连续时间LTI系统的频域分析35三、实验容及步骤35实验四通信系统仿真41三、实验容及步骤41实验五连续时间LTI系统的复频域分析51三、实验容及步骤51实验一信号与系统的时域分析三、实验容及步骤实验前,必须首先阅读本实验原理,读懂所给出的全部例程序。实验开始时,先在计算机上运行这些例程序,观察所得到的信号的波形图。并结合例程序应该完成的工作,进一步分析程序中各个语句的作用,从而真正理解这些程序。实验前,一定要针对下面的实验项目做好相应的实验准备工作,包括事先编写好相应的实验程序等事项。Q1-1:修改程序Program1_1,将dt改为0.2,再执行该程序,保存图形,看看所得图形的效果如何?这两幅图形有什么区别,哪一幅图形看起来与实际信号波形更像?答:Q1-2:修改程序Program1_1,并以Q1_2为文件名存盘,产生实指数信号x(t)=e。要求在图形中加上网格线,并使用函数axis()控制图形的时间围在02秒之间。然后执行该程序,保存所的图形。修改Program1_1后得到的程序Q1_2如下:信号x(t)=e的波形图clear, % Clear all variablesclose all, % Close all figure windowsdt = 0.2; % Specify the step of time variablet = -2:dt:2; % Specify the interval of timex = exp(-0.5*t); % Generate the signalplot(t,x) grid on;axis (0 2 0 1 ) title(Sinusoidal signal x(t)xlabel(Time t (sec)Q1-3:修改程序Program1_1,并以Q1_3为文件名存盘,使之能够仿真从键盘上任意输入的一个连续时间信号,并利用该程序仿真信号x(t)=e-2t。修改Program1_1后得到的程序Q1_3如下:信号x(t)=e-2t的波形图clear, close all, dt = 0.2; t = -2:dt:2; x=input(Input x(t):);plot(t,x) grid on;axis (0 2 -1 1 ) title(Sinusoidal signal x(t)xlabel(Time t (sec)Q1-4:将实验原理中所给的单位冲激信号和单位阶跃信号的函数文件在MATLAB文件编辑器中编写好,并分别以文件名delta和u存入work文件夹中以便于使用。抄写函数文件delta如下:抄写函数文件u如下:function y = delta(t) % Unit step functiondt = 0.01; function y = u(t)y = (u(t)-u(t-dt)/dt; y = (t=0); % y = 1 for t 0, else y = 0Q1-5:修改程序Program1_4,并以Q1_5为文件名存盘,利用axis()函数,将图形窗口的横坐标围改为-2n x 1.5。修改Program1_4后得到的程序Q1_5如下:信号的波形图clear, close all, n = -5:5; x = zeros(1,4), 0.1, 1.1, -1.2, 0, 1.3, zeros(1,2); stem (n,x,.) grid on,axis(-2 5 -1.5 1.5);title (A discrete-time sequence xn)xlabel (Time index n)Q1-6:|n| 和x(t)=cos(2t)u(t)-u(t-3)。要求选择的时间窗能够表现出信号的主要部分(或特征)。编写的程序Q1_6如下:|n| 的波形图和信号x(t)=cos(2t)u(t)-u(t-3)的波形图clear,close all,t = -1:0.01:4;xt = cos(2*pi*t).*(u(t)-u(t-3); n=-5:5; xn=(0.5).abs(n); subplot(211)plot(t,xt) grid on,title (Original signal x(t)subplot(212)stem(n,xn,.) grid on,title (Original signal x(n)xlabel (Time t (sec)Q1-7:根据示例程序的编程方法,编写一个MATLAB程序,以Q1_7为文件名存盘,由给定信号x(t) = eu(t) 求信号y(t) = x(1.5t+3),并绘制出x(t) 和y(t)的图形。编写的程序Q1_7如下:function y=x(t)y=exp(-0.5*t).*u(t);clear,close all,t = -3:0.01:4;xt = x(t); % Generate the original signal x(t)yt=x(1.5*t+3); subplot(211)plot(t,xt) % Plot x(t)grid on,title (Original signal x(t)subplot(212)plot(t,yt) % Plot x(t)grid on,title (Original signal y(t)xlabel (Time t (sec)信号x(t)的波形图信号y(t) = x(1.5t+3) 的波形图Q1-8:给定一个离散时间信号xn = un un-8,仿照示例程序Program1_5,编写程序Q1_8,产生xn的左移序列x1n = xn+6和右移序列x2n = xn-6,并在同一个图形窗口的三个子图中分别绘制这三个序列的图形。编写的程序Q1_8如下:function y=xx(n)y=u(n)-u(n-8);clear,close all,n = -10:15;x =xx(n); % Generate the original signal x(n)x1 = xx(n+6); % Shift x(t) to the left by 2 second to get x1(n+6)x2 =xx(n-6); % Shift x(t) to the right by 2 second to get x2(n-6)subplot(311)stem(n,x,.) % Plot x(t)grid on,title (Original signal x(n)subplot (312)stem (n,x1,.) % Plot x1(t)grid on,title (Left shifted version of x(n)subplot (313)stem (n,x2,.) % Plot x2(t)grid on,title (Right shifted version of x(n)xlabel (Time t (sec)信号波形图Q1-9:编写程序Q1_9,使之能够接受以键盘方式输入的定义在不同时间段的两个不同连续时间信号并完成卷积运算,分别绘制这两个信号及其卷积的结果的图形,图形按照22分割成四个子图。编写的程序Q1_9如下:clear;close all;dt = 0.01;t0=input(Input first signal t0:);t1=input(Input first first signal t1:);tx = t0:dt:t1;x = input(Input first signal variable(tx) :);t2=input(Input second signal t0:);t3=input(Input second signal t1:);th=t2:dt:t3;h = input(Input second signal variable(th) :)y = dt*conv(x,h); % pute the convolution of x(t) and h(t)subplot(221)plot(tx,x), grid on, title(Signal x(t)xlabel(Time t sec)subplot(222)plot(th,h), grid on, title(Signal h(t)xlabel(Time t sec)subplot(313)plot(y), grid on, title(The convolution of x(t) and h(t) xlabel(Time t sec)信号x (t)、h(t)和x (t)*h(t)的波形图Q1-10:给定两个离散时间序列nun-un-8 hn = un-un-8编写程序Q1_10,计算它们的卷积,并分别绘制xn、hn和它们的卷积yn的图形。编写的程序Q1_10如下:n=0:10;x = (0.5).n.*(u(n)-u(n-8);h = u(n)-u(n-8);y =conv(x,h); % pute the convolution of x(t) and h(t)subplot(221)stem(n,x,.), grid on, title(Signal x(n)subplot(222)stem(n,h,.), grid on, title(Signal h(n)subplot(212)stem(y), grid on, title(The convolution of x(n) and h(n), xlabel(Time t sec);信号xn、hn和yn的波形图Q1-11已知一个序列为编写MATLAB程序Q1_11,能够将xn以N = 8为周期进行周期延拓得到一个周期为N =8的周期序列yn,并分别绘制xn和yn图形。编写的程序Q1_11如下:function y=u4(n)y=n.*(u(n)-u(n-5);Q1clear, close all;n =-16:32x=u4(n);T = 8; y = 0;for k = -2:4; y =y+u4(n-k*T);endsubplot(211)stem(n,x,.);grid on,title (Original signal x(n)xlabel(Time t sec)subplot(212)stem(n,y);title (period signal x(n)xlabel(Time t sec)grid on,信号xn的波形图信号yn的波形图Q1-12仿照例程序Program1_7,编写程序Q1_12,计算并绘制由如下微分方程表示的系统在输入信号为x(t) = (e-2t - e-3t)u(t)时的零状态响应和你手工计算得到的系统零状态响应曲线。手工计算得到的系统零状态响应的数学表达式是:编写的程序Q1_12如下:用MATLAB绘制的手工计算的系统响应clear, close all;num = input(Type in the right coefficient vector of differential equation:);den = input(Type in the left coefficient vector of differential equation:);t = 0:0.01:8;x = input(Type in the expression of the input signal x(t):);y=lsim(num,den,x,t);plot(t,y)执行程序Q1_12得到的系统响应Q1-13:利用程序Q1_9,验证卷积的相关性质。(a)验证性质:选择信号x(t)的数学表达式为:sin(t)x(t)、(t)和x(t)*(t)的波形验证所得结论是:(b)验证性质:选择信号x(t)的数学表达式为:sin(t) t0=2x(t)、(t-t0) 和的波形验证所得结论是:(c)验证性质:选择信号x(t)的数学表达式为: sin(t) 选择的t1 = 2 秒,t2 = 3 秒。执行程序Q1_9,输入信号x(t-t1) 和(t-t2) 的数学表达式,得到的信号及其卷积的波形图如下:执行程序Q1_9,输入信号x(t-t2) 和(t-t1) 的数学表达式,得到的信号及其卷积的波形图如下:验证所得结论是:(d) 验证性质:选择信号x(t)(建议选择一个时限信号)的数学表达式为:u(t)-u(t-3)的数学表达式为:手工绘制的波形如下:执行程序Q1_9,输入信号x(t) 和u(t) 的数学表达式,得到的信号及其卷积的波形图如下:验证所得结论是:(e)验证性质:选择信号x(t)的数学表达式为: sin(t) 选择信号h(t)的数学表达式为:sin(t)选择的t0=:1执行程序Q1_9,输入信号x(t) 和h(t-t0) 的数学表达式,得到的信号及其卷积的波形图如下:执行程序Q1_9,输入信号x(t-t0) 和h(t) 的数学表达式,得到的信号及其卷积的波形图如下:验证所得结论是:Q1-14:做如下总结:1、信号与系统分析,就是基于信号的分解,在时域中,信号主要分解成:2、写出卷积的运算步骤,并谈谈你对卷积的一些基本性质的理解。利用MATLAB计算卷积的函数是什么?如何使用?3、在时域中,描述一个连续时间LTI系统的数学模型有:4、MATLAB是如何表示一个由微分方程描述的连续时间LTI系统的?求解连续时间LTI系统的单位冲激响应、单位阶跃响应以及系统在某一个输入信号作用下的零状态响应的MATLAB函数有哪些?四、实验报告要求1、按要求完整书写你所编写的全部MATLAB程序2、详细记录实验过程中的有关信号波形图(存于自带的U盘中),图形要有明确的标题。全部的MATLAB图形应该用打印机打印,然后贴在本实验报告中的相应位置,禁止复印件。3、实事地回答相关问题,严禁抄袭。本实验完成时间:年月日实验二连续时间信号的频域分析三、实验容及步骤实验前,必须首先阅读本实验原理,读懂所给出的全部例程序。实验开始时,先在计算机上运行这些例程序,观察所得到的信号的波形图。并结合例程序应该完成的工作,进一步分析程序中各个语句的作用,从而真正理解这些程序。实验前,一定要针对下面的实验项目做好相应的实验准备工作,包括事先编写好相应的实验程序等事项。Q2-1编写程序Q2_1,绘制下面的信号的波形图:其中,w0,要求将一个图形窗口分割成四个子图,分别绘制cos(w0t)、cos(3w0t)、cos(5w0t) 和x(t) 的波形图,给图形加title,网格线和x坐标标签,并且程序能够接受从键盘输入的和式中的项数。抄写程序Q2_1如下:clear,close allT = 2; dt = 0.00001; t = -2*pi:dt:2*pi; w0=0.5*pi;x1 = cos(w0*t);x3=(-1/3)*cos(3*w0*t);x5=(1/5)*cos(5*w0*t);N = input(Type in the number of the harmonic ponents N = :);y=0;for q = 1:N; % Synthesiz the periodic signal y(t) from the finite Fourier series y = y+(1/q).*sin(q*pi)/2).*cos(q*w0*t);end;subplot(221),plot(t,x1), title(The original signal cos(w0t);grid on; axis(-2*pi,2*pi,-1,1), xlabel(Time t)subplot(223), plot(t,x5), title(The original signal (1/5)cos(5w0t);grid on; axis(-2*pi,2*pi,-1,1), xlabel(Time t)subplot(222)plot(t,x3), title(The original signal (-1/3)cos(3w0t);grid on; axis(-2*pi,2*pi,-1,1), xlabel(Time t)subplot(224)plot(t,y), title(The synthesis signal of x(t);grid on; axis(-10,10,-1,1), xlabel(Index N)执行程序Q2_1所得到的图形如下:N=10Q2-2给程序Program2_1增加适当的语句,并以Q2_2存盘,使之能够计算例题2-1中的周期方波信号的傅里叶级数的系数,并绘制出信号的幅度谱和相位谱的谱线图。通过增加适当的语句修改Program2_1而成的程序Q2_2抄写如下:clear,close allT = 2; dt = 0.00001; t = -2:dt:2;x1 = u(t)-u(t-1-dt); x = 0;for m = -1:1 x = x + u(t-m*T) - u(t-1-m*T-dt); % Periodically extend x1(t) to form a periodic signalendw0 = 2*pi/T;N = input(Type in the number of the harmonic ponents N = :);L = 2*N+1;for k = -N:1:N; ak(N+1+k) = (1/T)*x1*exp(-j*k*w0*t)*dt;endphi = angle(ak);y=0;for q = 1:L; % Synthesiz the periodic signal y(t) from the finite Fourier series y = y+ak(q)*exp(j*(-(L-1)/2+q-1)*2*pi*t/T);end;subplot(221)plot(t,x), title(The original signal x(t), axis(-2,2,-0.2,1.2),grid on;subplot(222)k=-N:N; stem(ak), title(The ak of x(t), axis(-1,1,-0.4,0.4),grid on;subplot(223)k=-N:N; stem(k,abs(ak),k.), title(The amplitude |ak| of x(t), axis(-N,N,-0.1,0.6),grid on;subplot(224)stem(k,phi,r.), title(The phase phi(k) of x(t), axis(-N,N,-2,2), xlabel(Index k),grid on;执行程序Q2_2得到的图形Q2-3反复执行程序Program2_2,每次执行该程序时,输入不同的N值,并观察所合成的周期方波信号。通过观察,你了解的吉伯斯现象的特点是: N=5 N=10N=20 N=401、周期信号的傅里叶级数与GIBBS现象给定如下两个周期信号:Q2-4分别手工计算x1(t) 和x2(t) 的傅里叶级数的系数。信号x1(t) 在其主周期的数学表达式为:t+1 -1t01-t 0t1计算x1(t) 的傅里叶级数的系数的计算过程如下:k = -10:10;ak=0; ak = 1/2.* (sin(k)*pi/2)./(k)*pi/2)N=-10:10; stem(k,ak);通过计算得到的x1(t)的傅里叶级数的系数的数学表达式是:1/2.* (sin(k)*pi/2)./(k)*pi/2)信号x2(t) 在其主周期的数学表达式为: 0 0.2|t|1计算x2(t) 的傅里叶级数的系数的计算过程如下:k = -10:10;ak=0; ak =sin(k*pi*0.2)./(k*pi)N=-10:10; stem(k,ak);通过计算得到的x1(t)的傅里叶级数的系数的数学表达式是:sin(k*pi*0.2)./(k*pi)用MATLAB帮助你计算出你手工计算的傅里叶级数的系数ak从-10到10共21个系数。从命令窗口上抄写x1(t)的21个系数如下:ak = Columns 1 through 8 Columns 9 through 16 Columns 17 through 21 从命令窗口上抄写x2(t)的21个系数如下:Columns 1 through 8 Columns 9 through 16 Columns 17 through 21 Q2-5仿照程序Program2_1,编写程序Q2_5,以计算x1(t)的傅里叶级数的系数。程序Q2_5如下:function y=x1(t)y1=t+1;y2=1-t;y=y1.*(-1t&t=0)+y2.*(0t&t1);clear,close allT = 2; dt = 0.00001; t = -8:dt:8;x11 = x1(t); x = 0;for m = -8:8 x = x + x1(t-m*T); % Periodically extend x1(t) to form a periodic signalendw0 = 2*pi/T;N = 10;L = 2*N+1;for k = -N:1:N; ak(N+1+k) = (1/T)*x11*exp(-j*k*w0*t)*dt;endphi = angle(ak);y=0;for q = 1:L; % Synthesiz the periodic signal y(t) from the finite Fourier series y = y+ak(q)*exp(j*(-(L-1)/2+q-1)*2*pi*t/T);end;subplot(211),plot(t,x), title(The original signal x(t), axis(-8,8,-0.2,1.2),grid on,subplot(212)k=-N:N; stem(k,ak,k.), title(The factor ak of x(t), axis(-N,N,-0.1,0.6),grid on,执行程序Q2_5所得到的x1(t)的傅里叶级数的ak从-10到10共21个系数如下:Columns 1 through 5 Columns 6 through 10 Columns 11 through 15 Columns 16 through 20 Column 21 与你手工计算的ak相比较,是否相同,如有不同,是何原因造成的?答:Q2-6仿照程序Program2_1,编写程序Q2_6,以计算x2(t) 的傅里叶级数的系数(不绘图)。程序Q2_6如下:function y=x2(t)y1=1;y2=1;y=y1.*(-0.2t&t=0)+y2.*(0t&t=0.2);clear,close allT = 2; dt = 0.00001; t = -8:dt:8;x11 = x2(t); x = 0;for m = -8:8 x = x + x2(t-m*T); % Periodically extend x1(t) to form a periodic signalendw0 = 2*pi/T;N = 10;L = 2*N+1;for k = -N:1:N; ak(N+1+k) = (1/T)*x11*exp(-j*k*w0*t)*dt;endphi = angle(ak);y=0;for q = 1:L; % Synthesiz the periodic signal y(t) from the finite Fourier series y = y+ak(q)*exp(j*(-(L-1)/2+q-1)*2*pi*t/T);end;subplot(211),plot(t,x), title(The original signal x(t), axis(-8,8,-0.2,1.2),grid on,subplot(212)k=-N:N; stem(k,ak,k.), title(The factor ak of x(t), axis(-N,N,-0.1,0.6),grid on,执行程序Q2_6所得到的x2(t)的傅里叶级数的ak从-10到10共21个系数如下:Columns 1 through 5 Columns 6 through 10 Columns 11 through 15 Columns 16 through 20 Column 21 与你手工计算的ak相比较,是否相同,如有不同,是何原因造成的?答:Q2-7仿照程序Program2_2,编写程序Q2_7,计算并绘制出原始信号x1(t) 的波形图,用有限项级数合成的y1(t) 的波形图,以及x1(t) 的幅度频谱和相位频谱的谱线图。编写程序Q2_7如下:clear,close allT = 2; dt = 0.00001; t = -8:dt:8;x11 = x1(t); x = 0;for m = -8:8 x = x + x1(t-m*T); % Periodically extend x1(t) to form a periodic signalendw0 = 2*pi/T;N = 5;L = 2*N+1;for k = -N:1:N; ak(N+1+k) = (1/T)*x11*exp(-j*k*w0*t)*dt;endphi = angle(ak);y=0;for q = 1:L; % Synthesiz the periodic signal y(t) from the finite Fourier series y = y+ak(q)*exp(j*(-(L-1)/2+q-1)*2*pi*t/T);end;phi = angle(ak);y=0;for q = 1:L; % Synthesiz the periodic signal y(t) from the finite Fourier series y = y+ak(q)*exp(j*(-(L-1)/2+q-1)*2*pi*t/T);end;subplot(221),plot(t,x), title(The original signal x(t), axis(-8,8,-0.2,1.2),subplot(223), plot(t,y), title(The synthesis signal y(t), axis(-8,8,-0.2,1.2), xlabel(Time t),subplot(222)k=-N:N; stem(k,abs(ak),k.), title(The amplitude |ak| of x(t), axis(-N,N,-0.1,0.6)subplot(224)stem(k,phi,r.), title(The phase phi(k) of x(t), axis(-N,N,-2,2), xlabel(Index k)执行程序Q2_7,输入N = 5所得到的图形如下:反复执行程序Q2_7,输入不同的N值,观察合成的信号波形中,是否会产生Gibbs现象?为什么?;答:2. 连续时间非周期信号的傅里叶变换给定两个时限信号:Q2-8利用单位阶跃信号u(t),将x1(t) 表示成一个数学闭式表达式,并手工绘制x1(t) 和x2(t) 的时域波形图。信号x1(t) 的闭式数学表达式为:x1(t) = :y1=t+2;y2=1;y3=-t+2;y=y1.*(-2=t&t-1)+y2.*(-1=t&t1)+y3.*(1=t&t2);手工绘制的x1(t)的时域波形图手工绘制的x2(t)的时域波形图function y=x28(t)y1=t+2;y2=1;y3=-t+2;y=y1.*(-2=t&t-1)+y2.*(-1=t&t1)+y3.*(1=t&t2);clear,close allT = 2; dt = 0.00001; t = -5:dt:5;x1 = x28(t).*(u(t+2)-u(t-2); x2=cos(pi/2*t).*(u(t+1)-u(t-1);subplot(211),plot(t,x1,.),title(The original signal x1(t), axis(-5,5,-1,1), xlabel(Time t)subplot(212),plot(t,x2,.),title(The original signal x2(t),axis(-5,5,-1,1), xlabel(Time t)Q2-9手工计算x1(t) 和x2(t) 的傅里叶变换(如能够用傅里叶变换的性质计算最好),并手工绘制出它们的幅度谱和相位谱;计算x1(t) 的傅里叶变换的过程:计算得到的x1(t) 的傅里叶变换的数学表达式为:clear,close allT = 0.01; dw = 0.1; %时间和频率变化的步长t = -10:T:10;w = -4*pi:dw:4*pi;xx=x28(t);X=x28(t)*exp(-j*t*w)*T; %傅里叶变换X1=abs(X); %计算幅度谱phai=angle(X); %计算相位谱subplot(221);plot(t,xx),title(The original signal x1(t),axis(-10,10,-1,2),xlabel(Time t),grid on;subplot(222)plot(w,X),title(The Fourier Transform of x1(t) ),axis(-4*pi,4*pi,-1,3.5),xlabel(f(jw),grid on;subplot(223);plot(w,X1), title(The amplitude of f(jw) ), axis(-4*pi,4*pi,-1,3.5),xlabel(f(jw),grid on;subplot(224);plot(w,phai),title(The phase of f(jw),axis(-pi,pi,-4,4),xlabel(f(jw),grid on;计算x2(t) 的傅里叶变换的过程:clear,close allT = 0.01; dw = 0.1; %时间和频率变化的步长t = -10:T:10;w = -4*pi:dw:4*pi;xx=cos(pi/2*t).*(u(t+1)-u(t-1);X=xx*exp(-j*t*w)*T; %傅里叶变换X1=abs(X); %计算幅度谱phai=angle(X); %计算相位谱subplot(221);plot(t,xx),title(The original signal x1(t),axis(-10,10,-1,2),xlabel(Time t),grid on;subplot(222)plot(w,X),title(The Fourier Transform of x1(t) ),axis(-4*pi,4*pi,-1,3.5),xlabel(f(jw),grid on;subplot(223);plot(w,X1), title(The amplitude of f(jw) ), axis(-4*pi,4*pi,-1,3.5),xlabel(f(jw),grid on;subplot(224);plot(w,phai),title(The phase of f(jw),axis(-pi,pi,-4,4),xlabel(f(jw),grid on;计算得到的x2(t) 的傅里叶变换的数学表达式为:手工绘制的x1(t)的幅度频谱图手工绘制的x2(t)的幅度频谱图Q2-10编写MATLAB程序Q2_10,能够接受从键盘输入的时域信号表达式,计算并绘制出信号的时域波形、幅度谱。程序Q2_10抄写如下clear,close allT = 0.01; dw = 0.1; %时间和频率变化的步长t = -10:T:10;w = -4*pi:dw:4*pi;xx= input(Input the signal (t) :);X=xx*exp(-j*t*w)*T; %傅里叶变换X1=abs(X); %计算幅度谱phai=angle(X); %计算相位谱subplot(211);plot(t,xx),title(The original signal x(t),axis(-10,10,-1,2),xlabel(Time t),grid on;subplot(223)plot(w,X1),title(The amplitude of f(jw) ),xlabel(f(jw),grid on;subplot(224);plot(w,phai),title(The phase of f(jw),axis(-pi,pi,-4,4),xlabel(f(jw),grid on;执行程序Q2_10,输入信号x1(t)的数学表达式,得到的信号时域波形、幅度谱和相位谱如下:X1(t)=exp(-t)执行程序Q2_10,输入信号x2(t)的数学表达式,得到的信号时域波形、幅度谱和相位谱如下:Q2-11修改程序Q2_10,并以程序Q2_11为文件名存盘,要求能够接受从键盘输入的时域信号表达式,计算其傅里叶变换,并分别绘制其傅里叶变换的实部、虚部、幅度频谱和相位频谱的图形。编写的程序Q2_11如下:clear,close allT = 0.01; dw = 0.1; %时间和频率变化的步长t = -10:T:10;w = -4*pi:dw:4*pi;xx= input(Input the signal (t) :);X=xx*exp(-j*t*w)*T; %傅里叶变换X1=abs(X); %计算幅度谱phai=angle(X); %计算相位谱realx=real(X);imagx=imag(X);subplot(311);plot(t,xx),title(The original signal x(t),axis(-10,10,-1,2),xlabel(Time t),grid on;subplot(323)plot(w,realx),title(The real of f(jw) ),xlabel(f(jw),grid on;subplot(324);plot(w,imagx),title(The imag of f(jw),axis(-pi,pi,-4,4),xlabel(f(jw),grid on;subplot(325)plot(w,X1),title(The amplitude of f(jw) ),xlabel(f(jw),grid on;subplot(326);plot(w,phai),title(The phase of f(jw),axis(-pi,pi,-4,4),xlabel(f(jw),grid on;选定适当的信号,该信号的时域表达式为:u(t)-u(t-3)执行你编写好的MATLAB程序Q2_11,输入你选定的信号的数学表达式,绘制出的该信号的傅里叶变换的图形如下:Q2-12修改程序Q2_11,并以Q2_12存盘,要求程序能接受从键盘输入信号的时域表达式,计算并绘制信号的时域波形、信号的幅度频谱和相位频谱图。编写的程序Q2_12如下:clear,close allT = 0.01; dw = 0.1; %时间和频率变化的步长t = -10:T:10;w = -4*pi:dw:4*pi;xx= input(Input the signal (t) :);X=xx*exp(-j*t*w)*T; %傅里叶变换X1=abs(X); %计算幅度谱phai=angle(X); %计算相位谱subplot(211);plot(t,xx),title(The original signal x(t),axis(-10,10,-1,2),xlabel(Time t),grid on;subplot(223)plot(w,X1),title(The amplitude of f(jw) ),xlabel(f(jw),grid on;subplot(224);plot(w,phai),title(The phase of f(jw),axis(-pi,pi,-4,4),xlabel(f(jw),grid on;Q2-13选择一个时限信号,执行程序Q2_12以验证-对偶性质。选定适当的信号x1(t),该信号的时域表达式为:x1(t) =u(t+1/2)-u(t-1/2)执行程序Q2_12,绘制出的该信号的傅里叶变换的图形如下:选定适当的信号x2(t),要求其数学表达式与x1(t) 的傅里叶变换的数学表达式相同,该信号的时域表达式为:x2(t) =再一次执行程序Q2_12,绘制出的信号x2(t)的傅里叶变换的图形如下:比较这两次执行的结果,简述对偶性质,并说明验证结论。答:Q2-14选择一个时限信号,执行程序Q2_12以验证性质-时间尺度变换。选定适当的信号x3(t),该信号的时域表达式为:x3(t) =: exp(-t) 执行程序Q2_12,绘制出的该信号的傅里叶变换的图形如下:选定信号x4(t) = x3(2t),该信号的时域表达式为:x4(t) =: exp(-2t) ,再一次执行程序Q2_12,绘制出的信号x4(t)的傅里叶变换的图形如下:比较这两次执行的结果,简述时间尺度变换性质,并说明验证结论。答:Q2-15选择一个时限信号,执行程序Q2_12以验证性质-时移。选定适当的信号x1(t),该信号的时域表达式为:x1(t) = : exp(-t).*u(t) ,执行程序Q2_12,绘制出的该信号的傅里叶变换的图形如下:选定信号x2(t) = x1(t-1),该信号的时域表达式为:x2(t) = : exp(-t+3).*u(t-3) ,再一次执行程序Q2_12,绘制出的信号x2(t) 的傅里叶变换的图形如下:比较这两次执行的结果,简述时移性质,并说明验证结论。答:Q2-16选择一个合适的信号,执行程序Q2_12以验证性质-频移(Multiplication by ejw0t)。选定适当的信号x1(t),该信号的时域表达式为:x1(t) = : exp(-t).*u(t) ,执行程序Q2_12,绘制出的该信号的傅里叶变换的图形如下:选定信号x2(t) = ejw0tx1(t),其中w0 = 2 ,再一次执行程序Q2_12,绘制出的信号x2(t)的傅里叶变换的图形如下:比较这两次执行的结果,简述频移(Multiplication by ejw0t)性质,并说明验证结论。答:
展开阅读全文
相关资源
正为您匹配相似的精品文档
相关搜索

最新文档


当前位置:首页 > 管理文书 > 施工组织


copyright@ 2023-2025  zhuangpeitu.com 装配图网版权所有   联系电话:18123376007

备案号:ICP2024067431-1 川公网安备51140202000466号


本站为文档C2C交易模式,即用户上传的文档直接被用户下载,本站只是中间服务平台,本站所有文档下载所得的收益归上传人(含作者)所有。装配图网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。若文档所含内容侵犯了您的版权或隐私,请立即通知装配图网,我们立即给予删除!