GENERATION OF ALL SIGNALS

clc;
close all;
clear all;
t=0:.001:2*pi;
y=10*sin(t);
subplot(3,2,1);
plot(t,y);
xlabel('Time');
ylabel('Amplitude');
title('Sinusoidal Wave');
a=0:10;
subplot(3,2,2);
plot(a,a);
xlabel('Time');
ylabel('Amplitude');
title('Ramp Function');
t=0:.01:6;
y=10*exp(t);
subplot(3,2,3);
plot(t,y);
xlabel('Time');
ylabel('Amplitude');
title('Exponential Function');
z=5*exp(-t);
subplot(3,2,4);
plot(t,z);
xlabel('Time');
ylabel('Amplitude');
title('Exponential Function');
x=0:1:6;
y=1.^x;
subplot(3,2,5);
plot(x,y);
xlabel('Time');
ylabel('Amplitude');
title('Unit Step');
x=[0];
y=[2];
subplot(3,2,6);
stem(x,y);
xlabel('Time');
ylabel('Amplitude');
title('Impulse Function');

Output:

No comments:

Post a Comment