信号在MATLAB中的运算——连续信号的尺度变换
连续信号的尺度变换
连续时间信号的尺度变换,是指将信号的横坐标进行扩展或者压缩,即将信号 f(t) 的自变量 t 更换为 at,当 a>1 时,信号 f(at) 以原点为基准,沿时间轴压缩到原来的1/a ;当 a<1 时,信号 f(at) 沿时间轴扩展到原来的 1/a 倍;
1、矩形波的尺度变换示例
% E_5_13.m
% 矩形波的尺度变换示例
clear, clc, clf;
t = -4:0.001:4;
T = 2;
f = rectpuls(t,T);
subplot(311); plot(t,f);
axis([-4,4, -0.5,1.5]); title('原序列'); grid on;
xlabel('t'); ylabel('f(t)');
ft = rectpuls(2*t,T);
subplot(312); plot(t,ft);
axis([-4,4, -0.5,1.5]); title('2t后的序列'); grid on;
xlabel('t'); ylabel('f(2t)');
ft2 = rectpuls(0.5*t,T);
subplot(313); plot(t,ft2);
axis([-4,4, -0.5,1.5]); title('0.5t后的序列'); grid on;
xlabel('t'); ylabel('f(0.5t)');
2、三角波的尺度变换
% E_5_14.m
% 三角波的尺度变换
figure
t = -5:0.001:5;
ft = tripuls(t,4,0.5);
subplot(311); plot(t,ft);
title('原序列'); grid on;
xlabel('t'); ylabel('f(2t)');
ft = tripuls(3*t,4,0.5);
subplot(312); plot(t,ft);
title('3t后的序列'); grid on;
xlabel('t'); ylabel('f(3t)');
ft2 = tripuls(0.5*t,4,0.5);
subplot(313); plot(t,ft2);
title('0.5t后的序列'); grid on;
xlabel('t'); ylabel('f(0.5t)');