{ "metadata": { "name": "", "signature": "sha256:3f5444f542f0d6a3b857b61fbecdc4e8047247ed8828d4cea5a34f91ccdf5eb3" }, "nbformat": 3, "nbformat_minor": 0, "worksheets": [ { "cells": [ { "cell_type": "heading", "level": 1, "metadata": {}, "source": [ "Chapter 1:Geotechnical Properties of Soil" ] }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Ex1.1:Pg-10" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#example 1.1\n", "\n", "V=0.25; # ft^3\n", "W=30.8; #lb\n", "Wd=28.2; # weight dried lb\n", "Gs=2.7;\n", "Gammaw=62.4; #lb/ft^3\n", "Gamma=W/V;\n", "print Gamma,\" is moist unit weight in lb/ft^3\"\n", "w=(W-Wd)/W;\n", "print round(w*100,2),\"is moisture content in %\"\n", "Gammad=Wd/V;\n", "print Gammad, \"is dry unit weight in lb/ft^3\"\n", "Vs=Wd/Gs/Gammaw;\n", "Vv=V-Vs;\n", "e=Vv/Vs;\n", "print round(e,3),\" is void ratio\"\n", "n=e/(1+e);\n", "print round(n,2),\"is porosity\"\n", "Vw=(W-Wd)/Gammaw;\n", "S=Vw/Vv;\n", "print round(S*100,2),\"is saturation in %\"\n", "\n", "# The answers in the book are different due to approximation while here calculations are precise\n", "\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "123.2 is moist unit weight in lb/ft^3\n", "8.44 is moisture content in %\n", "112.8 is dry unit weight in lb/ft^3\n", "0.494 is void ratio\n", "0.33 is porosity\n", "50.43 is saturation in %\n" ] } ], "prompt_number": 9 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Ex1.2:Pg-11" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#example 1.2\n", "\n", "e=0.72;\n", "w=12.0/100; #moisture content\n", "Gs=2.72;\n", "Gammaw=9.81;#kN/m^3\n", "Gammad=Gs*Gammaw/(1+e);\n", "print round(Gammad,2),\"= dry unit weight in kN/m^3\"\n", "Gamma=Gs*Gammaw*(1+w)/(1+e);\n", "print round(Gamma,2),\" = moist unit weight in kN/m^3\"\n", "Gammasat=(Gs+e)*Gammaw/(1+e);\n", "wa=Gammasat-Gamma;#water added\n", "print round(wa,2),\" = water added in kN/m^3\"\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "15.51 = dry unit weight in kN/m^3\n", "17.38 = moist unit weight in kN/m^3\n", "2.24 = water added in kN/m^3\n" ] } ], "prompt_number": 12 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Ex1.3:Pg-12" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#example 1.3\n", "from scipy.optimize import fsolve\n", "gmax=17.1; # Gammadmax\n", "Dr=0.7;\n", "w=8.0/100;#moisture content\n", "gmin=14.2; #Gammadmin\n", "def f(x):\n", " return (x-14.2)/(17.1-14.2)*17.1/x-0.7 \n", "x=fsolve(f,16);#solving for gammad\n", "Gamma=x[0]*(1+w);\n", "print round(Gamma,2),\"moist unit weight in kN/m^3\"\n", "\n", "\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "17.4 moist unit weight in kN/m^3\n" ] } ], "prompt_number": 14 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Ex1.7:Pg-38" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#example 1.7\n", "import math\n", "#part (a)\n", "e1=0.92;\n", "e2=0.86;\n", "Hc=2.8; # in m\n", "s2=212.0;#sigma2dash Load in kN/m2\n", "s1=140.0;#sigma1dash Load in kN/m2\n", "Cc=(e1-e2)/math.log10(s2/s1);\n", "Sc=Cc*Hc/(1+e1)*math.log10(s2/s1);\n", "print Sc*1000,\"consolidated depth in mm\"\n", "#part (b)\n", "# from Figure (1.21):\n", "Sct=40.0;# in mm\n", "T50=0.197;\n", "t=4.5; # in MIN\n", "Cr=T50*12.7**2.0/t;\n", "U=Sct/Sc*100.0/1000;\n", "H=Hc/2;\n", "Tv=math.pi/4*U**2.0/100**2;\n", "t=Tv*H**2.0/Cr*1000.0**2/60.0/24;\n", "print round(t,1),\" is time required in days\"\n", "\n", "\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "87.5 consolidated depth in mm\n", "31.6 is time required in days\n" ] } ], "prompt_number": 27 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Ex1.8:Pg-42" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#example 1.8\n", "\n", "Cv=7.061; # in mm^2/min\n", "tc=15*24*60.0;\n", "H=2.8/2*1000.0;\n", "Scmax=87.5; # consolidation\n", "Tc=Cv*tc/H**2;\n", "tv=31.6*24*60;\n", "Tv=Cv*tv/H**2;\n", "#from figure 1.28\n", "Sct=Scmax*0.36;\n", "print Sct,\"is consolidation in 31.6 days in mm\"\n", "\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "31.5 is consolidation in 31.6 days in mm\n" ] } ], "prompt_number": 28 } ], "metadata": {} } ] }