{
 "metadata": {
  "name": "",
  "signature": "sha256:9faffb3351aeb094129fceae3a1317161b22c496d3426397bbf5e546aeffe719"
 },
 "nbformat": 3,
 "nbformat_minor": 0,
 "worksheets": [
  {
   "cells": [
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {},
     "source": [
      "Chapter15-Fracture Mechanics"
     ]
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex2-pg559"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#calculate the magnitude of the fracture of load\n",
      "## initialization of variables\n",
      "import math\n",
      "d=250. ##mm\n",
      "c=30. ##mm\n",
      "t=25. ##mm\n",
      "## part (a)\n",
      "a=5 ##mm\n",
      "lambd=a/(2.*c)\n",
      "f1l=1.22 ##from the tble\n",
      "f2l=1.02\n",
      "##We don't know P yet so say P=1 \n",
      "P=1\n",
      "Sfl=P/(t*2.*c)*f1l+3.*280.*P*f2l/(2.*t*c**2)\n",
      "K_IC=59.*math.sqrt(1000.)\n",
      "P=K_IC/(Sfl*math.sqrt(a*math.pi))\n",
      "print('part (a)')\n",
      "print'%s %.2f %s'%('\\n P = ',P/10**3,' kN')\n",
      "## part (b)\n",
      "a=10. ##mm\n",
      "lambd=a/(2.*c)\n",
      "f1l=1.33 ##from the tble\n",
      "f2l=1.05\n",
      "## We don't know P yet so say P=1 \n",
      "P=1.\n",
      "Sfl=P/(t*2.*c)*f1l+3.*280.*P*f2l/(2.*t*c**2)\n",
      "K_IC=59.*math.sqrt(1000.)\n",
      "P=K_IC/(Sfl*math.sqrt(a*math.pi))\n",
      "print('\\n part (b)')\n",
      "print'%s %.2f %s'%('\\n P = ',P/10**3,' kN')\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "part (a)\n",
        "\n",
        " P =  23.71  kN\n",
        "\n",
        " part (b)\n",
        "\n",
        " P =  16.25  kN\n"
       ]
      }
     ],
     "prompt_number": 1
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex3-pg560"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#calculate the  nominal stress\n",
      "## initialization of variables\n",
      "import math \n",
      "a=100./2. ##mm\n",
      "Y=1500. ##MPa\n",
      "t=6. ##mm\n",
      "w=800. ##mmm\n",
      "c=200. ##mm\n",
      "a_c=a/c\n",
      "fl=1.045\n",
      "w=w*10**-3\n",
      "t=t*10**-3\n",
      "a=a*10**-3\n",
      "A=w*t\n",
      "Sigma=1./A\n",
      "K_I=Sigma*math.sqrt(math.pi*a)*fl\n",
      "print('part (a)')\n",
      "print'%s %.2f %s'%('\\n K_I = ',K_I,' MPa sqrt(m)')\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "part (a)\n",
        "\n",
        " K_I =  86.28  MPa sqrt(m)\n"
       ]
      }
     ],
     "prompt_number": 2
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex4-pg560"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#calculate the  maximum allowable crack length of central crack in the sheet of steel\n",
      "## initialization of variables\n",
      "import math\n",
      "S_u=1300. ##MPa\n",
      "K_C=69. ## MPa sqrt(m)\n",
      "SF=2.2\n",
      "##calculations\n",
      "S_c=S_u/2.2\n",
      "a=1./math.pi*(K_C/S_c)**2\n",
      "print'%s %.2f %s'%('a = ',a*10**3,' mm')\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "a =  4.34  mm\n"
       ]
      }
     ],
     "prompt_number": 3
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex5-pg561"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#calculate the aveage fracture stress \n",
      "## initialization of variables\n",
      "import math\n",
      "## For 30 mm crack\n",
      "a=30./2. ## mm  crack\n",
      "S_30 =600. ##MPa\n",
      "a=a*10**-3\n",
      "C=S_30*math.sqrt(a)\n",
      "## For 120 mm crack\n",
      "a=120/2.\n",
      "a=a*10**-3\n",
      "S_120=C/math.sqrt(a)\n",
      "print'%s %.2f %s'%('Sigma_120 = ',S_120,' MPa')\n",
      "\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Sigma_120 =  300.00  MPa\n"
       ]
      }
     ],
     "prompt_number": 4
    }
   ],
   "metadata": {}
  }
 ]
}