信号与系统学习笔记与代码实现1


1.1.1 连续时间信号与离散时间信号

在数学上,信号可以表示为一个或多个变量的函数。
两种基本类型的信号分别为:连续时间信号与离散时间信号。
matlab示例代码如下所示。
如下所示的正弦信号振幅为1,周期为 2 π w 2\pi \over w w2π等于64。

t=linspace(1,64,64);
y=sin(pi/32*t);
subplot(2,1,1);%表示分成两行一列,并绘制第一个
plot(t,y); 
subplot(2,1,2);%表示分成两行一列,并绘制第二个
stem(t,y);

在这里插入图片描述

t=linspace(1,64,64);
y=sin(pi/32*t);
plot(t,y); 
set(gca,'FontSize',16,'FontName','Times New Roman');%设置坐标轴数字大小字体
xlabel('Iteration','fontsize',16,'FontName','Times New Roman');%设置x轴标签大小字体
ylabel('Amplitude','fontsize',16,'FontName','Times New Roman');%设置y轴标签大小字体
legend('boxoff');%取消函数小标的方框
legend({
   'y(t)'},'FontSize',14,'FontName','Times New Roman');%设置函数小标名称字体大小

在这里插入图片描述

1.1.2 信号的能量和功率

连续时间信号的能量可以定义为:
W = ∫ t 1 t 2 ∣ x ( t ) ∣ 2   d t W=\int_{t_1}^{t_2} \rvert{x(t)}\rvert^2 \,{\rm d}t W=t1t2x(t)2dt
功率为:
P = 1 t 2 − t 1 ∫ t 1 t 2 ∣ x ( t ) ∣ 2   d t P=\frac {1} { {t_2}-{t_1}}\int_{t_1}^{t_2} \rvert{x(t)}\rvert^2 \,{\rm d}t P=t2t11t1t2x(t)2dt
离散时间信号的能量可以定义为:
W = ∑ n = n 1 n 2 ∣ x [ n ] ∣ 2 W=\sum_{n=n_1}^{n_2} \rvert{x[n]} \rvert^2 W=n=n1n2x[n]2
功率为:
P = 1 n 2 − n 1 + 1 ∑ n = n 1 n 2 ∣ x [ n ] ∣ 2 P=\frac {1} { {n_2}-{n_1}+1}\sum_{n=n_1}^{n_2} \rvert{x[n]} \rvert^2 P=n2n1+11n=n1n2x[n]2
可以理解为,将每个点的能量相加取平均,共有n2-n1+1个点。

t=linspace(1,64,64);
y=sin(pi/32*t);
W=sum(y.*y);
P=W/64;

1.2.1 自变量变换

时移变换(time shift),两个信号形状完全相同,但在位置上有一个移位。
y 1 ( t ) = y ( t + 12 ) y_1(t)=y(t+12) y1(t)=y(t+12)
y 2 ( t ) = y ( t − 12 ) y_2(t)=y(t-12) y2(t)=y(t12)
这里 y 1 ( t ) y_1(t) y1(t)超前 y ( t ) y(t) y(t)共12个单位, y 2 ( t ) y_2(t) y2(t)滞后或延迟 y ( t ) y(t) y(t)共12个单位

t=linspace(1,64,64);
y=sin(pi/32*t);
t1=t+12;
y1=sin(pi/32*t1);
t2=t-12;
y2=sin(pi/32*t2);
 plot(t,y,'linewidth',1.0); %设置线宽为1.0
 hold on
 plot(t,y1,'linewidth',1.0); 
 hold on
 plot(t,y2,'linewidth',1.0); 
set(gca,'FontSize',16,'FontName','Times New Roman');%设置坐标轴数字大小字体
xlabel('Iteration','fontsize',16,'FontName','Times New Roman');%设置x轴标签大小字体
ylabel('Amplitude','fontsize',16,'FontName','Times New Roman');%设置y轴标签大小字体
legend('y(t)','y1(t)','y2(t)');%设置函数小标
legend('boxoff');%取消函数小标的方框
legend({
   'y(t)','y1(t)','y2(t)'},'FontSize',14,'FontName','Times New Roman');%设置函数小标名称字体大小

在这里插入图片描述

时间反转(time reversal)
以t=0轴进行反转。
y 1 ( t ) = y ( − t ) y_1(t)=y(-t) y1(t)=y(t)

t=linspace(1,64,64);
y=sin(pi/32*t);
W=sum(y.*y);
P=W/64;
t1=-t;
y1=sin(pi/32*t1);
 plot(t,y,'linewidth',1.0); %设置线宽为1.0
 hold on
 plot(t1,y,'linewidth',1.0); 
set(gca,'FontSize',16,'FontName','Times New Roman');%设置坐标轴数字大小字体
xlabel('Iteration','fontsize',16,'FontName','Times New Roman');%设置x轴标签大小字体
ylabel('Amplitude','fontsize',16,'FontName','Times New Roman');%设置y轴标签大小字体
legend('y(t)','y1(t)');%设置函数小标
legend('boxoff');%取消函数小标的方框
legend({
   'y(t)','y1(t)'},'FontSize',14,'FontName','Times New Roman');%设置函数小标名称字体大小

在这里插入图片描述
时间尺度变换(time scaling)
y 1 ( t ) = y ( 2 t ) y_1(t)=y(2t) y1(t)=y(2t)
y 2 ( t ) = y ( t / 2 ) y_2(t)=y(t/2) y2(t)=y(t/2)

t=linspace(1,64,64);
y=sin(pi/32*t);
t1=2*t;
t2=t/2;
 plot(t,y,'linewidth',1.0); %设置线宽为1.0
 hold on
 plot(t1,y,'linewidth',1.0); 
 hold on
 plot(t2,y,'linewidth',1.0); 
set(gca,'FontSize',16,'FontName','Times New Roman');%设置坐标轴数字大小字体
xlabel('Iteration','fontsize',16,'FontName','Times New Roman');%设置x轴标签大小字体
ylabel('Amplitude','fontsize',16,'FontName','Times New Roman');%设置y轴标签大小字体
legend('y(t)','y1(t)','y2(t)');%设置函数小标
legend('boxoff');%取消函数小标的方框
legend({
   'y(t)','y1(t)','y2(t)'},'FontSize',14,'FontName','Times New Roman');%设置函数小标名称字体大小

在这里插入图片描述
在这里插入图片描述

1.2.2 周期信号

一个周期(periodic)连续时间信号为: x ( t ) = x ( t + T ) x(t)=x(t+T) x(t)=x(t+T),使公式成立的最小周期 T T T 称为基波周期(fundamental period)
周期的离散时间信号为: x [ n ] = x [ n + N ] x[n]=x[n+N] x[n]=x[n+N],基波周期为 N N N

1.2.3 偶信号与奇信号

偶(even)信号定义为:

x ( − t ) = x ( t ) x(-t)=x(t) x(t)=x(t)
x [ − n ] = x [ n ] x[-n]=x[n] x[n]=x[n]

奇(odd)信号定义为:
x ( − t ) = − x ( t ) x(-t)=-x(t) x(t)=x(t)
x [ − n ] = − x [ n ] x[-n]=-x[n]

  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值