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 /848/CH1/EX1.5/Example1_5.sce | |
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 '848/CH1/EX1.5/Example1_5.sce')
-rwxr-xr-x | 848/CH1/EX1.5/Example1_5.sce | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/848/CH1/EX1.5/Example1_5.sce b/848/CH1/EX1.5/Example1_5.sce new file mode 100755 index 000000000..d79345b24 --- /dev/null +++ b/848/CH1/EX1.5/Example1_5.sce @@ -0,0 +1,20 @@ +//clear//
+//Caption:Capacity of a channel using shannon's formula
+//Example1.5
+//page 12
+clear;
+clc;
+close;
+fLow = 3*(10^6); //low frequency = 3MHz
+fHigh = 4*(10^6); //hihg frequency = 4MHz
+S_N_dB = 20; //signal-to-noise ratio 20 dB
+S_N = 10^(S_N_dB/10);
+B = fHigh - fLow;
+C = B*log2(1+S_N);
+disp(B,'Bandwidth in Hz B = ')
+disp(C,'Capacity of a channel in bits/secs C =')
+disp(S_N,'signal to noise ratio S/N = ')
+//Result
+// Bandwidth in Hz B = 1000000.
+// Capacity of a channel in bits/secs C = 6658211.5
+// signal to noise ratio S/N = 100.
|