diff options
Diffstat (limited to 'Testing_the_interface/chapter1_3.ipynb')
-rwxr-xr-x | Testing_the_interface/chapter1_3.ipynb | 423 |
1 files changed, 0 insertions, 423 deletions
diff --git a/Testing_the_interface/chapter1_3.ipynb b/Testing_the_interface/chapter1_3.ipynb deleted file mode 100755 index cf45a409..00000000 --- a/Testing_the_interface/chapter1_3.ipynb +++ /dev/null @@ -1,423 +0,0 @@ -{ - "metadata": { - "name": "" - }, - "nbformat": 3, - "nbformat_minor": 0, - "worksheets": [ - { - "cells": [ - { - "cell_type": "heading", - "level": 1, - "metadata": {}, - "source": [ - "Chapter 1: Tension Comprssion and Shear" - ] - }, - { - "cell_type": "heading", - "level": 2, - "metadata": {}, - "source": [ - "Example 1.1, page no. 9" - ] - }, - { - "cell_type": "code", - "collapsed": false, - "input": [ - "\"\"\"\n", - "Find compressive stress and strain in the post\n", - "\"\"\"\n", - "\n", - "import math\n", - "\n", - "#initialisation\n", - "\n", - "d_1 = 4 # inner diameter (inch)\n", - "d_2 = 4.5 #outer diameter (inch)\n", - "P = 26000 # pressure in pound\n", - "L = 16 # Length of cylinder (inch)\n", - "my_del = 0.012 # shortening of post (inch)\n", - "\n", - "#calculation\n", - "A = (math.pi/4)*((d_2**2)-(d_1**2)) #Area (inch^2)\n", - "s = P/A # stress\n", - "\n", - "print \"compressive stress in the post is \", round(s), \"psi\"\n", - "\n", - "e = my_del/L # strain\n", - "\n", - "print \"compressive strain in the post is %e\" %e" - ], - "language": "python", - "metadata": {}, - "outputs": [ - { - "output_type": "stream", - "stream": "stdout", - "text": [ - "compressive stress in the post is 7789.0 psi\n", - "compressive strain in the post is 7.500000e-04\n" - ] - } - ], - "prompt_number": 5 - }, - { - "cell_type": "heading", - "level": 2, - "metadata": {}, - "source": [ - "Example 1.2, page no. 10" - ] - }, - { - "cell_type": "code", - "collapsed": false, - "input": [ - "\"\"\"\n", - "formula for maximum stress & calculating maximum stress\n", - "\"\"\"\n", - "\n", - "import math \n", - "\n", - "#initialisation\n", - "W = 1500 # weight (Newton)\n", - "d = 0.008 #diameter(meter) \n", - "g = 77000 # Weight density of steel\n", - "L = 40 # Length of bar (m)\n", - "\n", - "#calculation\n", - "\n", - "A = (math.pi/4)*(d**2) # Area\n", - "s_max = (1500/A) + (g*L) # maximum stress\n", - "\n", - "#result\n", - "print \"Therefore the maximum stress in the rod is \", round(s_max,1), \"Pa\"" - ], - "language": "python", - "metadata": {}, - "outputs": [ - { - "output_type": "stream", - "stream": "stdout", - "text": [ - "Therefore the maximum stress in the rod is 32921551.8 Pa\n" - ] - } - ], - "prompt_number": 16 - }, - { - "cell_type": "heading", - "level": 2, - "metadata": {}, - "source": [ - "Example 1.3. page no. 26" - ] - }, - { - "cell_type": "code", - "collapsed": false, - "input": [ - "\"\"\"\n", - "calculating change in lenght of pipe, strain in pipe, increase in diameter & increase in wall thickness\n", - "\"\"\"\n", - "\n", - "import math \n", - "\n", - "#initialisation\n", - "d1 = 4.5 # diameter in inch\n", - "d2 = 6 # diameter in inch\n", - "A = (math.pi/4)*((d2**2)-(d1**2)) # Area\n", - "P = 140 # pressure in K\n", - "s = -P/A # stress (compression)\n", - "E = 30000 # young's modulus in Ksi\n", - "e = s/E # strain\n", - "\n", - "#calculation\n", - "\n", - "# Part (a)\n", - "my_del = e*4*12 # del = e*L \n", - "print \"Change in length of the pipe is\", round(my_del,3), \"inch\"\n", - "\n", - "# Part (b)\n", - "v = 0.30 # Poissio's ratio\n", - "e_ = -(v*e)\n", - "print \"Lateral strain in the pipe is %e\" %e_\n", - "\n", - "# Part (c)\n", - "del_d2 = e_*d2 \n", - "del_d1 = e_*d1\n", - "print \"Increase in the inner diameter is \", round(del_d1,6), \"inch\"\n", - "\n", - "# Part (d)\n", - "t = 0.75\n", - "del_t = e_*t\n", - "print \"Increase in the wall thicness is %f\" %del_t, \"inch\"\n", - "del_t1 = (del_d2-del_d1)/2 \n", - "print \"del_t1 = del_t\"" - ], - "language": "python", - "metadata": {}, - "outputs": [ - { - "output_type": "stream", - "stream": "stdout", - "text": [ - "Change in length of the pipe is -0.018 inch\n", - "Lateral strain in the pipe is 1.131768e-04\n", - "Increase in the inner diameter is 0.000509 inch\n", - "Increase in the wall thicness is 0.000085 inch\n", - "del_t1 = del_t\n" - ] - } - ], - "prompt_number": 7 - }, - { - "cell_type": "heading", - "level": 2, - "metadata": {}, - "source": [ - "Example 1.4, page no. 35" - ] - }, - { - "cell_type": "code", - "collapsed": false, - "input": [ - "\"\"\"\n", - "calculate average shear stress and compressive stress\n", - "\"\"\"\n", - "\n", - "import math \n", - "\n", - "#initialisation\n", - "d = 0.02 # diameter in m\n", - "t = 0.008 # thickness in m\n", - "A = math.pi*d*t # shear area\n", - "P = 110000 # prassure in Newton\n", - "\n", - "#calculation\n", - "A1 = (math.pi/4)*(d**2) # Punch area\n", - "t_aver = P/A # Average shear stress \n", - "\n", - "\n", - "print \"Average shear stress in the plate is \", t_aver, \"Pa\"\n", - "s_c = P/A1 # compressive stress\n", - "print \"Average compressive stress in the plate is \", s_c, \"Pa\"" - ], - "language": "python", - "metadata": {}, - "outputs": [ - { - "output_type": "stream", - "stream": "stdout", - "text": [ - "Average shear stress in the plate is 218838046.751 Pa\n", - "Average compressive stress in the plate is 350140874.802 Pa\n" - ] - } - ], - "prompt_number": 37 - }, - { - "cell_type": "heading", - "level": 2, - "metadata": {}, - "source": [ - "Eample 1.5, page no. 36" - ] - }, - { - "cell_type": "code", - "collapsed": false, - "input": [ - "\"\"\"\n", - "calculate bearing stress, shear stress in pin,\n", - "bearing stress between pin and gussets,\n", - "shear stress in anchor bolts\n", - "\"\"\"\n", - "\n", - "import math \n", - "\n", - "#initialisation\n", - "\n", - "P = 12.0 # Pressure in K\n", - "t = 0.375 # thickness of wall in inch\n", - "theta = 40.0 # angle in degree\n", - "d_pin = 0.75 # diameter of pin in inch\n", - "t_G = 0.625 # thickness of gusset in inch\n", - "t_B = 0.375 #thickness of base plate in inch\n", - "d_b = 0.50 # diameter of bolt in inch\n", - "\n", - "#calculation\n", - "\n", - "#Part (a)\n", - "s_b1 = P/(2*t*d_pin) # bearing stress\n", - "print \"Bearing stress between strut and pin\", round(s_b1,1), \"ksi\"\n", - "\n", - "#Part (b)\n", - "t_pin = (4*P)/(2*math.pi*(d_pin**2)) # average shear stress in the \n", - "print \"Shear stress in pin is \", round(t_pin,1), \"ksi\"\n", - "\n", - "# Part (c)\n", - "s_b2 = P/(2*t_G*d_pin) # bearing stress between pin and gusset\n", - "print \"Bearing stress between pin and gussets is\", s_b2, \"ksi\"\n", - "\n", - "# Part (d)\n", - "s_b3 = (P*math.cos(math.radians(40))/(4*t_B*d_b)) # bearing stress between anchor bolt and base plate\n", - "print \"Bearing stress between anchor bolts & base plate\", round(s_b3,1), \"ksi\"\n", - "\n", - "# Part (e)\n", - "t_bolt = (4*math.cos(math.radians(40))*P)/(4*math.pi*(d_b**2)) # shear stress in anchor bolt\n", - "print \"Shear stress in anchor bolts is\", round(t_bolt,1), \"ksi\"" - ], - "language": "python", - "metadata": {}, - "outputs": [ - { - "output_type": "stream", - "stream": "stdout", - "text": [ - "Bearing stress between strut and pin 21.3 ksi\n", - "Shear stress in pin is 13.6 ksi\n", - "Bearing stress between pin and gussets is 12.8 ksi\n", - "Bearing stress between anchor bolts & base plate 12.3 ksi\n", - "Shear stress in anchor bolts is 11.7 ksi\n" - ] - } - ], - "prompt_number": 39 - }, - { - "cell_type": "heading", - "level": 2, - "metadata": {}, - "source": [ - "Example 1.7, page no. 42" - ] - }, - { - "cell_type": "code", - "collapsed": false, - "input": [ - "\"\"\"\n", - "determine stress at various parts\n", - "\"\"\"\n", - "\n", - "import math\n", - "\n", - "#initialisation\n", - "b1 = 1.5 # width of recmath.tangular crosssection in inch\n", - "t = 0.5 # thickness of recmath.tangular crosssection in inch\n", - "b2 = 3.0 # width of enlarged recmath.tangular crosssection in inch\n", - "d = 1.0 # diameter in inch\n", - "\n", - "#calculation\n", - "\n", - "# Part (a)\n", - "s_1 = 16000 # maximum allowable tensile stress in Psi\n", - "P_1 = s_1*t*b1 \n", - "print \"The allowable load P1 is\", P_1, \"lb\"\n", - "\n", - "# Part (b)\n", - "s_2 = 11000 # maximum allowable tensile stress in Psi\n", - "P_2 = s_2*t*(b2-d) \n", - "print \"allowable load P2 at this section is\", P_2, \"lb\"\n", - "\n", - "#Part (c)\n", - "s_3 = 26000 # maximum allowable tensile stress in Psi\n", - "P_3 = s_3*t*d \n", - "print \"The allowable load based upon bearing between the hanger and the bolt is\", P_3, \"lb\"\n", - "\n", - "# Part (d)\n", - "s_4 = 6500 # maximum allowable tensile stress in Psi\n", - "P_4 = (math.pi/4)*(d**2)*2*s_4 \n", - "print \"the allowable load P4 based upon shear in the bolt is\", round(P_4), \"lb\"\n" - ], - "language": "python", - "metadata": {}, - "outputs": [ - { - "output_type": "stream", - "stream": "stdout", - "text": [ - "The allowable load P1 is 12000.0 lb\n", - "allowable load P2 at this section is 11000.0 lb\n", - "The allowable load based upon bearing between the hanger and the bolt is 13000.0 lb\n", - "the allowable load P4 based upon shear in the bolt is 10210.0 lb\n" - ] - } - ], - "prompt_number": 42 - }, - { - "cell_type": "heading", - "level": 2, - "metadata": {}, - "source": [ - "Example 1.8, page no. 46" - ] - }, - { - "cell_type": "code", - "collapsed": false, - "input": [ - "\"\"\"\n", - "calculating the cross sectional area \n", - "\"\"\"\n", - "\n", - "import math \n", - "\n", - "#initialisation\n", - "R_ah = (2700*0.8 + 2700*2.6)/2 # Horizontal component at A in N\n", - "R_ch = R_ah # Horizontal component at C in N\n", - "R_cv = (2700*2.2 + 2700*0.4)/3 # vertical component at C in N\n", - "R_av = 2700 + 2700 - R_cv # vertical component at A in N\n", - "R_a = math.sqrt((R_ah**2)+(R_av**2))\n", - "R_c = math.sqrt((R_ch**2)+(R_cv**2))\n", - "Fab = R_a # Tensile force in bar AB\n", - "Vc = R_c # Shear force acting on the pin at C\n", - "s_allow = 125000000 # allowable stress in tension \n", - "t_allow = 45000000 # allowable stress in shear\n", - "\n", - "#calculation\n", - "Aab = Fab / s_allow # required area of bar \n", - "Apin = Vc / (2*t_allow) # required area of pin\n", - "\n", - "\n", - "print \"Required area of bar is %f\" %Apin, \"m^2\"\n", - "d = math.sqrt((4*Apin)/math.pi) # diameter in meter\n", - "print \"Required diameter of pin is %f\" %d, \"m\"" - ], - "language": "python", - "metadata": {}, - "outputs": [ - { - "output_type": "stream", - "stream": "stdout", - "text": [ - "Required area of bar is 0.000057 m^2\n", - "Required diameter of pin is 0.008537 m\n" - ] - } - ], - "prompt_number": 9 - }, - { - "cell_type": "code", - "collapsed": false, - "input": [], - "language": "python", - "metadata": {}, - "outputs": [] - } - ], - "metadata": {} - } - ] -}
\ No newline at end of file |