diff options
author | prashantsinalkar | 2017-10-10 12:27:19 +0530 |
---|---|---|
committer | prashantsinalkar | 2017-10-10 12:27:19 +0530 |
commit | 7f60ea012dd2524dae921a2a35adbf7ef21f2bb6 (patch) | |
tree | dbb9e3ddb5fc829e7c5c7e6be99b2c4ba356132c /2279/CH4/EX4.30 | |
parent | b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (diff) | |
download | Scilab-TBC-Uploads-7f60ea012dd2524dae921a2a35adbf7ef21f2bb6.tar.gz Scilab-TBC-Uploads-7f60ea012dd2524dae921a2a35adbf7ef21f2bb6.tar.bz2 Scilab-TBC-Uploads-7f60ea012dd2524dae921a2a35adbf7ef21f2bb6.zip |
initial commit / add all books
Diffstat (limited to '2279/CH4/EX4.30')
-rw-r--r-- | 2279/CH4/EX4.30/Ex4_30.sce | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/2279/CH4/EX4.30/Ex4_30.sce b/2279/CH4/EX4.30/Ex4_30.sce new file mode 100644 index 000000000..83912f6d8 --- /dev/null +++ b/2279/CH4/EX4.30/Ex4_30.sce @@ -0,0 +1,33 @@ +//Example 4.30
+//Cascade connection of systems
+clc
+clear
+n=0:10;
+h11=[1 -0.5];
+for i=1:length(n)
+ h2(i)=0.5^n(i);
+ if (n(i)==0) then
+ h1(i)=1;
+ elseif n(i)==1 then
+ h1(i)=-0.5
+ else
+ h1(i)=0;
+ end
+end
+h=convol(h11,h2);
+n2=0:11;
+//assume x[n]=[1 1 1]
+n1=0:2;
+x=[1 1 1];
+n3=0:13;
+y=convol(x,h);
+subplot(3,1,1);
+plot(n1,x,'.');
+xtitle("Input Signal x[n]","n","x[n]")
+subplot(3,1,2);
+plot(n2,h,'.');
+xtitle("Impulse Response h[n]","n","h[n]")
+subplot(3,1,3);
+plot(n3,y,'.');
+xtitle("Output Signal y[n]","n","y[n]")
+disp("the given system is an invertible system");
|