summaryrefslogtreecommitdiff
path: root/848/CH7
diff options
context:
space:
mode:
authorpriyanka2015-06-24 15:03:17 +0530
committerpriyanka2015-06-24 15:03:17 +0530
commitb1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (patch)
treeab291cffc65280e58ac82470ba63fbcca7805165 /848/CH7
downloadScilab-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/CH7')
-rwxr-xr-x848/CH7/EX7.1/Example7_1.sce18
-rwxr-xr-x848/CH7/EX7.2/Example7_2.sce15
-rwxr-xr-x848/CH7/EX7.3/Example7_3.jpgbin0 -> 15407 bytes
-rwxr-xr-x848/CH7/EX7.3/Example7_3.sce43
-rwxr-xr-x848/CH7/EX7.4/Example7_4.sce22
5 files changed, 98 insertions, 0 deletions
diff --git a/848/CH7/EX7.1/Example7_1.sce b/848/CH7/EX7.1/Example7_1.sce
new file mode 100755
index 000000000..d0e81351b
--- /dev/null
+++ b/848/CH7/EX7.1/Example7_1.sce
@@ -0,0 +1,18 @@
+//clear//
+//Caption: To find optimum decision threshold
+//Example7.1
+//Page 258
+clear;
+clc;
+close;
+bon = 1;
+boff =0;
+sigma_on = 1;
+sigma_off = 1;
+Q = (bon-boff)/(sigma_on+sigma_off)
+Vth = bon-Q*sigma_on
+disp(Q,'Q parameter value =')
+disp(Vth,'optimum decision threshold Vth =')
+//Result
+//Q parameter value = 0.5
+//optimum decision threshold Vth = 0.5
diff --git a/848/CH7/EX7.2/Example7_2.sce b/848/CH7/EX7.2/Example7_2.sce
new file mode 100755
index 000000000..56ebef637
--- /dev/null
+++ b/848/CH7/EX7.2/Example7_2.sce
@@ -0,0 +1,15 @@
+//clear//
+//Caption: To find out signal-to-noise ratio and probability of error for given 'Q'
+//Example7.2
+//Page 258
+clear;
+clc;
+close;
+Q = 6;
+Pe = (1/2)*(1-erf(Q/sqrt(2)));
+S_N_dB = 10*log10(2*Q);
+disp(Pe,'Probability of error Pe(Q) =')
+disp(S_N_dB,'Signal-to-noise ratio in dB S/N =')
+//Result
+//Probability of error Pe(Q) = 9.866D-10
+//Signal-to-noise ratio in dB S/N = 10.791812
diff --git a/848/CH7/EX7.3/Example7_3.jpg b/848/CH7/EX7.3/Example7_3.jpg
new file mode 100755
index 000000000..85b547f9f
--- /dev/null
+++ b/848/CH7/EX7.3/Example7_3.jpg
Binary files differ
diff --git a/848/CH7/EX7.3/Example7_3.sce b/848/CH7/EX7.3/Example7_3.sce
new file mode 100755
index 000000000..72a65704f
--- /dev/null
+++ b/848/CH7/EX7.3/Example7_3.sce
@@ -0,0 +1,43 @@
+//clear//
+//Caption:Plotting Bit-Error-Rate versus Q factor
+//Example7.3
+//page 259
+clear;
+clc;
+close;
+Q = 0:0.01:8;
+Pe = (1/2)*(1-erf(Q./sqrt(2)));
+a =gca();
+a.data_bounds =[0,1e-16;8,0.5];
+plot(Q,Pe,'r')
+xlabel('Q')
+ylabel('Pe')
+title('BER(Pe) versus the factor Q')
+disp(Pe(1),'Probability of error at Q =0')
+disp(Pe(101),'Probability of error at Q =1')
+disp(Pe(201),'Probability of error at Q =2')
+disp(Pe(301),'Probability of error at Q =3')
+disp(Pe(401),'Probability of error at Q =4')
+disp(Pe(501),'Probability of error at Q =5')
+disp(Pe(601),'Probability of error at Q =6')
+disp(Pe(701),'Probability of error at Q =7')
+disp(Pe(801),'Probability of error at Q =8')
+//Result
+//Probability of error at Q =0
+// 0.5
+//Probability of error at Q =1
+// 0.1586553
+//Probability of error at Q =2
+// 0.0227501
+//Probability of error at Q =3
+// 0.0013499
+//Probability of error at Q =4
+// 0.0000317
+//Probability of error at Q =5
+// 0.0000003
+//Probability of error at Q =6
+// 9.866D-10
+//Probability of error at Q =7
+// 1.280D-12
+//Probability of error at Q =8
+// 6.106D-16
diff --git a/848/CH7/EX7.4/Example7_4.sce b/848/CH7/EX7.4/Example7_4.sce
new file mode 100755
index 000000000..6c9b783b7
--- /dev/null
+++ b/848/CH7/EX7.4/Example7_4.sce
@@ -0,0 +1,22 @@
+//clear//
+//Caption: To find the energy of the photon incident on photodiode
+//and Minimum incident optical power
+//Example7.4
+//page 262
+clear;
+clc;
+close;
+h = 6.626e-34; //planks constant J/s
+C = 3e08; //free space velocity in m/s
+B = 10e06; //data rate 10 Mb/sec
+tuo = 2/B; //1/tuo = half the data rate B
+Lambda = 850e-09; //operating wavelength in nm
+E = 20.7*h*C/Lambda;
+Pi = E/tuo;
+disp(E,'Energy of the incident photon E =')
+disp(Pi,'minimum incident optical power Pi =')
+disp(10*log10(Pi*1000),'minimum incident optical power in dBm =')
+//Result
+// Energy of the incident photon E = 4.841D-18
+// minimum incident optical power Pi = 2.420D-11
+// minimum incident optical power in dBm = - 76.161059