Download as pdf or txt
Download as pdf or txt
You are on page 1of 2

%Time shifting on operation on sinusoidal signal

cc

f = 1000;
T = 1/f;
t = -T:T/f:T;
x = sin(2*pi*f*t);

t1 = t-T/2;
t2 = t+T/4;
x1 = sin(2*pi*f*t1);
x2 = sin(2*pi*f*t2);

subplot(3,1,1)
plot(t,x)
grid
xlabel('Time - t')
ylabel('amplitude')
title('Sinusoidal signal x(t) - 21075A1008')
axis( [-T T -1.2 1.2] )

subplot(3,1,2)
plot(t,x1)
grid
xlabel('Time - t')
ylabel('amplitude')
title('Delayed Sinusoidal signal x(t) - 21075A1008')
axis( [-T T -1.2 1.2] )

subplot(3,1,3)
plot(t,x2)
grid
xlabel('Time - t')
ylabel('amplitude')
title('Advanced Sinusoidal signal x(t) - 21075A1008')
axis( [-T T -1.2 1.2] )

1
Published with MATLAB® R2020a

You might also like