summaryrefslogtreecommitdiff
path: root/Heat_And_Thermodynamics_by_A._Manna/ch4.ipynb
blob: 6682bd509da60b8b3cea20f79dce71e927ca31a5 (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
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
{
 "metadata": {
  "name": ""
 },
 "nbformat": 3,
 "nbformat_minor": 0,
 "worksheets": [
  {
   "cells": [
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {},
     "source": [
      "Chapter 4 : Kinetic theory of gases"
     ]
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.1 page no : 137\n"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "# Variables\n",
      "t = 273;\t\t\t    #temperture of the oxygen molecule in K\n",
      "m = 32;\t\t        \t#molecular mass of the gas in gm\n",
      "r = 8.32*10**7;\t\t\t#molar gas consmath.tant in ergs per mole\n",
      "v2 = 33200.;\t\t\t#velocity of the gas in cm/sec\n",
      "\n",
      "# Calculations\n",
      "v1 = ((3*r*t)/m)**(1./2);\t\t\t#rms velocity of the molecule in cm/s\n",
      "T = ((v2*v2*m)/(3*r));\t\t\t#temperature of the molecule with sound has velocity in K\n",
      "\n",
      "# Result\n",
      "print 'the rms velocity of the molecule is %.2e cm/s  \\\n",
      "\\nthe temperature of the molecule is %3.0f K'%(v1,T)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the rms velocity of the molecule is 4.61e+04 cm/s  \n",
        "the temperature of the molecule is 141 K\n"
       ]
      }
     ],
     "prompt_number": 1
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.2 page no : 137"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "\n",
      "# Variables\n",
      "t1 = 308.;\t\t\t#temperature of the nitrogen molecule in K\n",
      "m1 = 28.;\t\t\t#molecular mass of the nitrogen in gm\n",
      "m2 = 2.;\t\t\t#molecular mass of the hydrogen molecule in gm\n",
      "\n",
      "# Calculations\n",
      "t2 = (t1*m2/m1);\t\t\t#temperature of the hydrogen molecule in K\n",
      "\n",
      "# Result\n",
      "print 'the temperature of the hydrogen molecule is %3.0fK'%(t2)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the temperature of the hydrogen molecule is  22K\n"
       ]
      }
     ],
     "prompt_number": 2
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.3 pageno : 138"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "# Variables\n",
      "y = 0.00129;\t\t\t#density of the air in gm/cc\n",
      "p = 76;\t\t\t#pressure of the nitrogen molecule in cm\n",
      "g = 981;\t\t\t#accelaration due to gravity in cm/sec**2\n",
      "m = 13.6;\t\t\t#density of the mercury in gm/cc\n",
      "\n",
      "# Calculations\n",
      "v = ((3*p*g*m)/y)**(1./2);\t\t\t#rms velocity of air at ntp in cm/sec\n",
      "\n",
      "# Result\n",
      "print 'the rms velocity of the air is %.2e cm/sec'%(v)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the rms velocity of the air is 4.86e+04 cm/sec\n"
       ]
      }
     ],
     "prompt_number": 3
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.4 pageno : 138"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "# Variables\n",
      "d = 16*0.000089;\t\t\t#density of the oxygen molecule in gm/cc\n",
      "p = 76;\t\t\t#pressure of the air in cm\n",
      "g = 981;\t\t\t#gravitaitonal accelaration in cm/sec**2\n",
      "m = 13.6;\t\t\t#density of the mercury in gm/cc\n",
      "\n",
      "# Calculations\n",
      "v = ((3*p*g*m)/d)**(1./2);\t\t\t#velocuty of the oxygen molecule in cm/sec\n",
      "\n",
      "# Result\n",
      "print 'velocity of oxygen molecule is %.2e cm/sec'%(v)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "velocity of oxygen molecule is 4.62e+04 cm/sec\n"
       ]
      }
     ],
     "prompt_number": 5
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.5 pageno : 138"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "# Variables\n",
      "t = 273;\t\t\t#temperature of the hydrogen molecule in K\n",
      "n = 6.03*10**23;\t\t\t#1 mole of hydrogen molecules\n",
      "r = 8.31*10**7;\t\t\t#universal gas consmath.tant in erg/K/mole\n",
      "\n",
      "# Calculations\n",
      "e = (1.5*r*t)/n;\t\t\t#kinetic energy of the hydrogen molecule in erg\n",
      "\n",
      "# Result\n",
      "print \"the kinetic energy of the hydrogen molecule is %.2e erg\"%e\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the kinetic energy of the hydrogen molecule is 5.64e-14 erg\n"
       ]
      }
     ],
     "prompt_number": 7
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.6 page no : 138"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "# Variables\n",
      "m = 1.;\t\t\t#mass of the oxygen in gm\n",
      "r = 8.31*10**7;\t\t\t#universal gas consmath.tant in erg/K/mole\n",
      "t = 320.;\t\t\t#temperature of the oxygen in K\n",
      "\t\t\t#for 1gm mole k.e is 1.5rt then for 1 gm oxygen (1/32)(k.e)\n",
      "\n",
      "# Calculations\n",
      "e = (m/32)*(3*r*t/2);\t\t\t#kinetic energy of the oxygen in erg\n",
      "\n",
      "# Result\n",
      "print 'the kinetic energy of the oxygen is %.2e erg'%(e)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the kinetic energy of the oxygen is 1.25e+09 erg\n"
       ]
      }
     ],
     "prompt_number": 9
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.7 pageno : 138"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "# Variables\n",
      "t = 273;\t\t\t#temperature at ntp in K\n",
      "\t\t\t#rms velocity of oxygen is 3/2 times its rms velocity at ntp then e1 = (3/2)*e\n",
      "\n",
      "# Calculations\n",
      "t1 = (9.*t/4.);\t\t\t#temperature of the oxygen molecule in K\n",
      "\n",
      "# Result\n",
      "print 'temperature of the oxygen in %3.1f K'%(t1)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "temperature of the oxygen in 614.2 K\n"
       ]
      }
     ],
     "prompt_number": 11
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.8 page no : 139"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "# Variables\n",
      "p = 10;\t\t\t#pressure of the gas in atm\n",
      "v = 5000;\t\t\t#volume of the gas in ml\n",
      "l = 76;\t\t\t#length of the mercury in barometer in cm\n",
      "g = 981;\t\t\t#accelaration due to gravity in cm/sec**2\n",
      "d = 13.6;\t\t\t#density of the mercury in gm/cc\n",
      "\n",
      "# Calculations\n",
      "e = 3*p*v*l*g*d;\t\t\t#kinetic energy of the molecule in ergs\n",
      "\n",
      "# Result\n",
      "print 'the kinetic energy of the molecule is %.2e ergs'%(e)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the kinetic energy of the molecule is 1.52e+11 ergs\n"
       ]
      }
     ],
     "prompt_number": 12
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.9 page no : 139"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "# Variables\n",
      "t = 323;\t\t\t#temperature of the hydrogen molecule in K\n",
      "m1 = 1;\t\t\t#mass of the hydrogen molecule in gm\n",
      "m2 = 2;\t\t\t#molecular weight of the hydrogen in gm\n",
      "r = 8.3*10**7;\t\t\t#universal gas consmath.tant in erg/K/mole\n",
      "\n",
      "# Calculations\n",
      "e = (m1*r*t*3/(m2*2));\t\t\t#kinetic enrgy of the hydrogen molecule in ergs\n",
      "\n",
      "# Result\n",
      "print 'the kinetic energy of the molecule is %.0e ergs'%(e)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the kinetic energy of the molecule is 2e+10 ergs\n"
       ]
      }
     ],
     "prompt_number": 13
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.10 page no : 139"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "\n",
      "# Variables\n",
      "t1 = 273;\t\t\t#temperature of the hydrogen molecule at n.t.p in K\n",
      "\n",
      "# Calculations\n",
      "#rms value of hydrogen molecule is double to its rms value at n.t.p, so 3rt/m = 4(3rt/m)\n",
      "t2 = 4*t1;\t\t\t#temperature of the hydrogen molecule in K\n",
      "\n",
      "# Result\n",
      "print 'the temperature of the hydrogen molecule is %.f K'%(t2)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the temperature of the hydrogen molecule is 1092 K\n"
       ]
      }
     ],
     "prompt_number": 14
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.11 page no : 139"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "# Variables\n",
      "t1 = 273.;\t\t\t#temperature of the hydrogen molecule in K\n",
      "t2 = 373;\t\t\t#temperature of the hydrogen molecule in K\n",
      "d = 0.0000896;\t\t\t#density of the hydrogen molecule in gm/cc\n",
      "p = 76*13.6*981;\t\t\t#pressure of the hydrogen molecule in gm/cm/sec**2\n",
      "\n",
      "# Calculations\n",
      "v0 = (3*p/d)**(0.5);\t\t\t#rms velocity at 0deg.C\n",
      "v100 = v0*(t2/t1)**(0.5);\t\t\t#rms velocity at 100deg.C\n",
      "\n",
      "# Result\n",
      "print 'the rms velocity at 0deg.C is %.2e cm/sec  \\\n",
      "\\nthe rms velocity at 100deg.C is %.3e cm/sec'%(v0,v100)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the rms velocity at 0deg.C is 1.84e+05 cm/sec  \n",
        "the rms velocity at 100deg.C is 2.154e+05 cm/sec\n"
       ]
      }
     ],
     "prompt_number": 16
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.12 page no : 140"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "\n",
      "# Variables\n",
      "cp = 6.84;\t\t\t#specific heat at consmath.tant pressure in cal/gm mole/deg.C\n",
      "r = 8.31*10**7;\t\t\t#universal gas constant in ergs/gm mole/deg.C\n",
      "v = 130000;\t\t\t#velocity of sound in cm/sec\n",
      "j = 4.2*10**7;\t\t\t#joules constant in ergs/cal\n",
      "\n",
      "#CALCULATION\n",
      "cv = cp-(r/j);\t\t\t#specific heat at constant volume in gm-mole/deg.C\n",
      "y = (cp/cv);\t\t\t#index of co-efficient\n",
      "v1 = (3/y)**(0.5)*v;\t\t\t#rms velocity in cm/sec\n",
      "\n",
      "# Result\n",
      "print 'the rms velocity of gas molecule is %.3e cm/sec'%(v1)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the rms velocity of gas molecule is 1.898e+05 cm/sec\n"
       ]
      }
     ],
     "prompt_number": 17
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.13 page no : 140"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "# Variables\n",
      "t = 300;\t\t\t#temperature of the oxygen molecule in K\n",
      "n = 6.02*10**23;\t\t\t#avagdrao's number\n",
      "m = 32/n;\t\t\t#mass of each molecule in oxygen\n",
      "k = 1.38*10**(-16);\t\t\t#boltzmann consmath.tant in erg/deg\n",
      "\n",
      "# Calculations\n",
      "v = (8*k*t/(3.14*m))**(0.5);\t\t\t#average velocity of oxygen molecule in cm/sec\n",
      "v2 = v*0.022384;\t\t\t#velocity in miles/hrs\n",
      "\n",
      "# Results\n",
      "print 'the avg velocity of  oxygen molecule is %.f miles/hour'%(v2)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the avg velocity of  oxygen molecule is 997 miles/hour\n"
       ]
      }
     ],
     "prompt_number": 18
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.14 page no : 140"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "# Variables\n",
      "v1 = 2.4;\t\t\t#velocity of first particle in km/sec\n",
      "v2 = 2.6;\t\t\t#velocity of second particle in km/sec\n",
      "v3 = 3.7;\t\t\t#velocity of third particle in km/sec\n",
      "\n",
      "# Calculations\n",
      "rv = ((v1**2+v2**2+v3**2)/(3))**(0.5);\t\t\t#rms velocity of the particles in km/sec\n",
      "mv = (v1+v2+v3)/(3);\t\t\t                #mean velocity of the particles in km/sec\n",
      "r = rv/mv;\t\t\t                            #ratio of the rms to mean velocity\n",
      "\n",
      "# Results\n",
      "print 'the ratio of rms to mean velocity is %3.3f'%(r)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the ratio of rms to mean velocity is 1.019\n"
       ]
      }
     ],
     "prompt_number": 19
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.15 pageno : 141"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "# Variables\n",
      "n = 2.76*10**19;\t\t\t#no.of molecules per cc\n",
      "d = 3.36*10**(-8);\t\t\t#diameter of the helium molecule in cm\n",
      "\n",
      "# Calculations\n",
      "mf = 1/((2**(0.5))*3.14*(d**2)*n)\n",
      "\n",
      "# Result\n",
      "print 'the mean free path of the hydrogen molecue is %.2e cm'%(mf)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the mean free path of the hydrogen molecue is 7.23e-06 cm\n"
       ]
      }
     ],
     "prompt_number": 20
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.16 page no : 141"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "# Variables\n",
      "n = 85*10**(-6);\t\t\t#coefficent of vismath.cosity in dynes/cm**2/velocity gradient\n",
      "c = 16*10**4;\t\t\t#velocity in cm/sec\n",
      "p = 0.000089;\t\t\t#density in gm/cc\n",
      "N = 6.06*10**23/22400;\t\t\t#avagadro number\n",
      "a = (2)**(0.5)*(22./7);\t\t\t#constant\n",
      "\n",
      "# Calculations\n",
      "mf = (3*n/(p*c));\t\t\t#mean free path in cm\n",
      "cr = c/mf;\t\t\t#collision rate\n",
      "d = (1/(a*N*mf))**(0.5);\t\t\t#molecular diameter of hydrogen gas in cm\n",
      "\n",
      "# Results\n",
      "print 'the mean free path is %.2e cm  \\\n",
      "\\nthe collision rate is %.1e  \\\n",
      "\\nthe molecular diameter of hydrogen gas is %.1e cm'%(mf,cr,d)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the mean free path is 1.79e-05 cm  \n",
        "the collision rate is 8.9e+09  \n",
        "the molecular diameter of hydrogen gas is 2.2e-08 cm\n"
       ]
      }
     ],
     "prompt_number": 3
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.17 page no : 141"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "\n",
      "# Variables\n",
      "d = 2*10**(-8);\t\t\t#diameter of the molecule in cm\n",
      "k = 1.38*10**(-6);\t\t\t#boltzmann constant in ergs/deg\n",
      "t = 273;\t\t\t#temperature at ntp in K\n",
      "p = 76*13.6*981;\t\t\t#pressure at ntp in gm/cm/sec**2\n",
      "\n",
      "# Calculations\n",
      "mf = ((k*t)/(2**(0.5)*3.14*(d**2)*p));\t\t\t#mean free path in cm\n",
      "\n",
      "# Result\n",
      "print 'mean free path at ntp is %.1e cm'%(mf)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "mean free path at ntp is 2.1e+05 cm\n"
       ]
      }
     ],
     "prompt_number": 22
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.18 page no : 141"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "# Variables\n",
      "t = 288;\t\t\t#temperature in K\n",
      "k = 1.38*10**(-16);\t\t\t#boltzmann constant in erg/deg\n",
      "N = 6.02*10**23;\t\t\t#avagadro number\n",
      "m = 32/N;\t\t\t#mass of each oxygen molecule in gm\n",
      "v = 196*10**-6;\t\t\t#viscosity in poise\n",
      "\n",
      "# Calculations\n",
      "av = ((8*k*t/(3.14*m))**0.5);\t\t\t#average velocity in cm/sec\n",
      "d = (m*av/(3*3.14*2**(0.5)*v))**0.5;\t\t\t#diameter of the molecule in cm\n",
      "\n",
      "# Results\n",
      "print 'diameter of the molecule is %.1e cm'%(d)\n",
      "print \"Note : answer is slightly different because of rounding error\""
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "diameter of the molecule is 3.0e-08 cm\n",
        "Note : answer is slightly different because of rounding error\n"
       ]
      }
     ],
     "prompt_number": 2
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.19 page no : 142"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "\n",
      "# Variables\n",
      "mf = 15;\t\t\t#mean free path in cm\n",
      "t = 300;\t\t\t#temperature of oxygen molecule in K\n",
      "d = 3*10**(-8);\t\t\t#diameter of the molecule in cm\n",
      "N = 6.02*10**23;\t\t\t#avagadro number\n",
      "r = 8.32*10**7;\t\t\t#universal gas constant in ergs/mole/deg\n",
      "a = (2**(0.5))*(22./7);\n",
      "\n",
      "#CALCULATIONS\n",
      "p = (r*t)/(N*a*(d**2)*mf);\t\t\t#pressure of the oxygen molecule in dynes/sq.cm\n",
      "\n",
      "# Result\n",
      "print 'the pressure of the oxygen molecule is %3.3f dynes/sq.cm'%(p)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the pressure of the oxygen molecule is 0.691 dynes/sq.cm\n"
       ]
      }
     ],
     "prompt_number": 27
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.20 pageno : 142"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "# Variables\n",
      "k = 5.64*10**-14;\t\t\t#kinetic energy of the hydrogen molecule ergs\n",
      "t = 273;\t\t\t#temperature of the oxygen molecule in K\n",
      "r = 8.32*10**7;\t\t\t#universal gas constant in ergs \n",
      "\n",
      "# Calculations\n",
      "N = (3./2)*(r*t/k);\t\t\t#avagadro number\n",
      "\n",
      "# Result\n",
      "print 'the avagadro number is %.2e'%(N)\n",
      "print \"Note : answer is slightly different because of rounding error\""
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the avagadro number is 6.04e+23\n",
        "Note : answer is slightly different because of rounding error\n"
       ]
      }
     ],
     "prompt_number": 30
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.21 pageno : 143"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "\n",
      "# Variables\n",
      "q = 5000;\t\t\t#total number of molecules\n",
      "e = 2.7183;\t\t\t#constant value\n",
      "t1 = 0.5;\t\t\t#distance travled to the mean free path\n",
      "t2 = 1;\t\t\t#distance travelled to the mean free path\n",
      "\n",
      "#CALCULATONS\n",
      "p1 = q*(e**-t1);\t\t\t#n0.of molecules having no collision in traversing a dismath.tance t1\n",
      "p2 = q*(e**-t2);\t\t\t#n0.of molecules having no collision in traversing a dismath.tance t2\n",
      "\n",
      "#OUPUT\n",
      "print 'the no. of molecules having no collision in traversing distance equal to 0.5 times the mean free path is %.f  \\\n",
      "\\nthe no. of molecules having no collision in traversing a distance equal to 1 time the mean free path is %.f'%(p1,p2)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the no. of molecules having no collision in traversing distance equal to 0.5 times the mean free path is 3033  \n",
        "the no. of molecules having no collision in traversing a distance equal to 1 time the mean free path is 1839\n"
       ]
      }
     ],
     "prompt_number": 5
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.22 page no  : 143"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "\n",
      "# Variables\n",
      "t = 38380;\t\t\t#temperature of the molecule in K\n",
      "k = 1.38*10**-16;\t\t\t#boltzman consmath.tant of one electron in ergs/K\n",
      "e = 1.6*10**-12;\t\t\t#charge of one electron volts\n",
      "\n",
      "#CALCULATIOS\n",
      "mk = 1.5*k*t/e;\t\t\t#mean kinetic energy per atom in ev\n",
      "\n",
      "# Result\n",
      "print 'the mean kinetic energy of the molecule is %3.2f ev'%(mk) \n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the mean kinetic energy of the molecule is 4.97 ev\n"
       ]
      }
     ],
     "prompt_number": 32
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.23 pageno : 143"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "# Variables\n",
      "v = 1.7*10**-4;\t\t\t#vismath.cosity of the air molecule in cgs\n",
      "d = 0.00129;\t\t\t#density of the molecule in gm/ml\n",
      "p = 76*13.6*981;\t\t\t#pressure of the molecule in gm/cm/sec**2\n",
      "\n",
      "# Calculations\n",
      "r = (3*p/d)**(0.5);\t\t\t#rms velocity of the molecule in cm/sec\n",
      "mf = (3*v/(d*r));\t\t\t#mean free path in cm\n",
      "cf = r/mf;\t\t\t#collision frequency\n",
      "\n",
      "# Result\n",
      "print 'the mean free path is %.1e cm  \\\n",
      "\\nthe collision frequency is %.e'%(mf,cf)\n",
      "print \"Note : answer is slightly different because of rounding error\""
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the mean free path is 8.1e-06 cm  \n",
        "the collision frequency is 6e+09\n",
        "Note : answer is slightly different because of rounding error\n"
       ]
      }
     ],
     "prompt_number": 36
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.24 page no : 143"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "# The pressure of the gas\n",
      "\n",
      "# Variables\n",
      "t2 = 296.4;\t\t\t#temperature of the first plate in K\n",
      "t1 = 304.7;\t\t\t#temperature of the second plate in K\n",
      "f = 1.6*10**-2;\t\t\t#force repelled cold is dynes/sq.cm\n",
      "\n",
      "# Calculations\n",
      "p = (4*f*t2/(t1-t2));\t\t\t#pressure of the gas in dynes/sq.cm\n",
      "\n",
      "# Result\n",
      "print 'the pressure of the gas is %3.3f dynes/sq.cm'%(p)\n",
      "print \"Note : mistake in answer in book. Please calculate manually.\""
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the pressure of the gas is 2.285 dynes/sq.cm\n",
        "Note : mistake in answer in book. Please calculate manually.\n"
       ]
      }
     ],
     "prompt_number": 40
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.25 page no : 144"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "# Variables\n",
      "mf = 28.5*10**-6;\t\t\t#mean free path in cm\n",
      "d = 0.000178;\t\t\t#density of helium in gm/ml\n",
      "m = 6*10**-24;\t\t\t#mass of the helium atom in gm\n",
      "a = (2**(0.5))*3.14;\t\t\t#constant\n",
      "\n",
      "# Calculations\n",
      "d = (m/(a*d*mf))**(0.5);\t\t\t#diameter of the size in cm\n",
      "\n",
      "# Result\n",
      "print 'the size of the helium atom is %.2e cm'%(d)\n",
      "print \"Note : answer is slightly different because of rounding error\""
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the size of the helium atom is 1.63e-08 cm\n",
        "Note : answer is slightly different because of rounding error\n"
       ]
      }
     ],
     "prompt_number": 42
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.26 page no : 144"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "\n",
      "# Variables\n",
      "a1 = 0*10**-4;\t\t\t#first horizontal print lacement in cm\n",
      "a2 = 5.6*10**-4;\t\t\t#second horizontal print lacement in cm\n",
      "a3 = -4.7*10**-4;\t\t\t#third horzontal print lacement in cm\n",
      "a4 = -10.8*10**-4;\t\t\t#fourth horizontal print lacement in cm\n",
      "a5 = 6.6*10**-4;\t\t\t#fifth horizontal print lacement print lacement in cm\n",
      "a6 = -9.8*10**-4;\t\t\t#sixth horizontal print lacement in cm\n",
      "a7 = -11.2*10**-4;\t\t\t#7th horizontal print lacement in cm\n",
      "a8 = -4.0*10**-4;\t\t\t#8th horizontal print lacement in cm\n",
      "a9 = 15.0*10**-4;\t\t\t#9thhorizontal print lacement in cm\n",
      "a10 = 19.1*10**-4;\t\t\t#10th horizontal print lacement in cm\n",
      "a11 = 16.0*10**-4;\t\t\t#11ht horizontal print lacement in cm\n",
      "T = 293;\t\t\t#temperature of the particle in K\n",
      "v = 0.01;\t\t\t#viscosity in cgs\n",
      "r = 1.15*10**-5;\t\t\t#radius of the particle in cm\n",
      "R = 8.32*10**7;\t\t\t#universal gas constant in kj/kg mole\n",
      "t = 30;\t\t\t#time for observation of each in sec\n",
      "\n",
      "# Calculations\n",
      "x = (a1**2+a2**2+a3**2+a4**2+a5**2+a6**2+a7**2+a8**2+a9**2+a10**2+a11**2)/11\n",
      "n = R*T*t/(x*3*3.14*v*r);\t\t\t#no.of molecules in the observation \n",
      "\n",
      "# Result\n",
      "print 'the value of n is %.1e'%(n)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the value of n is 5.7e+23\n"
       ]
      }
     ],
     "prompt_number": 43
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4.27 page no : 144"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "# Variables\n",
      "m = 6.*10**-24;\t\t\t#mass of the helium atom in gm\n",
      "k =  1.38*10**-16;\t\t\t#boltzmann consmath.tant in erg\n",
      "t1 = 100.;\t\t\t#temperature in K\n",
      "t2 = 900.;\t\t\t#temperature in K\n",
      "\n",
      "# Calculations\n",
      "r = (t1/t2)**(3./2)*(2.7183**(m*(1./(2*k))*10**8*(1-(1./9))));\t\t\t#fractional change in the no.of helium atoms\n",
      "\n",
      "#OUPUT\n",
      "print 'the fractional change in the no.of helium atoms %.3f'%(r)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "the fractional change in the no.of helium atoms 0.256\n"
       ]
      }
     ],
     "prompt_number": 45
    }
   ],
   "metadata": {}
  }
 ]
}