{
 "metadata": {
  "name": "",
  "signature": "sha256:53a1ba1b803cb0b51138c9b8688085c88b0a88d5fedff21bf58ba2fdae3bfaab"
 },
 "nbformat": 3,
 "nbformat_minor": 0,
 "worksheets": [
  {
   "cells": [
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {},
     "source": [
      "Ch:11 Riveted joints"
     ]
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "exa 11-1 - Page 322"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "from math import pi\n",
      "t=20#\n",
      "p=100#\n",
      "d=25#\n",
      "sigt=40#\n",
      "P=(p-d)*t*sigt#\n",
      "Ts=(4*P)/(pi*d**2)#\n",
      "sigb=P/(d*t)#\n",
      "print \" P is %0.0f N     \"%(P)#\n",
      "print \"\\n Ts is %0.2f MPa     \"%(Ts)#\n",
      "print \"\\n sigb is %0.0f MPa     \"%(sigb)#"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " P is 60000 N     \n",
        "\n",
        " Ts is 122.23 MPa     \n",
        "\n",
        " sigb is 120 MPa     \n"
       ]
      }
     ],
     "prompt_number": 2
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "exa 11-2 - Page 322"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "t=22#\n",
      "t1=5*t/8#\n",
      "d=30#\n",
      "p=100#\n",
      "sigt=75#\n",
      "P=(p-d)*t*sigt#\n",
      "Ts=(2*P)/(pi*d**2)#\n",
      "sigb=P/(d*t)#\n",
      "P=P*10**-3\n",
      "print \" P is %0.1f kN     \"%(P)#\n",
      "print \"\\n Ts is %0.1f MPa     \"%(Ts)#\n",
      "print \"\\n sigb is %0.0f N/mm**2     \"%(sigb)#"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " P is 115.5 kN     \n",
        "\n",
        " Ts is 81.7 MPa     \n",
        "\n",
        " sigb is 175 N/mm**2     \n"
       ]
      }
     ],
     "prompt_number": 3
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "exa 11-3 - Page 323"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "t=15#\n",
      "t1=5*t/8#\n",
      "d=25#\n",
      "n=2#\n",
      "Ta=80#\n",
      "sigta=100#\n",
      "sigba=120#\n",
      "Ps=n*1.875*pi*d**2*Ta/4#\n",
      "Pb=n*d*t*sigba#\n",
      "p=Pb/(t*Ta)+d#\n",
      "Pp=p*t*Ta#\n",
      "n=Pb/Pp#\n",
      "print \" p is %0.0f mm     \"%(p)#\n",
      "print \"\\n n is %0.2f      \"%(n)#"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " p is 100 mm     \n",
        "\n",
        " n is 0.00      \n"
       ]
      }
     ],
     "prompt_number": 5
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "exa 11-4 - Page 323"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "from math import sqrt\n",
      "b=200#\n",
      "t=16#\n",
      "d=6*sqrt(t)#\n",
      "sigta=80#\n",
      "Ta=60#\n",
      "sigba=100#\n",
      "Pt=(b-d)*t*sigta#\n",
      "Ps=1.875*pi*d**2*Ta/4#\n",
      "Pb=d*t*sigba#\n",
      "n1=Pt/Pb#\n",
      "n1=6#\n",
      "Pt2=((b-(2*d))*t*sigta)+Pb#\n",
      "Pt3=((b-(3*d))*t*sigta)+(3*Pb)#\n",
      "Pp=b*t*sigta#\n",
      "n2=Pt/Pp#\n",
      "n2=n2*100#\n",
      "print \" d is %0.0f mm     \"%(d)#\n",
      "print \"\\n n1 is %0.0f      \"%(n1)#\n",
      "print \"\\n Pt is %0.0f N      \"%(Pt)#\n",
      "print \"\\n Pt2 is %0.0f N     \"%(Pt2)#\n",
      "print \"\\n Pt3 is %0.0f N     \"%(Pt3)#\n",
      "print \"\\n n2 is %0.0f      \"%(n2)#\n",
      "#Answer to strength of rivet in bearing 'Pb' is calculated incorrectly in the book, hence Pt2,Pt3 is calculated subsequently incorrect."
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " d is 24 mm     \n",
        "\n",
        " n1 is 6      \n",
        "\n",
        " Pt is 225280 N      \n",
        "\n",
        " Pt2 is 232960 N     \n",
        "\n",
        " Pt3 is 279040 N     \n",
        "\n",
        " n2 is 88      \n"
       ]
      }
     ],
     "prompt_number": 7
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "exa 11-5 - Page 324"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "from math import atan\n",
      "a=50#\n",
      "b=75#\n",
      "P=36*10**3#\n",
      "d=24#\n",
      "Ta=60#\n",
      "n=9#\n",
      "A=pi*d**2/4#\n",
      "Td=P/(n*A)#\n",
      "theta=atan(b/a)#\n",
      "Ts=54.64#\n",
      "r2=90.184#\n",
      "e=A*29575.7/P#\n",
      "print \" e is %0.1f mm     \"%(e)#"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " e is 371.7 mm     \n"
       ]
      }
     ],
     "prompt_number": 9
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "exa 11-6 - Page 325"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "P=12*10**3#\n",
      "Tmax=100#\n",
      "n=6#\n",
      "e=50+50+(5/2)#\n",
      "T=P*e#\n",
      "Td=P/n#\n",
      "ra=125#\n",
      "k=T/((2*125**2)+(2*75**2)+(2*25**2))#\n",
      "Tr=(k*ra)+Td#\n",
      "A=Tr/Tmax#\n",
      "d=sqrt(A*4/pi)#\n",
      "d=12#\n",
      "print \" d is %0.0f mm     \"%(d)#"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " d is 12 mm     \n"
       ]
      }
     ],
     "prompt_number": 10
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "exa 11-7 - Page 326"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "from __future__ import division\n",
      "t=15#\n",
      "d=6*sqrt(t)#\n",
      "d=24#\n",
      "sigta=75#\n",
      "sigba=105#\n",
      "Ta=60#\n",
      "n=4#\n",
      "Pt=n*pi*d**2*Ta/4#\n",
      "x=d*t*sigta#\n",
      "y=2*t*sigta#\n",
      "p=(Pt+x)/y#\n",
      "p=60#\n",
      "C=4.17#\n",
      "pmax=(C*t)+41.28#\n",
      "Pt1=(y*p)-x#\n",
      "Ps=n*pi*d**2*Ta/4#\n",
      "Pb=n*d*t*sigba#\n",
      "S=2*p*t*sigta#\n",
      "n=Pt1/S#\n",
      "n=n*100#\n",
      "print \" n is %0.f      \"%(n)#  "
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " n is 80      \n"
       ]
      }
     ],
     "prompt_number": 13
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "exa 11-8 - Page 327"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "D=1500#\n",
      "p=2#\n",
      "nt=0.75#\n",
      "sigut=420#\n",
      "FOS=5#\n",
      "sigta=sigut/FOS#\n",
      "t=p*D/(2*sigta*nt)#\n",
      "t=24#\n",
      "d=6*sqrt(t)#\n",
      "d=30#\n",
      "Ta=330/5#\n",
      "sigba=640/5#\n",
      "Ps=2*1.875*pi*(d**2)*Ta/4#\n",
      "p=(Ps/(t*sigta))+d#\n",
      "p=117#\n",
      "t1=5*t/8#\n",
      "Pt=(p-d)*t*sigta#\n",
      "Pp=p*t*sigta#\n",
      "Pb=2*d*t*sigba#\n",
      "n=Ps/Pb#\n",
      "n=n*100#\n",
      "print \" n is %0.0f      \"%(n)#"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " n is 95      \n"
       ]
      }
     ],
     "prompt_number": 14
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "exa 11-9 - Page 327"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "D=1200#\n",
      "p=2.5#\n",
      "sigba=110#\n",
      "Pa=pi*D**2*p/4#\n",
      "nt=0.8#\n",
      "sigta=80#\n",
      "t=p*D/(2*sigta*nt)#\n",
      "t=24#\n",
      "d=6*sqrt(t)#\n",
      "d=30#\n",
      "Ta=55#\n",
      "Ps=pi*(d**2)*Ta/4#\n",
      "Np=Pa/Ps#\n",
      "Np=74#\n",
      "nr=Np/2#\n",
      "p=pi*(D+t)/nr#\n",
      "pb=2*d#\n",
      "m=1.5*d#\n",
      "Pt=(p-d)*t*sigta#\n",
      "Ps=2*Ps#\n",
      "Pb=2*d*t*sigba#\n",
      "Pp=p*t*sigta#\n",
      "n=Ps/Pp#\n",
      "n=n*100#\n",
      "print \" n is %0.0f      \"%(n)#"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " n is 39      \n"
       ]
      }
     ],
     "prompt_number": 15
    }
   ],
   "metadata": {}
  }
 ]
}