summaryrefslogtreecommitdiff
path: root/Engineering_Physics_by_K._Rajagopal/Chapter_9.ipynb
blob: 94d3c95528f19dab881db5780ffcca4a4bfa21a1 (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
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
{
 "metadata": {
  "name": ""
 },
 "nbformat": 3,
 "nbformat_minor": 0,
 "worksheets": [
  {
   "cells": [
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {},
     "source": [
      "Chapter 9: Quantum Physics"
     ]
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.1, Page 279"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Varaible declaration\n",
      "e = 1.602e-19; # Charge of electron in Coloumb\n",
      "lamda = 2e-10; # Wavelength of a photon in meters\n",
      "h = 6.62e-34; # Planc's constant in Joule second\n",
      "c = 3.e8; # Velocity og light in air in meter per second\n",
      "\n",
      "#Calculations\n",
      "E = (h*c)/(lamda*e);#Thermal conductivity of Ni\n",
      "p = h/lamda;#The momentum of photon \n",
      "\n",
      "#Results\n",
      "print 'The energy of photon is ',round(E,3),'eV' #Incorrect answer in textbook\n",
      "print 'The momentum of photon is ',p,'(kg.m)/s'\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The energy of photon is  6198.502 eV\n",
        "The momentum of photon is  3.31e-24 (kg.m)/s\n"
       ]
      }
     ],
     "prompt_number": 1
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.2, Page 280"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Varaible declaration\n",
      "h = 6.62e-34; # Planck's constant J.s\n",
      "v = 440e3; # Operating frequency of radio in Hertz\n",
      "P = 20e3 ; # Power of radio transmitter in Watts\n",
      "\n",
      "#Calculation\n",
      "n = P/(h*v);# Let n be the number of photons emitted per second\n",
      "\n",
      "#Result\n",
      "print 'Number of photon emitted per second is ',round(n/1e30,2),'*10^30'\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Number of photon emitted per second is  68.66 *10^30\n"
       ]
      }
     ],
     "prompt_number": 2
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.3, Page 280"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Varaible declaration\n",
      "h = 6.62e-34; # Planck's constant in J.s\n",
      "c = 3e8; # Velocity of ligth in air\n",
      "t = 18000; # Time of glow - (5*3600) in seconds\n",
      "P = 30 #Power in watts\n",
      "lamda = 5893e-10; # Wavelength of emitted ligth in meters\n",
      "\n",
      "#calculations\n",
      "E = (h*c)/lamda; # Energy of a photon\n",
      "n = (P*t)/E; # let n be the number of photons emitted in 5 hours\n",
      "\n",
      "#Result\n",
      "print 'Number of photons emitted in 5 hours is',round(n/1e24,3),'*10^24'\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Number of photons emitted in 5 hours is 1.602 *10^24\n"
       ]
      }
     ],
     "prompt_number": 3
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.4, Page 287"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "from math import cos\n",
      "\n",
      "#Varaible declaration\n",
      "h = 6.62*1e-34; # Plancl's constant in J.s\n",
      "c = 3*1e8; # Velocity of light in vacccum in m/s \n",
      "m = 9.1*1e-31; # Mass of electron in Kg\n",
      "l = 0.7078*1e-10 # Wavelength in meter\n",
      "theta = 90;\n",
      "\n",
      "#Calculations\n",
      "delta = (h*(1-round(cos(theta)))/(m*c));\n",
      "Nlambda = l + delta;\n",
      "\n",
      "#Result\n",
      "print 'The wavelength of scattered X-rays is %.4f A'%(Nlambda/1e-10)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The wavelength of scattered X-rays is 0.7320 A\n"
       ]
      }
     ],
     "prompt_number": 4
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.5, Page 287"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "from math import cos,degrees,radians\n",
      "\n",
      "#Varaible declaration\n",
      "m = 9.1e-31; # Mass of electron in kg\n",
      "h = 6.62e-34; # Planck's constant in J.s\n",
      "c = 3e8; # Velocity of light in vaccum\n",
      "lamda = 1.8e18; # Frequency of the incident rays\n",
      "theta = 180;#angle in degree\n",
      "\n",
      "#Calculations\n",
      "lamda = c/lamda;\n",
      "delta = (h*(1-cos(radians(theta))))/(m*c);\n",
      "Nlambda = lamda+delta;#'Wavelength of scattered X-rays\n",
      "\n",
      "#Result\n",
      "print 'Wavelength of scattered X-rays is %.4f A'%(Nlambda/1e-10)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Wavelength of scattered X-rays is 1.7152 A\n"
       ]
      }
     ],
     "prompt_number": 5
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.6, Page 288"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "from math import cos\n",
      "\n",
      "#Varaible declaration\n",
      "m = 9.1e-31; # Mass of electron in kg\n",
      "h = 6.62e-34; # Planck's constant in Js\n",
      "c = 3e8; # Velocity of light in vaccum\n",
      "lamda = 1.12e-10; # Wavelength of light in meters\n",
      "theta = 90;\n",
      "\n",
      "#Calculations\n",
      "delta = (h*(1-round(cos(theta))))/(m*c);\n",
      "Nlambda = lamda + delta;#The wavelength of scattered X-rays \n",
      "E = (h*c)*((1/lamda)-(1/Nlambda)) ;#Energy of electron\n",
      "\n",
      "#Results\n",
      "print 'The wavelength of scattered X-rays is %.3f A'%(Nlambda/1e-10)\n",
      "print 'Energy of electron is %.2f *10^-17 J'%(E/1e-17)\n",
      " \n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The wavelength of scattered X-rays is 1.144 A\n",
        "Energy of electron is 3.76 *10^-17 J\n"
       ]
      }
     ],
     "prompt_number": 6
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Exampe 9.7, Page 289"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "from math import cos,radians\n",
      "\n",
      "#Varaible declaration\n",
      "m = 9.1e-31; # Mass of electron in kg\n",
      "h = 6.62e-34; # Planck's constant in Js\n",
      "c = 3e8; # Velocity of light in vaccum\n",
      "lamda = 0.03e-10; # Wavelength of light in meters\n",
      "theta = 60;#angle in degrees\n",
      "\n",
      "#Calculations\n",
      "delta = (h*(1-cos(radians(theta))))/(m*c);\n",
      "Nlambda = lamda + delta;\n",
      "E = ((h*c)*((1./lamda)-(1./Nlambda)))/1.6e-19 ;#Energy of recoiling electron\n",
      "\n",
      "#Result\n",
      "print 'Energy of recoiling electron is %.3f MeV'%(E/1e+6)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Energy of recoiling electron is 0.119 MeV\n"
       ]
      }
     ],
     "prompt_number": 7
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Eample 9.8, Page 289"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "from math import cos,radians\n",
      "\n",
      "#Varaible declaration\n",
      "m = 9.1e-31; # Mass of electron in kg\n",
      "h = 6.62e-34; # Planck's constant in Js\n",
      "c = 3e8; # Velocity of light in vaccum\n",
      "lamda = 0.5e-10; # Wavelength of light in meters\n",
      "theta = 90;\n",
      "\n",
      "#Calculations\n",
      "delta = (h*(1-cos(radians(theta))))/(m*c);\n",
      "Nlambda = lamda + delta;\n",
      "E = (h*c)*((1./lamda)-(1./Nlambda)) ;\n",
      "\n",
      "#Result\n",
      "print 'Energy of electron is %.2f *10^-16 J'%(E/1e-16)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Energy of electron is 1.84 *10^-16 J\n"
       ]
      }
     ],
     "prompt_number": 8
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.9, Page 290"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Varaible declaration\n",
      "m = 9.1e-31; # Mass of electron in kg\n",
      "h = 6.62e-34; # Planck's constant in Js\n",
      "c = 3e8; # Velocity of light in vaccum\n",
      "lamda = 1.5e-10; # Wavelength of light in meters\n",
      "E = 0.5e-16; # Energy of electron in J \n",
      "\n",
      "#Calculation\n",
      "Nlambda = ((h*c)/lamda)-E;#'Energy of scattered electron\n",
      "\n",
      "#Result\n",
      "print 'Energy of scattered electron is %.2f *10^-16 J'%(Nlambda/1e-16)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Energy of scattered electron is 12.74 *10^-16 J\n"
       ]
      }
     ],
     "prompt_number": 9
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.10, Page 290"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "from math import cos,radians\n",
      "\n",
      "#Varaible declaration\n",
      "lamda=0.022*1e-10;#wavelength in meters\n",
      "th=45;#angle in degree\n",
      "m=9.1*1e-31;\n",
      "c=3*1e8;#velocity of light in free space\n",
      "h=6.62*1e-34;#planck's constant\n",
      "\n",
      "#Calculations&Results\n",
      "x=cos(th);\n",
      "dlamda=h*(1-cos(radians(th)))/(m*c);#delta lemda \n",
      "print 'delta lemda is= %.3f A'%(dlamda/1e-10)\n",
      "lamda1=lamda-dlamda;#wavelength of incident X-rays\n",
      "print 'wavelength of incident X-rays %.3f A'%(lamda1/1e-10)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "delta lemda is= 0.007 A\n",
        "wavelength of incident X-rays 0.015 A\n"
       ]
      }
     ],
     "prompt_number": 10
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.11, Page 314"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Varaible declaration\n",
      "a = 1e-10 # Width of box in meter\n",
      "m = 9.1e-31; # Mass of electron in kg\n",
      "h = 6.62e-34; # Planck's constant in Js\n",
      "c = 3e8; # Velocity of light in vaccum\n",
      "n = 1; # Single electron\n",
      "\n",
      "#Calculation\n",
      "E = (n**2 * h**2)/(8*m*a**2*1.6e-19);\n",
      "\n",
      "#Result\n",
      "print'Energy of electrons is %.1f n^2 eV'%E\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Energy of electrons is 37.6 n^2 eV\n"
       ]
      }
     ],
     "prompt_number": 11
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.12, Page 314"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Varaible declaration\n",
      "a = 1e-10 # Width of box in meter\n",
      "m = 9.1e-31; # Mass of electron in kg\n",
      "h = 6.62e-34; # Planck's constant in Js\n",
      "c = 3e8; # Velocity of light in vaccum\n",
      "n = 1; # Single electron\n",
      "\n",
      "#Calculations\n",
      "E = (h**2)/(8*m*a**2);#Energy of in lower level\n",
      "p = h/(2*a);#Momentum \n",
      "\n",
      "#Results\n",
      "print 'Energy of in lower level %.f *10^-18 J'%(E/1e-18)\n",
      "print'Momentum is %.2f *10^-24 (kg.m)/s'%(p/1e-24)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Energy of in lower level 6 *10^-18 J\n",
        "Momentum is 3.31 *10^-24 (kg.m)/s\n"
       ]
      }
     ],
     "prompt_number": 12
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.13, Page 315"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Varaible declaration\n",
      "a = 0.2e-9 # Width of box in meter\n",
      "m = 9.1e-31; # Mass of electron in kg\n",
      "h = 6.62e-34; # Planck's constant in Js\n",
      "c = 3e8; # Velocity of light in vaccum\n",
      "E5 = 230*1.6e-19 #  Energy of a particle in Volts in 5th antinode\n",
      "n = 5;\n",
      "\n",
      "#Calculations\n",
      "E1 = E5/(n**2);\n",
      "m = (h**2)/(8*E1*a**2);#Mass of electron \n",
      "\n",
      "#Result\n",
      "print 'Mass of electron is %.2f *10^-31 kg'%(m/1e-31)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Mass of electron is 9.30 *10^-31 kg\n"
       ]
      }
     ],
     "prompt_number": 13
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.14, Page 316"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Varaible declaration\n",
      "n = 1; # Single particle\n",
      "a = 50e-10; # Width of box in meter\n",
      "deltax = 10e-10; # Intervel between particle\n",
      "\n",
      "#Calculations\n",
      "p = (2/a)*deltax;#The probability of finding the particle\n",
      "\n",
      "#Result\n",
      "print 'The probability of finding the particle is %.1f'%p\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The probability of finding the particle is 0.4\n"
       ]
      }
     ],
     "prompt_number": 14
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.15, Page 316"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "from math import sqrt\n",
      "\n",
      "#Varaible declaration\n",
      "h = 6.62*1e-34; # Planck's constant\n",
      "m = 1e-9; # Mass of particle in kg\n",
      "t = 100; #Time reqired by the particle to cross 1 mm distance\n",
      "a = 1e-3 ; # Width of box in m\n",
      "v = 1e-5; # Velocity of particle in m/s\n",
      "\n",
      "#Calculations\n",
      "E = (0.5*m*v**2);\n",
      "n = sqrt(8*m*a**2*E/(h**2));#The quantum state\n",
      "\n",
      "#Result\n",
      "print 'The quantum state is %.f*10^16 '%(n/1e+16)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The quantum state is 3*10^16 \n"
       ]
      }
     ],
     "prompt_number": 15
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.16, Page 317"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Varaible declaration\n",
      "h = 6.62e-34; # Planck's constant in J.s\n",
      "m = 9.1e-31 # Mass of electron in kg\n",
      "nk =1;\n",
      "nl = 1;\n",
      "nm = 1;\n",
      "a = 0.5e-10 # Width of cubical box in meter\n",
      "\n",
      "#Calculation\n",
      "E = (h**2*(nk**2+nl**2+nm**2))/(8*m*a**2*1.6e-19);#The lowest energy level will have energy\n",
      "\n",
      "#Result\n",
      "print 'The lowest energy level will have energy %.f eV'%E\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The lowest energy level will have energy 451 eV\n"
       ]
      }
     ],
     "prompt_number": 16
    }
   ],
   "metadata": {}
  }
 ]
}