summaryrefslogtreecommitdiff
path: root/Engineering_Physics_by_G._Vijayakumari/Chapter1.ipynb
blob: aea79a8cc1746c1f2e4313897b87049fe9fa5cec (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
{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "#1: Acoustics"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##Example number 1.1, Page number 2"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The sound intensity level is imcreased by 13.01 dB when the intensity is doubled\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "i=20;     #the intensity of a source is increased 20 times\n",
    "\n",
    "#Calculation\n",
    "I=(10*(math.log10(i)));    #intensity of sound(dB)\n",
    "\n",
    "#Result\n",
    "print \"The sound intensity level is imcreased by\",round(I,2),\"dB when the intensity is doubled\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##Example number 1.2, Page number 2"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The sound intensity level is increased by 6 dB\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "i=4;   #the intensity of a source is increased 4 times\n",
    "\n",
    "#Calculation\n",
    "I=(10*(math.log10(i)));    #intensity of sound(dB)\n",
    "\n",
    "#Result\n",
    "print \"The sound intensity level is increased by\",int(I),\"dB\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##Example number 1.3, Page number 2"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The intensity level of a plane just leaving the runway is 150.0 dB\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "I=1000;   #sound intensity of plane leaving the runway(Wm**-2)\n",
    "Io=10**-12;    #threshold intensity of sound(Wm**-2)\n",
    "\n",
    "#Calculation\n",
    "IL=(10*math.log10(I/Io));   #The intensity level of a plane just leaving the runway(dB)\n",
    "\n",
    "#Result\n",
    "print \"The intensity level of a plane just leaving the runway is\",IL,\"dB\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##Example number 1.4, Page number 2"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The intensity level is 60.0 dB\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "I=10**-6;     #intensity of sound during heavy traffic(Wm**-2)\n",
    "Io=10**-12;   #threshold intensity of sound(Wm**-2)\n",
    "\n",
    "#Calculation\n",
    "IL=(10*math.log10(I/Io));    #The intensity level(dB)\n",
    "\n",
    "#Result\n",
    "print \"The intensity level is\",IL,\"dB\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##Example number 1.5, Page number 3"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The intensity level is -48.9994 dB\n",
      "answer varies due to rounding off errors\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "Q=3.56;     #rate of energy radiates(W)\n",
    "r=15;    #distance of intensity level(m)\n",
    "Io=100;  #reference intensity(Wm^-2)\n",
    "\n",
    "#Calculation\n",
    "A=4*math.pi*r**2;    #Area(m^2)\n",
    "I=(Q/A);    #sound intensity(Wm^-2)\n",
    "IL=(10*math.log10(I/Io));    #The intensity level(dB)\n",
    "\n",
    "#Result\n",
    "print \"The intensity level is\",round(IL,4),\"dB\"\n",
    "print \"answer varies due to rounding off errors\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##Example number 1.6, Page number 3"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The resultant sound level is 80.41 dB\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "Il1=70;   #sound(dB)\n",
    "Il2=80;   #sound(dB)\n",
    "\n",
    "#Calculation\n",
    "I1=10**(Il1/10);    #ratio of intensity\n",
    "I2=10**(Il2/10);    #ratio of intensity\n",
    "I=I1+I2;    #intensity of sound(dB)\n",
    "Il=10*math.log10(I);   #resultant intensity(dB)\n",
    "\n",
    "#Result\n",
    "print \"The resultant sound level is\",round(Il,2),\"dB\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##Example number 1.7, Page number 4"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The noise level at the point when 4 such drills are working at the same distance away is 101.02 dB\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "i=4;   #the intensity of a source\n",
    "I1=95;  #The noise level of sound from a drill(dB)\n",
    "\n",
    "#Calculation\n",
    "I2=(10*(math.log10(i)));    #intensity of source(dB)\n",
    "IL=I1+I2;    #The noise level at this point(dB)\n",
    "\n",
    "#Result\n",
    "print \"The noise level at the point when 4 such drills are working at the same distance away is\",round(IL,2),\"dB\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##Example number 1.8, Page number 4"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 17,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The flow of energy across 1m^2 per second is 6.638 *10**4 Wm**-2\n",
      "answer varies due to rounding off errors\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "f=426;    #frequency of sound(Hz)\n",
    "a=0.65*10**-2;   #amplitude of sound wave(m)\n",
    "A=1;     #area(m^2)\n",
    "v=340;   #velocity of sound in air(ms^-1)\n",
    "d=1.29;  #density of air(Kgm^-3)\n",
    "\n",
    "#Calculation\n",
    "I=(2*math.pi**2*f**2*a**2*d*v);     #The flow of energy across 1m^2 per second(Wm^-2*10^4)\n",
    "\n",
    "#Result\n",
    "print \"The flow of energy across 1m^2 per second is\",round(I/10**4,3),\"*10**4 Wm**-2\"\n",
    "print \"answer varies due to rounding off errors\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##Example number 1.9, Page number 12"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The reverberation time of the hall is 2.087 sec\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "V=1000;     #volume of hall(m^3)\n",
    "S=400;   #sound absorbing surface of area(m^2)\n",
    "a=0.2;   #average absorption coefficient(sabine)\n",
    "\n",
    "#Calculation\n",
    "T=(0.167*V)/(a*S);    #The reverberation time of the hall(sec)\n",
    "\n",
    "#Result\n",
    "print \"The reverberation time of the hall is\",round(T,3),\"sec\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##Example number 1.10, Page number 12"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The average absorbtion coefficient is 0.2374 O.W.U\n",
      "Total sound absorbtion of the room is 128.2 O.W.U m^2\n",
      "answer varies due to rounding off errors\n",
      "The reverberation time is 1.954 sec\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "V=1500;    #volume of room(m^3)\n",
    "a1=0.03;   #average sound coefficient for wall(sabine)\n",
    "a2=0.06;   #average sound coefficient for the ceiling(sabine)\n",
    "a3=0.8;    #average sound coefficient for the floor(sabine)\n",
    "S1=260;    #The wall area of the room(m^2)\n",
    "S2=140;    #The floor area of the room(m^2)\n",
    "S3=140;    #The ceiling area of the room(m^2)\n",
    "\n",
    "#Calculation\n",
    "a=((a1*S1)+(a2*S2)+(a3*S3))/(S1+S2+S3);     #The average absorbtion coefficient(O.W.U)\n",
    "TS=S1+S2+S3;     #total area of the room(m^2)\n",
    "x=(a*TS);      #Total sound absorbtion of the room(O.W.U m^2)\n",
    "T=((0.167*V)/x);   #The reverberation time(sec)\n",
    "\n",
    "#Result\n",
    "print \"The average absorbtion coefficient is\",round(a,4),\"O.W.U\"\n",
    "print \"Total sound absorbtion of the room is\",x,\"O.W.U m^2\"\n",
    "print \"answer varies due to rounding off errors\"\n",
    "print \"The reverberation time is\",round(T,3),\"sec\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##Example number 1.11, Page number 13"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The area of interior surfaces is 3340.0 m**2\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "V=12000;   #volume of auditorium(m^3)\n",
    "T=1.5;    #The reverberation time of the auditorium(sec)\n",
    "a=0.4;    #average absorption coefficient(sabine)\n",
    "\n",
    "#Calculation\n",
    "S=(0.167*V)/(a*T);      #area of interior surfaces(m^2)\n",
    "\n",
    "#Result\n",
    "print \"The area of interior surfaces is\",S,\"m**2\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##Example number 1.12, Page number 13"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The total absorbtion in the hall is 835.0 sabine m^2\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "V=7500;   #volume of cinema hall(m^3)\n",
    "T=1.5;    #The reverberation time of the cinema hall(sec)\n",
    "\n",
    "#Calculation\n",
    "TaS=(0.167*V)/(T);     #The total absorbtion in the hall(sabine m^2)\n",
    "\n",
    "#Result\n",
    "print \"The total absorbtion in the hall is\",TaS,\"sabine m^2\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##Example number 1.13, Page number 13"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The new reverberation time after placing the cushioned chairs is 1.3115 sec\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "V=12500;    #volume of hall(m^3)\n",
    "T1=1.5;     #The reverberation time of the hall(sec)\n",
    "a2S2=200;   #The number of cushioned chairs are additionally placed in the hall(sabine-m^2)\n",
    "\n",
    "#Calculation\n",
    "Ta1S1=(0.167*V)/T1;    #The reverberation time before placed cushioned chairs(sabine m^2)\n",
    "T2=(0.167*V)/(Ta1S1+a2S2);    #The new reverberation time after placing the cushioned chairs(sec)\n",
    "\n",
    "#Result\n",
    "print \"The new reverberation time after placing the cushioned chairs is\",round(T2,4),\"sec\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##Example number 1.14, Page number 14"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 12,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The reverberation time for the hall is 1.2794 sec\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "V=475;    #volume of hall(m^3)\n",
    "a1=0.025;    #absorbtion coefficient for wall(O.W.U)\n",
    "a2=0.02;     #absorbtion coefficient for the ceiling(O.W.U)\n",
    "a3=0.55;     #absorbtion coefficient for the floor(O.W.U)\n",
    "S1=200;    #The wall area of the room(m^2)\n",
    "S2=100;    #The floor area of the room(m^2)\n",
    "S3=100;    #The ceiling area of the room(m^2)\n",
    "\n",
    "#Calculation\n",
    "TaS=((a1*S1)+(a2*S2)+(a3*S3));   #The average absorbtion coefficient(O.W.U-m^2)\n",
    "T=((0.167*V)/TaS);    #The reverberation time(sec)\n",
    "\n",
    "#Result\n",
    "print \"The reverberation time for the hall is\",round(T,4),\"sec\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##Example number 1.15, Page number 14"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 16,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The reverberation time in the hall without audience is 3.9879 sec\n",
      "The reverberation time in the hall with audience is 1.99396 sec\n",
      "Thus,the reverberation reduces to half of its initial value when the audience fill the hall\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "V=2265;    #volume of hall(m^3)\n",
    "Ta1S1=94.85;   #The total absorbtion coefficient(m^2)\n",
    "\n",
    "#Calculation\n",
    "T1=((0.167*V)/Ta1S1);    #The reverberation time in the hall without audience(sec)\n",
    "Ta2S2=2*Ta1S1;   #The new absorbtion coefficient(m^2)\n",
    "T2=((0.167*V)/Ta2S2);    #The reverberation time in the hall with audience(sec)\n",
    "\n",
    "#Result\n",
    "print \"The reverberation time in the hall without audience is\",round(T1,4),\"sec\"\n",
    "print \"The reverberation time in the hall with audience is\",round(T2,5),\"sec\"\n",
    "print \"Thus,the reverberation reduces to half of its initial value when the audience fill the hall\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "##Example number 1.16, Page number 14"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 18,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The average absorbing power of the surface is 0.48789 sabine\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "V=120000;   #Volume of the hall(m^3)\n",
    "T=1.55;    #The reverberation time(sec)\n",
    "S=26500;   #The total absorbing surface(m^2)\n",
    "\n",
    "#Calculation\n",
    "TaS=(0.167*V)/T;   #The average absorbtion coefficient(sabine-m^2)\n",
    "a=(TaS/S);    #The average absorbing power of the surface(sabine)\n",
    "\n",
    "#Result\n",
    "print \"The average absorbing power of the surface is\",round(a,5),\"sabine\""
   ]
  }
 ],
 "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
}