summaryrefslogtreecommitdiff
path: root/Fiber_Optics_Communication_by_H_Kolimbiris/12-Optical_Systems_.ipynb
diff options
context:
space:
mode:
Diffstat (limited to 'Fiber_Optics_Communication_by_H_Kolimbiris/12-Optical_Systems_.ipynb')
-rw-r--r--Fiber_Optics_Communication_by_H_Kolimbiris/12-Optical_Systems_.ipynb1754
1 files changed, 1754 insertions, 0 deletions
diff --git a/Fiber_Optics_Communication_by_H_Kolimbiris/12-Optical_Systems_.ipynb b/Fiber_Optics_Communication_by_H_Kolimbiris/12-Optical_Systems_.ipynb
new file mode 100644
index 0000000..9efbcbb
--- /dev/null
+++ b/Fiber_Optics_Communication_by_H_Kolimbiris/12-Optical_Systems_.ipynb
@@ -0,0 +1,1754 @@
+{
+"cells": [
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# Chapter 12: Optical Systems "
+ ]
+ },
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.10: Calculate_chromatic_dispersio.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 444\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"L=200; //in km\n",
+"dL=1550; //in nm\n",
+"R=10; //in Gb/s\n",
+"Cd=17; //in ps/nm-km\n",
+"w=0.1; //Assused bandwidth\n",
+"Cd200=Cd*L;\n",
+"printf('\n Dispersion by 200km ofc = %0.1f*10^3 ps/nm',Cd200/10^3);\n",
+"TCd=w*Cd200;\n",
+"printf('\n total chromatic dispersion = %0.2f*10^3 ps',TCd/10^3);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.11: Calculate_dispersion_penalty.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 480\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"L=1.5; //in km\n",
+"Ls=L/3; //in km\n",
+"BwF=600; //in MHz\n",
+"fb=1; //in Gbps\n",
+"Bdlaser=0.71*BwF*L^-0.7*Ls^-0.25;\n",
+"printf('Laser bandwidth is %0.0f MHz',Bdlaser); //Answer in book is approx\n",
+"mD=0.85*(fb*10^3/Bdlaser)^2;\n",
+"printf('\n Mean dispersion penalty is %0.1f dB',mD); //Answer in book is approx"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.12: Calculate_maximum_length.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 481\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"E=0.182; //from table 12-11 for 2dB dispersion penalty\n",
+"fb=622; //in Mb/s\n",
+"dl=4; //in nm\n",
+"ofdisp=3; //in ps/km-nm\n",
+"Dmax=E/(10^-6*fb*dl);\n",
+"printf('\n Dmax is %0.1f ps/nm',Dmax); \n",
+"Lmax=Dmax/ofdisp;\n",
+"printf('\n Maximum link distance is %0.1f km',Lmax); \n",
+"//Answer in the book is rounded"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.13: Calculate_the_maximum_length_of_optical_link.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 481\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"E=0.115; //from table 12-11 for 2dB dispersion penalty\n",
+"fb=622; //in Mb/s\n",
+"dl=4; //in nm\n",
+"ofdisp=3; //in ps/km-nm\n",
+"Dmax=E/(10^-6*fb*dl);\n",
+"printf('\n Dmax is %0.1f ps/nm',Dmax); \n",
+"Lmax=Dmax/ofdisp;\n",
+"printf('\n Maximum link distance is %0.1f km',Lmax); \n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.14: Calculate_maximum_dispersion_mean_link_margin_sigma_link_margin.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 481\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"mc=0.4; //in dB\n",
+"sc=0.0; //in dB\n",
+"dmax=2.8; //in dB\n",
+"mt=-4.9; //in dBm\n",
+"st=0.5; //in dBm\n",
+"mr=-38.1; //in dBm\n",
+"sr=0.48; //in dBm\n",
+"mco=0.35; //in dB\n",
+"sco=0.20; //in dB\n",
+"ms=0.2; //in dB\n",
+"ss=0.1; //in dB\n",
+"E=0.182; //from table 12-11 for 2dB dispersion penalty\n",
+"fb=156; //in Mb/s\n",
+"dl=4; //in nm\n",
+"ofdisp=2.8; //in ps/nm-km\n",
+"Nco=7;\n",
+"mD=2;\n",
+"sD=0.1;\n",
+"sH=2;\n",
+"sCR=0.25;\n",
+"Ns=4;\n",
+"mH=0;\n",
+"mCR=0.5;\n",
+"L=50;\n",
+"Ls=10;\n",
+"Dmax=E/(10^-6*fb*dl);\n",
+"printf('\n Dmax is %0.0f ps/nm\n',Dmax); \n",
+"Lmax=Dmax/ofdisp;\n",
+"printf('\n Maximum link distance is %0.0f km\n',Lmax); \n",
+"mM=mt-mr-(mc*L+mco*Nco+ms*Ns+mD+mH+mCR);\n",
+"printf('\n Mean link margin is %0.2f dB\n',mM); \n",
+"sM=sqrt(st^2+sr^2+sc^2*L*Ls+sco^2*Nco+sD^2*sH^2+sCR^2);\n",
+"printf('\n Sigma link margin is %0.3f dB\n',sM); \n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.15: Compute_maximum_dispersion_and_nominal_distribution.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 483\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"E=0.115; \n",
+"fb=622; //in Mb/s\n",
+"dl=4; //in nm\n",
+"mt=0.1; //in dBm\n",
+"mr=-31.5; //in dBm\n",
+"mc=0.41; //in dB\n",
+"L=25;\n",
+"mco=0.12; //in dB\n",
+"Nco=2;\n",
+"ms=0.15; //in dB\n",
+"Ns=4;\n",
+"mD=1;\n",
+"mH=0;\n",
+"mCR=0;\n",
+"\n",
+"sc=0.0; //in dB\n",
+"st=-0.15; //in dBm\n",
+"sr=0.3; //in dBm\n",
+"sco=0.08; //in dB\n",
+"ss=0.1; //in dB\n",
+"ofdisp=2.8; //in ps/nm-km\n",
+"sD=2;\n",
+"sH=0;\n",
+"sCR=0.0;\n",
+"Ls=12;\n",
+"\n",
+"Dmax=E/(10^-6*fb*dl);\n",
+"printf('\n Dmax is %0.2f ps/nm\n',Dmax); \n",
+"Lmax=Dmax/ofdisp;\n",
+"printf('\n Maximum link distance is %0.1f km\n',Lmax); //in book 4 is misprint for solving \n",
+"mM=mt-mr-(mc*L+mco*Nco+ms*Ns+mD+mH+mCR);\n",
+"printf('\n Mean link margin is %0.1f dB\n',mM); //wrong in book\n",
+"L=60;\n",
+"Ls=12; \n",
+"sM=sqrt(st^2+sr^2+sc^2*L*Ls+sco^2*Nco+ss^2*Ns+sD^2*sH^2+sCR^2);\n",
+"printf('\n Sigma link margin is %0.2f dB\n',sM); \n",
+"spm=mM-2*sM-1;\n",
+"printf('\n System power margin is %0.2f dB\n',spm); //answer is slighty difeerent due to mM=19.5\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.16: Calculate_maximum_dispersion_and_maximum_distance.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 484\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"E=0.115; \n",
+"fb=1062; //in Mb/s\n",
+"dl=6; //in nm\n",
+"mt=-8; //in dBm\n",
+"mr=28.7; //in dBm\n",
+"mc=0.4; //in dB\n",
+"L=5;\n",
+"mco=0.12; //in dB\n",
+"Nco=8;\n",
+"ms=0.2; //in dB\n",
+"Ns=4;\n",
+"mD=1;\n",
+"mH=0;\n",
+"mCR=1;\n",
+"\n",
+"sc=0.0; //in dB\n",
+"st=0.6; //in dBm\n",
+"sr=0.75; //in dBm\n",
+"sco=0.08; //in dB\n",
+"ss=0.1; //in dB\n",
+"ofdisp=2.8; //in ps/nm-km\n",
+"sD=2;\n",
+"sH=0;\n",
+"sCR=0.25;\n",
+"Ls=12;\n",
+"\n",
+"Dmax=round(E/(10^-6*fb*dl)); //taking to nearest integer in ps/nm\n",
+"printf('\n Dmax is %0.0f ps/nm\n',Dmax); \n",
+"Lmax=Dmax/ofdisp;\n",
+"printf('\n Maximum link distance is %0.2f km\n',Lmax); \n",
+"mM=mt+mr-(mc*L+mco*Nco+ms*Ns+mD+mH+mCR);\n",
+"printf('\n Mean link margin is %0.1f dB\n',mM);\n",
+"L=60;\n",
+"Ls=12; \n",
+"sM=sqrt(st^2+sr^2+sc^2*L*Ls+sco^2*Nco+ss^2*Ns+sD^2*sH^2+sCR^2);\n",
+"printf('\n Sigma link margin is %0.2f dB\n',sM); \n",
+"mM=round(mM*10)/10; //talking only to 1 decimal place and rounding of other values\n",
+"spm=mM-2*sM-1;\n",
+"printf('\n mM-2*sM = %0.2f\n',mM-2*sM);\n",
+"printf('\n System power margin is %0.2f dB\n',spm); //answer is slighty diferent due to m\sM=1.03\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.17: Calculate_the_CSO_distortio.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 486\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"Ncso=50;\n",
+"a=3.6*10^-3;\n",
+"m=0.05;\n",
+"CSO=10*log10(Ncso*(a*m)^2);\n",
+"printf('\n CSO distortion for 50 channel optical system = %0.1f dB\n',CSO); "
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.18: Calculate_the_required_AM_modulatio.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 486\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"CSO=-59.8; //in dB\n",
+"y=10^(CSO/10);\n",
+"mprintf('AM modulation depth (m) = %e\n',y);\n",
+"asq=3.6*10^-3;\n",
+"Ncso=50;\n",
+"msq=(y/Ncso/asq/asq);\n",
+"mprintf('\n m^2 = %e\n',msq);\n",
+"printf('\n Decrease of AM modulation depth decrease the CSO distortion by = %0.0f percent',sqrt(msq)*100);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.19: Compute_the_CTO_distortio.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 486\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"Ncto=50;\n",
+"b=1.07*10^-2;\n",
+"m=0.05;\n",
+"CTO=10*log10(Ncto*(1.5*b*m)^2);\n",
+"printf('\n CTO distortion for 50 channel optical system = %0.1f dB\n',CTO); \n",
+"//Answer in the book is misprinted\n",
+"//The solution in the book is calculated without multipication of Ncto"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.1: Compute_power_margi.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 431\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"Pt=10; //in microW\n",
+"Pr=1; //in microW\n",
+"PtdBm=10*log10(Pt*10^-6/10^-3) //in dBm\n",
+"printf('\n Transmitter Power = %0.0f dBm',PtdBm);\n",
+"PrdBm=10*log10(Pr*10^-6/10^-3) //in dBm\n",
+"printf('\n Receiver Power = %0.0f dBm',PrdBm);\n",
+"Pm=PtdBm-PrdBm;\n",
+"printf('\n Power margin= %0.0f dBm',Pm); //misprint in book"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.20: Calculate_the_CSO_and_CTO.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 487\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"Ncso=80;\n",
+"a=2.43*10^-3;\n",
+"b=4.65*10^-3;\n",
+"m=0.05;\n",
+"//Part (i)\n",
+"CSO=10*log10(Ncso*(a*m)^2);\n",
+"printf('\n CSO distortion for 50 channel optical system for m = 5 percent \n CSOdB = %0.1f dB\n',CSO); \n",
+"//Part (ii)\n",
+"CTO=10*log10(Ncso*(1.5*b*m)^2);\n",
+"printf('\n CTO distortion for 50 channel optical system for m = 5 percent \n CTOdB = %0.1f dB\n',CTO);\n",
+"//Part (iii)\n",
+"m=0.03;\n",
+"\n",
+"CSO=10*log10(Ncso*(a*m)^2); \n",
+"// Value of a in the book is considered 2.4 instead of 2.43\n",
+"printf('\n CSO distortion for 50 channel optical system for m = 3 percent \n CSOdB = %0.1f dB\n',CSO); \n",
+"\n",
+"//Part (iv)\n",
+"CTO=10*log10(Ncso*(1.5*b*m)^2);\n",
+"printf('\n CTO distortion for 50 channel optical system for m = 3 percent \n CTOdB = %0.1f dB\n',CTO);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.21: Calculate_the_CNR.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 487\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"RIN=-150; //in dB\n",
+"B=4*10^6;\n",
+"m=0.04;\n",
+"CNR=10*log10(m^2/(2*10^-15*B));\n",
+"printf('\n CNR = %0.0f dB',CNR);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.22: Calculate_the_RIN.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"\n",
+"\n",
+"\n",
+"\n",
+"//Chapter 12\n",
+"//page no 488\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"CNR=50; //in dB\n",
+"Bch=4*10^6;\n",
+"m=0.03;\n",
+"RIN=m^2/2/Bch/10^(CNR/10)\n",
+"mprintf('\n RIN = %e ',RIN);\n",
+"//Miscalculated answer in the book\n",
+"RINdB=10*log10(RIN);\n",
+"printf('\nRIN in Db is %.2f',RINdB)\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.23: Calculate_the_required_optical_power.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 490\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"Ipd=0.15; //in mA\n",
+"n=0.75;\n",
+"e=1.6*10^-19; //electron charge\n",
+"hv=1.55*10^-19;\n",
+"Pin=hv*Ipd/n/e;\n",
+"printf('\n Pin = %0.6f mW',Pin); //Result\n",
+"//answer in book is misprint"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.24: Calculate_the_percentage_of_optical_power_reflected_back.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 492\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"OBR=-40; //in dB\n",
+"//y=Pref/Pin\n",
+"y=10^(OBR/10);\n",
+"printf('\n Prefl = %0.2f percent Pin',y*100);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.25: Calculate_the_output_voltage_of_an_optical_receiver.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 493\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"R=800; //in V/W\n",
+"Pin=1.5; //in mW\n",
+"m=0.04;\n",
+"Voutp=R*Pin*m;\n",
+"printf('\n Vout(peak) = %0.0f mV',Voutp);\n",
+"Vavg=Voutp/sqrt(2);\n",
+"printf('\n Vavg = %0.1f mV',Vavg);\n",
+"//in dB\n",
+"Vavgd=20*log10(Vavg*10^-3);\n",
+"printf('\n Vavg(in dBmV) = %0.1f ',Vavgd);\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.26: Determine_the_optical_receiver_responsivity.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 494\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"Voutp=20; //in dB\n",
+"Pin=1.2; //in mW\n",
+"m=0.035;\n",
+"Vavg=10^(Voutp/20); //in \n",
+"R=Vavg*sqrt(2)/Pin/m;\n",
+"printf('\n R = %0.1f V/W',R);\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.27: Calculate_the_modulation_depth.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 494\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"Voutp=28; //in dB\n",
+"Pin=1; //in mW\n",
+"R=800; //in V/W\n",
+"Vavg=10^(Voutp/20); //in \n",
+"m=Vavg*sqrt(2)/Pin/R;\n",
+"printf('\n The modulation depth ,m = %0.1f percent',m*100);\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.28: Calculate_the_CNR.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 495\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"Ipd=1.2; //in mA\n",
+"m=0.04; \n",
+"RINd=-160; //in dB/Hz\n",
+"e=1.6*10^-19; \n",
+"nth=8; //in pA/Hz\n",
+"BW=4; //in MHz\n",
+"Rin=10^(RINd/10); //in \n",
+"\n",
+"CNR=[0.5*(m*Ipd*10^-3)^2]/[(2*e*Ipd*10^-3)+(Rin*Ipd*10^-3)^2+((nth*10^-12)^2)*BW/10^6];\n",
+"printf('Value of CNR=%e',CNR)\n",
+"CNRdB=10*log10(CNR)\n",
+"printf('\nValue of CNR in dB=%.2f dB',CNRdB)\n",
+"//Answer in the book is misprinted or wrong calculation performed in the book"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.29: Total_fiber_span_attenuation.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 509\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"L1=40; //in km\n",
+"L2=100; //in km\n",
+"A=0.2; //in dB/Km\n",
+"TFA1=A*L1;\n",
+"\n",
+"printf('\n Total fibre span attenuation %0.0f dB\n',TFA1);\n",
+"TFA2=A*L2;\n",
+"printf('\n Total fibre span attenuation %0.0f dB\n',TFA2);\n",
+"nsd=TFA2-TFA1;\n",
+"printf('\n Noise spectral density = %0.0f dB ',nsd);\n",
+"nsd_abs=10^(nsd/10)\n",
+"printf('\n\n Absolute value of noise spectral density = %0.0f dB ',nsd_abs);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.2: Compute_power_margi.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 431\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"Pt=25; //in microW\n",
+"Prd=15; //in dBm\n",
+"Ptd=10*log10(Pt*10^-6/10^-3) //in dBm\n",
+"printf('\n Transmitter Power = %0.0f dBm',Ptd);\n",
+"Pm=Ptd-Prd;\n",
+"printf('\n Power margin= %0.0f dBm',Pm);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.30: Calculate_the_SNR.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"\n",
+"\n",
+"\n",
+"\n",
+"//Chapter 12\n",
+"//page no 510\n",
+"//given\n",
+"clc;\n",
+"clear ;\n",
+"P1=2.75; //in mW\n",
+"NFd=5; //in dB\n",
+"bw=5; //in GHz\n",
+"G=10; //in dB\n",
+"hv=1.6*10^-19; //photon energy in J\n",
+"N=1; //no of amplifiers\n",
+"NF=10^(NFd/10); //amplifier noise figure\n",
+"SNR=10*log10(P1*10^-3/[G*hv*bw*10^9*N*NF]); //signal to nois eratio\n",
+"printf('\n Spectral Noise density = %0.0f dB ',SNR);//result\n",
+"\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.31: Calculate_the_optical_power_in_fiber.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 510\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"SNRdB=40; //in dB\n",
+"NFd=6; //in dB\n",
+"bw=4; //in GHz\n",
+"Gd=8; //in dB\n",
+"hv=1.6*10^-19; //photon energy in J\n",
+"N=8; //no of amplifiers\n",
+"SNR=10^(SNRdB/10);\n",
+"NF=10^(NFd/10); //amplifier noise figure\n",
+"G=10^(Gd/10); //amplifer gain\n",
+"P1=10*(SNR/10)*[G*hv*bw*10^9*N*NF]/10^-3; //optical power launched into fibre\n",
+"printf('\n Optical power required , Pl = %0.1f mW ',P1); //Result\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.32: Compute_the_transmission_length.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"\n",
+"\n",
+"\n",
+"\n",
+"//Chapter 12\n",
+"//page no 518\n",
+"//given\n",
+"clc;\n",
+"clear all ;\n",
+"l=1550; //wavelength in nm\n",
+"fb=10; //system bit rate Gb/s\n",
+"Df=17; //fiber dispersion in ps/nm-km\n",
+"L=10^5/Df/fb^2; //fiber length in km \n",
+"printf('\n Transmission length is %0.1f km',L);\n",
+"fb2=2.5; //system bit rate Gb/s\n",
+"disp('for fb=2.5 Gb/s')\n",
+"L2=10^5/Df/fb2^2; //fiber length in km \n",
+"printf(' Transmission length is %0.0f km',L2);//result misprint in book"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.33: Compute_the_maximum_bit_rate.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 518\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"lembda=1550; //wavelength in nm\n",
+"Df=17; //fiber dispersion in ps/nm-km\n",
+"L=80 //fiber length in km \n",
+"fb=sqrt(10^5/Df/L)\n",
+"printf('\n Maximum bit rate fb = %.1f Mb/s',fb);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.34: Compute_the_solition_characteristic_length.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 530\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"D=0.2; //dispersion constant in ps/nm/km\n",
+"Tfwhm=18; //ps\n",
+"Zs=0.25*Tfwhm^2/D; // Characteristic length\n",
+"printf('\n Zs = %0.0f km',Zs); //answer in book is miscalculated\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.35: Determine_maximum_dispersion.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 530\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"lembda=1550; //wavelength in nm\n",
+"c=3*10^5; //speed of light in km/s\n",
+"Zs=600; //in km\n",
+"Tfwhm=20; //in ps\n",
+"D=1/1.763^2*[2*%pi*c*Tfwhm^2/(lembda^2*Zs)]; //dispersion constant\n",
+"printf('\n dispersion constant, D = %0.2f ps/nm/km',D); //result"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.36: Calculate_the_solition_pulse_width.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"\n",
+"\n",
+"\n",
+"\n",
+"//Chapter 12\n",
+"//page no 530\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"l=1557; //wavelength in nm\n",
+"c=3*10^5; //speed of light in km/s\n",
+"Zs=550; //in km\n",
+"D=0.25; //in ps/nm/km\n",
+"Tfwhm=sqrt(1.763^2*l^2*D*Zs/(2*%pi*c));//Soliton pulse width \n",
+"printf('\n Tfwhm = %0.0f ps',Tfwhm); //Result"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.37: Calculate_the_solition_peak_pulse.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 531\n",
+"//given\n",
+"clc;\n",
+"clear ;\n",
+"Aeff=55; //in sq micrometer\n",
+"l=1557; //wavelength in nm\n",
+"c=3*10^5; //speed of light in km/s\n",
+"n2=2.6*10^-16; //in cm^2/W\n",
+"D=0.20; //Dispersion constant in ps/nm/km\n",
+"Tfwhm=30; //in ps\n",
+"Zs=[2*%pi*c*Tfwhm^2/l^2/D]/(1.763)^2 ;//charecteristic length \n",
+"printf('\n Zs = %0.0f km',Zs); //result \n",
+"Ps=(Aeff*10^-12*l*10^-9)/(2*%pi*n2*10^-4*Zs*10^3);//Peak pulse power\n",
+"//Miscalculation in the book\n",
+"printf('\n Ps = %0.2f mW',Ps*1000); //Result"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.38: Compute_the_standard_deviation.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"//Chapter 12\n",
+"//page no 533\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"Z=10; //in mm\n",
+"Tfwhm=22; //in ps\n",
+"D=0.5; //ps/nm/km\n",
+"Aeff=55; //in microm^2\n",
+"A=0.05; //in km^-1\n",
+"nsp=1.5; //spontaneous emission \n",
+"F=2; //amplifier noise\n",
+"s=3.6*10^3*nsp*F*A*D*Z^3/(Aeff*Tfwhm);\n",
+"printf('\n sigma = %0.0f ps',s); //Result\n",
+"\n",
+"//answer in book is misprint"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.39: Calculate_the_system_BER.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 533\n",
+"//given\n",
+"clc;\n",
+"clear ;\n",
+"Q1=4; //quality factor\n",
+"Q2=6; //quality factor\n",
+"BER1=[2*%pi*(Q1^2+2)]^-0.5*exp(-Q1*Q1/2); \n",
+"BER2=[2*%pi*(Q2^2+2)]^-0.5*exp(-Q2*Q2/2);\n",
+"printf('\n For Q=4 ,BER = %0.0f*10^-5 ',BER1*10^5); //Result\n",
+"printf('\n For Q=6 ,BER = %0.1f*10^-10 ',BER2*10^10); //Result\n",
+"//Answer second is misprinted in the book\n",
+"\n",
+"\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.3: Calculate_level_of_additional_power_launched.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 432\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"Pt1=-18; //in dBm for 50/125 micron fiber\n",
+"Pt2=-10; //in dBm for 100/125 micron fiber\n",
+"Pd=Pt1-Pt2;\n",
+"printf('\n Additional Power = %0.0f dBm',Pd);\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.40: Compute_the_standard_deviation.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 534\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"D=0.5; //Dispersion constant ps/nm/km\n",
+"Ts=22; //Pulse width in ps\n",
+"fb=10; //system transmission rate in Gb/s\n",
+"Z1=1; //System total length Mm\n",
+"Z2=10; //System total length Mm\n",
+"sa1=8.6*D*D*Z1*Z1*sqrt(fb-0.99)/22/2; //standard deviation based on accoustic effect\n",
+"sa2=8.6*D*D*Z2*Z2*sqrt(fb-0.99)/22/2; //standard deviation based on accoustic effect\n",
+"printf('\n For Z=1000km ,sigma acoustic = %0.2f ps ',sa1); //Result\n",
+"printf('\n For Z=10000km ,sigma acoustic = %0.0f ps ',sa2); //Result\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.41: Calculate_the_collision_length.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 535\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"D=0.45; //dispersion coefficient in ps/nm/km\n",
+"Ts=22; //Pulse width in ps\n",
+"l=0.5; //length in nm\n",
+"Lcollision=2*Ts/l/D; //collision length in km\n",
+"printf('\n Lcollision = %0.1f km ',Lcollision); //Result\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.42: Calculate_the_half_channel_length.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 537\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"f=70; //Maximum frequencyshift in Ghz\n",
+"Ts=22; //Pulse width in ps\n",
+"CS=1.783*f*10^9*Ts*10^-12; //half channel seperation \n",
+"printf('\n The half channel seperation %0.2f ',CS);\n",
+"df=0.105/f/10^9/Ts/Ts/10^-24; //maximum frequency shift\n",
+"printf('\n The maximum frequency shift %0.0f GHz',df/10^9);\n",
+"dt=0.1786/f/10^9/f/10^9/Ts/10^-12; //time displacement\n",
+"printf('\n The time displacement %0.2f ps',dt*10^12);\n",
+"\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.43: Calculate_the_minimum_number_of_soliton.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 538\n",
+"//given\n",
+"clc;\n",
+"clear ;\n",
+"M=1; \n",
+"N=1; //no of collision \n",
+"S1=4; //soliton colllision \n",
+"S2=5; //soliton colllision \n",
+"Nc=S1*S1/4*[M*S1/2-M+N]; //minimum no of collision\n",
+"printf('\n Ncollision for S=4,is %0.0f',Nc);\n",
+"Nc2=(S2*S2-1)/4*[M*S2/2-M+N]; //minimum no of collision\n",
+"printf('\n Ncollision for S=5,is %0.0f',Nc2);\n",
+"\n",
+"\n",
+"\n",
+"\n",
+"\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.44: Compute_the_maximum_number_of_soliton.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 539\n",
+"//given\n",
+"clc;\n",
+"clear;\n",
+"S=4;\n",
+"n=5;\n",
+"printf('\n Maximum number of solition Collisions\n');\n",
+"for M = 1:n\n",
+"N=M;\n",
+"Nc=S*[M*S*S/3+S*(N/2-M)-N/2+2*M/3]; //minimum no of collision\n",
+"printf('\n M=%0.0f N=%0.0f S=%0.0f ,is %0.0f',M,N,S,Nc);//result\n",
+"\n",
+" \n",
+"end"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.45: Compute_the_number_of_collision.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 539\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"M=1; //number of solition Collisions\n",
+"N=1; // number of solition Collisions\n",
+"x=2; \n",
+"y=1/2;\n",
+"p=3;\n",
+"p2=4;\n",
+"Tb=100; //ps\n",
+"l=1; //difference in wavelength in nm \n",
+"D=7*10^-2; //ps/nm^2*km\n",
+"Zr=y*y*(Tb/l/l/D); //regeration spacing in km\n",
+"printf('\n Zr = %0.0f km\n',Zr);\n",
+"P=(p-1)*N+(p-2)*(p-1)*M/2;\n",
+"printf('\n P(%0.0f) =%0.0f',p,P); //result number of Collisions\n",
+"P2=(p2-1)*N+(p2-2)*(p2-1)*M/2; \n",
+"printf('\n P(%0.0f) =%0.0f',p2,P2); //result number of Collisions"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.46: Calculate_the_channel_spacing.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//chapter 12\n",
+"//page no 540\n",
+"//exa 12_46\n",
+"//given\n",
+"clear;\n",
+"clc;\n",
+"Tb=100; //bit period in ps\n",
+"dZ=0.4; //in ps/nm/km\n",
+"Zr=150; //Modulator spacing in km\n",
+"Ta=Tb/(dZ*Zr); //channel spacing in nm\n",
+"printf('\n Channel spacing %0.1f nm',Ta); //result\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.47: Compute_the_bit_period.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//chapter 12\n",
+"//page no 540\n",
+"//exa 12_47\n",
+"//given\n",
+"clear;\n",
+"clc;\n",
+"Zr=200; //Modulator spacing in km\n",
+"D=0.6; //in ps/nm/km\n",
+"l=2; //in nm\n",
+"Tb=l*(Zr*D); //bit period in ps\n",
+"printf('\n Bit period Tb = %0.0f ps',Tb);//result\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.48: Calculate_the_maximum_modulator_spacing.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//chapter 12\n",
+"//page no 540\n",
+"//exa 12_48\n",
+"//given\n",
+"clear;\n",
+"clc;\n",
+"D=0.5; //ps/nm-km\n",
+"Tb=80; //bit period in ps\n",
+"l=1.5; //in nm\n",
+"Zr=Tb/(D*l); //Modulator spacing in km\n",
+"printf('\n Maximum modulator spacing Zr = %0.2f km',Zr);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.49: Calculate_the_length_of_dispersion.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//chapter 12\n",
+"//page no 541\n",
+"//exa 12_49\n",
+"//given\n",
+"clear;\n",
+"clc;\n",
+"Zd=100; //in km\n",
+"Do=0.07; //in ps/nm^2\n",
+"D1=-0.3; //in ps/nm^2\n",
+"Ldsf=(Zd*Do)/(Do-D1); //length of dispersion compensation fiber in km\n",
+"printf('\n Length of Dispersion compensation fiber, Ldsf = %0.0f km',Ldsf);//Result"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.4: Compute_link_power_budget.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 432\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"Plb=10; //in dBm for 50/125 micron fiber\n",
+"Ps=3; //in dBm for safety margin\n",
+"Prs=-30; //in dBm for receiver sensivity\n",
+"Pt=Plb+Ps+Prs;\n",
+"printf('\n Link power budget = %0.0f dBm',Pt);\n",
+"Ptw=10^(Pt/10)*1000;\n",
+"printf('\n Transmitter Power = %0.0f microW',Ptw);\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.50: Calculate_the_collision_length.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//chapter 12\n",
+"//page no 542\n",
+"//ex 12_50\n",
+"//given\n",
+"clear;\n",
+"clc;\n",
+"m=3;\n",
+"n=1;\n",
+"Tb=100; //ps\n",
+"l=1; //nm\n",
+"D=0.07; //ps/nm^2*km\n",
+"lmn=1; //nm\n",
+"lmo=2; //nm\n",
+"Do=0.1; //ps/nm-km\n",
+"Lc=4*Tb/[5*D*lmn*(lmn+2*lmo)];//Collision length in km\n",
+"printf('\n Collision length without dispersion slope compensation = %0.1f km\n',Lc);//result\n",
+"Lc2=2*Tb/[5*Do*lmn];//Collision length in km\n",
+"printf('\n Collision length with dispersion slope compensation = %0.0f km',Lc2);//result\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.51: Compute_the_soliton_collision_length.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//chapter 12\n",
+"//page no 542\n",
+"//ex 12_51\n",
+"//given\n",
+"clear;\n",
+"clc;\n",
+"Zr=200; //in km\n",
+"S=4;\n",
+"Ltot1=2*Zr*(S-1); //total solition collion length in km\n",
+"printf('\n Total solition Collisions length With DSC ,Ltotal = %0.0f km\n',Ltot1);//Result\n",
+"Ltot2=(2/5)*Zr*(S-1); //total solition collion length in km\n",
+"printf('\n Total solition Collisions length With non-DSC ,Ltotal = %0.0f km\n',Ltot2);//result"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.5: Calculate_PIN_diode_required_operating_power_and_total_power_budget.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"\n",
+"\n",
+"\n",
+"\n",
+"//Chapter 12\n",
+"//page no 433\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"Is=0.5; //in A/W\n",
+"Ir=1.5; //in microA\n",
+"Xw=Ir/Is;\n",
+"printf('\n Electrical power required by PIN diode is = %0.0f microW',Xw);\n",
+"Pxw=10*log10(Xw/10^3);\n",
+"printf('\n Therefore, Electrical power required by PIN diode is = %0.1f dBm',Pxw);\n",
+"\n",
+"Ps=3; //in dB for safety margin\n",
+"Tp=5; //in dB\n",
+"Pt=Tp+Ps+Pxw;\n",
+"printf('\n Total Power Required = %0.1f dBm',Pt);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.6: Calculate_maximum_link_distance.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 442\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"fb=1.25; //in Gb/s\n",
+"D=17; //in ps/nm.km\n",
+"dL=0.5; //in nm\n",
+"Lmax=1/fb/10^9/dL/10^-9/D/10^-12*10^-9;\n",
+"printf('\n Maximum Link span,Lmax = %0.0f km',Lmax);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.7: Compute_chromatic_dispersio.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 442\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"fb=2.5; //in Gb/s\n",
+"Lmax=50; //in km\n",
+"dL=0.4; //in nm\n",
+"D=1/fb/10^9/dL/10^-9/Lmax/10^-12*10^-9;\n",
+"printf('\n Maximum allowable dispersion,D = %0.0f ps/nm-km',D);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.8: Compute_maximum_bit_rate.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 443\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"Lmax=60; //in km\n",
+"D=17; //in ps/nm.km\n",
+"dL=0.5; //in nm\n",
+"fb=1/Lmax/10^9/dL/10^-9/D/10^-12*10^-9;\n",
+"printf('\n Maximum system bit rate,fb = %0.2f Gb/s',fb);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 12.9: Compute_Maximum_link_span.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter 12\n",
+"//page no 443\n",
+"//given\n",
+"clc;\n",
+"clear all;\n",
+"c1=4; //channel1\n",
+"c2=8; //channel2\n",
+"c3=16; //channel3\n",
+"fb=2.5; //in Gb/s\n",
+"Lmax1=6.1*10^3/(c1*fb)^2;\n",
+"printf('\n Maximum Link span for %0.0f channel, Lmax = %0.0f km \n',c1,Lmax1);\n",
+"Lmax2=6.1*10^3/(c2*fb)^2;\n",
+"printf('\n Maximum Link span for %0.0f channel, Lmax = %0.2f km \n',c2,Lmax2);\n",
+"Lmax3=6.1*10^3/(c3*fb)^2;\n",
+"printf('\n Maximum Link span for %0.0f channel, Lmax = %0.1f km \n',c3,Lmax3);"
+ ]
+ }
+],
+"metadata": {
+ "kernelspec": {
+ "display_name": "Scilab",
+ "language": "scilab",
+ "name": "scilab"
+ },
+ "language_info": {
+ "file_extension": ".sce",
+ "help_links": [
+ {
+ "text": "MetaKernel Magics",
+ "url": "https://github.com/calysto/metakernel/blob/master/metakernel/magics/README.md"
+ }
+ ],
+ "mimetype": "text/x-octave",
+ "name": "scilab",
+ "version": "0.7.1"
+ }
+ },
+ "nbformat": 4,
+ "nbformat_minor": 0
+}