summaryrefslogtreecommitdiff
path: root/Engineering_Physics_by_G._Vijayakumari/Chapter5.ipynb
blob: 9c78727b621cd88bc5cb667e42ffa3c510c43c47 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "#5: Laser"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##Example number 5.1, Page number 124"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The ratio of propulsion of the two states in a laser is 1.3893 *10**-30\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "t=300;    #temperature(K)\n",
    "w=698.3*10**-9;   #wavelength of photon(m)\n",
    "h=6.625*10**-34;  #Planck's constant(m^2 Kg/sec)\n",
    "c=3*10**8;     #velocity of light(m/s)\n",
    "Kb=1.38*10**-23;   #Boltzmann's constant(m^2 Kg.s^-2 k^-1)\n",
    "\n",
    "#Calculation\n",
    "Ratio=math.exp((-h*c)/(w*Kb*t));    #ratio of propulsion of the two states in a laser\n",
    "\n",
    "#Result\n",
    "print \"The ratio of propulsion of the two states in a laser is\",round(Ratio*10**30,4),\"*10**-30\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##Example number 5.2, Page number 133"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The band gap for lnp laser diode is 0.8014 eV\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "w=1.55*10**-6;   #wavelength of light emission(m)\n",
    "h=6.625*10**-34;  #Planck's constant(m^2 Kg/sec)\n",
    "c=3*10**8;    #velocity of light(m/s)\n",
    "e=1.6*10**-19;   #charge of electron(c)\n",
    "\n",
    "#Calculation\n",
    "Eg=(h*c)/(w*e);    #band gap(eV)\n",
    "\n",
    "#Result\n",
    "print \"The band gap for lnp laser diode is\",round(Eg,4),\"eV\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##Example number 5.3, Page number 133"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 9,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The long wavelength limit of an extrinsic semiconductor is 6.2109 *10**-5 m\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "E=0.02*1.6*10**-19;    #Ionisation energy(J)\n",
    "h=6.625*10**-34;    #Planck's constant(m^2 Kg/sec)\n",
    "c=3*10**8;        #velocity of light(m/s)\n",
    "\n",
    "#Calculation\n",
    "w=h*c/E;       #long wavelength limit of an extrinsic semiconductor(m)\n",
    "\n",
    "#Result\n",
    "print \"The long wavelength limit of an extrinsic semiconductor is\",round(w*10**5,4),\"*10**-5 m\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##Example number 5.4, Page number 133"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The number of photons emitted per minute is 6.562 *10**17 photons/minute\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "E=3.5*10**-3*60;    #power output(J/min)\n",
    "w=0.621*10**-6;     #wavelength of light(m)\n",
    "h=6.625*10**-34;    #Planck's constant(m^2 Kg/sec)\n",
    "c=3*10**8;       #velocity of light(m/s)\n",
    "\n",
    "#Calculation\n",
    "e=h*c/w;      #energy emitted by one photon(J)\n",
    "n=E/e;     #The number of photons emitted per minute(photons/minute)\n",
    "\n",
    "#Result\n",
    "print \"The number of photons emitted per minute is\",round(n/10**17,3),\"*10**17 photons/minute\""
   ]
  }
 ],
 "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
}