diff options
author | kinitrupti | 2017-05-12 18:53:46 +0530 |
---|---|---|
committer | kinitrupti | 2017-05-12 18:53:46 +0530 |
commit | 6279fa19ac6e2a4087df2e6fe985430ecc2c2d5d (patch) | |
tree | 22789c9dbe468dae6697dcd12d8e97de4bcf94a2 /Mechanics_of_Materials_by_R._C._Hibbeler/Chapter5.ipynb | |
parent | d36fc3b8f88cc3108ffff6151e376b619b9abb01 (diff) | |
download | Python-Textbook-Companions-6279fa19ac6e2a4087df2e6fe985430ecc2c2d5d.tar.gz Python-Textbook-Companions-6279fa19ac6e2a4087df2e6fe985430ecc2c2d5d.tar.bz2 Python-Textbook-Companions-6279fa19ac6e2a4087df2e6fe985430ecc2c2d5d.zip |
Removed duplicates
Diffstat (limited to 'Mechanics_of_Materials_by_R._C._Hibbeler/Chapter5.ipynb')
-rwxr-xr-x | Mechanics_of_Materials_by_R._C._Hibbeler/Chapter5.ipynb | 736 |
1 files changed, 736 insertions, 0 deletions
diff --git a/Mechanics_of_Materials_by_R._C._Hibbeler/Chapter5.ipynb b/Mechanics_of_Materials_by_R._C._Hibbeler/Chapter5.ipynb new file mode 100755 index 00000000..649dd3d3 --- /dev/null +++ b/Mechanics_of_Materials_by_R._C._Hibbeler/Chapter5.ipynb @@ -0,0 +1,736 @@ +{
+ "metadata": {
+ "name": ""
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "Chapter 5:Torsion"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.2 Page No 188"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given\n",
+ "T1 = 4250.0 #kNmm, torque\n",
+ "T2 = -3000.0 #kNm\n",
+ "T3 = T1+T2 #kNm\n",
+ "r = 75.0 #mm, radius\n",
+ "\n",
+ "#Calculation\n",
+ "#Section Property\n",
+ "import math\n",
+ "J = (math.pi/2.0)*(r**4) #polar moment of inertia\n",
+ "#Shear Stress\n",
+ "c_a = 75 #mm\n",
+ "tou_a = (T3*c_a*1000)/J #tou = Tc/J\n",
+ "c_b = 15 #mm\n",
+ "tou_b = (T3*c_b*1000)/J #tou = Tc/J\n",
+ "\n",
+ "#Display\n",
+ "print'The shear stress developed at A = ',round(tou_a*10,1),\"ksi\"\n",
+ "print'The shear stress developed at B = ',round(tou_b*10,2),\"ksi\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The shear stress developed at A = 18.9 ksi\n",
+ "The shear stress developed at B = 3.77 ksi\n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.3 Page No 189"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given\n",
+ "di = 80 #mm, inside diameter\n",
+ "ri = 40/1000.0 #m, inside radius\n",
+ "d0 = 100 #mm, outside diameter\n",
+ "ro = d0/2000.0 #m outside radius\n",
+ "F = 80 #N, force\n",
+ "l1 = 0.2 #m, length\n",
+ "l2 = 0.3 #m\n",
+ "\n",
+ "#Internal Torque\n",
+ "T = F*(l1+l2)\n",
+ "#Section Property\n",
+ "import math\n",
+ "J = (math.pi/2.0)*((ro**4)-(ri**4))\n",
+ "#Shear Stress\n",
+ "c_o = 0.05#m\n",
+ "tou_o = (T*c_o)/(J*10**6)\n",
+ "c_i = 0.04 #m\n",
+ "tou_i = (T*c_i)/(J*10**6)\n",
+ "\n",
+ "#Display\n",
+ "print'The shear stress in the inner wall = ',round(tou_i,3),\"MPa\"\n",
+ "print'The shear stress in the outer wall = ',round(tou_o,3),\"MPa\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The shear stress in the inner wall = 0.276 MPa\n",
+ "The shear stress in the outer wall = 0.345 MPa\n"
+ ]
+ }
+ ],
+ "prompt_number": 12
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.4 Page No 191"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given\n",
+ "P = 5 #hp\n",
+ "N = 175 #rpm\n",
+ "allow_shear = 14.5 #ksi\n",
+ "\n",
+ "#Calculations\n",
+ "import math\n",
+ "P_=P*550 #ftlb/s\n",
+ "ang_vel = (2*math.pi*N)/60.0 # rad/s\n",
+ "T = P_/ang_vel #P = T*angular velocity\n",
+ "c = ((2*T*12)/(math.pi*allow_shear*1000))**(1/3.0)\n",
+ "d =2*c\n",
+ "\n",
+ "#Display\n",
+ "print'The required diameter of the shaft = ',round(d,3),\"inch\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The required diameter of the shaft = 0.858 inch\n"
+ ]
+ }
+ ],
+ "prompt_number": 22
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.5 Page No 205"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given\n",
+ "E = 80*10**9 #N/m**2, longitudinal stress\n",
+ "d = 14/1000.0 #m, diameter\n",
+ "r = d/2.0 #m, radius\n",
+ "R = 100 #mm\n",
+ "l_ac = 0.4 #m, length\n",
+ "l_cd = 0.3 #m\n",
+ "l_de = 0.5 #m\n",
+ "T_c = 280 #Nm, torque\n",
+ "T_a = 150 #Nm\n",
+ "T_d = 40 #Nm\n",
+ "T_ac = T_a #Nm\n",
+ "\n",
+ "#Calculation\n",
+ "T_cd = T_ac - T_c \n",
+ "T_de = T_cd - T_d\n",
+ "#Angle of Twist\n",
+ "import math\n",
+ "J = (math.pi/2.0)*(r**4)\n",
+ "phiA=T_ac*l_ac/(J*E)+T_cd*l_cd/(J*E)+T_de*l_de/(J*E)\n",
+ "Sp=phiA*R\n",
+ "\n",
+ "#Display\n",
+ "print'The angle of twist of the shaft = ',round(phiA,3),\"rad\"\n",
+ "print'The displacement of tooth P on gear A =',round(Sp,3),\"mm\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The angle of twist of the shaft = -0.212 rad\n",
+ "The displacement of tooth P on gear A = -21.212 mm\n"
+ ]
+ }
+ ],
+ "prompt_number": 28
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.6 Page No 206"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given\n",
+ "T = 45\t\t #N, torque\n",
+ "G = 80 \t\t#GPa, pressure\n",
+ "d = 20/1000.0\t\t #m\n",
+ "r = d/2.0\t #m\n",
+ "l_dc = 1.5\t\t #m\n",
+ "l_ab = 2 \t\t#m\n",
+ "r1 = 75/1000.0\t\t #m\n",
+ "r2 = 150/1000.0\t\t #m\n",
+ "\n",
+ "#Calculation\n",
+ "#Internal Torque\n",
+ "F = T/r2\n",
+ "T_d_x = F*r1\n",
+ "#Angle of twist\n",
+ "import math\n",
+ "J = (math.pi/2)*(r**4)\n",
+ "phi_c = (T*l_dc)/(2*J*G*10**9)\n",
+ "phi_b = (phi_c*r1)/r2\n",
+ "phi_ab = (T*l_ab)/(J*G*10**9)\n",
+ "phi_a = phi_b + phi_ab\n",
+ "\n",
+ "#Display\n",
+ "print'The angle of twist of end A of shaft AB = ',round(phi_a,3),\"rad\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The angle of twist of end A of shaft AB = 0.085 rad\n"
+ ]
+ }
+ ],
+ "prompt_number": 31
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.7 Page No 207"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given\n",
+ "d = 2 #inch, diameter\n",
+ "r = d/2.0 #radius\n",
+ "c = d/2.0\n",
+ "l_buried = 600\t\t #mm, buried length\n",
+ "G = 5500*10**3 \t\t#MPa\n",
+ "F = 1 \t\t#N\n",
+ "l_handle= 150 \t\t#mm\n",
+ "l_ab = 36 \t\t#inch\n",
+ "\n",
+ "#Internal Torque\n",
+ "T_ab = F*2*l_handle\n",
+ "t = T_ab/l_buried\n",
+ "#Maximum Shear Stress\n",
+ "import math\n",
+ "J = (math.pi/2.0)*(r**4)\n",
+ "tou_max = (T_ab*c)/(J)\n",
+ "\n",
+ "#Angle of Twist\n",
+ "from scipy import integrate\n",
+ "def f(x):\n",
+ " return(x)\n",
+ "x=integrate.quad(f,0,24) #Strain formula for short line segment = delta(sdash) =(1+e_z)delta(s) \n",
+ "X= x[0]\n",
+ "phi_a = ((T_ab*l_ab)+(50*X/4.0))/(J*G) \n",
+ "\n",
+ "#Display\n",
+ "print'The maximum shear stress in the post =',round(tou_max,1),\"psi\"\n",
+ "print'The angle of twist at the top of the post = ',round(phi_a,5),\"rad\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The maximum shear stress in the post = 191.0 psi\n",
+ "The angle of twist at the top of the post = 0.00167 rad\n"
+ ]
+ }
+ ],
+ "prompt_number": 50
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.8 Page No 216"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given\n",
+ "d = 20/1000.0 #m, diameter\n",
+ "r = d/2.0\n",
+ "l_bc = 0.2\n",
+ "l_cd = 1.5\n",
+ "l_da = 0.3\n",
+ "T_c = 800 #Nm, torque\n",
+ "T_d = -500 #Nm\n",
+ "\n",
+ "#Calculation\n",
+ "#Eqn 1 300 = T_a + T_b\n",
+ "#Compatibility\n",
+ "#Eqn 2\n",
+ "coeff_Tb = -l_bc\n",
+ "coeff_Ta = l_cd + l_da\n",
+ "#Solving Equations simultaneously using matrices\n",
+ "T_b = 645\n",
+ "T_a = -345\n",
+ "\n",
+ "#Display\n",
+ "print'The reaction at A = ',T_a,\"Nm\"\n",
+ "print'The reaction at B = ',T_b,\"Nm\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The reaction at A = -345 Nm\n",
+ "The reaction at B = 645 Nm\n"
+ ]
+ }
+ ],
+ "prompt_number": 54
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.9 Page No 217"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given\n",
+ "T = 250 #Nm, torque\n",
+ "G_st = 80 #GPa, pressure\n",
+ "G_br = 36 #GPa\n",
+ "ri = 0.5 #inch, inside radius\n",
+ "ro = 1 #inch, outside radius\n",
+ "l_ab = 1.2 #m\n",
+ "\n",
+ "#Equilibrium\n",
+ "# -Tst-Tbr+250Nm = 0\n",
+ "coeff1_st = -1\n",
+ "coeff1_br = -1\n",
+ "b1 = -250\n",
+ "\n",
+ "#Compatibility\n",
+ "#phi = TL/JG\n",
+ "import math\n",
+ "J1 = (math.pi/2.0)*(ro**4 - ri**4)\n",
+ "J2 = (math.pi/2.0)*(ri**4)\n",
+ "coeff2_st = 1/(J1*G_st*10**3)\n",
+ "coeff2_br = -1/(J2*G_br*10**3)\n",
+ "b2 = 0\n",
+ "\n",
+ "#Solving the above two equations simultaneously using matrices\n",
+ "T_st = 2911.5 #lb-inch\n",
+ "T_br = 88.5 #lb-inch\n",
+ "\n",
+ "shear_br_max = (T_br*10**3*ri)/(J2) #tou = (Tr)/J\n",
+ "shear_st_min = (T_st*10**3*ri)/(J1) #tou = (Tr)/J\n",
+ "shear_st_max = (T_st*10**3*ro)/(J1) #tou = (Tr)/J\n",
+ "\n",
+ "shear_strain = shear_br_max / G_br\n",
+ "shear_strain = shear_strain\n",
+ "\n",
+ "#Display\n",
+ "print'The maximum shear stress experienced by Steel =',round(shear_st_max/1000),\"psi\"\n",
+ "print'The minimum shear stress experienced by Steel =',round(shear_st_min/1000),\"psi\"\n",
+ "print'The maximum shear stress experienced by Brass ',round(shear_br_max/1000),\"psi\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The maximum shear stress experienced by Steel = 1977.0 psi\n",
+ "The minimum shear stress experienced by Steel = 989.0 psi\n",
+ "The maximum shear stress experienced by Brass 451.0 psi\n"
+ ]
+ }
+ ],
+ "prompt_number": 61
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.10 Page No 223"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given\n",
+ "import math\n",
+ "l = 4*12 #m, length\n",
+ "a = 1.5 #inch\n",
+ "tou_allow = 8000 #lb\n",
+ "phi_allow = 0.02 #rad\n",
+ "G = 3.7*10**6 #lb/inch**2, pressure\n",
+ "alpha = (60*math.pi)/180.0 #degrees\n",
+ " \n",
+ "#Calculations\n",
+ "T_shear1 = (tou_allow*a**3)/(20.0) # allowable shear stress = (20T)/(a**3)\n",
+ "T_twist1 = (phi_allow*a**4*G)/(46*l) #angle of twist =(46TL)/(a**4*G)\n",
+ "T1 = min(T_shear1, T_twist1)\n",
+ " \n",
+ "#Circular Cross Section\n",
+ "c_ = (a*a*math.sin(alpha))/(math.pi*2)\n",
+ "c = math.sqrt(c_)\n",
+ "\n",
+ "J = (math.pi/2.0)*(c**4)\n",
+ "T_shear2 = (tou_allow*J)/(c*1000)\n",
+ "T_twist2 = (phi_allow*J*G*10**3)/(l*10**6)\n",
+ "T2 = min(T_shear2, T_twist2)\n",
+ "\n",
+ "#Display\n",
+ "print'The largest torque that applied at the end of the triangular shaft ',round(T1,0),\"lb-in\"\n",
+ "print'The largest torque that applied at the end of the circular shaft ',round(T2*1000,0),\"lb-in\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The largest torque that applied at the end of the triangular shaft 170.0 lb-in\n",
+ "The largest torque that applied at the end of the circular shaft 233.0 lb-in\n"
+ ]
+ }
+ ],
+ "prompt_number": 69
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.12 Page No 228"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given\n",
+ "#The given dimension are\n",
+ "l_cd = 0.5 #m\n",
+ "l_de = 1.5 #m\n",
+ "h =60/1000.0 #m\n",
+ "w = 40/1000.0 #m\n",
+ "t_h = 3/1000.0 #m\n",
+ "t_w = 5/1000.0 #m\n",
+ "T_c = 60 #Nm\n",
+ "T_d = 25 #Nm\n",
+ "G = 38*10**9 #N/m**2\n",
+ "T1 = T_c - T_d\n",
+ "\n",
+ "#Calculation\n",
+ "#Average Shear Stress\n",
+ "area = (w-t_w)*(h-t_h)\n",
+ "shear_a = T1/(2*t_w*area*10**6)\n",
+ "shear_b = T1/(2*t_h*area*10**6)\n",
+ "\n",
+ "#Angle of Twist\n",
+ "phi=(T_c*l_cd/(4*area**2*G))*((2*57/5.0)+(2*35/3.0))+(T1*l_de/(4*area**2*G))*((2*57/5.0)+(2*35/3.0))\n",
+ "\n",
+ "#Display\n",
+ "print'The average shear stress of the tube at A = ',round(shear_a,2),\"MPa\"\n",
+ "print'The average shear stress of the tube at B = ',round(shear_b,2),\"MPa\"\n",
+ "print'The angle of twist of end C = ',round(phi,5),\"rad\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The average shear stress of the tube at A = 1.75 MPa\n",
+ "The average shear stress of the tube at B = 2.92 MPa\n",
+ "The angle of twist of end C = 0.00629 rad\n"
+ ]
+ }
+ ],
+ "prompt_number": 78
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.13 Page No 236"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given\n",
+ "fillet_r = 6 #mm, fillet radius\n",
+ "D = 40/1000.0 #m, diameter\n",
+ "d = 20/1000.0 #m\n",
+ "T = 30 #Nm\n",
+ "\n",
+ "#Calculation\n",
+ "D_d = D/d \n",
+ "r_d = fillet_r/d \n",
+ "k = 1.3\n",
+ "#Maximum Shear Stress\n",
+ "import math\n",
+ "c = D/2.0\n",
+ "J = (math.pi/2.0)*(c**4)\n",
+ "max_shear = (k*T*c)/(J*10**6) # tou = K(Tc/J)\n",
+ "\n",
+ "#Display\n",
+ "print'The maximum shear stress in the shaft is = ',round(max_shear,1),\"MPa\"\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The maximum shear stress in the shaft is = 3.1 MPa\n"
+ ]
+ }
+ ],
+ "prompt_number": 83
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.14 Page No 242"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given\n",
+ "ro = 50/1000.0 #m, outside radius\n",
+ "ri = 30/1000.0 #m inside radius\n",
+ "c = ro\n",
+ "shear = 20*10**6 #N/m**2\n",
+ "\n",
+ "#Maximum Elastic Torque\n",
+ "import math\n",
+ "J = (math.pi/2.0)*((ro**4)-(ri**4))\n",
+ "T_y = (shear*J)/c # tou = Tc/J\n",
+ "T_y = T_y/1000.0 #in kN\n",
+ "\n",
+ "#Plastic Torque\n",
+ "x0 = 0.03\n",
+ "x1 = 0.05\n",
+ "\n",
+ "from scipy import integrate\n",
+ "def f(rho):\n",
+ " return(rho**2)\n",
+ "I=integrate.quad(f,x0,x1) #Strain formula for short line segment = delta(sdash) =(1+e_z)delta(s) \n",
+ "\n",
+ "Tp =(2*math.pi*I[0]*shear)\n",
+ "Tp_= Tp/1000.0\n",
+ "#Outer Shear Strain\n",
+ "strain = (0.286*10**-3*ro)/(ri)\n",
+ "\n",
+ "#Display\n",
+ "print'The maximum torque that can be applied to the shaft ',round(T_y,2),\"kNm\"\n",
+ "print'The plastic torque that can be applied to the shaft',round(Tp_,2),\"kNm\" \n",
+ "print'The minimum shear strain at the outer radius of the shaft ',round(strain,6),\"rad\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The maximum torque that can be applied to the shaft 3.42 kNm\n",
+ "The plastic torque that can be applied to the shaft 4.11 kNm\n",
+ "The minimum shear strain at the outer radius of the shaft 0.000477 rad\n"
+ ]
+ }
+ ],
+ "prompt_number": 104
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.15 Page No 243"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given\n",
+ "r = 20/1000.0 #m, radius\n",
+ "l = 1.5 #m, length\n",
+ "phi = 0.6 #rad\n",
+ "shear_y = 75*10**6 #N/m**2\n",
+ "\n",
+ "#Calculations\n",
+ "max_shear_strain = (phi*r)/(l) #phi = (strain*L)/r\n",
+ "strain_y = 0.0016\n",
+ "r_y = (r*strain_y)/(max_shear_strain) #by ratios\n",
+ "#T= (math.pi*shear_y)*(4c**3 - r_y**3)/6.0\n",
+ "import math\n",
+ "c = r\n",
+ "T = (math.pi*shear_y)*(4*c**3 - r_y**3)/6.0\n",
+ "T = T/1000.0\n",
+ "\n",
+ "#Display\n",
+ "print'The torque needed to twist the shaft by 0.6 rad ',T,\"kNm\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The torque needed to twist the shaft by 0.6 rad 1.25412378731 kNm\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.16 Page No 244"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Given\n",
+ "l = 5 #m, length\n",
+ "G = 12*10**3 #GPa\n",
+ "co = 2 #inch\n",
+ "ci = 1 #inch\n",
+ "shear_y = 12 #N/mm**2\n",
+ "strain_y = 0.002 #rad, strain\n",
+ "\n",
+ "#Plastic Torque\n",
+ "import math\n",
+ "T_p = ((2*math.pi)*(co**3 - ci**3)*shear_y)/3.0\n",
+ "phi_p = (strain_y*l*shear_y)/ci\n",
+ "J = (math.pi/2.0)*(co**4 - ci**4)\n",
+ "shear_r = (T_p*co)/J\n",
+ "shear_i = (shear_r*ci)/(co)# shear = Tc/J\n",
+ "G = shear_y/strain_y \n",
+ "phi_dash = (T_p*l*10**3)/(J*G) #phi = TpL/JG\n",
+ "phi = phi_p - phi_dash\n",
+ "\n",
+ "\n",
+ "#Display\n",
+ "print'The plastic torque Tp = ',round(T_p,1),\"kip in\"\n",
+ "print'shear stress at inner wall is ',round(shear_i,2),\"ksi\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The plastic torque Tp = 175.9 kip in\n",
+ "shear stress at inner wall is 7.47 ksi\n"
+ ]
+ }
+ ],
+ "prompt_number": 16
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+}
\ No newline at end of file |