{ "metadata": { "celltoolbar": "Raw Cell Format", "name": "", "signature": "sha256:a2b560d73b954e9a1c7f8ed18b2499b5355c9c4b506d0daba4c1031f93d49041" }, "nbformat": 3, "nbformat_minor": 0, "worksheets": [ { "cells": [ { "cell_type": "heading", "level": 1, "metadata": {}, "source": [ "Chapter 5: Optical Amplifiers" ] }, { "cell_type": "heading", "level": 3, "metadata": {}, "source": [ "Example 5.1,Page number 128" ] }, { "cell_type": "code", "collapsed": false, "input": [ "import math\n", "\n", "#given\n", "\n", "Vrms=0.3; #in V\n", "CF=0.75; #in V/mW\n", "Pi=Vrms/CF; \n", "print\" input power \",round(Pi,4),\"mW\";" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ " input power 0.4 mW\n" ] } ], "prompt_number": 5 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example 5.2,Page number 131" ] }, { "cell_type": "code", "collapsed": false, "input": [ "import math\n", "\n", "#given\n", "\n", "Di=155; #in Mb/s\n", "sl=10**-3*Di*10**6; #in bitstream\n", "#PRBS=2**x-1=sl;\n", "x=log(sl+1)/log(2); #equation is made to pick value of x\n", "print\" PRBS =(2^\",int(x),\")-1\";\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ " PRBS =(2^ 17 )-1\n" ] } ], "prompt_number": 9 }, { "cell_type": "code", "collapsed": false, "input": [], "language": "python", "metadata": {}, "outputs": [] } ], "metadata": {} } ] }