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
|
{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# Ch:5 Introduction to pressure vessels"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## exa 5-1 - Page 138"
]
},
{
"cell_type": "code",
"execution_count": 7,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"t1 is 3.83 mm \n",
"\n",
"t2 is 3.894 mm \n"
]
}
],
"source": [
"p=2#\n",
"Rm=220#\n",
"#tensile hoop or circumferential stress= sigt\n",
"sigr=-2#\n",
"#sigt=(p*Rm)/t#\n",
"Sa=230/2#\n",
"#t1=thickness according to maximum principal stress theory\n",
"#t2=thickness according to maximum shear stress theory\n",
"t1=(p*Rm)/Sa#\n",
"t2=(p*Rm)/(Sa+sigr)#\n",
"print \"t1 is %0.2f mm \"%(t1)#\n",
"print \"\\nt2 is %0.3f mm \"%(t2)#"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## exa 5-2 - Page 139"
]
},
{
"cell_type": "code",
"execution_count": 8,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"t is 17.0mm \n",
"\n",
"M is 2295.0mm \n",
"\n",
"sigb is 47.6mm \n",
"sigb is below allowable sigd.\n"
]
}
],
"source": [
"from math import sqrt\n",
"from __future__ import division\n",
"#Elastic limit=sige\n",
"sige=310#\n",
"#inside diameter=di\n",
"di=300#\n",
"p=1.8#\n",
"FOS=2#\n",
"#design stress=sigd#\n",
"sigd=sige/2#\n",
"c=0.162#\n",
"d=380#\n",
"#cover plate thickness=t#\n",
"t=d*sqrt(c*p/sigd)#\n",
"t=17#\n",
"M=di*p*t/4#\n",
"\n",
"z=(1/6)*1*t**2#\n",
"#bending stress=sigb#\n",
"sigb=M/z#\n",
"print \"t is %0.1fmm \"%(t)#\n",
"print \"\\nM is %0.1fmm \"%(M)#\n",
"print \"\\nsigb is %0.1fmm \"%(sigb)#\n",
"if (sigb<=sigd):\n",
" print 'sigb is below allowable sigd.'"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## exa 5-3 - Page 140"
]
},
{
"cell_type": "code",
"execution_count": 9,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"t1 is 24.0mm \n",
"\n",
"t2 is 30.206mm \n"
]
}
],
"source": [
"from math import sqrt\n",
"sige=220#\n",
"v=0.29#\n",
"Ri=175#\n",
"FOS=3#\n",
"Sa=sige/3#\n",
"p=10#\n",
"#t1=thickness according to maximum principal stress theory\n",
"#t2=thickness according to maximum shear stress theory\n",
"x=Sa+(p*(1-(2*v)))#\n",
"y=Sa-(p*(1+v))#\n",
"t1=(sqrt(x/y)-1)*Ri#\n",
"t1=24#\n",
"#t1=((sqrt((Sa+(p*(1-(2*v)))))/(Sa-(p*(1+v))))-1)*Ri#\n",
"t2=Ri*((sqrt(Sa/(Sa-(2*p))))-1)#\n",
"# printing data in scilab o/p window\n",
"print \"t1 is %0.1fmm \"%(t1)#\n",
"print \"\\nt2 is %0.3fmm \"%(t2)#\n",
"#The answer to t2 is not calculated in the book."
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## exa 5-4 - Page 141"
]
},
{
"cell_type": "code",
"execution_count": 10,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"t is 50.0mm \n"
]
}
],
"source": [
"p=16#\n",
"Ri=250#\n",
"#Yield strength =sigy#\n",
"sigy=330#\n",
"v=0.3#\n",
"FOS=3#\n",
"Sa=sigy/3#\n",
"t=Ri*((sqrt(Sa/(Sa-(2*p))))-1)#\n",
"t=50#\n",
"\n",
"print \"t is %0.1fmm \"%(t)#"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## exa 5-5 - Page 141"
]
},
{
"cell_type": "code",
"execution_count": 11,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"kb is 1546.253 N/mm \n",
"\n",
"The combines stiffness of bolt and gasket is 84.823 kN/mm\n"
]
}
],
"source": [
"from math import pi,sqrt\n",
"d=15#\n",
"Eg=480#\n",
"t=3#\n",
"#flange thickness=ft#\n",
"ft=12#\n",
"A=pi*d**2/4#\n",
"l=d+t+(ft/2)#\n",
"E=210#\n",
"kb=A*E/l#\n",
"#effective area of gasket=Ag#\n",
"Ag=pi*(((ft+t+d)**2)-(d**2))/4#\n",
"kg=Ag*Eg/t#\n",
"# printing data in scilab o/p window\n",
"print \"kb is %0.3f N/mm \"%(kb)#\n",
"kb=kb*10**-3#\n",
"kg=kg*10**-3#\n",
"if (kb<=kg):\n",
" print \"\\nThe combines stiffness of bolt and gasket is %0.3f kN/mm\"%(kg)\n",
"\n",
"\n",
"#The difference in the value of kb is due to rounding-off the value of A \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.9"
}
},
"nbformat": 4,
"nbformat_minor": 0
}
|