diff options
Diffstat (limited to 'Thermodynamics_by_F_P_Durham/chapter13.ipynb')
-rwxr-xr-x | Thermodynamics_by_F_P_Durham/chapter13.ipynb | 302 |
1 files changed, 302 insertions, 0 deletions
diff --git a/Thermodynamics_by_F_P_Durham/chapter13.ipynb b/Thermodynamics_by_F_P_Durham/chapter13.ipynb new file mode 100755 index 00000000..134029ab --- /dev/null +++ b/Thermodynamics_by_F_P_Durham/chapter13.ipynb @@ -0,0 +1,302 @@ +{ + "metadata": { + "name": "", + "signature": "sha256:9400ac9019314c4e9a568a522343f0bdbb2a3d098bb24add69a9bd20d9589ad0" + }, + "nbformat": 3, + "nbformat_minor": 0, + "worksheets": [ + { + "cells": [ + { + "cell_type": "heading", + "level": 1, + "metadata": {}, + "source": [ + "Chapter 13: Gas Dynamics" + ] + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example 13.1, page no. 259" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "\n", + "import math\n", + "\n", + "#initialization\n", + "v = 2000.0 #ft/sec\n", + "P = 14.7 #lb/in^2\n", + "g = 1.4\n", + "T = 10+460.0 #R\n", + "\n", + "#calculation\n", + "c = math.sqrt(g*32.2*53.3*T)\n", + "Nm = v/c\n", + "Tratio = 1+ (g-1)/2 *Nm**2\n", + "Tt = Tratio*T\n", + "Pratio = (Tratio)**(g/(g-1))\n", + "Pt = Pratio*P\n", + "\n", + "#result\n", + "print \"Stagnation temperature = %d R\" %Tt\n", + "print \"Stagnation pressure = \", round(Pt, 1), \"lb/in^2\"" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "Stagnation temperature = 802 R\n", + "Stagnation pressure = 95.8 lb/in^2\n" + ] + } + ], + "prompt_number": 2 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example 13.2, page no. 261" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "\n", + "import math\n", + "\n", + "#initialization\n", + "A = 0.3 #ft^2\n", + "P = 30.0 #lb/in^2\n", + "T = 160+460.0 #R\n", + "Mn = 0.82\n", + "g = 1.4\n", + "\n", + "#calculation\n", + "w = A*144*P*math.sqrt(g*32.2) *Mn*(1+ (g-1)/2.0 *(Mn)**2)**(-3)/math.sqrt(53.3*T)\n", + "\n", + "#result\n", + "print \"Mass flow = \", round(w, 1), \"lbm/sec\"" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "Mass flow = 26.9 lbm/sec\n" + ] + } + ], + "prompt_number": 3 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example 13.3, page no. 263" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "\n", + "import math\n", + "\n", + "#initialization\n", + "Mn = 3.0\n", + "Mni = 0.2\n", + "w = 10.0 #lbm/sec\n", + "g = 1.4\n", + "P = 200.0 #lb/in^2\n", + "T = 400+460.0 #R\n", + "\n", + "#calculation\n", + "Astar = w*math.sqrt(53.3*T) *((g+1)/2)**3 /(P*math.sqrt(g*32.2))\n", + "A1ratio = (2.0/(g+1) + (g-1)*Mni**2 /(g+1))**3 /Mni\n", + "A1 = A1ratio*Astar\n", + "A2ratio = (2.0/(g+1) + (g-1)*Mn**2 /(g+1))**3 /Mn\n", + "A2 = A2ratio*Astar\n", + "Pexit = P/(1+ Mni*Mn**2)**(g/(g-1))\n", + "\n", + "#result\n", + "print \"Throat Area = \", round(Astar, 2), \"in^2\"\n", + "print \"Inlet Area = \", round(A1, 2), \"in^2\"\n", + "print \"Exit Area = \", round(A2, 2), \"in^2\"\n", + "print \"Exit pressure = \", round(Pexit, 2), \"lb/in^2\"" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "Throat Area = 2.76 in^2\n", + "Inlet Area = 8.16 in^2\n", + "Exit Area = 11.67 in^2\n", + "Exit pressure = 5.44 lb/in^2\n" + ] + } + ], + "prompt_number": 4 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example 13.4, page no. 266" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "\n", + "import math\n", + "\n", + "#initialization\n", + "Pi = 750.0 #lb/in^2\n", + "g = 1.25\n", + "TA = 2.0 #in^2\n", + "r = 3.0\n", + "\n", + "#calculation\n", + "Fstar = round(((g+1)*(2.0/(g+1))**5 *TA*750))\n", + "Me = 2.45\n", + "Fratio = round(((1+g*Me**2)/(Me*(math.sqrt(4.5+ (g**2 -1)*Me**2)))), 3)\n", + "F2 = Fratio*Fstar\n", + "Pratio = (1+ 0.2*Me**2)**5\n", + "Fnstar = Fratio-((g+1)/2.0)**5 *r/(Pratio*2.25)\n", + "Fn = Fnstar*Fstar\n", + "\n", + "#result\n", + "print \"Internal rocket thrust = %d lb\" %F2 #answer in textbook is wrong\n", + "print \"External thrust = %d lb\" %Fn #answer in textbook is wrong" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "Internal rocket thrust = 2316 lb\n", + "External thrust = 2229 lb\n" + ] + } + ], + "prompt_number": 13 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example 13.5, page no. 270" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "\n", + "#initialization\n", + "Tt2 = 1620+460 #R\n", + "Tt1 = 60+460 #R\n", + "Mi = 0.2\n", + "P = 40 #lb/in^2\n", + "g = 1.35\n", + "\n", + "#calculation\n", + "Tratio = Tt2/Tt1\n", + "#From figure\n", + "fM = 4*0.036\n", + "NM2 = 0.49\n", + "Pratio = 0.98/0.885\n", + "Pt2 = P/Pratio\n", + "\n", + "#result\n", + "print \"Final stagnation pressure = \", round(Pt2, 1), \"lb/in^2\"\n", + "print \"Final mach number = \", round(fM, 3)" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "Final stagnation pressure = 36.1 lb/in^2\n", + "Final mach number = 0.144\n" + ] + } + ], + "prompt_number": 16 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example 13.6, page no. 273" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "\n", + "#initialization\n", + "M = 0.4\n", + "l = 10.0 #ft\n", + "dia = 3.0 #in\n", + "P = 50.0 #lb/in^2\n", + "ff = 0.008\n", + "T = 100+460.0 #R\n", + "\n", + "#calculation\n", + "constant = 4*ff*l/dia\n", + "exitM = 2.9-constant\n", + "Nm2 = 0.5\n", + "Ptratio = 2.73/2.3\n", + "Pt2 = P/Ptratio\n", + "\n", + "#result\n", + "print \"Exit total pressure = \", round(Pt2, 1), \"lb/in^2\"" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "Exit total pressure = 42.1 lb/in^2\n" + ] + } + ], + "prompt_number": 17 + } + ], + "metadata": {} + } + ] +}
\ No newline at end of file |