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 /116/CH3/EX3.4 | |
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 '116/CH3/EX3.4')
-rwxr-xr-x | 116/CH3/EX3.4/exa3_4.sce | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/116/CH3/EX3.4/exa3_4.sce b/116/CH3/EX3.4/exa3_4.sce new file mode 100755 index 000000000..eb0c422f7 --- /dev/null +++ b/116/CH3/EX3.4/exa3_4.sce @@ -0,0 +1,23 @@ +//Caption:Program to calculate how many bits per sample can be saved by using DPCM
+
+//Example 3.4
+
+//Page 128
+
+w=800//Omega=800Hz
+
+//x(t)=A sin(2pi.wt), equation for sine wave with maximum amplitude
+
+//x'(t)=A(2pi).w.cos(2pi.wt), diff w.r.t time
+
+(2*%pi)*800*(1/8000)
+
+//0.62831*a, x'(t)max
+
+disp('savings in the bits per sample can be determined as ')
+
+log2(1/0.628)
+
+//Result
+
+//0.67 bits
\ No newline at end of file |