Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronic Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Register Log in

Testing shift invariant system help

Status
Not open for further replies.

lesgoodfella

Newbie level 2
Joined
Sep 13, 2009
Messages
2
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,293
I need help in testing whether or not a system in time-invariant, the problem is, i don't know how to enter the system into matlab.

this is the system:

y(n) = n*x(n)+x(n-1)

then i want to shift it by 10 and compare the output.
This is my program and i get errors:
n = 0:40; D = 10;a = 3.0;b = -2;
x = a*cos(2*pi*0.1*n) + b*cos(2*pi*0.4*n);
n1 = n-1;
x1 = a*cos(2*pi*0.1*n1) + b*cos(2*pi*0.4*n1);
xd = [zeros(1,D) x];
xd1 = [zeros(1,D) x1];
y = n.*x+x1;
yd = n.*xd+xd1;
d = y - yd(1+D:41+D);

is there an easier way to do this?
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Top