From d36fc3b8f88cc3108ffff6151e376b619b9abb01 Mon Sep 17 00:00:00 2001 From: kinitrupti Date: Fri, 12 May 2017 18:40:35 +0530 Subject: Revised list of TBCs --- .../Chapter_7.ipynb | 232 +++++++++++++++++++++ 1 file changed, 232 insertions(+) create mode 100755 sample_notebooks/RohithYeedulapalli/RohithYeedulapalli_version_backup/Chapter_7.ipynb (limited to 'sample_notebooks/RohithYeedulapalli/RohithYeedulapalli_version_backup/Chapter_7.ipynb') diff --git a/sample_notebooks/RohithYeedulapalli/RohithYeedulapalli_version_backup/Chapter_7.ipynb b/sample_notebooks/RohithYeedulapalli/RohithYeedulapalli_version_backup/Chapter_7.ipynb new file mode 100755 index 00000000..c41c4cd6 --- /dev/null +++ b/sample_notebooks/RohithYeedulapalli/RohithYeedulapalli_version_backup/Chapter_7.ipynb @@ -0,0 +1,232 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 7:LASERS " + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "##Example 7.1, Page number 7.32" + ] + }, + { + "cell_type": "code", + "execution_count": 16, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Divergence = 0.5 *10**-3 radian\n" + ] + } + ], + "source": [ + "import math\n", + "from __future__ import division\n", + "\n", + "#variable declaration\n", + "r1 = 2; #in radians\n", + "r2 = 3; #in radians\n", + "d1 = 4; #Converting from mm to radians\n", + "d2 = 6; #Converting from mm to radians\n", + "\n", + "#calculations\n", + "D = (r2-r1)/(d2*10**3-d1*10**3)\n", + "\n", + "#Result\n", + "print \"Divergence =\",round(D*10**3,3),\"*10**-3 radian\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "##Example 7.2, Page number 7.32" + ] + }, + { + "cell_type": "code", + "execution_count": 23, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Frequency (V) = 4.32 *10**14 Hz\n", + "Relative Population= 1.081 *10**30\n" + ] + } + ], + "source": [ + "import math\n", + "from __future__ import division\n", + "from sympy import *\n", + "#variable declaration\n", + "C=3*10**8 #The speed of light\n", + "L=6943 #Wavelength\n", + "T=300 #Temperature in Kelvin\n", + "h=6.626*10**-34 #Planck constant \n", + "k=1.38*10**-23 #Boltzmann's constant\n", + "\n", + "#Calculations\n", + "\n", + "V=(C)/(L*10**-10)\n", + "R=math.exp(h*V/(k*T))\n", + "\n", + "#Result\n", + "print \"Frequency (V) =\",round(V/10**14,2),\"*10**14 Hz\"\n", + "print \"Relative Population=\",round(R/10**30,3),\"*10**30\"\n" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "##Example 7.3, Page number 7.32" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + " Frequency= 4.74 *10**14 Hz\n", + "no.of photons emitted= 7.322 *10**15 photons/sec\n", + "Power density = 2.3 kWm**-2\n" + ] + } + ], + "source": [ + "import math\n", + "\n", + "C=3*10**8 #Velocity of light\n", + "W=632.8*10**-9 #wavelength\n", + "P=2.3\n", + "t=1\n", + "h=6.626*10**-34 #Planck constant \n", + "S=1*10**-6\n", + "\n", + "#Calculations\n", + "V=C/W #Frequency\n", + "n=((P*10**-3)*t)/(h*V) #no.of photons emitted\n", + "PD=P*10**-3/S\n", + "\n", + "#Result\n", + "print \"Frequency=\",round(V/10**14,2),\"*10**14 Hz\"\n", + "print \"no.of photons emitted=\",round(n/10**15,3),\"*10**15 photons/sec\"\n", + "print \"Power density =\",round(PD/1000,1),\"kWm**-2\"\n" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "##Example 7.4, Page number 7.33" + ] + }, + { + "cell_type": "code", + "execution_count": 13, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Wavelenght = 8628.0 Angstrom\n" + ] + } + ], + "source": [ + "import math\n", + "\n", + "#variable declaration\n", + "h=6.626*10**-34 #Planck constant \n", + "C=3*10**8 #Velocity of light\n", + "E_g=1.44 #bandgap \n", + "\n", + "#calculations\n", + "W=(h*C)*10**10/(E_g*1.6*10**-19)\n", + "\n", + "#Result\n", + "print \"Wavelenght =\",round(W),\"Angstrom\"\n" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "##Example 7.5, Page number 7.33" + ] + }, + { + "cell_type": "code", + "execution_count": 25, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Band gap = 0.8 eV\n" + ] + } + ], + "source": [ + "import math\n", + "\n", + "#variable declaration\n", + "W=1.55 #wavelength\n", + "\n", + "#Calculations\n", + "E_g=(1.24)/W #Bandgap in eV \n", + "\n", + "#Result\n", + "print \"Band gap =\",E_g,\"eV\"" + ] + } + ], + "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.9" + } + }, + "nbformat": 4, + "nbformat_minor": 0 +} -- cgit