summaryrefslogtreecommitdiff
path: root/Basic_Engineering_Thermodynamics_by_Rayner_Joel/Chapter17.ipynb
blob: 691778750ae563dccbd47704b03d0b5b1442aefa (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
{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# Chapter 17 - Engine and plant trails"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example 1: pg 589 "
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Example 17.1\n",
      " The Indicated power is (kW) =  26.2\n",
      " The Brake power is (kW) =  22.0\n",
      " The mechanical efficiency is (percent) =  837.0\n",
      "Energy can be tabulated as :-\n",
      "----------------------------------------------------------------------------------------------------\n",
      "                                                  kJ/s                           Percentage   \n",
      "----------------------------------------------------------------------------------------------------\n",
      " Energy from fuel                          88.0                     100.0 \n",
      " Energy to brake power                 22.0                      25.0 \n",
      " Energy to coolant                        20.7                     23.5  \n",
      " Energy to exhaust                       33.6                      38.2 \n",
      " Energy to suroundings,etc.          11.8                      13.4\n"
     ]
    }
   ],
   "source": [
    "#pg 589\n",
    "print('Example 17.1');\n",
    "\n",
    "# aim : To determine\n",
    "# the indicated and brake output and the mechanicl efficiency\n",
    "# draw up an overall energy balance and as % age\n",
    "import math\n",
    "# given values\n",
    "h = 21;# height of indicator diagram, [mm]\n",
    "ic = 27;# indicator calibration, [kN/m**2 per mm]\n",
    "sv = 14*10**-3;# swept volume of the cylinder;,[m**3]\n",
    "N = 6.6;# speed of engine, [rev/s]\n",
    "ebl = 77;# effective brake load, [kg]\n",
    "ebr = .7;# effective brake radious, [m]\n",
    "fc = .002;# fuel consumption, [kg/s]\n",
    "CV = 44000;# calorific value of fuel, [kJ/kg]\n",
    "cwc = .15;# cooling water circulation, [kg/s]\n",
    "Ti = 38;# cooling water inlet temperature, [C]\n",
    "To = 71;# cooling water outlet temperature, [C]\n",
    "c = 4.18;# specific heat capacity of water, [kJ/kg]\n",
    "eeg = 33.6;# energy to exhaust gases, [kJ/s]\n",
    "g = 9.81;# gravitational acceleration, [m/s**2]\n",
    "\n",
    "# solution\n",
    "PM = ic*h;# mean effective pressure, [kN/m**2]\n",
    "LA = sv;# swept volume of the cylinder, [m**3]\n",
    "ip = PM*LA*N/2;# indicated power,[kW]\n",
    "T = ebl*g*ebr;# torque, [N*m]\n",
    "bp = 2*math.pi*N*T;# brake power, [W]\n",
    "n_mech = bp/ip;# mechanical efficiency\n",
    "print ' The Indicated power is (kW) = ',round(ip,2)\n",
    "print ' The Brake power is (kW) = ',round(bp*10**-3)\n",
    "print ' The mechanical efficiency is (percent) = ',round(n_mech)\n",
    "\n",
    "ef = CV*fc;# energy from fuel, [kJ/s]\n",
    "eb = bp*10**-3;# energy to brake power,[kJ/s]\n",
    "ec = cwc*c*(To-Ti);# energy to coolant,[kJ/s]\n",
    "es = ef-(eb+ec+eeg);# energy to surrounding,[kJ/s]\n",
    "\n",
    "print('Energy can be tabulated as :-');\n",
    "print('----------------------------------------------------------------------------------------------------');\n",
    "print('                                                  kJ/s                           Percentage   ')\n",
    "print('----------------------------------------------------------------------------------------------------');\n",
    "print ' Energy from fuel                         ',ef,'                   ',ef/ef*100,'\\n Energy to brake power                ',round(eb),'                    ',round(eb/ef*100),'\\n Energy to coolant                       ',round(ec,1),'                   ',round(ec/ef*100,1),' \\n Energy to exhaust                      ',eeg,'                    ',round(eeg/ef*100,1),'\\n Energy to suroundings,etc.         ',round(es,1),'                    ',round(es/ef*100,1)\n",
    "\n",
    "#  End\n"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example 2: pg 591"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Example 17.2\n",
      " (a) The brake power is (kW) =  14.657\n",
      " (b) The indicated power is (kW) =  18.2\n",
      " (c) The mechanical efficiency is (percent) =  80.4\n",
      " (d) The indicated thermal efficiency is (percent) =  12.94\n",
      " (e) The brake steam consumption is (kg/kWh) =  13.75\n",
      " (f) Energy supplied/min is (kJ) =  9092.0\n",
      "    Energy to bp/min is (kJ) =  879.0\n",
      "    Energy to condenser cooling water/min is (kJ) =  5196.0\n",
      "    Energy to condensate/min is (kJ) =  534.0\n",
      "    Energy to surrounding, etc/min is (kJ) =  2483.0\n",
      "answer in the book is misprinted for Es\n"
     ]
    }
   ],
   "source": [
    "#pg 591\n",
    "print('Example 17.2');\n",
    "import math\n",
    "# aim : To determine\n",
    "# (a) bp\n",
    "# (b) ip\n",
    "# (c) mechanical efficiency\n",
    "# (d) indicated thermal efficiency\n",
    "# (e) brake specific steam consumption\n",
    "# (f) draw up complete energy account for the test one-minute basis taking 0 C as datum\n",
    "\n",
    "# given values\n",
    "d = 200.*10**-3;# cylinder diameter, [mm]\n",
    "L = 250.*10**-3;# stroke, [mm]\n",
    "N = 5.;# speed, [rev/s]\n",
    "r = .75/2;# effective radious of brake wheel, [m]\n",
    "Ps = 800.;# stop valve pressure, [kN/m**2]\n",
    "x = .97;# dryness fraction of steam\n",
    "BL = 136.;# brake load, [kg]\n",
    "SL = 90.;# spring balance load, [N]\n",
    "PM = 232.;# mean effective pressure, [kN/m**2]\n",
    "Pc = 10.;# condenser pressure, [kN/m**2]\n",
    "m_dot = 3.36;# steam consumption, [kg/min]\n",
    "CC = 113.;# condenser cooling water, [kg/min]\n",
    "Tr = 11.;# temperature rise of condenser cooling water, [K]\n",
    "Tc = 38.;# condensate temperature, [C]\n",
    "C = 4.18;# heat capacity of water, [kJ/kg K]\n",
    "g = 9.81;# gravitational acceleration, [m/s**2]\n",
    "\n",
    "# solution\n",
    "# from steam table\n",
    "# at 800 kN/m**2\n",
    "tf1 = 170.4;# saturation temperature, [C]\n",
    "hf1 = 720.9;# [kJ/kg]\n",
    "hfg1 = 2046.5;# [kJ/kg]\n",
    "hg1 = 2767.5;# [kJ/kg]\n",
    "vg1 = .2403;# [m**3/kg]\n",
    "\n",
    "# at 10 kN/m**2\n",
    "tf2 = 45.8;# saturation temperature, [C]\n",
    "hf2 = 191.8;# [kJ/kg]\n",
    "hfg2 = 2392.9;# [kJ/kg]\n",
    "hg2 = 2584.8;# [kJ/kg]\n",
    "vg2 = 14.67;# [m**3/kg]\n",
    "\n",
    "# (a)\n",
    "T = (BL*g-SL)*r;# torque, [Nm]\n",
    "bp = 2*math.pi*N*T*10**-3;# brake power,[W]\n",
    "print ' (a) The brake power is (kW) = ',round(bp,3)\n",
    "\n",
    "# (b)\n",
    "A = math.pi*d**2/4;# area, [m**2]\n",
    "ip = PM*L*A*N*2;# double-acting so*2, [kW]\n",
    "print ' (b) The indicated power is (kW) = ',round(ip,1)\n",
    "\n",
    "# (c)\n",
    "n_mec = bp/ip;# mechanical efficiency\n",
    "print ' (c) The mechanical efficiency is (percent) = ',round(n_mec*100,1)\n",
    "\n",
    "# (d)\n",
    "h = hf1+x*hfg1;# [kJ/kg]\n",
    "hf = hf2;\n",
    "ITE = ip/((m_dot/60)*(h-hf));# indicated thermal efficiency\n",
    "print ' (d) The indicated thermal efficiency is (percent) = ',round(ITE*100,2)\n",
    "# (e)\n",
    "Bsc=m_dot*60/bp;# brake specific steam consumption, [kg/kWh]\n",
    "print ' (e) The brake steam consumption is (kg/kWh) = ',round(Bsc,2)\n",
    "\n",
    "# (f)\n",
    "# energy balanvce reckoned from 0 C\n",
    "Es = m_dot*h;# energy supplied, [kJ]\n",
    "Eb = bp*60;# energy to bp, [kJ]\n",
    "Ecc = CC*C*Tr;# energy to condensate cooling water, [kJ]\n",
    "Ec = m_dot*C*Tc;# energy to condensate, [kJ]\n",
    "Ese = Es-Eb-Ecc-Ec;# energy to surrounding,etc, [kJ]\n",
    "\n",
    "print ' (f) Energy supplied/min is (kJ) = ',round(Es)\n",
    "\n",
    "print '    Energy to bp/min is (kJ) = ',round(Eb)\n",
    "print '    Energy to condenser cooling water/min is (kJ) = ',round(Ecc)\n",
    "print '    Energy to condensate/min is (kJ) = ',round(Ec)\n",
    "print '    Energy to surrounding, etc/min is (kJ) = ',round(Ese)\n",
    "\n",
    "print 'answer in the book is misprinted for Es'\n",
    "\n",
    "#  End\n"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example 3: pg 593"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Example 17.3\n",
      " (a) The Brake power is (kW) =  60.5\n",
      " (b) The brake specific fuel consumption is (kg/kWh) =  0.309\n",
      " (c) The indicated thermal efficiency is (percent) =  33.2\n",
      " (d) Energy from fuel is (kJ) =  13184.0\n",
      "      Energy to brake power is  (kJ) =  3629.0\n",
      "      Energy to cooling water is (kJ) =  4038.0\n",
      "      Energy to exhaust is (kJ) =  3739.0\n",
      "      Energy to surrounding, etc is (kJ) =  1778.0\n",
      "The answer is a bit different due to rounding off error in textbook\n"
     ]
    }
   ],
   "source": [
    "#pg 593\n",
    "print('Example 17.3');\n",
    "\n",
    "# aim : To determine\n",
    "# (a) the brake power\n",
    "# (b) the brake specific fuel consumption\n",
    "# (c) the indicated thermal efficiency\n",
    "# (d) the energy balance, expressing the various items\n",
    "import math\n",
    "# given values\n",
    "t = 30.;# duration of trial, [min]\n",
    "N = 1750.;# speed of engine, [rev/min]\n",
    "T = 330.;# brake torque, [Nm]\n",
    "mf = 9.35;# fuel consumption, [kg]\n",
    "CV = 42300.;# calorific value of fuel, [kJ/kg]\n",
    "cwc = 483.;# jacket cooling water circulation, [kg]\n",
    "Ti = 17.;# inlet temperature, [C]\n",
    "To = 77.;# outlet  temperature, [C]\n",
    "ma = 182.;# air consumption, [kg]\n",
    "Te = 486.;# exhaust temperature, [C]\n",
    "Ta = 17.;# atmospheric temperature, [C]\n",
    "n_mec = .83;# mechanical efficiency\n",
    "c = 1.25;# mean specific heat capacity of exhaust gas, [kJ/kg K]\n",
    "C = 4.18;# specific heat capacity, [kJ/kg K]\n",
    "\n",
    "# solution\n",
    "# (a)\n",
    "bp = 2*math.pi*N*T/60*10**-3;# brake power, [kW]\n",
    "print ' (a) The Brake power is (kW) = ',round(bp,1)\n",
    "\n",
    "# (b)\n",
    "bsf = mf*2/bp;#brake specific fuel consumption, [kg/kWh]\n",
    "print ' (b) The brake specific fuel consumption is (kg/kWh) = ',round(bsf,3)\n",
    "\n",
    "# (c)\n",
    "ip = bp/n_mec;# indicated power, [kW]\n",
    "ITE = ip/(2*mf*CV/3600);# indicated thermal efficiency\n",
    "print ' (c) The indicated thermal efficiency is (percent) = ',round(ITE*100,1)\n",
    "\n",
    "# (d)\n",
    "# taking  basis one minute \n",
    "ef = CV*mf/30;# energy from fuel, [kJ]\n",
    "eb = bp*60;# energy to brake power,[kJ]\n",
    "ec = cwc/30*C*(To-Ti);# energy to cooling water,[kJ]\n",
    "ee = (ma+mf)/30*c*(Te-Ta);# energy to exhaust, [kJ]\n",
    "es = ef-(eb+ec+ee);# energy to surrounding,etc,[kJ]\n",
    "\n",
    "print ' (d) Energy from fuel is (kJ) = ',round(ef)\n",
    "print '      Energy to brake power is  (kJ) = ',round(eb)\n",
    "print '      Energy to cooling water is (kJ) = ',round(ec)\n",
    "print '      Energy to exhaust is (kJ) = ',round(ee)\n",
    "print '      Energy to surrounding, etc is (kJ) = ',round(es)\n",
    " \n",
    "print 'The answer is a bit different due to rounding off error in textbook'\n",
    "#  End\n"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example 4: pg 594"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Example 17.4\n",
      " (a) The indicated power of the engine is (kW) =  69.9\n",
      " (b) The mechanical  efficiency of the engine is (percent) =  74.4\n"
     ]
    }
   ],
   "source": [
    "#pg 594\n",
    "print('Example 17.4');\n",
    "\n",
    "# aim : To determine\n",
    "# (a) the indicated power of the engine\n",
    "# (b) the mechanical efficiency of the engine\n",
    "\n",
    "# given values\n",
    "bp = 52;# brake power output, [kW]\n",
    "bp1 = 40.5;# brake power of cylinder cut1, [kW]\n",
    "bp2 = 40.2;# brake power of cylinder cut2, [kW]\n",
    "bp3 = 40.1;# brake power of cylinder cut3, [kW]\n",
    "bp4 = 40.6;# brake power of cylinder cut4, [kW]\n",
    "bp5 = 40.7;# brake power of cylinder cut5, [kW]\n",
    "bp6 = 40.0;# brake power of cylinder cut6, [kW]\n",
    "\n",
    "# sollution\n",
    "ip1 = bp-bp1;# indicated power of cylinder cut1, [kW]\n",
    "ip2 = bp-bp2;# indicated power of cylinder cut2, [kW]\n",
    "ip3 = bp-bp3;# indicated power of cylinder cut3, [kW]\n",
    "ip4 = bp-bp4;# indicated power of cylinder cut4, [kW]\n",
    "ip5 = bp-bp5;# indicated power of cylinder cut5, [kW]\n",
    "ip6 = bp-bp6;# indicated power of cylinder cut6, [kW]\n",
    "\n",
    "ip = ip1+ip2+ip3+ip4+ip5+ip6;# indicated power of engine,[kW]\n",
    "print ' (a) The indicated power of the engine is (kW) = ',ip\n",
    "\n",
    "# (b)\n",
    "n_mec = bp/ip;# mechanical efficiency\n",
    "print ' (b) The mechanical  efficiency of the engine is (percent) = ',round(n_mec*100,1)\n",
    "\n",
    "# End\n"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example 5: pg 595"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Example 17.5\n",
      " The Brake power is (kW) =  29.3\n",
      " The Indicated power is (kW) =  37.3\n",
      " The mechanical efficiency is (percent) =  78.8\n",
      "Energy can be tabulated as :-\n",
      "----------------------------------------------------------------------------------------------------\n",
      "                                                  kJ/s                           Percentage   \n",
      "----------------------------------------------------------------------------------------------------\n",
      " Energy from fuel                          135.3                   100.0 \n",
      " Energy to brake power                  29.3                     21.7 \n",
      " Energy to exhaust                        35.4                     26.0 \n",
      " Energy to coolant                         44.5                     32.9 \n",
      " Energy to suroundings,etc.            26.1                    19.3\n",
      "there is minor variation in the result reported in the book due to rounding off error\n"
     ]
    }
   ],
   "source": [
    "#pg 595\n",
    "print('Example 17.5');\n",
    "\n",
    "# aim : To determine\n",
    "# the brake power,indicated power and mechanicl efficiency\n",
    "# draw up an energy balance and as % age of the energy supplied\n",
    "\n",
    "# given values\n",
    "N = 50.;# speed, [rev/s]\n",
    "BL = 267.;# break load.,[N]\n",
    "BL1 = 178.;# break load of cylinder cut1, [N]\n",
    "BL2 = 187.;# break load of cylinder cut2, [N]\n",
    "BL3 = 182.;# break load of cylinder cut3, [N]\n",
    "BL4 = 182.;# break load of cylinder cut4, [N]\n",
    "\n",
    "FC = .568/130;# fuel consumption, [L/s]\n",
    "s = .72;# specific gravity of fuel\n",
    "CV = 43000;# calorific value of fuel, [kJ/kg]\n",
    "\n",
    "Te = 760;# exhaust temperature, [C]\n",
    "c = 1.015;# specific heat capacity of exhaust gas, [kJ/kg K]\n",
    "Ti = 18;# cooling water inlet temperature, [C]\n",
    "To = 56;# cooling water outlet temperature, [C]\n",
    "mw = .28;# cooling water flow rate, [kg/s]\n",
    "Ta = 21;# ambient tempearture, [C]\n",
    "C = 4.18;# specific heat capacity of cooling water, [kJ/kg K]\n",
    "\n",
    "# solution\n",
    "bp = BL*N/455;# brake power of engine, [kW]\n",
    "bp1 = BL1*N/455;# brake power of cylinder cut1, [kW]\n",
    "i1 = bp-bp1;# indicated power of cylinder cut1, [kW]\n",
    "bp2 = BL2*N/455;# brake power of cylinder cut2, [kW]\n",
    "i2 = bp-bp2;# indicated power of cylinder cut2, [kW]\n",
    "bp3 = BL3*N/455;# brake power of cylinder cut3, [kW]\n",
    "i3 = bp-bp3;# indicated power of cylinder cut3, [kW]\n",
    "bp4 = BL4*N/455;# brake power of cylinder cut4, [kW]\n",
    "i4 = bp-bp4;# indicated power of cylinder cut4, [kW]\n",
    "\n",
    "ip = i1+i2+i3+i4;# indicated power of engine, [kW]\n",
    "n_mec = bp/ip;# mechanical efficiency\n",
    "\n",
    "print ' The Brake power is (kW) = ',round(bp,1)\n",
    "print ' The Indicated power is (kW) = ',round(ip,1)\n",
    "print ' The mechanical efficiency is (percent) = ',round(n_mec*100,1)\n",
    "\n",
    "mf = FC*s;# mass of fuel/s, [kg]\n",
    "ef = CV*mf;# energy from fuel/s, [kJ]\n",
    "me = 15*mf;# mass of exhaust/s,[kg],(given in condition)\n",
    "ee = me*c*(Te-Ta);# energy to exhaust/s,[kJ]\n",
    "ec = mw*C*(To-Ti);# energy to cooling water/s,[kJ]\n",
    "es = ef-(ee+ec+bp);# energy to surrounding,etc/s,[kJ]\n",
    "\n",
    "print('Energy can be tabulated as :-');\n",
    "print('----------------------------------------------------------------------------------------------------');\n",
    "print('                                                  kJ/s                           Percentage   ')\n",
    "print('----------------------------------------------------------------------------------------------------');\n",
    "print ' Energy from fuel                         ',round(ef,1),'                 ',ef/ef*100,'\\n Energy to brake power                 ',round(bp,1),'                   ',round(bp/ef*100.,1),'\\n Energy to exhaust                       ',round(ee,1),'                   ',round(ee/ef*100),'\\n Energy to coolant                        ',round(ec,1),'                   ',round(ec/ef*100,1),'\\n Energy to suroundings,etc.           ',round(es,1),'                  ',round(es/ef*100,1)\n",
    "\n",
    "print 'there is minor variation in the result reported in the book due to rounding off error'\n",
    "#  End\n"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example 6: pg 596"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Example 17.6\n",
      " (a) The brake power is (MW) =  23.719\n",
      " (b) The fuel consumption is (tonne/h) =  4.74\n",
      " (c) The brake thermal efficiency is (percent) =  42.0\n"
     ]
    }
   ],
   "source": [
    "#pg 596\n",
    "print('Example 17.6');\n",
    "\n",
    "# aim : To determine \n",
    "# (a) the break power of engine\n",
    "# (b) the fuel consumption of the engine\n",
    "# (c) the brake thermal efficiency of the engine\n",
    "import math\n",
    "# given values\n",
    "d = 850*10**-3;# bore , [m]\n",
    "L = 2200*10**-3;# stroke, [m]\n",
    "PMb = 15;# BMEP of cylinder, [bar]\n",
    "N = 95./60;# speed of engine, [rev/s]\n",
    "sfc = .2;# specific fuel oil consumption, [kg/kWh]\n",
    "CV = 43000;# calorific value of the fuel oil, [kJ/kg]\n",
    "\n",
    "# solution\n",
    "# (a)\n",
    "A = math.pi*d**2/4;# area, [m**2]\n",
    "bp = PMb*L*A*N*8/10;# brake power,[MW]\n",
    "print ' (a) The brake power is (MW) = ',round(bp,3)\n",
    "\n",
    "# (b)\n",
    "FC = bp*sfc;# fuel consumption, [kg/h]\n",
    "print ' (b) The fuel consumption is (tonne/h) = ',round(FC,2)\n",
    "\n",
    "# (c)\n",
    "mf = FC/3600;# fuel used, [kg/s]\n",
    "n_the = bp/(mf*CV);# brake thermal efficiency\n",
    "print ' (c) The brake thermal efficiency is (percent) = ',round(n_the*100)\n",
    "\n",
    "# End\n"
   ]
  }
 ],
 "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.11"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 0
}