diff options
author | hardythe1 | 2015-04-07 16:03:32 +0530 |
---|---|---|
committer | hardythe1 | 2015-04-07 16:03:32 +0530 |
commit | ba4d7bfd00d268a9a5fbdee8938f9a4b5a04851d (patch) | |
tree | fcc60b142916d4a738807d3de7ed170b3f9818f6 /Optical_Fiber_Communications_Principles_and_Practice | |
parent | 92cca121f959c6616e3da431c1e2d23c4fa5e886 (diff) | |
parent | 121f6027864eec574ad581705eb277e19120720c (diff) | |
download | Python-Textbook-Companions-ba4d7bfd00d268a9a5fbdee8938f9a4b5a04851d.tar.gz Python-Textbook-Companions-ba4d7bfd00d268a9a5fbdee8938f9a4b5a04851d.tar.bz2 Python-Textbook-Companions-ba4d7bfd00d268a9a5fbdee8938f9a4b5a04851d.zip |
add/modify/remove book
Diffstat (limited to 'Optical_Fiber_Communications_Principles_and_Practice')
-rwxr-xr-x | Optical_Fiber_Communications_Principles_and_Practice/Chapter_12.ipynb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Optical_Fiber_Communications_Principles_and_Practice/Chapter_12.ipynb b/Optical_Fiber_Communications_Principles_and_Practice/Chapter_12.ipynb index 38f7d751..38f16b21 100755 --- a/Optical_Fiber_Communications_Principles_and_Practice/Chapter_12.ipynb +++ b/Optical_Fiber_Communications_Principles_and_Practice/Chapter_12.ipynb @@ -379,7 +379,7 @@ { "cell_type": "code", "collapsed": false, - "input": "%pylab inline\nimport math\nfrom pylab import *\nfrom numpy import *\n\n#Variable declaration\nacr=1 #connector loss in dB\nafc=5 #loss per kilometer in dB\nLbu=0.1 #fiber length between each of the access couplers\nLac=1 #insertion loss\nLtr=10 #loss due to the tap ratio\nLsp=3 #splitting loss\n \n#Calculating, we get two equation in terms of N, no of nodes, i.e C(1,N-1)=(3.5*N)+8.5 and C(star)=4.5+(10*log10(N)) \n\n#For Bus distribution system\n\nfor N in range(1,13,1):\n C=(3.5*N)+8.5;\n a=plot(N,C,'.r')\n \n \n#for Star distribution system\n \nfor N in range(1,30,1):\n C1=4.5+(10*log10(N));\n b=plot(N,C1,'.g')\n \n \n#To show plot in same graph\n#Graphical comparison showing total channel loss against number of nodes\n\nplt.annotate('Linear Bus',xy=(10, 43.5), xytext=(11, 40))\nplt.annotate('Star',xy=(16, 15), xytext=(17, 13))\nxlabel(\"Number of nodes $N$\")\nylabel(\"Total channel loss $CL$ (dB)\")\ntitle(\"Characteristics showing the total channel loss against the number of nodes\")\ngrid()\nshow(a)\nshow(b)\n", + "input": "%matplotlib inline\nimport math\nfrom pylab import *\nfrom numpy import *\n\n#Variable declaration\nacr=1 #connector loss in dB\nafc=5 #loss per kilometer in dB\nLbu=0.1 #fiber length between each of the access couplers\nLac=1 #insertion loss\nLtr=10 #loss due to the tap ratio\nLsp=3 #splitting loss\n \n#Calculating, we get two equation in terms of N, no of nodes, i.e C(1,N-1)=(3.5*N)+8.5 and C(star)=4.5+(10*log10(N)) \n\n#For Bus distribution system\n\nfor N in range(1,13,1):\n C=(3.5*N)+8.5;\n a=plot(N,C,'.r')\n \n \n#for Star distribution system\n \nfor N in range(1,30,1):\n C1=4.5+(10*log10(N));\n b=plot(N,C1,'.g')\n \n \n#To show plot in same graph\n#Graphical comparison showing total channel loss against number of nodes\n\nplt.annotate('Linear Bus',xy=(10, 43.5), xytext=(11, 40))\nplt.annotate('Star',xy=(16, 15), xytext=(17, 13))\nxlabel(\"Number of nodes $N$\")\nylabel(\"Total channel loss $CL$ (dB)\")\ntitle(\"Characteristics showing the total channel loss against the number of nodes\")\ngrid()\nshow(a)\nshow(b)\n", "language": "python", "metadata": {}, "outputs": [ |