diff options
author | priyanka | 2015-06-24 15:03:17 +0530 |
---|---|---|
committer | priyanka | 2015-06-24 15:03:17 +0530 |
commit | b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (patch) | |
tree | ab291cffc65280e58ac82470ba63fbcca7805165 /40/CH10/EX10.8 | |
download | Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.gz Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.bz2 Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.zip |
initial commit / add all books
Diffstat (limited to '40/CH10/EX10.8')
-rwxr-xr-x | 40/CH10/EX10.8/Exa_10_8.sce | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/40/CH10/EX10.8/Exa_10_8.sce b/40/CH10/EX10.8/Exa_10_8.sce new file mode 100755 index 000000000..994cbe31f --- /dev/null +++ b/40/CH10/EX10.8/Exa_10_8.sce @@ -0,0 +1,27 @@ +//Design of interpolating filters
+//(a)Design using a single stage interpolator
+fp=1.8;Sout=48;Sin=4;
+Ap=0.6;As=50;
+fs=Sin-fp;
+//finding ripple parameters
+delp=(10^(Ap/20)-1)/(10^(Ap/20)+1);
+dels=10^(-As/20);
+N=Sout*(-10*log10(delp*dels)-13)/(14.6*(fs-fp))+1;
+disp('By using single stage interpolator the filter design is:');
+ceil(N)
+//Design using 3-stage interpolator with I1=2;I2=3;I3=2
+Ap=0.2;
+Sin=[4 8 24];
+Sout=[8 24 48];
+fp=[1.8 1.8 1.8];
+fs=Sin-fp;
+delp=(10^(Ap/20)-1)/(10^(Ap/20)+1);
+dels=10^(-As/20);
+p=14.6*(fs-fp);
+N1=((-10*log10(delp*dels)-13)./p);
+N1=(Sout.*N1)+1;N=0;
+for i=1:length(N1)
+ N=N+N1(i);
+end
+disp('By using single stage interpolator the filter design is:');
+ceil(N)
\ No newline at end of file |