{ "metadata": { "name": "", "signature": "sha256:76799d83bd91128bf807e32787abef19090d6630d45c16a130eb1ab2178963ed" }, "nbformat": 3, "nbformat_minor": 0, "worksheets": [ { "cells": [ { "cell_type": "heading", "level": 1, "metadata": {}, "source": [ "Chapter 5 : Flow of Water Over Weirs" ] }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example 5.1 Page No : 141" ] }, { "cell_type": "code", "collapsed": false, "input": [ "import math \n", "\t\t\n", "#initialisation of variables\n", "L = 6. \t\t#ft\n", "H = 15. \t\t#in\n", "Cd = 0.62\n", "g = 32.2 \t\t#ft/sec**2\n", "\n", "#CALCULAIONS\n", "Q = 2*Cd*L*math.sqrt(2*g)*(H/12)**1.5/3\n", "\t\t\n", "#RESULTS\n", "print 'Total Discharge = %.1f cuses'%(Q)\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "Total Discharge = 27.8 cuses\n" ] } ], "prompt_number": 1 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example 5.2 Page No : 143" ] }, { "cell_type": "code", "collapsed": false, "input": [ "import math \n", "\t\t\n", "#initialisation of variables\n", "o = 90. \t\t#degrees\n", "H = 15.5 \t\t#in\n", "Cd = 0.6\n", "g = 32.2 \t\t#ft/sec**2\n", "\t\t\n", "#CALCULATIONS\n", "Q = 8*Cd*math.tan(math.radians(o/2))*math.sqrt(2*g)*(H/12)**2.5/15\n", "\t\t\n", "#RESULTS\n", "print 'Total Discharge = %.2f cuses'%(Q)\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "Total Discharge = 4.87 cuses\n" ] } ], "prompt_number": 2 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example 5.3 Page No : 143" ] }, { "cell_type": "code", "collapsed": false, "input": [ "import math \n", "\t\t\n", "#initialisation of variables\n", "Cd = 0.62\n", "L = 4. \t\t#ft\n", "g = 32.2 \t\t#ft/sec**2\n", "H = 6. \t\t#in\n", "o = 90. \t\t#degrees\n", "\t\t\n", "#CALCULATIONS\n", "Q = Cd*L*math.sqrt(2*g)*(H/12)**1.5*(2./3)\n", "H1 = (Q*15/(8*Cd*math.tan(math.radians(o/2))*math.sqrt(2*g)))**(2./5)\n", "\t\t\n", "#RESULTS\n", "print 'depth of water = %.2f ft'%(H1)\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "depth of water = 1.26 ft\n" ] } ], "prompt_number": 3 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example 5.4 Page No : 144" ] }, { "cell_type": "code", "collapsed": false, "input": [ "import math \n", "\t\t\n", "#initialisation of variables\n", "Cd = 0.62\n", "L = 3. \t\t#ft\n", "g = 32.2 \t\t#ft/sec**2\n", "H = 1. \t\t#ft\n", "L1 = 2. \t\t#ft\n", "h = 0.5 \t\t#ft\n", "L2 = 1. \t\t#ft\n", "h1 = 0.25 \t\t#ft\n", "\t\t\n", "#CALCULATIONS\n", "Q = 2*Cd*L*math.sqrt(2*g)*H**1.5/3\n", "Q1 =2*Cd*L1*math.sqrt(2*g)*((H+h)**1.5- H**1.5)/3\n", "Q2 = 2*Cd*L2*math.sqrt(2*g)*((H+h+h1)**1.5- (H+h)**1.5)/3\n", "Q3 = Q1+Q2+Q\n", "\t\t\n", "#RESULTS\n", "print 'Total Discharge = %.2f cuses'%(Q3)\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "Total Discharge = 17.09 cuses\n" ] } ], "prompt_number": 4 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example 5.5 Page No : 149" ] }, { "cell_type": "code", "collapsed": false, "input": [ "import math \n", "\t\t\n", "#initialisation of variables\n", "h = 9. \t\t#in\n", "l = 6. \t\t#ft\n", "g = 32.2 \t\t#ft/sec**2\n", "\t\t\n", "#CALCULATIONS\n", "H = h/12\n", "Q = math.sqrt(2*g)*l*(H/12)**1.5*(0.405+(0.00984/0.75))\n", "Q1 = 3.33*l*H**1.5\n", "\t\t\n", "#RESULTS\n", "print 'Discharge by francis formula = %.2f cuses'%(Q1)\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "Discharge by francis formula = 12.98 cuses\n" ] } ], "prompt_number": 5 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example 5.6 Page No : 149" ] }, { "cell_type": "code", "collapsed": false, "input": [ "\t\t\n", "#initialisation of variables\n", "l = 24. \t\t#ft\n", "n = 5. \t\t#parts\n", "h = 2. \t\t#ft\n", "w = 1.\t\t#ft\n", "n1 = 4.\n", "c = 10.\n", "\t\t\n", "#CALCULATIONS\n", "Q = 3.33*((l-n1)-0.1*c*h)*h**1.5\n", "\t\t\n", "#RESULTS\n", "print 'Discharge = %.1f cuses'%(Q)\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "Discharge = 169.5 cuses\n" ] } ], "prompt_number": 6 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example 5.7 Page No : 150" ] }, { "cell_type": "code", "collapsed": false, "input": [ "\t\t\n", "#initialisation of variables\n", "A = 25. \t\t#miles**2\n", "t = 24. \t\t#hr\n", "p = 50. \t\t#per cent\n", "l = 3. \t\t#in\n", "h = 4. \t\t#ft\n", "\t\t\n", "#CALCULATIONS\n", "A1 = 5280**2*A\n", "V = A1*l/12\n", "V1 = V/(t*60*60)\n", "V2 = V1/2\n", "L = (V2/(3.33*h*2))+0.2*4\n", "\t\t\n", "#RESULTS\n", "print 'length of weir = %.1f ft'%(L)\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "length of weir = 38.7 ft\n" ] } ], "prompt_number": 7 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example 5.8 Page No : 151" ] }, { "cell_type": "code", "collapsed": false, "input": [ "\t\t\n", "#initialisation of variables\n", "h = 4. \t\t#ft\n", "w = 5. \t\t#ft\n", "l = 2. \t\t#ft\n", "Q1 = 1008.5 \t\t#cuses\n", "n = 8. \t\t#piers\n", "\t\t\n", "#CALCULATIONS\n", "Q = 3.33*(w-0.2*h)*h**1.5\n", "n1 = Q1/Q\n", "L = n*l+w*n1\n", "\t\t\n", "#RESULTS\n", "print 'length of weir = %.f ft'%(L)\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "length of weir = 61 ft\n" ] } ], "prompt_number": 8 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example 5.9 Page No : 153" ] }, { "cell_type": "code", "collapsed": false, "input": [ "\n", "import math \n", "\t\t\n", "#initialisation of variables\n", "k = 3.33\n", "l = 10. \t\t#ft\n", "x = 2. \t\t#ft\n", "A = 30. \t\t#ft**2\n", "g = 32.2 \t\t#ft/sec**2\n", "\t\t\n", "#CALCULATIONS\n", "Q = k*(l-0.2*x)*x**1.5\n", "V = Q/A\n", "h = V**2/(2*g)\n", "Q1 = k*(l-0.2*(x+h))*((x+h)**1.5-h**1.5)\n", "va = Q1/A\n", "ha = va**2/(2*g)\n", "Q2 = k*(l-0.2*(x+ha))*((x+ha)**1.5-ha**1.5)\n", "\t\t\n", "#RESULTS\n", "\t\t\n", "#RESULTS\n", "print 'Discharge in franccis formula = %.2f cusecs'%(Q1)\n", "print ' Discharge in corrected franccis formula = %.2f cusecs'%(Q2)\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "Discharge in franccis formula = 98.17 cusecs\n", " Discharge in corrected franccis formula = 99.41 cusecs\n" ] } ], "prompt_number": 9 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example 5.10 Page No : 154" ] }, { "cell_type": "code", "collapsed": false, "input": [ "import math \n", "\t\t\n", "#initialisation of variables\n", "Cd = 0.6\n", "g = 32.2 \t\t#ft/sec**2\n", "o = 90. \t\t#degrees\n", "H = 2. \t\t#ft\n", "A = 15.2 \t\t#ft**2\n", "\t\t\n", "#CALCULATIONS\n", "Q = 8*Cd*math.sqrt(2*g)*math.tan(math.radians(o/2))*H**2.5/15\n", "va = Q/A\n", "ha = va**2/(2*g)\n", "Q1 = 8*Cd*math.sqrt(2*g)*((H+ha)**2.5-ha**2.5)/15\n", "\t\t\n", "#RESULTS\n", "print 'Discharge of stream = %.1f cuses'%(Q1)\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "Discharge of stream = 14.8 cuses\n" ] } ], "prompt_number": 4 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example 5.11 Page No : 155" ] }, { "cell_type": "code", "collapsed": false, "input": [ "\t\t\n", "#initialisation of variables\n", "va = 4. \t\t#ft/sec\n", "g = 32.2 \t\t#ft/sec**2\n", "H = 1.25 \n", "l = 10. \t\t#ft\n", "w = 62.4 \t\t#lbs/ft**3\n", "p = 60. \t\t#per cent\n", "l1 = 90. \t\t#ft\n", "\t\t\n", "#CALCULATIONS\n", "ha = va**2/(2*g)\n", "Q = 3.333*(l-0.1*2*(H+ha))*((H+ha)**1.5-ha**1.5)*w\n", "E = Q*l1\n", "HP = E*60/(100*550)\n", "\t\t\n", "#RESULTS\n", "print 'H.P available = %.1f H.P'%(HP)\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "H.P available = 338.8 H.P\n" ] } ], "prompt_number": 11 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example 5.12 Page No : 157" ] }, { "cell_type": "code", "collapsed": false, "input": [ "import math \n", "\t\t\n", "#initialisation of variables\n", "L = 8. \t\t#ft\n", "d = 9. \t\t#in\n", "h = 3. \t\t#in\n", "Cd1 = 0.62\n", "Cd2 = 0.62\n", "g = 32.2 \t\t#ft/sec**2\n", "\t\t\n", "#CALCULATIONS\n", "Q1 = (2./3)*Cd1*L*math.sqrt(2*g)*(h/12)**1.5\n", "Q2 = Cd2*L*d*math.sqrt(2*g*h/12)/12\n", "Q = Q1+Q2\n", "\t\t\n", "#RESULTS\n", "print 'Discharge = %.2f cuses'%(Q)\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "Discharge = 18.24 cuses\n" ] } ], "prompt_number": 12 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example 5.13 Page No : 158" ] }, { "cell_type": "code", "collapsed": false, "input": [ "import math \n", "\t\t\n", "#initialisation of variables\n", "L = 50. \t\t#ft\n", "d = 2. \t\t#ft\n", "h = 4. \t\t#ft\n", "Cd1 = 0.58\n", "Cd2 = 0.8\n", "g = 32.2 \t\t#ft/sec**2\n", "\t\t\n", "#CALCULATIONS\n", "ha = h/(2*g)\n", "Q1 = (2./3)*Cd1*L*math.sqrt(2*g)*((h+ha)**1.5-ha**1.5)\n", "Q2 = Cd2*L*d*math.sqrt(2*g*(h+ha))\n", "Q = Q1+Q2\n", "\n", "\n", "#RESULTS\n", "print 'Discharge = %d cuses'%(Q)\n", "\n", "# note : value of ha is calculated wrongly. please check." ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "Discharge = 2561 cuses\n" ] } ], "prompt_number": 4 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example 5.14 Page No : 158" ] }, { "cell_type": "code", "collapsed": false, "input": [ "import math \n", "\t\t\n", "#initialisation of variables\n", "M = 60.\n", "k = 500.\n", "v = 8. \t\t#ft/sec\n", "w = 100. \t\t#ft\n", "h1 = 5. \t\t#ft\n", "g = 32.2 \t\t#ft/sec**2\n", "x = 1.95 \t\t#ft\n", "\t\t\n", "#CALCULATIONS\n", "Q = k*M**(2./3)\n", "A = Q/v\n", "md = A/w\n", "h = md-h1\n", "ha = v**2/(2*g)\n", "H = h+x**2-1+h1-1\n", "\t\t\n", "#RESULTS\n", "print 'height above the crest of the air = %.2f ft of water'%(H)\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "height above the crest of the air = 11.38 ft of water\n" ] } ], "prompt_number": 14 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example 5.16 Page No : 163" ] }, { "cell_type": "code", "collapsed": false, "input": [ "import math \n", "\t\t\n", "#initialisation of variables\n", "H2 = 1.5 \t\t#ft\n", "H1 = 1. \t\t#ft\n", "A = 100. \t\t#yards**2\n", "Cd = 0.6\n", "g = 32.2 \t\t#ft/sec**2\n", "\t\t\n", "#CALCULATIONS\n", "A1 = A*9\n", "T = (1.25*A1/(Cd*math.sqrt(2*g)))*(H1-(1/H2)**1.5)\n", "\t\t\n", "#RESULTS\n", "print 'time of lowering the surface = %.1f sec'%(T)\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "time of lowering the surface = 106.5 sec\n" ] } ], "prompt_number": 15 } ], "metadata": {} } ] }