{ "metadata": { "name": "" }, "nbformat": 3, "nbformat_minor": 0, "worksheets": [ { "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "

# Chapter 14: INTERNAL AND EXTERNAL FLOW

" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "

## Example 14.01, page: 319

" ] }, { "cell_type": "code", "collapsed": false, "input": [ "from __future__ import division\n", "import math\n", "\n", "# Initialization of Variable\n", "D = 4 #mm\n", "V = 50 #m/s\n", "l = 0.1 #m\n", "p = 1.23 #kg/m3\n", "mu = 1.79E-5 #Ns/m2\n", "\n", "#calculations:\n", "#reynolds number\n", "Re = p*V*(D/1000)/mu\n", "#from table 14.1\n", "e = 0.0015 #mm\n", "#e/D\n", "e_D = e/D\n", "#from chart 14.7\n", "f = 0.028\n", "#pressure drop\n", "dP = f*(l/(D/1000))*(p/2)*V**2/1000\n", "\n", "#Results\n", "print \"the pressure drop is\",round(dP,3),\"kPa\"\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "the pressure drop is 1.076 kPa\n" ] } ], "prompt_number": 2 }, { "cell_type": "markdown", "metadata": {}, "source": [ "

## Example 14.02, page: 322

" ] }, { "cell_type": "code", "collapsed": false, "input": [ "from __future__ import division\n", "import math\n", "\n", "# Initialization of Variable\n", "T = 60 #degF\n", "p = 1.94 #slug/ft3\n", "mu = 2.34E-5 #lbf.s/ft2\n", "D = 0.0625 #ft\n", "Q = 0.0267 #ft3/s\n", "Df = 0.0417 #ft\n", "z1 = 0 #ft\n", "z2 = 20 #ft\n", "P2 = 0 #gage\n", "l13 = 15 #ft\n", "l34 = 10 #ft\n", "l45 = 5 #ft\n", "l56 = 10 #ft\n", "l67 = 10 #ft\n", "l78 = 10 #ft\n", "\n", "#calculations:\n", "#Area at 1\n", "A1 = math.pi*D**2/4\n", "#fluid vel in pipe\n", "V1 = Q/A1\n", "#reynolds number\n", "Re = p*V1*D/mu\n", "#area at 2\n", "A2 = math.pi*Df**2/4\n", "#velocity of stream exciting from faucet\n", "V2 = Q/A2\n", "r = 62.4 #lbf/ft3\n", "#total length\n", "l = l13 + l34 + l45 + l56 + l67 + l78\n", "#from Moody chart\n", "f = 0.0215\n", "#pressure drop\n", "P1 = (r*z2 + 0.5*p*(V2**2 - V1**2) + p*f*(l/D)*(V1**2/2))/144\n", "#loss coeff\n", "Kl = 4*1.5 + 10 + 2\n", "#entire Pressure drop\n", "P1 = P1 + p*(V1**2/2)*Kl/144\n", "\n", "#Results\n", "print \"entire pressure drop is\", round(P1,1),\"Psi\"\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "entire pressure drop is 30.4 Psi\n" ] } ], "prompt_number": 3 }, { "cell_type": "markdown", "metadata": {}, "source": [ "

## Example 14.03, page: 324

" ] }, { "cell_type": "code", "collapsed": false, "input": [ "from __future__ import division\n", "import math\n", "\n", "# Initialization of Variable\n", "T = 140 #degF\n", "r = 53.7 #lbf/ft3\n", "p = 1.67 #slug/ft3\n", "mu = 8E-5 #lbf.s/ft2\n", "l = 799 #mile\n", "D = 4 #ft\n", "Q = 117 #ft3/s\n", "V = 9.31 #ft/s\n", "g = 32.2 #ft/s2\n", "\n", "#calculations:\n", "#reynolds number\n", "Re = p*V*D/mu\n", "#from fig 14.7\n", "f = 0.0125\n", "#pump head\n", "hp = f*(l/D)*5280*(V**2/(2*g))\n", "#power req\n", "Wpdot = r*Q*hp/550\n", "\n", "#Results\n", "print \"the power added to the fluid by the pumps that drive this system is\", round(Wpdot,0),\"hp\"\n", "#answer wrong in book\n", "\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "the power added to the fluid by the pumps that drive this system is 202694.0 hp\n" ] } ], "prompt_number": 4 }, { "cell_type": "markdown", "metadata": {}, "source": [ "

## Example 14.04, page: 325

" ] }, { "cell_type": "code", "collapsed": false, "input": [ "from __future__ import division\n", "import math\n", "\n", "# Initialization of Variable\n", "P1_rw = 0.2 #P1/rH2O in inch\n", "V1 = 0\n", "g = 32.2 #ft/s2\n", "l = 20 #ft\n", "D = 4 #in\n", "P2 = 0\n", "rair = 0.0709 #lbf/ft3\n", "vair = 1.79E-4 #ft2/s\n", "rw = 62.4 #lbf/ft2\n", "\n", "#calculations:\n", "#loss coeffs\n", "KLent = 0.5 #entrance\n", "KLelb = 1.5 #elbow\n", "KL = KLent + 4*KLelb\n", "#P1\n", "P1 = P1_rw/12*rw\n", "#assumption\n", "f = 0.022\n", "V = ((P1/rair)*2*g/(1 + (l*f/(D/12)) + KL))**0.5\n", "#reynolds number\n", "Re = V*D/(vair*12)\n", "#Area\n", "A = math.pi/4*(D/12)**2\n", "#volumetric flow rate\n", "Q = A*V\n", "\n", "#Results\n", "print \"Volumetric flow rate is\", round(Q,3),\"ft3/s\"\n", "#answer wrong in book\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "Volumetric flow rate is 0.903 ft3/s\n" ] } ], "prompt_number": 5 }, { "cell_type": "markdown", "metadata": {}, "source": [ "

## Example 14.05, page: 325

" ] }, { "cell_type": "code", "collapsed": false, "input": [ "from __future__ import division\n", "import math\n", "\n", "# Initialization of Variable\n", "D = 60 #mm\n", "d = 30 #mm\n", "dP = 4 #kPa\n", "mu = 1.19E-3 #N.s/m2\n", "p = 789 #kg/m3\n", "\n", "#calculations:\n", "#area\n", "Ao = math.pi*(d/1000)**2/4\n", "b = d/D\n", "#at this b,\n", "Co = 0.613\n", "#from fig 14.10 and Re at this value of b, we get\n", "#volumetric flow rate\n", "Q = Co*Ao*(2*dP*1000/(p*(1 - b**4)))**0.5\n", "\n", "#Results\n", "print \"Volumetric flow rate is\", round(Q,5),\"m3/s\"\n", "#answer wrong in book\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "Volumetric flow rate is 0.00142 m3/s\n" ] } ], "prompt_number": 6 }, { "cell_type": "markdown", "metadata": {}, "source": [ "

## Example 14.06, page: 327

" ] }, { "cell_type": "code", "collapsed": false, "input": [ "from __future__ import division\n", "import math\n", "\n", "# Initialization of Variable\n", "U = 10 #ft/s\n", "Tw = 60 #degF\n", "Tg = 68 #degF\n", "Rexc = 5E5\n", "vW = 1.21E-5 #ft2/s\n", "vA = 1.57E-4 #ft2/s\n", "vG = 1.28E-2 #ft2/s\n", "\n", "#calculations:\n", "#water\n", "Xc_W = vW*Rexc/U\n", "dXc_W = 5*(vW*Xc_W/U)**0.5\n", "#air\n", "Xc_A = vA*Rexc/U\n", "dXc_A = 5*(vA*Xc_A/U)**0.5\n", "#glycerin\n", "Xc_G = vG*Rexc/U\n", "dXc_G = 5*(vG*Xc_G/U)**0.5\n", "\n", "#Results\n", "print \" Fluid\\t\\t v(ft2/s)\\t\\t Xc(ft)\\t\\t d(Xc)(ft)\"\n", "print \"a)Water\\t\\t\",vW,\"\\t\\t \",round(Xc_W,3),\"\\t \", round(dXc_W,5)\n", "print \"b)Air\\t\\t\",vA,\"\\t\\t \",round(Xc_A,2),\"\\t\\t \", round(dXc_A,4)\n", "print \"c)Glycerin\\t\",vG,\"\\t\\t\\t \",round(Xc_G,0),\"\\t \", round(dXc_G,2)\n", "\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ " Fluid\t\t v(ft2/s)\t\t Xc(ft)\t\t d(Xc)(ft)\n", "a)Water\t\t1.21e-05 \t\t 0.605 \t 0.00428\n", "b)Air\t\t0.000157 \t\t 7.85 \t\t 0.0555\n", "c)Glycerin\t0.0128 \t\t\t 640.0 \t 4.53\n" ] } ], "prompt_number": 7 }, { "cell_type": "markdown", "metadata": {}, "source": [ "

## Example 14.07, page: 329

" ] }, { "cell_type": "code", "collapsed": false, "input": [ "from __future__ import division\n", "import math\n", "\n", "# Initialization of Variable\n", "l = 8 #ft\n", "b = 4 #ft\n", "U = 80.7 #ft/s\n", "e = 0.003 #ft\n", "p = 0.00238 #slug/ft3\n", "mu = 3.74E-7 #lbf.s/ft2\n", "\n", "#calculations:\n", "A = l*b\n", "#reynolds number\n", "Re = p*U*l/mu\n", "#e_D = e/D\n", "e_D = e/l\n", "#from fig 14.14\n", "Cd = 0.0066\n", "#fraction drag\n", "D = 0.5*p*U**2*l*b*Cd\n", "\n", "#Results\n", "print \"the drag on the top surface of the plywood is\", round(D,2),\"lbf\"\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "the drag on the top surface of the plywood is 1.64 lbf\n" ] } ], "prompt_number": 8 }, { "cell_type": "markdown", "metadata": {}, "source": [ "

## Example 14.08, page: 334

" ] }, { "cell_type": "code", "collapsed": false, "input": [ "from __future__ import division\n", "import math\n", "\n", "# Initialization of Variable\n", "U = 95.3 #ft/s\n", "Cd1940 = 0.55\n", "b1940 = 5.2 #ft\n", "h1940 = 5.1 #ft\n", "Cd2003 = 0.30\n", "b2003 = 5.2 #ft\n", "h2003 = 4.3 #ft\n", "p = 0.00238 #slug/ft3\n", "\n", "#calculations:\n", "#Area\n", "A1940 = b1940*h1940\n", "A2003 = b2003*h2003\n", "#Drag\n", "D1940 = 0.5*p*U**2*A1940*Cd1940\n", "D2003 = 0.5*p*U**2*A2003*Cd2003\n", "#Power required\n", "W1940dot = U*D1940/550\n", "W2003dot = U*D2003/550\n", "\n", "#Results\n", "print \"drag force on 1940 car is\",round(D1940,0),\"lbf and on 2003 is\",round(D2003,1),\"lbf\"\n", "print \"power required to overcome drag force by 1940 car is\",round(W1940dot,1),\"hp and by 2003 car is\",round(W2003dot,1),\"hp\"\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "drag force on 1940 car is 158.0 lbf and on 2003 is 72.5 lbf\n", "power required to overcome drag force by 1940 car is 27.3 hp and by 2003 car is 12.6 hp\n" ] } ], "prompt_number": 9 }, { "cell_type": "markdown", "metadata": {}, "source": [ "

## Example 14.09, page: 336

" ] }, { "cell_type": "code", "collapsed": false, "input": [ "from __future__ import division\n", "import math\n", "\n", "# Initialization of Variable\n", "b = 96 #ft\n", "c = 7.5 #ft\n", "W = 210 #lbf\n", "U = 15 #ft/s\n", "d = 0.5 #mi\n", "p = 0.00238 #slug/ft3\n", "\n", "#calculations:\n", "#area\n", "A = b*c\n", "#lift coeff\n", "CL = 2*W/(p*U**2*A)\n", "\n", "#Results\n", "print \"coeff. of lift is\",round(CL,2)\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "coeff. of lift is 1.09\n" ] } ], "prompt_number": 10 } ], "metadata": {} } ] }