summaryrefslogtreecommitdiff
path: root/Internal_Combustion_Engines_by_H._B._Keswani/ch9.ipynb
blob: 86ac36dcb957007e1c2be62fdbca0777b97e8af0 (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
{
 "metadata": {
  "name": "",
  "signature": "sha256:a00950cac65288537bd949d90aa1f43e30aec0286f6a7dcfeeece2c2ad5453d8"
 },
 "nbformat": 3,
 "nbformat_minor": 0,
 "worksheets": [
  {
   "cells": [
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {},
     "source": [
      "Chapter 9 : Spark Ignition Engines"
     ]
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.1  Page no :  188"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math \n",
      "\t\t\t\t\t\n",
      "#Input data\n",
      "d = 0.001\t\t\t\t\t#Diameter of the jet in m\n",
      "vd = 104.\t\t\t\t\t#Venturi depression in cm of water. In textbook, it is given as 10 cm\n",
      "Cd = 0.65\t\t\t\t\t#Coefficient of discharge \n",
      "g = 0.76\t\t\t\t\t#Specific gravity of petrol\n",
      "w = 1000.\t\t\t\t\t#Weight of water per one cu.m in kg\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Calculations\n",
      "pa = (vd/100)*w\t\t\t\t\t#Venturi depression in kg/m**2\n",
      "dp = (g*w)\t\t\t\t\t#Density of petrol in kg/m**3\n",
      "wf = (((3.14*d**2)/4)*Cd*math.sqrt(2*9.81*dp*pa))/10**-3\t\t\t\t\t#Petrol discharge in gm/sec neglecting nozzle lip\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Output\n",
      "print 'The weight of petrol discharged is %3.2f gm/sec'%(wf)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The weight of petrol discharged is 2.01 gm/sec\n"
       ]
      }
     ],
     "prompt_number": 1
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.2  Page no :  193"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math \n",
      "\t\t\t\t\t\n",
      "#Input data\n",
      "d1 = 0.075\t\t\t\t\t#Throat diameter in m\n",
      "Ca = 0.93\t\t\t\t\t#Coefficient of air flow\n",
      "d2 = 0.005\t\t\t\t\t#Orifice diameter in m\n",
      "Cf = 0.68\t\t\t\t\t#Coefficient of fuel discharge\n",
      "ap = 1.\t\t\t\t\t#Approach factor\n",
      "dp = 0.15\t\t\t\t\t#Pressure drop in kg/cm**2\n",
      "da = 1.29\t\t\t\t\t#Density of air in kg/m**3\n",
      "df = 720\t\t\t\t\t#Density of fuel in kg/m**3\n",
      "\n",
      "\t\t\t\t\t#Calcultions\n",
      "w = (((3.14/4)*d1**2)/((3.14/4)*d2**2))*(Ca/Cf)*math.sqrt(da/df)\t\t\t\t\t#The air-fuel ratio neglecting the nozzle lip\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Output\n",
      "print 'The air-fuel ratio neglecting the nozzle lip is %3.1f'%(w)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The air-fuel ratio neglecting the nozzle lip is 13.0\n"
       ]
      }
     ],
     "prompt_number": 2
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.3  Page no :  193"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math \n",
      "\t\t\t\t\t\n",
      "#Input data\n",
      "af = 15.\t\t\t\t\t#Air fuel ratio\n",
      "dp = 753.\t\t\t\t\t#Density of petrol in kg/m**3\n",
      "da = 1.28\t\t\t\t\t#Density of air in kg/m**3\n",
      "C = [0.84,0.7]\t\t\t\t\t#Coefficient of discharge for air and fuel respectively\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Calculations\n",
      "A = 1/(af*(C[1]/C[0])*math.sqrt(dp/da))\t\t\t\t\t#Ratio of areas\n",
      "d = math.sqrt(A)\t\t\t\t\t#Ratio of diamter of jet to diameter of venturi\n",
      "x = (1/d)\t\t\t\t\t#Reverse of ratio\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Output\n",
      "print 'The ratio of diameter of jet to diameter of venturi is 1 : %3.1f'%(x)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The ratio of diameter of jet to diameter of venturi is 1 : 17.4\n"
       ]
      }
     ],
     "prompt_number": 3
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.4  Page no :  194"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math \n",
      "\t\t\t\t\t\n",
      "#Input data\n",
      "D = [10.,12.]\t\t\t\t\t#Dimensions of four cylinder in 10 cm* 12 cm\n",
      "n = 4.\t\t\t\t\t#Four cylinder\n",
      "N = 2000.\t\t\t\t\t#Speed in r.p.m\n",
      "d = 0.03\t\t\t\t\t#Venturi throat in m\n",
      "nv = 70.\t\t\t\t\t#Volumetric efficiency of the engine in percent\n",
      "Ca = 0.8\t\t\t\t\t#Coefficient of air flow\n",
      "da = 1.29\t\t\t\t\t#Density of air in kg/m**3\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Calculations\n",
      "Vs = (3.14/4)*(D[0]/100)**2*(D[1]/100)\t\t\t\t\t#Stroke volume of one cylinder in m**3\n",
      "Va = (Vs*n*(nv/100)*(N/2))\t\t\t\t\t#Volume of air drawn per minute in m**3\n",
      "w = (Va*da)/60\t\t\t\t\t#Weight of air drawn per sec\n",
      "dp = ((w/((3.14/4)*d**2*Ca))**2/(2*9.81*da))\t\t\t\t\t#Venturi depression in kg/cm**2\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Output\n",
      "print 'The venturi depression is %3.1f kg/m**2'%(dp)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The venturi depression is 397.7 kg/m**2\n"
       ]
      }
     ],
     "prompt_number": 4
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.5  Page no :  198"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math \n",
      "\t\t\t\t\t\n",
      "#Input data\n",
      "D = [8.25,11.5]\t\t\t\t\t#Dimensions of four cylinder in 8.25 cm* 11.5 cm\n",
      "n = 4.\t\t\t\t\t#Four cylinder\n",
      "N = 3000.\t\t\t\t\t#Speed in r.p.m\n",
      "v = 150.\t\t\t\t\t#Venturi depression in cm of water\n",
      "nv = 80.\t\t\t\t\t#Volumetric efficiency of the engine in percent\n",
      "af = 14.\t\t\t\t\t#Air fuel ratio\n",
      "Ca = 0.84\t\t\t\t\t#Coefficient of air flow\n",
      "Cf = 0.7\t\t\t\t\t#Coefficient of fuel orifice \n",
      "da = 1.29\t\t\t\t\t#Density of air in kg/m**3\n",
      "df = 700.\t\t\t\t\t#Density of fuel in kg/m**3\n",
      "dw = 1000.\t\t\t\t\t#Density of water in kg/m**3\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Calculations\n",
      "Va = ((3.14/4)*(D[0]/100)**2*(D[1]/100)*n*(nv/100)*(N/(2*60)))\t\t\t\t\t#Maximum amount of air pasmath.sing through the venturi in m**3\n",
      "vd = (v/100)*dw\t\t\t\t\t#Venturi depression in kg/m**2\n",
      "va = (Ca*math.sqrt((2*9.81*vd)/da))\t\t\t\t\t#Velocity of air in m/s\n",
      "d = math.sqrt((Va/va)*(4/3.14))\t\t\t\t\t#Throat diameter of venturi in m\n",
      "Af = 1/(af*(va/Va)*math.sqrt(df/da)*(Cf/Ca))\t\t\t\t\t#Area of orifice in m**2\n",
      "df = math.sqrt((Af*4)/3.14)*1000\t\t\t\t\t#Diameter of orifice in mm\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Output\n",
      "print 'The size of venturi is %i kg/m**2  \\\n",
      "\\nThe diameter of fuel orifice is %3.2f mm'%(vd,df)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The size of venturi is 1500 kg/m**2  \n",
        "The diameter of fuel orifice is 1.35 mm\n"
       ]
      }
     ],
     "prompt_number": 5
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.6  Page no :  198"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math \n",
      "D = [7.5,10]\t\t\t\t\t#Dimensions of four cylinder in 7.5 cm diameter and 10 cm stroke\n",
      "n = 6.\t\t\t\t\t#Six cylinder\n",
      "pC = 84.\t\t\t\t\t#Percentage of carbon in volatile fuel\n",
      "pH2 = 16.\t\t\t\t\t#Percentage of hydrogen in volatile fuel\n",
      "dc = (38.5/1000)\t\t\t\t\t#Diameter of the throat of the choke tube in m\n",
      "N = 3000.\t\t\t\t\t#Speed in r.p.m\n",
      "nv = 0.8\t\t\t\t\t#Volumetric efficiency in ratio\n",
      "p = 0.914\t\t\t\t\t#Pressure at the throat of the choke tube in kg/cm**2\n",
      "T = 15.5+273\t\t\t\t\t#Temperature at the throat of the choke tube in K\n",
      "Ts = 273.\t\t\t\t\t#Temperature of 0 degree C in K\n",
      "ps = 1.027\t\t\t\t\t#Atmospheric pressure in kg/cm**2\n",
      "Ra = 29.27\t\t\t\t\t#Universal gas constant for air in kg.m/kg.K\n",
      "Rf = 9.9\t\t\t\t\t#Gas constant for fuel in kg.m/kg.K\n",
      "pO2 = 23.\t\t\t\t\t#Composition by weight of oxygen in air in percent\n",
      "pN2 = 77.\t\t\t\t\t#Composition by weight of nitogen in air in percent\n",
      "mO2 = 32.\t\t\t\t\t#Molecular weight of O2\n",
      "mH2 = 2.\t\t\t\t\t#Molecular weight oh H2\n",
      "mC = 12.\t\t\t\t\t#Molecular weight of carbon\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Calculations\n",
      "Vm = ((3.14/4)*(D[0]/100)**2*(D[1]/100)*n*(N/2)*nv)\t\t\t\t\t#Volume of mixture supplied per sec in m**3\n",
      "qa = ((100/pO2)*(((pC/100)*(mO2/mC))+((pH2/100)*(mO2/(2*mH2)))))\t\t\t\t\t#Quantity of air required for complete combustion of fuel in kg\n",
      "vf = (Rf*Ts)/(ps*10**4)\t\t\t\t\t#Specific volume of volatile fuel in m**3/kg\n",
      "va = (Ra*Ts)/(ps*10**4)\t\t\t\t\t#Specific volume of air in m**3/kg\n",
      "wf = (Vm/(qa*va+vf))\t\t\t\t\t#Flow rate of fuel in kg/min\n",
      "Fc = (wf*60)\t\t\t\t\t#Fuel consumption in kg/hour\n",
      "da = (p*10**4)/(Ra*T)\t\t\t\t\t#Density of air at the throat of the choke in kg/m**3\n",
      "Va = ((qa*wf)/((3.14/4)*dc**2*da*60))\t\t\t\t\t#Speed of air at throat in m/s\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Output\n",
      "print 'a) The fuel consumption is %3.1f kg/hr  \\\n",
      "\\nb) The speed of the air through the choke is %3.1f m/s'%(Fc,Va)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "a) The fuel consumption is 0.0 kg/hr  \n",
        "b) The speed of the air through the choke is 0.0 m/s\n"
       ]
      }
     ],
     "prompt_number": 6
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.7  Page no :  203"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math \n",
      "\t\t\t\t\t\n",
      "#Input data\n",
      "mf = 7.5\t\t\t\t\t#Consumption of petrol per hour\n",
      "gf = 0.75\t\t\t\t\t#Specific gravity of fuel\n",
      "Tf = 25+273\t\t\t\t\t#Temperature of fuel in K\n",
      "af = 15\t\t\t\t\t#Air fuel ratio\n",
      "dc = 22\t\t\t\t\t#diameter of choke tube in mm\n",
      "l = 4\t\t\t\t\t#Top of the jet is 4 mm above the petrol level in the float chamber\n",
      "Ca = 0.82\t\t\t\t\t#Coefficient of discharge for air \n",
      "Cf = 0.7\t\t\t\t\t#Coefficient of discharge for fuel\n",
      "R = 29.27\t\t\t\t\t#Characteristic gas constant for air in kg.m/kg.K\n",
      "p = 1.03\t\t\t\t\t#Atmospheric pressure in kg/cm**2\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Calculations\n",
      "da = (p*10**4)/(R*Tf)\t\t\t\t\t#Density of air in kg/m**3 \n",
      "dp = (gf*1000)\t\t\t\t\t#Density of petrol in kg/cm**3\n",
      "dpa = ((af*mf*10**6)/(60*60*3.14*Ca*(dc/2)**2))**2/(2*9.81*da)\t\t\t\t\t#Change in pressure in kg/m**2\n",
      "df = math.sqrt((mf/(60*60*Cf*math.sqrt(2*9.81*dp*(dpa-((l/100)*dp)))))*(4/3.14))*1000\t\t\t\t\t#Diameter of the fuel jet in mm\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Output\n",
      "print 'Diameter of the jet of the carburettor is %3.2f mm'%(df) \n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Diameter of the jet of the carburettor is 1.22 mm\n"
       ]
      }
     ],
     "prompt_number": 7
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.8  Page no :  207"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math \n",
      "\t\t\t\t\t\n",
      "#Input data\n",
      "td = 7.5\t\t\t\t\t#Throat diameter in cm\n",
      "Ca = 0.85\t\t\t\t\t#Coefficient of air flow\n",
      "fd = 0.5\t\t\t\t\t#Diameter of fuel orifice in cm\n",
      "Cd = 0.7\t\t\t\t\t#Coefficient of discharge\n",
      "l = 5\t\t\t\t\t#Nozzle lip in mm\n",
      "x = 1\t\t\t\t\t#Approach factor\n",
      "dpa = 0.15\t\t\t\t\t#Pressure drop in kg/cm**2\n",
      "da = 1.29\t\t\t\t\t#Density of air in kg/m**3\n",
      "dp = 720\t\t\t\t\t#Density of fuel in kg/m**3\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Calculations\n",
      "afr1 = (((3.14*td**2)/(3.14*fd**2))*(Ca/Cd)*math.sqrt(da/dp))\t\t\t\t\t#Air fuel ratio\n",
      "afr2 = ((3.14*td**2)/(3.14*fd**2))*(Ca/Cd)*math.sqrt((da*dpa)/(dp*(dpa-((l/100)*(dp/10**6)))))\t\t\t\t\t#Air fuel ratio\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Output\n",
      "print 'The air fuel ratio  \\\n",
      "\\na) neglecting nozzle lip is %3.2f  \\\n",
      "\\nb) nozzle lip is taken into account is %3.2f'%(afr1,afr2)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The air fuel ratio  \n",
        "a) neglecting nozzle lip is 11.56  \n",
        "b) nozzle lip is taken into account is 11.56\n"
       ]
      }
     ],
     "prompt_number": 8
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.9  Page no :  209"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math \n",
      "\t\t\t\t\t\n",
      "#Input data\n",
      "td = 7.5\t\t\t\t\t#Throat diameter in cm\n",
      "Ca = 0.85\t\t\t\t\t#Coefficient of air flow\n",
      "fd = 0.5\t\t\t\t\t#Diameter of fuel orifice in cm\n",
      "Cd = 0.7\t\t\t\t\t#Coefficient of discharge\n",
      "l = 5.\t\t\t\t\t#Nozzle lip in mm\n",
      "x = 1.\t\t\t\t\t#Approach factor\n",
      "dpa = 0.15\t\t\t\t\t#Pressure drop in kg/cm**2\n",
      "da = 1.29\t\t\t\t\t#Density of air in kg/m**3\n",
      "dp = 720\t\t\t\t\t#Density of fuel in kg/m**3\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Calculations\n",
      "v = math.sqrt(2*9.81*(l/1000)*(dp/da))\t\t\t\t\t#Velocity of air in m/s\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Output\n",
      "print 'Velocity of air flow is %3.1f m/s'%(v)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Velocity of air flow is 7.4 m/s\n"
       ]
      }
     ],
     "prompt_number": 10
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.10  Page no :  212"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math \n",
      "\t\t\t\t\t\n",
      "#Input data\n",
      "x = 2.8\t\t\t\t\t#Height above the nozzle in mm\n",
      "va = 58\t\t\t\t\t#Velocity of air in m/s\n",
      "da = 1.28\t\t\t\t\t#Density of air in kg/m**3\n",
      "dp = 750\t\t\t\t\t#Density of petrol in kg/m**3\n",
      "An = 1.8\t\t\t\t\t#Area of cross section of nozzle in mm**2\n",
      "Cd = 0.6\t\t\t\t\t#Coefficient of discharge of nozzle \n",
      "Ca = 0.84\t\t\t\t\t#Coefficient of discharge of air\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Calculations\n",
      "dpa = ((va/Ca)**2*(da/(2*9.81)))\t\t\t\t\t#Change in pressure in kg/m**2\n",
      "wf = ((An*10**-6)*Cd*math.sqrt(2*9.81*dp*(dpa-((x/1000)*dp))))\t\t\t\t\t#Petrol consumption in kg/sec\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Output\n",
      "print 'Petrol consumption is %3.4f kg/sec'%(wf)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Petrol consumption is 0.0023 kg/sec\n"
       ]
      }
     ],
     "prompt_number": 11
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.11  Page no :  214"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math \n",
      "\t\t\t\t\t\n",
      "#Input data\n",
      "d = 0.155\t\t\t\t\t#Diameter of orifice in mm\n",
      "Cd = 0.94\t\t\t\t\t#Coefficient of discharge\n",
      "td = 3.18\t\t\t\t\t#Throat diameter in cm\n",
      "Ca = 0.84\t\t\t\t\t#Coefficient of discharge\n",
      "x = 29\t\t\t\t\t#Venturi depression\n",
      "dw = 0.89\t\t\t\t\t#Minimum depression of water in cm\n",
      "sa = 1.1\t\t\t\t\t#Specific weight of air in kg/m**3\n",
      "sg = 0.72\t\t\t\t\t#Specific gravity of petrol\n",
      "cyd = [7.75,10.75]\t\t\t\t\t#Cylinder dimensions in cm\n",
      "fc = 10.9\t\t\t\t\t#Fuel consumption in kg/hr\n",
      "N = 3200\t\t\t\t\t#Speed in r.p.m\n",
      "n = 4\t\t\t\t\t#Number of cylinders\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Calculations\n",
      "w = (((3.14/4)*td**2)/((3.14/4)*d**2))*(Ca/Cd)*math.sqrt((sa/(sg*1000))*(x/(x-dw)))\t\t\t\t\t#Air fuel ratio\n",
      "Va = (3.14/4)*(td/100)**2*Ca*math.sqrt(2*9.81*sa*x*6)\t\t\t\t\t#Volume of air drawn/sec\n",
      "vn = (Va/((3.14/4)*(cyd[0]/100)**2*(cyd[1]/100)*n*(N/(2*60))))*100\t\t\t\t\t#Volumetric efficiency in percent\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Output\n",
      "print 'Air fue ratio is %3.1f  \\\n",
      "\\nVolumetric efficiency is %3.1f percent'%(w,vn)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Air fue ratio is 14.9  \n",
        "Volumetric efficiency is 77.5 percent\n"
       ]
      }
     ],
     "prompt_number": 12
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.12  Page no :  219"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math \n",
      "\t\t\t\t\t\n",
      "#Input data\n",
      "af = 0.066\t\t\t\t\t#Air fuel ratio\n",
      "p = 0.83\t\t\t\t\t#Pressure at the venturi throat in kg/cm**2\n",
      "pd = 0.04\t\t\t\t\t#Pressure drop in kg/cm**2\n",
      "va = 245\t\t\t\t\t#Air flow at sea level in kg per hour\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Calculations\n",
      "dpa = 1.03-p\t\t\t\t\t#Pressure at air cleaner in kg/cm**2\n",
      "d = (1.03-pd-dpa)\t\t\t\t\t#Throat pressure when the air cleaner is fitted in kg/cm**2\n",
      "naf = (af*math.sqrt((1.03-d)/dpa))\t\t\t\t\t#New air fuel ratio\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Output\n",
      "print 'a) Throat pressure when the air cleaner is fitted is %3.2f kg/cm**2  \\\n",
      "\\nb) New air fuel ratio is %3.4f'%(d,naf)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "a) Throat pressure when the air cleaner is fitted is 0.79 kg/cm**2  \n",
        "b) New air fuel ratio is 0.0723\n"
       ]
      }
     ],
     "prompt_number": 13
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.13  Page no :  221"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math \n",
      "\t\t\t\t\t\n",
      "#Input data\n",
      "x = 3\t\t\t\t\t#Petrol smath.radians(numpy.arcmath.tan(s 3 mm below\n",
      "Ta = 15.5+273\t\t\t\t\t#Temperature of air in K\n",
      "pa = 1.027\t\t\t\t\t#Pressure of air in kg/cm**2\n",
      "R = 29.27\t\t\t\t\t#Characteristic gas constant in kg.m/kg.K \n",
      "sg = 0.76\t\t\t\t\t#Specific gravity of fuel\n",
      "fc = 6.4\t\t\t\t\t#Consumption of fuel in kg/hour\n",
      "jd = 1.27\t\t\t\t\t#Jet diameter in mm\n",
      "Cd = 0.6\t\t\t\t\t#Nozzle discharge coefficienct\n",
      "Ca = 0.8\t\t\t\t\t#Discharge coefficient of air\n",
      "af = 0.066\t\t\t\t\t#Air fuel ratio\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Calculations\n",
      "df = (sg*1000)\t\t\t\t\t#Density of fuel in kg/m**3\n",
      "da = (pa*10**4)/(R*Ta)\t\t\t\t\t#Density of air in kg/m**3\n",
      "va = Ca*math.sqrt((2*9.81*x*df)/(da*1000))\t\t\t\t\t#Critical velocity of air in m/s\n",
      "dpa = (((fc/(60*60))/((3.14/4)*(jd/1000)**2*Cd))**2/(2*9.81*df))+((x/1000)*df)\t\t\t\t\t#Drop in pressure in kg/m**3\n",
      "dpaw = (dpa/1000)*100\t\t\t\t\t#Drop in pressure in cm of water\n",
      "dj = math.sqrt(((fc/(3600*af))/(Ca*math.sqrt(2*9.81*da*dpa)))/(3.14/4))*1000\t\t\t\t\t#Effective throat diameter in mm\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Output\n",
      "print 'Critical air velocity is %3.2f m/sec  \\\n",
      "\\nEffective throat diameter of the venturi is %3.1f mm  \\\n",
      "\\nThe drop in pressure in the venturi is %3.2f cm of water'%(va,dj,dpaw)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Critical air velocity is 4.85 m/sec  \n",
        "Effective throat diameter of the venturi is 21.4 mm  \n",
        "The drop in pressure in the venturi is 36.73 cm of water\n"
       ]
      }
     ],
     "prompt_number": 14
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.14  Page no :  226"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math \n",
      "\t\t\t\t\t\n",
      "#Input data\n",
      "ma = 6.11\t\t\t\t\t#Flow rate of air in kg/min\n",
      "mf = 0.408\t\t\t\t\t#Flow arte of petrol in kg/min\n",
      "dp = 768\t\t\t\t\t#Density of petrol in kg/m**3\n",
      "Ta = 15.5+273\t\t\t\t\t#Temperature of air in K\n",
      "pa = 1.027\t\t\t\t\t#Pressure of air in kg/cm**2\n",
      "R = 29.27\t\t\t\t\t#Characteristic gas constant in kg.m/kg.K \n",
      "va = 97.5\t\t\t\t\t#Speed of air in m/sec\n",
      "Cv = 0.84\t\t\t\t\t#Velocity coefficient\n",
      "g = 1.4\t\t\t\t\t#Ratio of specific heats \n",
      "x = 0.8\t\t\t\t\t#pressure at the venturi is 0.8 of the pressure drop at the choke\n",
      "Cd = 0.66\t\t\t\t\t#Coefficient of discharge\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Calculations\n",
      "rp = (1-((va/Cv)**2/(((2*9.81*g)/(g-1))*R*Ta)))**(g/(g-1))\t\t\t\t\t#Pressure ratio\n",
      "p2 = (pa*rp)\t\t\t\t\t#Pressure in kg/cm**2\n",
      "T2 = (Ta*rp**((g-1)/g))\t\t\t\t\t#Temperature in K\n",
      "da = (p2/(R*T2))*10**4\t\t\t\t\t#Density in kg/m**3\n",
      "daa = math.sqrt((ma/(60*va*da))/(3.14/4))*1000\t\t\t\t\t#Throat diameter in mm\n",
      "df = math.sqrt((mf/(60*Cd*math.sqrt(2*9.81*dp*x*(pa-p2)*10**4)))/(3.14/4))*1000\t\t\t\t\t#Orifice diameter in mm\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Output\n",
      "print 'Throat diameter of the choke is %i mm  \\\n",
      "\\nThe orifice diameter is %3.2f mm'%(daa,df)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Throat diameter of the choke is 34 mm  \n",
        "The orifice diameter is 2.05 mm\n"
       ]
      }
     ],
     "prompt_number": 15
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.15  Page no :  226"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math \n",
      "\t\t\t\t\t\n",
      "#Input data\n",
      "ma = 6.8\t\t\t\t\t#Mass flow rate of air in kg/min\n",
      "mf = 0.45\t\t\t\t\t#Mass flow rate of petrol in kg/min\n",
      "pa = 1.033\t\t\t\t\t#Pressure of air in kg/cm**2\n",
      "Ta = 20+273\t\t\t\t\t#Temperature of air in K\n",
      "va = 97.5\t\t\t\t\t#Velocity of air in m/s\n",
      "Cv = 0.8\t\t\t\t\t#Velocity coefficient\n",
      "g = 1.4\t\t\t\t\t#Ratio of specific heats \n",
      "R = 29.27\t\t\t\t\t#Characteristic gas constant in kg.m/kg.K \n",
      "x = 0.75\t\t\t\t\t#pressure at the venturi is 0.8 of the pressure drop at the choke\n",
      "Cd = 0.65\t\t\t\t\t#Coefficient of discharge\n",
      "pw = 800\t\t\t\t\t#Weight of petrol in kg per cu.m\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Calculations\n",
      "rp = (1-((va/Cv)**2/(((2*9.81*g)/(g-1))*R*Ta)))**(g/(g-1))\t\t\t\t\t#Pressure ratio\n",
      "p2 = (pa*rp)\t\t\t\t\t#Pressure in kg/cm**2\n",
      "T2 = (Ta*rp**((g-1)/g))\t\t\t\t\t#Temperature in K\n",
      "da = (p2/(R*T2))*10**4\t\t\t\t\t#Density in kg/m**3\n",
      "daa = math.sqrt((ma/(60*va*da))/(3.14/4))*100\t\t\t\t\t#Throat diameter in mm\n",
      "df = math.sqrt((mf/(60*Cd*math.sqrt(2*9.81*pw*x*(pa-p2)*10**4)))/(3.14/4))\t\t\t\t\t#Orifice diameter in mm\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Output\n",
      "print 'Throat diameter of the choke is %3.2f cm  \\\n",
      "\\nThe orifice diameter is %3.5f m'%(daa,df)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Throat diameter of the choke is 3.62 cm  \n",
        "The orifice diameter is 0.00213 m\n"
       ]
      }
     ],
     "prompt_number": 16
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 9.16  Page no :  229"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math \n",
      "\t\t\t\t\t\n",
      "#Input data\n",
      "n = 6.\t\t\t\t\t#Number of cylinders\n",
      "d = 100.\t\t\t\t\t#Diameter in mm\n",
      "L = 100.\t\t\t\t\t#Stroke in mm\n",
      "N = 1500.\t\t\t\t\t#Speed in r.p.m\n",
      "ap = 13.5\t\t\t\t\t#Air fuel ratio\n",
      "Ta = 80.+273\t\t\t\t\t#Temperature of air in K\n",
      "x = (7./8)\t\t\t\t\t#Ratio of volume drawn\n",
      "nth = 22.\t\t\t\t\t#Thermal efficiency in percent\n",
      "p = 76.\t\t\t\t\t#Pressure in cm of mercury\n",
      "CV = 9000.\t\t\t\t\t#Calorific value of petrol in kcal/kg\n",
      "l = 1524.\t\t\t\t\t#Altitude in m\n",
      "dp = 2.54\t\t\t\t\t#Drop in pressure in cm of barometric reading\n",
      "lx = 274\t\t\t\t\t#Altitude rise in m\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Calculations\n",
      "Vs = (3.14/4)*(d/10)**2*(L/10)\t\t\t\t\t#Swept volume in c.c\n",
      "Va = (x*Vs)\t\t\t\t\t#Volume of air drawn in per cylinder per stroke in c.c\n",
      "wa = (Va*10**-6*(N/2)*n)\t\t\t\t\t#Weight of air supplied to the engine per minute in kg\n",
      "wf = (wa/ap)\t\t\t\t\t#Weight of fuel consumed per minute in kg\n",
      "q = (wf*CV)\t\t\t\t\t#Heat supplied to the engine per minute in kcal\n",
      "P = (q*(nth/100)*427)/4500\t\t\t\t\t#Power developed at ground level in H.P\n",
      "db = (l/lx)*dp\t\t\t\t\t#Drop in barometric reading at an altitude of 1524 m in cm\n",
      "Pd = (P/p)*(p-db)\t\t\t\t\t#Power developed at 1524 m altitude in H.P\n",
      "\n",
      "\t\t\t\t\t\n",
      "#Output\n",
      "print 'Power developed at the ground level is %i H.P  \\\n",
      "\\nPower developed at an altitude of %i m is %i H.P'%(P,l,Pd)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Power developed at the ground level is 43 H.P  \n",
        "Power developed at an altitude of 1524 m is 35 H.P\n"
       ]
      }
     ],
     "prompt_number": 17
    }
   ],
   "metadata": {}
  }
 ]
}