实验1高频电子线路.docx
《实验1高频电子线路.docx》由会员分享,可在线阅读,更多相关《实验1高频电子线路.docx(11页珍藏版)》请在冰豆网上搜索。
实验1高频电子线路
分析理想采样信号序列的特性。
>>n=0:
50;
A=444.128;
a=50*sqrt(2.0)*pi;
T=0.001;
w0=50*sqrt(2.0)*pi;
x=A*exp(-a*n*T).*sin(w0*n*T);
closeall;
subplot(1,1,1);stem(n,x);
title('理想采样信号序列')
>>n=0:
50;
A=444.128;
a=50*sqrt(2.0)*pi;
T=0.0033;
w0=50*sqrt(2.0)*pi;
x=A*exp(-a*n*T).*sin(w0*n*T);
closeall;
subplot(1,1,1);stem(n,x);
title('理想采样信号序列')
n=0:
50;
A=444.128;
a=50*sqrt(2.0)*pi;
T=0.0050;
w0=50*sqrt(2.0)*pi;
x=A*exp(-a*n*T).*sin(w0*n*T);
closeall;
subplot(1,1,1);stem(n,x);
title('理想采样信号序列')
2
(1)
>>n=1:
50;
>>A=1;a=0.4;w0=2.0734;T=1;
>>x=A*exp(-a*n*T).*sin(w0*n*T);
>>closeall
>>subplot(3,1,1);stem(n,x);
>>title('理想采样信号序列')
>>k=-25:
25;
>>W=(pi/12.5)*k;
>>X=x*(exp(-j*pi/12.5)).^(n'*k);
>>magX=abs(X);
>>subplot(3,1,2);stem(k,magX);title('理想采样信号序列的幅度谱');
>>angX=angle(X);
>>subplot(3,1,3);stem(k,angX);title('理想采样信号序列的相位谱')
>>n=1:
50;
x=zeros(1,50);
x
(1)=1;x
(2)=2.5;x(3)=2.5;x(4)=1;
closeall;subplot(3,1,1);stem(x);title('特定冲激串');
k=-25:
25;X=x*(exp(-j*pi/12.5)).^(n'*k);
magX=abs(X);
subplot(3,1,2);stem(magX);title('特定冲激串的幅度谱');
angX=angle(X);
subplot(3,1,3);stem(angX);title('特定冲激串的相位谱')
(2)
n=1:
50;
hb=zeros(1,50);
hb
(1)=1;hb
(2)=2.5;hb(3)=2.5;hb(4)=1;
closeall;subplot(3,1,1);stem(hb);title('系统(hb[n]');
m=1:
50;T=0.001;
A=444.128;a=50*sqrt(2.0)*pi;
w0=50*sqrt(2.0)*pi;
x=A*exp(-a*m*T).*sin(w0*m*T);
subplot(3,1,2);stem(x);title('输入信号x[n]');
y=conv(x,hb);
subplot(3,1,3);stem(y);title('输出信号y[n]')
n=1:
50;
hb=zeros(1,50);
hb
(1)=1;hb
(2)=2.5;hb(3)=2.5;hb(4)=1;
closeall;subplot(3,1,1);stem(hb);title('系统(hb[n]');
m=1:
50;T=1;
A=1;a=0.4;
w0=2.0734;
x=A*exp(-a*m*T).*sin(w0*m*T);
subplot(3,1,2);stem(x);title('输入信号x[n]');
y=conv(x,hb);
subplot(3,1,3);stem(y);title('输出信号y[n]')
n=1:
50;
hb=zeros(1,50);
hb
(1)=1;hb
(2)=2.5;hb(3)=2.5;hb(4)=1;
closeall;subplot(3,1,1);stem(hb);title('系统(hb[n]');
m=1:
50;T=1;
A=1;a=0.4;
w0=1.2516;
x=A*exp(-a*m*T).*sin(w0*m*T);
subplot(3,1,2);stem(x);title('输入信号x[n]');
y=conv(x,hb);
subplot(3,1,3);stem(y);title('输出信号y[n]')
2
k=-25:
25;X=x*(exp(-j*pi/12.5)).^(n'*k);
magX=abs(X);
subplot(3,2,1);stem(magX);title('输入信号的幅度谱');
angX=angle(X);
subplot(3,2,2);stem(angX);title('输入信号的相位谱x[n]');
Hb=hb*(exp(-j*pi/12.5)).^(n'*k);
magHb=abs(Hb);
subplot(3,2,3);stem(magHb);title('系统响应的幅度谱');
angHb=angle(Hb);
subplot(3,2,4);stem(magHb);title('系统响应的相位谱');
n=1:
99;k=1:
99;
Y=y*(exp(-j*pi/12.5)).^(n'*k);
magY=abs(Y);
subplot(3,2,5);stem(magY);title('输出信号的幅度谱');
angY=angle(Y);
subplot(3,2,6);stem(angY);title('输出信号的相位谱');
XHb=X.*Hb;
Subplot(2,1,1);stem(abs(XHb));title('x(n)的幅度谱与hb(n)的幅度谱相乘')
Subplot(2,1,2);stem(abs(Y));title('y(n)的幅度谱');axis([0,60,0,8000])