summaryrefslogtreecommitdiff
path: root/Fluid_Mechanics_by_John_F_Douglas/Chapter_12.ipynb
diff options
context:
space:
mode:
authorThomas Stephen Lee2015-09-04 22:04:10 +0530
committerThomas Stephen Lee2015-09-04 22:04:10 +0530
commit41f1f72e9502f5c3de6ca16b303803dfcf1df594 (patch)
treef4bf726a3e3ce5d7d9ee3781cbacfe3116115a2c /Fluid_Mechanics_by_John_F_Douglas/Chapter_12.ipynb
parent9c9779ba21b9bedde88e1e8216f9e3b4f8650b0e (diff)
downloadPython-Textbook-Companions-41f1f72e9502f5c3de6ca16b303803dfcf1df594.tar.gz
Python-Textbook-Companions-41f1f72e9502f5c3de6ca16b303803dfcf1df594.tar.bz2
Python-Textbook-Companions-41f1f72e9502f5c3de6ca16b303803dfcf1df594.zip
add/remove/update books
Diffstat (limited to 'Fluid_Mechanics_by_John_F_Douglas/Chapter_12.ipynb')
-rwxr-xr-xFluid_Mechanics_by_John_F_Douglas/Chapter_12.ipynb319
1 files changed, 319 insertions, 0 deletions
diff --git a/Fluid_Mechanics_by_John_F_Douglas/Chapter_12.ipynb b/Fluid_Mechanics_by_John_F_Douglas/Chapter_12.ipynb
new file mode 100755
index 00000000..745a2241
--- /dev/null
+++ b/Fluid_Mechanics_by_John_F_Douglas/Chapter_12.ipynb
@@ -0,0 +1,319 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:24438326f2aac267ced1e2e3aa21e094819eefb50d5f8862608b62208400992d"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "Chapter 12: Incompressible Flow around a Body"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.1, Page 399"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from __future__ import division\n",
+ "import math\n",
+ "\n",
+ "\n",
+ " #Initializing the variables\n",
+ "x =35;\n",
+ "T = 50;\n",
+ "m = 1;\n",
+ "g =9.81;\n",
+ "rho = 1.2;\n",
+ "A = 1.2;\n",
+ "U0 = 40*1000/3600; # Velocity in m/s\n",
+ "\n",
+ " #Calculations\n",
+ "L = T*math.sin(math.radians(x))+m*g;\n",
+ "D =T*math.cos(math.radians(x));\n",
+ "Cl = 2*L/(rho*U0**2*A);\n",
+ "Cd = 2*D/(rho*U0**2*A); \n",
+ "\n",
+ "print \"Lift Coefficient :\",round(Cl,3)\n",
+ "print \"Drag Coefficient :\",round(Cd,3)"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Lift Coefficient : 0.433\n",
+ "Drag Coefficient : 0.461\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.2, Page 406"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from __future__ import division\n",
+ "import math\n",
+ "\n",
+ "\n",
+ " #Initializing the variables\n",
+ "Vp =12;\n",
+ "lp = 40;\n",
+ "lm = 1;\n",
+ "As = 2500;\n",
+ "Dm = 32;\n",
+ "rhoP = 1025;\n",
+ "rhoM = 1000;\n",
+ "Ap = As;\n",
+ "\n",
+ " #Calculations\n",
+ "Am = As/40**2;\n",
+ "Vm = round(Vp*(lm/lp)**0.5,2);\n",
+ "Dfm = round(3.7*Vm**1.95*Am,1);\n",
+ "Rm = Dm - Dfm;\n",
+ "Rp = Rm *(rhoP/rhoM)*(lp/lm)**2*(Vp/Vm)**2;\n",
+ "Dfp = 2.9*Vp**1.8*Ap;\n",
+ "Dp = Rp + Dfp;\n",
+ "\n",
+ "print \"Expected total resistance (kN) :\",round(Dp/1000,2)"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Expected total resistance (kN) : 1407.07\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.3, Page 410"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from __future__ import division\n",
+ "import math\n",
+ "\n",
+ "\n",
+ " #Initializing the variables\n",
+ "U0 = 80*1000/3600;\n",
+ "d = 0.02;\n",
+ "rho =1.2;\n",
+ "mu = 1.7*10**-5;\n",
+ "A = 0.02*500; # Projected area of wire\n",
+ "N = 20; # No of cables\n",
+ "\n",
+ " #Calculations\n",
+ "Re = rho*U0*d/mu;\n",
+ "Cd = 1.2 # From figure 12.10 for given Re; \n",
+ "D = 0.5*rho*Cd*A*U0**2\n",
+ "F = N*D; \n",
+ "f = 0.198*(U0/d)*(1-19.7/Re);\n",
+ "\n",
+ "print \"Total force on tower (kN) :\",round(F/1000,2)\n",
+ "print \"Frequency (Hz) :\",round(f,1)"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Total force on tower (kN) : 71.11\n",
+ "Frequency (Hz) : 219.9\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.4, Page 415"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from __future__ import division\n",
+ "import math\n",
+ "\n",
+ "\n",
+ " #Initializing the variables\n",
+ "mu = 0.03;\n",
+ "d = 10**-3;\n",
+ "rhoP = 1.1*10**3;\n",
+ "g = 9.81;\n",
+ "rho0 = 0.9*10**3;\n",
+ " #Calculations\n",
+ "B = 18*mu/(d**2*rhoP);\n",
+ "t = round(4.60/B,4);\n",
+ "Vt = round(d**2*(rhoP - rho0)*g/(18*mu),5);\n",
+ "Re = rho0*Vt*d/mu;\n",
+ "\n",
+ "print \"Time taken by the particle take to reach 99 per cent of its terminal velocity (s):\",t\n",
+ "print \"\\nReynolds No corrosponding to the velocity :\",Re"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Time taken by the particle take to reach 99 per cent of its terminal velocity (s): 0.0094\n",
+ "\n",
+ "Reynolds No corrosponding to the velocity : 0.1089\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.5, Page 417"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from __future__ import division\n",
+ "import math\n",
+ "\n",
+ "\n",
+ " #Initializing the variables\n",
+ "muO = 0.0027;\n",
+ "Vt = 3*10**-3;\n",
+ "rhoW = 1000;\n",
+ "rhoP = 2.4*rhoW;\n",
+ "rhoO = 0.9*rhoW;\n",
+ "g = 9.81;\n",
+ "muA = 1.7*10**-5;\n",
+ "rhoA = 1.3;\n",
+ "\n",
+ " #Calculations\n",
+ "d = (18*muO*Vt/(rhoP-rhoO)/g)**0.5;\n",
+ "Re = Vt*d*rhoO/muO;\n",
+ "\n",
+ " #Movement of particle in upward direction\n",
+ "if(Re < 1):\n",
+ " v = 0.5;\n",
+ " \n",
+ " Re=5; # from fig 12.15\n",
+ " vt = muA*Re/(rhoA*d);\n",
+ " u = vt+v;\n",
+ " print \"Velocity of air stream blowing vertically up (m/s) :\",round(u,3) \n",
+ "else:\n",
+ " print \"strokes law is not valid\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Velocity of air stream blowing vertically up (m/s) : 1.157\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 12.6, Page 429"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from __future__ import division\n",
+ "import math\n",
+ "\n",
+ "\n",
+ " #Initializing the variables\n",
+ "c = 2;\n",
+ "s = 10;\n",
+ "rho = 5.33;\n",
+ "rho_ellip = 1.2;\n",
+ "D = 400;\n",
+ "L = 45000;\n",
+ "scale = 20;\n",
+ "U_windTunnel = 500;\n",
+ "U_proto = 400*1000/3600;\n",
+ "\n",
+ " #Calculations\n",
+ "A = c*s;\n",
+ "U_model = U_windTunnel/scale;\n",
+ "Cd = D/(0.5*rho*U_model**2*A);\n",
+ "Cl = L/(0.5*rho_ellip*U_proto**2*A); # Considering elliptical Lift model\n",
+ "Cdi = Cl**2/(math.pi*s/c); # Aspect Ratio = s/c \n",
+ "Cdt = Cd + Cdi;\n",
+ "Dw = 0.5*Cdt*rho_ellip*U_proto**2*A;\n",
+ "print \"Total drag on full sized wing (kN) :\",round(Dw/1000,2)"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Total drag on full sized wing (kN) : 2.65\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file