# Verification of Linearity and time in-variance  properties of a given continuous/discrete system

Aim: To compute linearity and time in-variance properties of a given continuous /discrete system

EQUIPMENTS:

PC with windows (95/98/XP/NT/2000).

MATLAB Software

THEORY:

LINEARITY PROPERTY:

Any system is said to be linear if it satisfies the superposition principal

superposition principal state that Response to a weighted sum of input signal equal to the corresponding weighted sum of the outputs of the system to each of the individual input signals

X(n)-----------input signal

Y(n) --------- output signal

Y(n)=T[x(n)]

Y1(n)=T[X1(n)] : Y2(n)=T[X2(n)]

x3=[a X1(n)] +b [X2(n) ]

Y3(n) = T [x3(n)]

= T [a X1(n)] +b [X2(n) ] = a Y1(n)+ b [X2(n) ]= Z3(n)

Let a [Y1(n)]+ b [X2(n) ] =Z 3(n)

If Y3(n )- Z 3(n)=0 then the system is stable other wise it is not stable.

Program-1:

``````clc;
clear all;
close all;
n=0:40; a=2; b=1;
x1=cos(2*pi*0.1*n);
x2=cos(2*pi*0.4*n);
x=a*x1+b*x2;
y=n.*x;
y1=n.*x1;
y2=n.*x2;
yt=a*y1+b*y2;
d=y-yt;
d=round(d)
if d
disp('Given system is not satisfy linearity property');
else
disp('Given system is satisfy linearity property');
end
subplot(3,1,1), stem(n,y); grid
subplot(3,1,2), stem(n,yt); grid
subplot(3,1,3), stem(n,d); grid``````

Output:

Result: d=0 so the it displays the output is 'Given system is satisfy linearity property'

Program-2

``````clc;
clear all;
close all;
n=0:40; a=2; b=-3;
x1=cos(2*pi*0.1*n);
x2=cos(2*pi*0.4*n);
x=a*x1+b*x2;
y=x.^2;
y1=x1.^2;
y2=x2.^2;
yt=a*y1+b*y2;
d=y-yt;
d=round(d);
if d
disp('Given system is not satisfy linearity property');
else
disp('Given system is satisfy linearity property');
end
subplot(3,1,1), stem(n,y); grid
subplot(3,1,2), stem(n,yt); grid
subplot(3,1,3), stem(n,d); grid``````

output:

Result: The d is not equal to zero, so the output displays ' Given system is not satisfy linearity property'

Program-3:

Program

``````clc;
close all;
clear all;
x=input('enter the sequence');
N=length(x);
n=0:1:N-1;
y=xcorr(x,x);
subplot(3,1,1);
stem(n,x);
xlabel(' n----->');ylabel('Amplitude--->');
title('input seq');
subplot(3,1,2);
N=length(y);
n=0:1:N-1;
stem(n,y);
xlabel('n---->');ylabel('Amplitude----.');
title('autocorr seq for input');
disp('autocorr seq for input');
disp(y)
p=fft(y,N);
subplot(3,1,3);
stem(n,p);
xlabel('K----->');ylabel('Amplitude--->');
title('psd of input');
disp('the psd fun:');
disp(p)``````

LINEAR TIME INVARIENT SYSTEMS (LTI):

A system is called time invariant if its input – output characteristics do not change with time.

X(t)---- input : Y(t) ---output

X(t-T) -----delay input by T seconds : Y(t-T) ------ Delayed output by T seconds

Program-1:

``````clc;
close all;
clear all;
n=0:40;
D=10;
x=3*cos(2*pi*0.1*n)-2*cos(2*pi*0.4*n);
xd=[zeros(1,D) x];
y=n.*xd(n+D);
n1=n+D;
yd=n1.*x;
d=y-yd;
if d
disp('Given system is not satisfy time shifting property');
else
disp('Given system is satisfy time shifting property');
end
subplot(3,1,1),stem(y),grid;
subplot(3,1,2),stem(yd),grid;
subplot(3,1,3),stem(d),grid;``````

Output:

Result:  d is not equal to zero so the output displays 'Given system is not satisfy time shifting property'.

Program-2:

``````clc;
close all;
clear all;
n=0:40;
D=10;
x=3*cos(2*pi*0.1*n)-2*cos(2*pi*0.4*n);
xd=[zeros(1,D) x];
x1=xd(n+D);
y=exp(x1);
n1=n+D;
yd=exp(xd(n1));
d=y-yd;
if d
disp('Given system is not satisfy time shifting property');
else
disp('Given system is satisfy time shifting property');
end
subplot(3,1,1),stem(y),grid;
subplot(3,1,2),stem(yd),grid;
subplot(3,1,3),stem(d),grid;``````

Output:

Result: d=0 so output displays 'Given system is satisfy time shifting property'.

CONCLUSION: In this experiment Linearity and Time in-variance property of given system has bees verified performed Using MATLAB

Applications:it is used to measure the degree to which the two signals are similar and it is also used for radar detection by estimating the time delay.it is also used in Digital communication defense applications and sound navigation

• Created
Dec 08, 2019
• Updated
Mar 01, 2020
• Views
409
You May Like