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
|
{
"metadata": {
"name": ""
},
"nbformat": 3,
"nbformat_minor": 0,
"worksheets": [
{
"cells": [
{
"cell_type": "heading",
"level": 1,
"metadata": {},
"source": [
"Chapter 13 : Unsteady-state transport"
]
},
{
"cell_type": "heading",
"level": 3,
"metadata": {},
"source": [
"Example 13.1 - Page No :651\n"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"'''\n",
"find the Biot number for: (a) a copper sphere\n",
"of radius 5 cm; (b) a copper cylinder of radius 5 cm and length 30 cm; and (c) a\n",
"square copper rod of length 40 cm and cross sectional area the same as the\n",
"cylinder of radius 5 cm.\n",
"'''\n",
"\n",
"import math \n",
"\n",
"# Variables\n",
"# given\n",
"h = 12.; \t\t\t #[W/m**2*K] - heat transfer coefficeint\n",
"k = 400.; \t\t\t #[W/m*K] - thermal conductivity\n",
"\n",
"# Calculation and Results\n",
"# (a) for sphere\n",
"r = 5.*10**-2; \t\t\t #[m] - radius of copper sphere\n",
"Lc = ((4*math.pi*((r)**3))/3)/(4*math.pi*((r)**2));\n",
"Nbi = h*Lc*(1./k);\n",
"print \" a) The biot no. is Nbi = %.0e\"%(Nbi);\n",
"\n",
"# (b) for cyclinder\n",
"r = 0.05; \t\t\t #[m] - radius of cyclinder\n",
"L = 0.3; \t\t\t #[m] - height of cyclinder\n",
"Lc = (math.pi*((r)**2)*L)/(2*math.pi*r*L);\n",
"Nbi = h*Lc*(1./k);\n",
"print \" b) The biot no. is Nbi = %.1e\"%(Nbi);\n",
"\n",
"# (c) for a long square rod\n",
"L = .4; \t\t\t #[m] - length of copper rod\n",
"r = 0.05; \t\t\t #[m] - radius of a cyclinder havimg same cross sectional area as that of square\n",
"x = ((math.pi*r**2)**(1./2));\n",
"Lc = ((x**2)*L)/(4*x*L);\n",
"Nbi = h*Lc*(1./k);\n",
"print \" c) The biot no. is Nbi = %.3e\"%(Nbi);\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
" a) The biot no. is Nbi = 5e-04\n",
" b) The biot no. is Nbi = 7.5e-04\n",
" c) The biot no. is Nbi = 6.647e-04\n"
]
}
],
"prompt_number": 2
},
{
"cell_type": "heading",
"level": 3,
"metadata": {},
"source": [
"Example 13.6 - Page No :684\n"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"'''\n",
"Calculate the temperature at the center after\n",
"1.2s if the heat transfer coefficient is 20 W m-*K-l\n",
"'''\n",
"\n",
"# Variables\n",
"# given\n",
"d = 1*0.0254; \t\t #[m] banana diameter\n",
"Lr = d/2; \t\t\t #[m]; \n",
"Lz = (1.2/2)*(0.0254); \n",
"x = Lz;\n",
"r = Lr;\n",
"k = 0.481; # thermal conductivity\n",
"h = 20.; # heat coefficient\n",
"mr = k/(h*Lr);\n",
"mz = k/(h*Lz);\n",
"nr = r/Lr;\n",
"nz = x/Lz;\n",
"t = 1.2; \t\t\t #[sec]\n",
"\n",
"# Calculations\n",
"alpha = 1.454*10**-4;\n",
"Xr = (alpha*t)/(Lr**2);\n",
"Xz = (alpha*t)/(Lz**2);\n",
"\n",
"# using the above value of m,n,X the value for Ycz and Ycr from fig 13.14 is\n",
"Ycr = 0.42;\n",
"Ycz = 0.75;\n",
"Yc = Ycr*Ycz;\n",
"T_infinity = 400.; \t\t\t #[K]\n",
"To = 295.;\n",
"Tc = T_infinity-(Yc*(T_infinity-To));\n",
"\n",
"# Results\n",
"print \" The temperature t the centre is Tc = %.0f K\"%(Tc);\n",
"\n",
"\n",
"# Answer is vary because of rounding error."
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
" The temperature t the centre is Tc = 367 K\n"
]
}
],
"prompt_number": 1
},
{
"cell_type": "heading",
"level": 3,
"metadata": {},
"source": [
"Example 13.7 - Page No :688\n"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"'''\n",
"Consider the agitation vessel in Example 13.5. Divide the\n",
"thickness into 10 increments and perform two iterations of the explicit method.\n",
"'''\n",
"\n",
"from numpy import *\n",
"# Variables\n",
"# given\n",
"T_x0 = 300.; \t\t\t #[K]\n",
"Tw = 400.; \t\t\t #[K]\n",
"L = 0.013; \t\t\t #[m]\n",
"alpha = 2.476*(10**-5); \t\t\t #[m**/sec]\n",
"h = 600.; \t\t\t #[W/m**2*K]\n",
"pcp = 3.393*(10**6); \t\t\t #[J/m**3*K]\n",
"L = 0.013; \t\t\t #[m]\n",
"del_tax = L/10.;\n",
"betaa = 0.5;\n",
"del_tat = 0.03;\n",
"\n",
"# Calculations\n",
"del_tat = betaa*((del_tax)**2)*(1./alpha);\n",
"T_infinity = 400.; \t\t\t #[K]\n",
"\n",
"# to be sure that the solution is stable, it is customary to truncate this number\n",
"del_tat = 0.03; \t\t\t #[sec]\n",
"# betaa = alpha*del_tat*((1./del_tax)**2);\n",
"Told = zeros(11)\n",
"for i in range(11):\n",
" Told[i] = 300.;\n",
"\n",
"a = ((2*h*del_tat)/(pcp*del_tax));\n",
"b = ((2*alpha*del_tat)/(pcp*((del_tax)**2)));\n",
"\n",
"Tnew = zeros(11)\n",
"for j in range(11):\n",
" Tnew[0] = (T_infinity*0.08162)+(Told[0]*(1-0.08162-0.8791))+(Told[1]*0.8791)\n",
" for k in range(9):\n",
" Tnew[k+1] = (betaa*Told[k+2])+((1.-2*betaa)*(Told[k+1]))+(betaa*Told[k]);\n",
" Tnew[10] = ((2*betaa)*(Told[9]))\n",
" Told = Tnew;\n",
"# Results\n",
"print \"Told values : \" ,(Told);\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"Told values : [ 325.54820838 319.78194857 315.05971328 311.28295197 308.32959437\n",
" 306.07276601 304.39590474 303.20406441 302.43143939 302.04512688\n",
" 302.04512688]\n"
]
}
],
"prompt_number": 3
},
{
"cell_type": "heading",
"level": 3,
"metadata": {},
"source": [
"Example 13.9 - Page No :700\n"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"'''\n",
"Estimate the depth that corresponds to a\n",
"temperature of -5\u00b0C if it is assumed that the period of time is 4 months.\n",
"'''\n",
"\n",
"# Variables\n",
"p = 2050.; \t\t\t #[kg/m**3] - density of soil\n",
"cp = 1840.; \t\t\t #[J/kg*K] - heat cpapacity of soil\n",
"k = 0.52; \t\t\t #[W/m*K] - thermal conductivity of soil\n",
"alpha = 0.138*10**-6; \t\t\t #[m**2/sec]\n",
"t = 4*30*24*3600; \t\t\t #[sec] - no. of seconds in 4 months\n",
"Tx = -5.; \t\t\t #[degC]\n",
"Tinf = -20.; \t\t\t #[degC]\n",
"T0 = 20.; \t\t\t #[degC]\n",
"\n",
"# from the fig 13.24 the dimensionless dismath.tance Z is \n",
"Z = 0.46;\n",
"\n",
"# Calculations\n",
"# then the depth is\n",
"x = 2*((alpha*t)**(1./2))*Z\n",
"\n",
"# Results\n",
"print \" the depth is x = %.1f m = %.1f ft\"%(x,x*3.6/1.10);\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
" the depth is x = 1.1 m = 3.6 ft\n"
]
}
],
"prompt_number": 7
},
{
"cell_type": "heading",
"level": 3,
"metadata": {},
"source": [
"Example 13.10 - Page No :701\n"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"# find the concentration of KC1 at the center after 60min.\n",
"\n",
"# Variables\n",
"d = 0.01; \t\t\t #[m] - diameter of cyclindrical porous plug\n",
"D = 2.*10**-9; \t\t\t #[m**2/sec] - diffusion coefficient\n",
"t = 60.*60; \t\t\t #[sec]\n",
"r = d/2.;\n",
"m = 0.;\n",
"Ca_inf = 0.;\n",
"Ca_0 = 10.;\n",
"X = (D*t)/((r)**2);\n",
"# from fig 13.14 the ordinate is\n",
"Y = 0.7;\n",
"\n",
"# Calculations\n",
"Ca_c = Ca_inf-Y*(Ca_inf-Ca_0);\n",
"\n",
"# Results\n",
"print \" the concentration of KCL at the centre after 60 min is Ca = %.2f kg/m**3\"%(Ca_c);\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
" the concentration of KCL at the centre after 60 min is Ca = 7.00 kg/m**3\n"
]
}
],
"prompt_number": 8
}
],
"metadata": {}
}
]
}
|