summaryrefslogtreecommitdiff
path: root/sample_notebooks/KAVANA B/CHAPTER.ipynb
blob: 13237c6c52c26d5da7a3a9fe6a8750f4567ed0d2 (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
{
 "metadata": {
  "name": ""
 },
 "nbformat": 3,
 "nbformat_minor": 0,
 "worksheets": [
  {
   "cells": [
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {},
     "source": [
      "CHAPTER 2: THERMAL STATIONS"
     ]
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.1, Page number 25-26"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Variable declaration\n",
      "M = 15000.0+10.0        #Water evaporated(kg)\n",
      "C = 5000.0+5.0          #Coal consumption(kg)\n",
      "time = 8.0              #Generation shift time(hours)\n",
      "\n",
      "#Calculation\n",
      "#Case(a)\n",
      "M1 = M-15000.0\n",
      "C1 = C-5000.0\n",
      "M_C = M1/C1\n",
      "#Case(b)\n",
      "kWh = 0                                           #Station output at no load\n",
      "consumption_noload = 5000+5*kWh                   #Coal consumption at no load(kg)\n",
      "consumption_noload_hr = consumption_noload/time   #Coal consumption per hour(kg)\n",
      "\n",
      "#Result\n",
      "print('Case(a): Limiting value of water evaporation , M/C = %.1f kg' %M_C)\n",
      "print('Case(b): Coal per hour for running station at no load = %.f kg' %consumption_noload_hr)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Case(a): Limiting value of water evaporation , M/C = 2.0 kg\n",
        "Case(b): Coal per hour for running station at no load = 625 kg\n"
       ]
      }
     ],
     "prompt_number": 1
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.2, Page number 26"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Variable declaration\n",
      "amount = 25.0*10**5          #Amount spent in 1 year(Rs)\n",
      "value_heat = 5000.0          #Heating value(kcal/kg)\n",
      "cost = 500.0                 #Cost of coal per ton(Rs)\n",
      "n_ther = 0.35                #Thermal efficiency\n",
      "n_elec = 0.9                 #Electrical efficiency\n",
      "\n",
      "#Calculation\n",
      "n = n_ther*n_elec                         #Overall efficiency\n",
      "consumption = amount+cost*value_heat      #Coal consumption i 1 year(kg)\n",
      "combustion = consumption*value_heat       #Heat of combustion(kcal)\n",
      "output = n*combustion                     #Heat output(kcal)\n",
      "kWh = output/860.0                        #Annual heat generated(kWh). 1 kWh = 860 kcal\n",
      "time = 365*24.0                           #Total time in a year(hour)\n",
      "load_average = kWh/time                   #Average load on the power plant(kW)\n",
      "\n",
      "#Result\n",
      "print('Average load on power plant = %.2f kW' %load_average)\n",
      "print('\\nNOTE: ERROR: Calculation mistake in the final answer in textbook')"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Average load on power plant = 1045.32 kW\n",
        "\n",
        "NOTE: ERROR: Calculation mistake in the final answer in textbook\n"
       ]
      }
     ],
     "prompt_number": 1
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.3, Page number 26"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Variable declaration\n",
      "consumption = 0.5      #Coal consumption per kWh output(kg)\n",
      "cal_value = 5000.0     #Calorific value(kcal/kg)\n",
      "n_boiler = 0.8         #Boiler efficiency\n",
      "n_elec = 0.9           #Electrical efficiency\n",
      "\n",
      "#Calculation\n",
      "input_heat = consumption*cal_value                 #Heat input(kcal)\n",
      "input_elec = input_heat/860.0                      #Equivalent electrical energy(kWh). 1 kWh = 860 kcal\n",
      "loss_boiler = input_elec*(1-n_boiler)              #Boiler loss(kWh)\n",
      "input_steam = input_elec-loss_boiler               #Heat input to steam(kWh)\n",
      "input_alter = 1/n_elec                             #Alternator input(kWh)\n",
      "loss_alter = input_alter*(1-n_elec)                #Alternate loss(kWh)\n",
      "loss_turbine = input_steam-input_alter             #Loss in turbine(kWh)\n",
      "loss_total = loss_boiler+loss_alter+loss_turbine   #Total loss(kWh)\n",
      "output = 1.0                                       #Output(kWh)\n",
      "Input = output+loss_total                          #Input(kWh)\n",
      "\n",
      "#Result\n",
      "print('Heat Balance Sheet')\n",
      "print('LOSSES:  Boiler loss      = %.3f kWh' %loss_boiler)\n",
      "print('         Alternator loss  = %.2f kWh' %loss_alter)\n",
      "print('         Turbine loss     = %.3f kWh' %loss_turbine)\n",
      "print('         Total loss       = %.2f kWh' %loss_total)\n",
      "print('OUTPUT:  %.1f kWh' %output)\n",
      "print('INPUT:   %.2f kWh' %Input)\n",
      "print('\\nNOTE: Changes in the obtained answer from that of textbook is due to precision')"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Heat Balance Sheet\n",
        "LOSSES:  Boiler loss      = 0.581 kWh\n",
        "         Alternator loss  = 0.11 kWh\n",
        "         Turbine loss     = 1.214 kWh\n",
        "         Total loss       = 1.91 kWh\n",
        "OUTPUT:  1.0 kWh\n",
        "INPUT:   2.91 kWh\n",
        "\n",
        "NOTE: Changes in the obtained answer from that of textbook is due to precision\n"
       ]
      }
     ],
     "prompt_number": 1
    }
   ],
   "metadata": {}
  }
 ]
}