武汉理工大学信号与系统实验答案.docx

上传人:b****4 文档编号:6891661 上传时间:2023-05-10 格式:DOCX 页数:12 大小:97.50KB
下载 相关 举报
武汉理工大学信号与系统实验答案.docx_第1页
第1页 / 共12页
武汉理工大学信号与系统实验答案.docx_第2页
第2页 / 共12页
武汉理工大学信号与系统实验答案.docx_第3页
第3页 / 共12页
武汉理工大学信号与系统实验答案.docx_第4页
第4页 / 共12页
武汉理工大学信号与系统实验答案.docx_第5页
第5页 / 共12页
武汉理工大学信号与系统实验答案.docx_第6页
第6页 / 共12页
武汉理工大学信号与系统实验答案.docx_第7页
第7页 / 共12页
武汉理工大学信号与系统实验答案.docx_第8页
第8页 / 共12页
武汉理工大学信号与系统实验答案.docx_第9页
第9页 / 共12页
武汉理工大学信号与系统实验答案.docx_第10页
第10页 / 共12页
武汉理工大学信号与系统实验答案.docx_第11页
第11页 / 共12页
武汉理工大学信号与系统实验答案.docx_第12页
第12页 / 共12页
亲,该文档总共12页,全部预览完了,如果喜欢就下载吧!
下载资源
资源描述

武汉理工大学信号与系统实验答案.docx

《武汉理工大学信号与系统实验答案.docx》由会员分享,可在线阅读,更多相关《武汉理工大学信号与系统实验答案.docx(12页珍藏版)》请在冰点文库上搜索。

武汉理工大学信号与系统实验答案.docx

武汉理工大学信号与系统实验答案

1-1-1

clear

closeall

dt=0.01;(dt=0.2;)

t=-2:

dt:

2;

x=sin(2*pi*t);

plot(t,x)

title('sinusoidalsingnalx(t)')

xlabel('Timet(sec)')

1-2

t=-5:

0.001:

5;

x=exp(-0.5*t).*u(t);

y=exp(-0.5*(1.5*t+3)).*u(1.5*t+3);

subplot(211)

plot(t,x)

title('x(t)')

subplot(212)

plot(t,y)

title('y(t)=x(1,5*t+3)')

1-3

clear;

closeall;

t0=0;t1=3.5;dt=0.001;

t=t0:

dt:

t1;

x1=u(t)-u(t-2);

x2=u(t-1)-u(t-3);

y=dt*conv(x1,x2);

subplot(221)

plot(t,x1)

gridon

title('Signalx1(t)')

axis([t0,t1,0,1.5])

subplot(222)

plot(t,x2)

gridon

title('signalx2(t)')

axis([t0,t1,0,1.5])

subplot(212)

t=t0:

dt:

2*t1;

plot(t,y)

gridon

title('Theconvolutionofx1(t)andx2(t)')

axis([2*t0,2*t1,0,2.5])

xlabel('Timet(sec)')

+

2-1

clear

closeall

num=input('Typeintherightcoeffcientvectorofdifferentialequation:

');

den=input('Typeintheleftcoefficientvectorofdifferentialequation:

');

t=0:

0.01:

10;

x=input('Typeintheexpressionoftheinputsignalx(t):

');

lsim(num,den,x,t)

运行过程:

Typeintherightcoeffcientvectorofdifferentialequation:

8

Typeintheleftcoefficientvectorofdifferentialequation:

[1,3,2]

Typeintheexpressionoftheinputsignalx(t):

(exp(-2*t)-exp(-3*t)).*u(t)

 

 

3-1

clear

closeall

T=2;

dt=0.00001;

t=-2:

dt:

2;

x1=(u(t+1)-u(t-1-dt)).*abs(t);

x=0;

form=-1:

1

x=x+u(t-m*T)-u(t-1-m*T-dt);

end

w0=2*pi/T;

N=10;

L=2*N+1;

fork=-N:

N;

ak(N+1+k)=(1/T)*x1*exp(-j*k*w0*t')*dt;

end

phi=angle(ak);

运行结果:

ak=

Columns1through6

0.0000-0.0000i-0.0025-0.0000i0.0000+0.0000i-0.0041+0.0000i

0.0000+0.0000i-0.0081-0.0000i

Columns7through12

0.0000-0.0000i-0.0225+0.0000i0.0000-0.0000i-0.2026+0.0000i

0.5000-0.2026-0.0000i

Columns13through18

0.0000+0.0000i-0.0225-0.0000i0.0000+0.0000i-0.0081+0.0000i

0.0000-0.0000i-0.0041-0.0000i

Columns19through21

0.0000-0.0000i-0.0025+0.0000i0.0000+0.0000i

3-2

b=input('b=');

a=input('a=');

[H,w]=freqs(b,a);

Hm=abs(H);

phai=angle(H);

hr=real(H);

Hi=imag(H);

subplot(221)

plot(w,Hm)

gridon

title('Magnituderesponse');

xlabel('Frequencyinrad/sec');

subplot(223)

plot(w,phai)

gridon

title('Phaseresponse')

xlabel('Frequencyinrad/sec');

subplot(222)

plot(w,hr),

gridon

title('Realpartoffrequencyresponse')

xlabel('Frequencyinrad/sec');

subplot(224)

plot(w,Hi),

gridon

title('Imaginarypartoffrequencyresponse')

xlabel('Frequencyinrad/sec');

运行过程:

1.b=[1,0]

a=[1,1,25]

2.

b=[1,-1]

a=[1,1]

3.

b=[262]

a=[1,10,48,148,306,401,262]

4-1

clear

closeall

a=-0:

0.1:

5;

b=-20:

0.1:

20;

[a,b]=meshgrid(a,b);

c=a+i*b;

c=(1-exp(-2*(c+eps)))./(c+eps);

c=abs(c);

subplot(211)

mesh(a,b,c);

surf(a,b,c);

view(-60,20)

axis([0,5,-20,20,0,2]);

title('TheLaplacetransformoftherectangularpulse');

w=-20:

0.1:

20;

Fw=(2*sin(w+eps).*exp(i*(w+eps)))./(w+eps);

subplot(212)

plot(w,abs(Fw))

title('TheFouriertransformoftherectangularpulse')

xlabel('Frequencyw')

4-2

clear

closeall

b=[0,1/16,0,1];

a=[1,2,2,1];

splane(b,a)

title('Thezero-polediagram')

附:

functionsplane(num,den)

p=roots(den);

q=roots(num);

p=p';

q=q';

x=max(abs([p,q]));

x=x+1;

y=x;

plot([-x,x],[0,0],':

');

holdon;

plot([0,0],[-y,y],':

');

holdon;

plot(real(p),imag(p),'x');

holdon;

plot(real(q),imag(q),'o');

holdon;

title('zero-poleplot');

xlabel('Realpart');

ylabel('Imaginalpart');

axis([-x,x,-y,y]);

(a=0.6)(a=16)

(a=0.8)(a=4)

5-2

clear

closeall

tmax=4;

dt=0.01;

t=0:

dt:

tmax;

Ts=1/10;

ws=2*pi/Ts;

w0=20*pi;

dw=0.1;

w=-w0:

dw:

w0;

n=0:

1:

tmax/Ts;

x=exp(-4*t).*u(t);

xn=exp(-4*n*Ts);

subplot(221)

plot(t,x);

title('Acontinuous-timesingnalx(t)');

xlabel('Timet');

axis([0,tmax,0,1]);

gridon

subplot(223)

stem(n,xn,'.');

title('Thesampledversionx[n]ofx(t)');

xlabel('Timeindexn');

axis([0,tmax/Ts,0,1]);

gridon

Xa=x*exp(-j*t'*w)*dt;

X=0;

fork=-8.8;

X=X+x*exp(-j*t'*(w-k*ws))*dt;

end

subplot(222)

plot(w,abs(Xa))

title('Magnitudespctrumofx(t)');

gridon;

axis([-60,60,0,1.8*max(abs(Xa))])

subplot(224)

plot(w,abs(X))

title('Magnitudespctrumofx(n)');

xlabel('Frequencyinradians/s');

gridon

axis([-60,60,0,1.8*max(abs(Xa))])

(Ts=1/2)(Ts=1/5)

(Ts=1/7)(Ts=1/10)

展开阅读全文
相关资源
猜你喜欢
相关搜索
资源标签

当前位置:首页 > IT计算机 > 电脑基础知识

copyright@ 2008-2023 冰点文库 网站版权所有

经营许可证编号:鄂ICP备19020893号-2