%Generation Step of C-T Signal
t =0:0.01:250;          %Generate the vector t for horizontal axis that contains
                        %the time values for which x values will be calculated, stored 
                        %and plotted depending on the elements in the vector t.
x1 = exp(-.02*t);       %Generate the first vector of the output containing 
                        %the values of the expression exp(-0.2*t).
x2 = sin((7*pi*t)/250);   %Generate the second vector of the output containing 
                        %the values of the expression sin((7*pi*t)/8).
x = x1.*x2;             %the resulting vector x must be multiplied element-by-element
                        %(multiplication of two output vectors), so we must 
                        %use the dot before the multiplication operator.

%Plotting Step of C-T Signal

%plotting the Exponential Signal
subplot(3,1,1);
plot(t,x1,'r');
axis auto;
grid
xlabel('Time (Sec)');
ylabel ('Amplitude');
legend('Exponential Signal');
title('Plotting the C-T Signals using Matlab');
%plotting the Sinusoidal Signal
subplot(3,1,2);
plot(t,x2,'b');
axis auto;
grid
xlabel('Time (Sec)');
ylabel ('Amplitude');
legend('Sinusoidal Signal');
%plotting the Damped Exponential Signal
subplot(3,1,3);
plot(t,x,'g');
axis auto;
grid
xlabel('Time (Sec)');
ylabel ('Amplitude');
legend('Damped Exponential Signal');
