summaryrefslogtreecommitdiff
path: root/Engineering_Mechanics_by_Tayal_A.K./chapter12_5.ipynb
blob: 9f1a86451b509c05f5c06840a4193198d3e20f5b (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
{
 "metadata": {
  "name": "chapter12.ipynb"
 },
 "nbformat": 3,
 "nbformat_minor": 0,
 "worksheets": [
  {
   "cells": [
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {},
     "source": [
      "Chapter 12: Moment Of Inertia"
     ]
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 12.12-7,Page No:285"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math\n",
      "\n",
      "# Initilization of variables\n",
      "\n",
      "A= 50 # cm^2 # area of the shaded portion\n",
      "J_A=22.5*10**2 # cm^4 # polar moment of inertia of the shaded portion\n",
      "d=6 # cm\n",
      "\n",
      "# Calculations\n",
      "\n",
      "J_c=J_A-(A*d**2) \n",
      "\n",
      "# substuting the value of I_x from eq'n 2 in eq'n 1 we get,\n",
      "I_y=J_c*0.333 # cm^4 # M.O.I about Y-axis # 1/3=0.333\n",
      "\n",
      "# Now from eq'n 2,\n",
      "I_x=2*I_y # cm^4 # M.O.I about X-axis\n",
      "\n",
      "# Results\n",
      "\n",
      "print\"The centroidal moment of inertia about X-axis (I_x) is \",round(I_x),\"cm^4\"\n",
      "print\"The centroidal moment of inertia about Y-axis (I_y) is \",round(I_y),\"cm^4\"\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The centroidal moment of inertia about X-axis (I_x) is  300.0 cm^4\n",
        "The centroidal moment of inertia about Y-axis (I_y) is  150.0 cm^4\n"
       ]
      }
     ],
     "prompt_number": 1
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 12.12-8,Page No:288"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math\n",
      "\n",
      "# Initilization of variables\n",
      "\n",
      "b=20 # cm # width of the pate\n",
      "d=30 # cm # depth of the plate\n",
      "r=15 # cm # radius of the circular hole\n",
      "h=20 # cm # distance between the centre of the circle & the x-axis\n",
      "\n",
      "# Calculations\n",
      "\n",
      "# (a) Location of the centroid of the composite area\n",
      "\n",
      "A_1=b*d # cm^2 # area of the plate\n",
      "y_1=d/2 # cm # y-coordinate of the centroid\n",
      "A_2=(pi*r**2)/4 # cm^2 # area of the circle removed (negative)\n",
      "y_2=h # cm # y-coordinate of the centroid\n",
      "y_c=((A_1*y_1)-(A_2*y_2))/(A_1-A_2) # cm # from the bottom edge\n",
      "\n",
      "# (b) Moment of Inertia of the composite area about the centroidal x-axis\n",
      "\n",
      "# Area (A_1) M.I of area A_1 about x-axis\n",
      "I_x1=(b*(d**3))/12 # cm^4\n",
      "\n",
      "# M.I of the area A_1 about the centroidal x-axis of the composite area (By parallel-axis theorem)\n",
      "OC_1=15 # cm # from the bottom edge\n",
      "OC_2=20 # cm\n",
      "OC=12.9 # cm # from the bottom edge\n",
      "d_1=OC_1-OC # cm\n",
      "d_2=OC_2-OC # cm \n",
      "I_X1=(I_x1)+(A_1*d_1**2) # cm^4\n",
      "\n",
      "# Area(A_2) M.I of area A_2 about x-axis\n",
      "I_x2=(pi*r**4)/64 # cm^2\n",
      "\n",
      "#M.I of the area A_2 about the centroidal x-axis of the composite area (By parallel-axis theorem)\n",
      "I_X2=(I_x2)+(A_2*d_2**2) # cm^4\n",
      "\n",
      "# COMPOSITE AREA:M.O.I of the composite area about the centroidal x-axis\n",
      "I_x=(I_X1)-(I_X2) # cm^4\n",
      "\n",
      "# Results\n",
      "\n",
      "print\"The M.O.I of the composite area about the centroidal x-axis is \",round(I_x),\"cm^4\" \n",
      "#due to decimal variance answer varies by 1cm^4 from textbook"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The M.O.I of the composite area about the centroidal x-axis is  36253.0 cm^4\n"
       ]
      }
     ],
     "prompt_number": 41
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 12.12-9,Page No:289"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math\n",
      "\n",
      "# Initilization of variables\n",
      "\n",
      "b1=80 # mm # width of the flange pate\n",
      "d1=20 # mm # depth of the flange plate\n",
      "b2=40 # mm # width/thickness of the web\n",
      "d2=60 # mm # depth of the web\n",
      "\n",
      "# Calculations\n",
      "\n",
      "# (a) Location of the centroid of the composite area\n",
      "A_1=b1*d1 # mm^2 # area of the flange plate\n",
      "y_1=d2+(d1/2) # mm # y-coordinate of the centroid\n",
      "A_2=b2*d2 # mm^2 # area of the web\n",
      "y_2=d2/2 # mm # y-coordinate of the centroid\n",
      "y_c=((A_1*y_1)+(A_2*y_2))/(A_1+A_2) # mm # from the bottom edge\n",
      "\n",
      "# (b) Moment of Inertia of the composite area about the centroidal x-axis\n",
      "\n",
      "# Area (A_1) M.I of area A_1 about x-axis\n",
      "I_x1=(b1*(d1**3))/12 # mm^4\n",
      "# M.I of the area A_1 about the centroidal x-axis of the composite area (By parallel-axis theorem)\n",
      "OC_1=70 # mm # from the bottom edge\n",
      "OC_2=30 # mm # from the bottom edge\n",
      "OC=y_c # mm # from the bottom edge\n",
      "d_1=(d2-y_c)+(d1/2) # mm\n",
      "d_2=y_c-OC_2 # mm \n",
      "I_X1=(I_x1)+(A_1*d_1**2) # mm^4\n",
      "\n",
      "# Area(A_2) M.I of area A_2 about x-axis\n",
      "I_x2=(b2*d2**3)/12 # mm^4\n",
      "# M.I of the area A_2 about the centroidal x-axis of the composite area (By parallel-axis theorem)\n",
      "I_X2=(I_x2)+(A_2*d_2**2) # mm^4\n",
      "# COMPOSITE AREA:M.O.I of the composite area about the centroidal x-axis\n",
      "I_x=(I_X1)+(I_X2) # mm^4\n",
      "\n",
      "# Results\n",
      "\n",
      "print\"The M.O.I of the composite area about the centroidal x-axis is \",round(I_x),\"mm^4\"\n",
      "# NOTE: The answer given in the text book is 2.31*10^3 insted of 2.31*10^6.\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The M.O.I of the composite area about the centroidal x-axis is  2309333.0 mm^4\n"
       ]
      }
     ],
     "prompt_number": 42
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 12.12-10,Page No:291"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "import math\n",
      "\n",
      "# Initilization of variables\n",
      "b1=120 # mm # width of the flange pate of L-section\n",
      "d1=20 # mm # depth of the flange plate\n",
      "b2=20 # mm # width/thickness of the web\n",
      "d2=130 # mm # depth of the web\n",
      "\n",
      "# Calculations\n",
      "\n",
      "# (a) Location of the centroid of the composite area\n",
      "A_1=b1*d1 # mm^2 # area of the flange plate\n",
      "A_2=b2*d2 # mm^2 # area of the web\n",
      "y_1=d2+(d1/2) # mm # y-coordinate of the centroid\n",
      "y_2=d2/2 # mm # y-coordinate of the centroid\n",
      "x_1=60 # mm # x-coordinate of the centroid\n",
      "x_2=110 # mm # x-coordinate of the centroid\n",
      "y_c=((A_1*y_1)+(A_2*y_2))/(A_1+A_2) # mm # from the bottom edge\n",
      "x_c=((A_1*x_1)+(A_2*x_2))/(A_1+A_2) # mm # from the bottom edge\n",
      "\n",
      "# (b) Moment of Inertia of the composite area about the centroidal x-axis\n",
      "\n",
      "# Area (A_1) M.I of area A_1 about x-axis\n",
      "I_x1=(b1*(d1**3))/12 # mm^4\n",
      "# M.I of the area A_1 about the centroidal x-axis of the composite area (By parallel-axis theorem)\n",
      "OC_1=d2+(d1/2) # mm # from the bottom edge\n",
      "OC_2=d2/2 # mm # from the bottom edge\n",
      "OC=y_c # mm # from the bottom edge\n",
      "d_1=(d2-y_c)+(d1/2) # mm\n",
      "d_2=y_c-OC_2 # mm \n",
      "I_X1=(I_x1)+(A_1*d_1**2) # mm^4\n",
      "\n",
      "# Area(A_2) M.I of area A_2 about x-axis\n",
      "I_x2=(b2*d2**3)/12 # mm^4\n",
      "\n",
      "# M.I of the area A_2 about the centroidal x-axis of the composite area (By parallel-axis theorem)\n",
      "I_X2=(I_x2)+(A_2*d_2**2) # mm^4\n",
      "# COMPOSITE AREA:M.O.I of the composite area about the centroidal x-axis\n",
      "I_x=(I_X1)+(I_X2) # mm^4\n",
      "\n",
      "# (c) Moment of Inertia of the composite area about the centroidal y-axis\n",
      "\n",
      "# Area (A_1) M.I of area A_1 about y-axis\n",
      "I_y1=(d1*(b1**3))/12 # mm^4\n",
      "# M.I of the area A_1 about the centroidal y-axis of the composite area (By parallel-axis theorem)\n",
      "d_3=x_c-(b1/2) # mm # distance between c &c1 along x axis\n",
      "I_Y1=(I_y1)+(A_1*d_3**2) # mm^4\n",
      "\n",
      "# Area(A_2) M.I of area A_2 about y-axis\n",
      "I_y2=(d2*b2**3)/12 # mm^4\n",
      "\n",
      "# M.I of the area A_2 about the centroidal y-axis of the composite area (By parallel-axis theorem)\n",
      "d_4=b1-x_c-(b2/2) # mm # distance between c &c2 along x axis\n",
      "I_Y2=(I_y2)+(A_2*d_4**2) # mm^4\n",
      "# COMPOSITE AREA:M.O.I of the composite area about the centroidal y-axis\n",
      "I_y=(I_Y1)+(I_Y2) # mm^4\n",
      "\n",
      "# Results\n",
      "\n",
      "print\"The M.O.I of the composite area about the centroidal x-axis is \",round(I_x),\"mm^4\"\n",
      "print\"The M.O.I of the composite area about the centroidal Y-axis is \",round(I_y),\"mm^4\"\n",
      "# NOTE: The answer for I_x given in text book is 0.76*10^6 insted of 10.76*10^6\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The M.O.I of the composite area about the centroidal x-axis is  10761666.0 mm^4\n",
        "The M.O.I of the composite area about the centroidal Y-axis is  6086666.0 mm^4\n"
       ]
      }
     ],
     "prompt_number": 43
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 12.12-14,Page No:299"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math\n",
      "\n",
      "# Initilization of variables\n",
      "\n",
      "b=1 # cm # smaller side of the L-section\n",
      "h=4 # cm # larger side of the L-section\n",
      "\n",
      "# Calculations\n",
      "\n",
      "# (A) RECTANGLE A_1: Using the paralel axis theorem\n",
      "Ixy=0\n",
      "I_xy1=(Ixy)+((h*b)*(b*0.5)*(h*0.5)) # cm**4\n",
      "\n",
      "# (B) RECTANGLE A_2: Using the paralel axis theorem\n",
      "I_xy2=(Ixy)+((b*(h-1))*(1+(1.5))*(b*0.5)) # cm**4\n",
      "\n",
      "# Product of inertia of the total area\n",
      "I_xy=I_xy1+I_xy2 # cm**4\n",
      "\n",
      "# Results\n",
      "\n",
      "print\"The Product of inertia of the L-section is \",round(I_xy,2),\"cm^4\"\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The Product of inertia of the L-section is  7.75 cm^4\n"
       ]
      }
     ],
     "prompt_number": 47
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 12.12-15,Page No:300"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math\n",
      "\n",
      "# Initilization of variables\n",
      "\n",
      "I_x=1548 # cm^4 # M.O.I of the Z-section about X-axis\n",
      "I_y=2668 # cm^4 # M.O.I of the Z-section about Y-axis\n",
      "b=12 # cm # width of flange of the Z-section\n",
      "d=3 # cm # depth of flange of the Z-section\n",
      "t=2 # cm # thickness of the web of the Z-section\n",
      "h=6 # cm # depth of the web of the Z-section\n",
      "\n",
      "#Calculations\n",
      "\n",
      "A_1=b*d # cm^2 # area of top flange\n",
      "x_1=-5 # cm # distance of the centroid from X-axis for top flange\n",
      "y_1=4.5 # cm # distance of the centroid from Y-axis for top flange\n",
      "A_2=t*h # cm^2 # area of web\n",
      "x_2=0 # cm # distance of the centroid from X-axis for the web\n",
      "y_2=0 # cm # distance of the centroid from Y-axis for the web\n",
      "A_3=b*d # cm^2 # area of bottom flange\n",
      "x_3=5 # cm # distance of the centroid from X-axis for top flange\n",
      "y_3=-4.5 # cm # distance of the centroid from Y-axis for top flange\n",
      "\n",
      "# Product of Inertia of the total area is,\n",
      "I_xy=((A_1*x_1*y_1)+(A_3*x_3*y_3)) # cm^4\n",
      "# The direction of the principal axes is,\n",
      "theta_m=(arctan((2*I_xy)/(I_y-I_x))*(180/pi))/2 # degree\n",
      "# Principa M.O.I\n",
      "I_max=((I_x+I_y)/2)+((((I_x-I_y)/2)**2+(I_xy)**2)**0.5) # cm**4\n",
      "I_mini=((I_x+I_y)/2)-((((I_x-I_y)/2)**2+(I_xy)**2)**0.5) # cm**4\n",
      "\n",
      "# Results\n",
      "\n",
      "print\"The principal axes of the section about O is \",round(theta_m,2),\"degree\"\n",
      "print\"The Maximum value of principal M.O.I is \",round(I_max),\"cm^4\"\n",
      "print\"The Minimum value of principal M.O.I is \",round(I_mini),\"cm^4\"\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The principal axes of the section about O is  -35.47 degree\n",
        "The Maximum value of principal M.O.I is  3822.0 cm^4\n",
        "The Minimum value of principal M.O.I is  394.0 cm^4\n"
       ]
      }
     ],
     "prompt_number": 50
    }
   ],
   "metadata": {}
  }
 ]
}