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
|
{
"metadata": {
"name": ""
},
"nbformat": 3,
"nbformat_minor": 0,
"worksheets": [
{
"cells": [
{
"cell_type": "heading",
"level": 1,
"metadata": {},
"source": [
"Chapter 6 - Flow processes : First law analysis"
]
},
{
"cell_type": "heading",
"level": 2,
"metadata": {},
"source": [
"Example 1 - Pg 76"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"#Calculate the power output of the machine\n",
"#initialization of varaibles\n",
"import math\n",
"u1=1111.9 #Btu/lb\n",
"P1=170. #psia\n",
"v1=2.675 #cu ft/lb\n",
"v2=100.9 #cu ft/lb\n",
"z1=10. #ft\n",
"V1=6000./60. #ft/sec\n",
"Q=-1000.\n",
"u2=914.6 #B/lb\n",
"P2=3. #psia\n",
"V2=300. #ft/sec\n",
"rate=2500. #lb/hr\n",
"#calculations\n",
"Wx=rate*(u1-u2 + (P1*v1-P2*v2)*144/778 +(V1*V1 -V2*V2)/(2*32.2*778.) +z1/778. +Q/rate)\n",
"f=3.92*math.pow(10,-4)\n",
"power = Wx*f\n",
"#results\n",
"print '%s %d %s' %(\"Power output of turbine = \",Wx,\"B/hr\")\n",
"print '%s %.1f %s' %(\"\\n Power output in hp =\",power,\"hp\")\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"Power output of turbine = 558647 B/hr\n",
"\n",
" Power output in hp = 219.0 hp\n"
]
}
],
"prompt_number": 1
},
{
"cell_type": "heading",
"level": 2,
"metadata": {},
"source": [
"Example 2 - Pg 78"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"#calculate the flow rate\n",
"#initialization of varaibles\n",
"w1=500. #lb/min\n",
"h1=132.9 #lb/min\n",
"h2=1150. #B/lb\n",
"h3=180. #B/lb\n",
"#calculations\n",
"w2=(w1*h1-w1*h3)/(h3-h2)\n",
"#results\n",
"print '%s %.1f %s' %(\"Flow rate =\",w2,\"lb/min\")\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"Flow rate = 24.3 lb/min\n"
]
}
],
"prompt_number": 2
},
{
"cell_type": "heading",
"level": 2,
"metadata": {},
"source": [
"Example 3 - Pg 79"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"#Calculate the average velocity and rate of flow\n",
"#initialization of varaibles\n",
"import math\n",
"v2=5.434 #cu ft/lb\n",
"v1=4.937 #cu ft/lb\n",
"h1=1227.6\n",
"h2=1223.9\n",
"A1=math.pi/144\n",
"#calculations\n",
"Vratio=v2/v1\n",
"V1=math.sqrt(64.4*(h1-h2)*778./(Vratio*Vratio -1))\n",
"V2=V1*Vratio\n",
"w=A1*V1/v1\n",
"#results\n",
"print '%s %d %s' %(\"Average velocity at 1 =\",V1,\"fps\")\n",
"print '%s %d %s' %(\"\\n Average velocity at 2 =\",V2,\"fps\")\n",
"print '%s %.2f %s' %(\"\\n Rate of flow = \",w,\"lb/sec\")\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"Average velocity at 1 = 936 fps\n",
"\n",
" Average velocity at 2 = 1030 fps\n",
"\n",
" Rate of flow = 4.14 lb/sec\n"
]
}
],
"prompt_number": 3
}
],
"metadata": {}
}
]
}
|