{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# Chapter 24 : Fiber Optics" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 3 : pg 888" ] }, { "cell_type": "code", "execution_count": 1, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "The core diameter is 4.18746666667e-06 m\n" ] } ], "source": [ " \n", "# page no 888\n", "# prob no 24.3\n", "#calculate the core diameter\n", "#given\n", "NA=0.15;\n", "wl=820*10**-9;#in m\n", "#calculations\n", "d_core=2*(0.383*wl/NA);\n", "#results\n", "print 'The core diameter is',d_core,'m'" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 4 : pg 890" ] }, { "cell_type": "code", "execution_count": 2, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "The maximun distance that can be use between repeaters is 5.88 km\n" ] } ], "source": [ " \n", "# page no 890\n", "# prob no 24.4\n", "#calculate the max distance\n", "#given\n", "Bl=500;#in MHz-km\n", "B=85.;#in MHz\n", "#calculations\n", "# By using Bandwidth-distance product formula\n", "l=Bl/B;\n", "#results\n", "print 'The maximun distance that can be use between repeaters is',round(l,2),'km'" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 5 : pg 891" ] }, { "cell_type": "code", "execution_count": 3, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "The total dispersion is 948.95 ps\n" ] } ], "source": [ " \n", "# page no 891\n", "# prob no 24.5\n", "#calculate the total dispersion\n", "#given\n", "wl0=1310.;#in ns\n", "So=0.05;#in ps/(nm**2*km)\n", "l=50.;#in km\n", "wl=1550.;#in ns\n", "d=2.;#in nm\n", "#calculations\n", "# Chromatic dispersion is given as\n", "Dc=(So/4)*(wl-(wl0**4/wl**3));\n", "# Dispersion is\n", "D=Dc*d;\n", "# Therefore total dispersion is \n", "dt=D*l;\n", "#results\n", "print 'The total dispersion is',round(dt,2),'ps'" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 6 : pg 893" ] }, { "cell_type": "code", "execution_count": 4, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "The bandwidth distance product is 26343519494.2 Hz-km\n" ] } ], "source": [ " \n", "# page no 893\n", "# prob no 24.6\n", "#given\n", "#calculate the bandwidth distance product\n", "#Refer problem 24.5\n", "dt=949*10**-12;#in sed\n", "l=50.;#in km\n", "#calculations\n", "B=1/(2*dt);\n", "#By using Bandwidth-distance product formula\n", "Bl= B*l;\n", "#results\n", "print 'The bandwidth distance product is',Bl,'Hz-km'" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 7 : pg 899" ] }, { "cell_type": "code", "execution_count": 7, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "a) The proportion of input power emerging at port 2 is 10.0 %\n", "b) The proportion of input power emerging at port 3 is 10.0 %\n", "Directivity is 40 dB\n", "the excess loss is 6.99 dB\n" ] } ], "source": [ " \n", "# page no 899\n", "# prob no 24.7\n", "#calculate the directivity, power, excess loss\n", "#given\n", "from math import log10\n", "# refer table from the problem page no 899\n", "P_coupling1 =-3; P_coupling2 = -6; P_coupling3 =-40;# in dB\n", "#calculations and results\n", "#Part a) The proportion of input power emerging at port 2\n", "P2_Pin=10**(P_coupling1/10);\n", "print 'a) The proportion of input power emerging at port 2 is',P2_Pin*100,'%'\n", "P3_Pin=10**(P_coupling2/10);\n", "print 'b) The proportion of input power emerging at port 3 is',P3_Pin*100,'%'\n", "# Part b) In the reverse direction,the signal is 40dB down for all combinations, so\n", "directivity = 40;\n", "print 'Directivity is',directivity,'dB'\n", "Pin_total = P2_Pin + P3_Pin;\n", "# excess loss in dB\n", "loss=-10*log10(Pin_total);\n", "print 'the excess loss is',round(loss,2),'dB'" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 8 : pg 901" ] }, { "cell_type": "code", "execution_count": 8, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "The energy of photon in eV is 1.242375 eV\n" ] } ], "source": [ " \n", "# page no 901\n", "# prob no 24.8\n", "#calculate the energy of photon\n", "#given\n", "wl=1*10**-6;\n", "c= 3*10**8;\n", "h=6.626*10**-34\n", "#calculations\n", "f=c/wl;\n", "E=h*f;# in Joule\n", "#this energy can be converted into electron-volt. we know 1eV=1.6*10**-19 J\n", "eV=1.6*10**-19 ;\n", "E_ev=E/eV;\n", "#results\n", "print 'The energy of photon in eV is',E_ev,'eV'" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 9 : pg 909" ] }, { "cell_type": "code", "execution_count": 9, "metadata": { "collapsed": false }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "The diode current is 165.0 nA\n" ] } ], "source": [ " \n", "# page no 909\n", "# prob no 24_9\n", "#calculate the diode current\n", "#given\n", "# refer fig 24.25\n", "P_in=500;Responsivity=0.33;\n", "#calculations\n", "I_d = P_in * Responsivity;\n", "#results\n", "print 'The diode current is',I_d,'nA'" ] } ], "metadata": { "kernelspec": { "display_name": "Python 2", "language": "python", "name": "python2" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 2 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython2", "version": "2.7.11" } }, "nbformat": 4, "nbformat_minor": 0 }