Professional Documents
Culture Documents
(EC2156)
EXPERIMENT 1
Aim:
To plot the exponential signal for different values of a for the given
equation
x(n)=an
(i)
(ii)
(iii)
(iv)
0<a<1
-1<a<0
a>1
a<-1
Program:
clc;
clear all;
close all;
n=0:20;
a1=input('Enter the value of a in 0<a<1 : ');
x=a1.^n;
a2=input('Enter the value of a in -1<a<0 : ');
y=a2.^n;
a3=input('Enter the value of a>1 : ');
z=a3.^n;
Input:
Enter the value of a in 0<a<1 : 0.5
Enter the value of a in -1<a<0 : -0.5
Enter the value of a>1 : 5
Enter the value of a<-1 : -5
Result:
Conclusion: Plotted the exponential signal for different values of a using MATLAB
and obtained the results.