From 64419e47f762802600b3a2b6d8c433a16ccd3d55 Mon Sep 17 00:00:00 2001 From: Thomas Stephen Lee Date: Fri, 4 Sep 2015 22:04:10 +0530 Subject: add/remove/update books --- .../Chapter9_2.ipynb | 630 +++++++++++++++++++++ 1 file changed, 630 insertions(+) create mode 100755 Thermodynamics_Demystified_by_Merle_C_Potter/Chapter9_2.ipynb (limited to 'Thermodynamics_Demystified_by_Merle_C_Potter/Chapter9_2.ipynb') diff --git a/Thermodynamics_Demystified_by_Merle_C_Potter/Chapter9_2.ipynb b/Thermodynamics_Demystified_by_Merle_C_Potter/Chapter9_2.ipynb new file mode 100755 index 00000000..9448e892 --- /dev/null +++ b/Thermodynamics_Demystified_by_Merle_C_Potter/Chapter9_2.ipynb @@ -0,0 +1,630 @@ +{ + "metadata": { + "name": "", + "signature": "sha256:7e02442740cf50f0beae7f1fd9dfdf2fb7a16b9c0848a48a17d80c7a19de3f3d" + }, + "nbformat": 3, + "nbformat_minor": 0, + "worksheets": [ + { + "cells": [ + { + "cell_type": "heading", + "level": 1, + "metadata": {}, + "source": [ + "Chapter 9:Combustion" + ] + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Ex9.1:PG-229" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "# initialization of variables\n", + "\n", + "AFactual=20 # air fuel ratio actual\n", + "# The energy balance is done from equation\n", + "\n", + "# C4H10 + 6.5(O2+3.76N2)-----> 4CO2 + 5H2O + 24.44N2\n", + "\n", + "P=100 # atmospheic preesure in kPa\n", + "mair=6.5*(1+3.76)*29 # mass of air\n", + "mfuel=1*58 # mass of fuel\n", + "AFth=mair/mfuel # theoritical air-fuel ratio\n", + "Pexcessair=(AFactual-AFth)*100/AFth\n", + "\n", + "print \"The % excess air is\",round(Pexcessair,2),\"% \\n\"\n", + "\n", + "# NOW THE REACTION IS\n", + "# C4H10+ (1+%excessair/100)*6.5*(O2+3.76N2) -----> 4CO2 + 5H2O + 1.903O2 + 31.6N2\n", + "\n", + "PCO2=4/42.5*100 # VOLUME % OF CO2\n", + "\n", + "print \"The volume % of CO2 is\",round(PCO2,2),\"% \\n\"\n", + "\n", + "# NOW WE FIND DEW POINT\n", + "Nv=5 # moles of water\n", + "N=42.5 # moles of air\n", + "Pv=P*(Nv/N) # partial pressure of vapour\n", + "Tdp=49# dew point temperature in degree celsius from table C.2\n", + "\n", + "print \"The Dew point temperature is\",round(Tdp,2),\"degree celsius\"" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "The % excess air is 29.28 % \n", + "\n", + "The volume % of CO2 is 9.41 % \n", + "\n", + "The Dew point temperature is 49.0 degree celsius\n" + ] + } + ], + "prompt_number": 2 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Ex9.2:PG-231" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "# initialization of variables\n", + "\n", + "Pair=0.9 # 90% air is used for combustion\n", + "\n", + "# THE REACTION IS\n", + "# C4H10 + 0.9*6.5*(O2+3.76N2)----> aCO2 + 5H20 + bCO\n", + "# a and b are calculated by atomic balance\n", + "a=2.7\n", + "b=1.3\n", + "PCO=b*100/31 # volume % of CO\n", + "\n", + "print \"The volume % of CO is\",round(PCO,2),\"% \\n\"\n", + "\n", + "mair=6.5*Pair*4.76*29 # mass of air in kg\n", + "mfuel=1*58 # mass of fuel butane in kg\n", + "AF=mair/mfuel # air-fuel ratio\n", + "\n", + "print \"The air to fuel ratio is\",round(AF,2),\"kg air/ kg fuel \"\n", + "# THE SOLUTION IS CORRECT BUT THERE ARE SOME PRINTING MISTAKES IN TEXTBOOK\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "The volume % of CO is 4.19 % \n", + "\n", + "The air to fuel ratio is 13.92 kg air/ kg fuel \n" + ] + } + ], + "prompt_number": 4 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Ex9.3:PG-231" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "# initialization of variables\n", + "\n", + "# THE REACTION IS\n", + "# aC4H10 + b(O2+3.76N2)----> CO2 + 1CO + 3.5H20 + 84.6N2 + cH2O\n", + "# a, b and c are calculated by atomic balance\n", + "# on balancing the equations we get a=3 b=22.5 c=15\n", + "# Now equation becomes\n", + "#C4H10 + 7.5(O2+3.76N2)----> 3.67CO2 + 0.33CO + 1.17H20 + 28.17N2 + 5H2O\n", + "#MOLES OF AIR in this equation is 7.5 moles\n", + "mairactual=7.5 # in moles\n", + "#MOLES OF AIR in standard equation of Ex.9 is 6.5\n", + "mairtheoritical=6.5\n", + "Ptheoriticalair=100*(mairactual/mairtheoritical) \n", + "print \"The % theoritical air is\",round(Ptheoriticalair,1),\"% \"\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "The % theoritical air is 115.4 % \n" + ] + } + ], + "prompt_number": 8 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Ex9.4:PG-232" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "# initialization of variables\n", + "# The reaction equation is \n", + "#CaHb + c(O2+3.76N2)---> 10.4CO2 + 1.2CO + 2.8O2 + 85.6N2 + dH2O\n", + "\n", + "# using atomic balancing the equations become\n", + "\n", + "# C11.6H37.9 + 21.08(O2+3.76N2)---> 11.6CO2 + 18.95H2O + 79.26N2\n", + "Ptheoriticalair=22.8*100/21.08 # theoritical air\n", + "excessair=Ptheoriticalair-100\n", + "\n", + "print\"The excess air is\",round(excessair),\"%\"\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "The excess air is 8.0 %\n" + ] + } + ], + "prompt_number": 11 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Ex9.5:PG-235" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "# initialization of variables\n", + "# The reaction equation is \n", + "#C3H8 + 5(O2+3.76N2)---> 3CO2 + 18.8N2 + 4H2O\n", + "\n", + "# All the enthalpy of formation values are taken from Table B.5 with units in kJ/mol\n", + "hfCO2=-393520 # enthalpy associated with CO2\n", + "hfH2O=-285830 # enthalpy associated with H2O(l)\n", + "hfC3H8=-103850# ehthalpy associated with C3H8\n", + "\n", + "# by first law Q= Hproducts - Hreactants\n", + "\n", + "Qg=3*(hfCO2)+4*(hfH2O)-(hfC3H8) # enthalpy of combustion for gaseous propane\n", + "\n", + "print \" The enthalpy of combustion for gaseous propane is\",round(Qg),\"kJ\\n\"\n", + "\n", + "hv=15060 # enthalpy of vaporization for propane\n", + "\n", + "Ql=3*(hfCO2)+4*(hfH2O)-(hfC3H8-hv) # enthalpy of combustion for liquid propane\n", + "\n", + "print \" The enthalpy of combustion for liquid propane is\",round(Ql),\"kJ\\n\"\n", + "\n", + "#The answers are slightly different in textbook as they have approximated the result while in Python results are precise\n", + "\n", + "\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + " The enthalpy of combustion for gaseous propane is -2220030.0 kJ\n", + "\n", + " The enthalpy of combustion for liquid propane is -2204970.0 kJ\n", + "\n" + ] + } + ], + "prompt_number": 15 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Ex9.6:PG-235" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "# initialization of variables\n", + "# The reaction equation is \n", + "#C3H8 + 5(O2+3.76N2)---> 3CO2 + 18.8N2 + 4H2O\n", + "\n", + "# All the enthalpy of formation values are taken from Table B.5 with units in kJ/mol\n", + "hfCO2=-393520 # enthalpy of formation associated with CO2\n", + "hbarCO2=22280 #enthalpy associated with CO2 at 600K from table E.4\n", + "hdotbarCO2=9364#enthalpy associated with CO2 at 298K from table E.4\n", + "\n", + "hfH2O=-241820 # enthalpy of formation associated with gaseous H2O\n", + "hbarH2O=20402 #enthalpy associated with H20 at 600K from table E.6\n", + "hdotbarH2O=9904#enthalpy associated with H20 at 298K from table E.6\n", + "\n", + "hfC3H8=-103850# ehthalpy of formation associated with C3H8\n", + "\n", + "hbarN2=17563 #enthalpy associated with N2 at 600K from table E.2\n", + "hdotbarN2=8669#enthalpy associated with N2 at 298K from table E.2\n", + "# by first law Q= Hproducts - Hreactants\n", + "\n", + "Qg=3*(hfCO2+hbarCO2-hdotbarCO2)+4*(hfH2O+hbarH2O-hdotbarH2O)+18.8*(hbarN2-hdotbarN2)-(hfC3H8) # enthalpy of combustion\n", + "\n", + "print\"The heat transfer required is\",round(Qg),\"kJ\\n\"\n", + "\n", + "#The answer is WRONG textbook as they have made an error in calculating Qg \n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "The heat transfer required is -1796043.0 kJ\n", + "\n" + ] + } + ], + "prompt_number": 17 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Ex9.7:PG-236" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "import math\n", + "# initialization of variables\n", + "# The reaction equation is \n", + "\n", + "#C8H18 + 12.5(O2+3.76N2)---> 8CO2 + 47N2 + 9H2O\n", + "\n", + "# All the enthalpy of formation values are taken from Table B.5 with units in kJ/mol\n", + "hfCO2=-393520 # enthalpy of formation associated with CO2\n", + "hbarCO2=42769 #enthalpy associated with CO2 at 1000K from table E.4\n", + "hdotbarCO2=9364#enthalpy associated with CO2 at 298K from table E.4\n", + "\n", + "hfH2O=-241820 # enthalpy of formation associated with gaseous H2O\n", + "hbarH2O=35882 #enthalpy associated with H20 at 1000K from table E.6\n", + "hdotbarH2O=9904#enthalpy associated with H20 at 298K from table E.6\n", + "hfC3H8=-103850# ehthalpy of formation associated with C3H8\n", + "\n", + "hbarN2p=(30784+29476)/2 #enthalpy associated with N2 at 1000K from table E.2 by averaging enthalpy at 1020K and 980K for product\n", + "hbarN2r=17563 #enthalpy associated with N2 at 600K from table E.2 for reactant\n", + "hdotbarN2=8669#enthalpy associated with N2 at 298K from table E.2\n", + "\n", + "hfC8H18=-249910 # enthalpy of formation associated with octane taken from internet as not provided in textbook\n", + "\n", + "hbarO2=17929 # enthalpy associated with O2 at 600K table E.3\n", + "hdotbarO2=8682#enthalpy associated with O2 at 298K table E.3\n", + "\n", + "# using first law and including kinetic energy change\n", + "# 0=Hp-Hr+Mp*(V^2)/2\n", + "\n", + "Hp=8*(hfCO2+hbarCO2-hdotbarCO2)+9*(hfH2O+hbarH2O-hdotbarH2O)+47*(hbarN2p-hdotbarN2)\n", + "# enthalpy of products\n", + "\n", + "Hr=(hfC8H18)+12.5*(hbarO2-hdotbarO2)+47*(hbarN2r-hdotbarN2)\n", + "# enthalpy of reactants\n", + "\n", + "Mp=8*44+9*18+47*28 #(mass of products by multiplying molecular mass to number of moles)\n", + "\n", + "V=math.sqrt(2*1000*(Hr-Hp)/Mp)# exit velocity using energy balance\n", + "\n", + "print \"The exit velocity is\",round(V),\"m/s\"\n", + "\n", + "#The answers are slightly different in textbook as they have approximated the values while in Python results are precise\n", + "\n", + "\n", + "\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "The exit velocity is 2116.0 m/s\n" + ] + } + ], + "prompt_number": 20 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Ex9.8:PG-237" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "# initialization of variables\n", + "\n", + "# The reaction equation with theoritical air is \n", + "# C8H18 + 12.5(O2+3.76N2)---> 8CO2 + 47N2 + 9H2O\n", + "\n", + "# for 400% theoritical air reaction is\n", + "\n", + "# C8H18 + 50(O2+3.76N2)---> 8CO2 + 188N2 + 9H2O + 37.5O2\n", + "\n", + "# All the enthalpy of formation values are taken from Table B.5 with units in kJ/mol\n", + "hfCO2=-393520 # enthalpy of formation associated with CO2\n", + "hbarCO2=42769 #enthalpy associated with CO2 at 1000K from table E.4\n", + "hdotbarCO2=9364#enthalpy associated with CO2 at 298K from table E.4\n", + "hfH2O=-241820 # enthalpy of formation associated with gaseous H2O\n", + "hbarH2O=35882 #enthalpy associated with H20 at 1000K from table E.6\n", + "hdotbarH2O=9904#enthalpy associated with H20 at 298K from table E.6\n", + "hbarN2p=(30784+29476)/2 #enthalpy associated with N2 at 1000K from table E.2 by averaging enthalpy at 1020K and 980K \n", + "hdotbarN2=8669#enthalpy associated with N2 at 298K from table E.2\n", + "\n", + "hfC8H18=-249910 # enthalpy associated with octane taken from internet as not provided in textbook\n", + "hbarO2=31389 # enthalpy associated with O2 at 1000K table E.3\n", + "hdotbarO2=8682#enthalpy associated with O2 at 298K table E.3\n", + "\n", + "Hp=8*(hfCO2+hbarCO2-hdotbarCO2)+9*(hfH2O+hbarH2O-hdotbarH2O)+37.5*(hbarO2-hdotbarO2)+188*(hbarN2p-hdotbarN2)# enthalpy of products\n", + "\n", + "Hr=(hfC8H18)\n", + "# enthalpy of reactants\n", + "\n", + "Q=Hp-Hr # using first law2\n", + "\n", + "print \" The heat transfer is\",round(Q),\"kJ\"\n", + "\n", + "#The answers are slightly different in textbook as they have approximated the values while in Python results are precise\n", + "\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + " The heat transfer is 312593.0 kJ\n" + ] + } + ], + "prompt_number": 22 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Ex9.9:PG-237" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "# initialization of variables\n", + "\n", + "# The reaction equation is \n", + "#C3H8 + 5O2---> 8CO2 + 4H2O\n", + "\n", + "# All the enthalpy of formation values are taken from Table B.5 with units in kJ/mol\n", + "hfCO2=-393520 # enthalpy associated with CO2\n", + "hfH2O=-241820 # enthalpy associated with gaseous H2O\n", + "hfC3H8=103850# enthalpy of formation associated with C3H8\n", + "hfgC3H8=15060# enthalpy of vapourization associated with C3H8\n", + "T=20+273 # temperature in kelvin\n", + "Rbar=8.314 # universal gas constant\n", + "Nr=6 # number of moles of reactants\n", + "Np=7 # number of moles of products\n", + "Hp=3*(hfCO2)+4*(hfH2O) # enthalpy of products\n", + "\n", + "Hr=hfC3H8+hfgC3H8 # enthalpy of reactants\n", + "\n", + "Q=(Hp-Hr-(Nr-Np)*Rbar*T)*10**(-3) # heat transfer from first law\n", + "\n", + "print \" The heat transfer is\",round(Q),\"MJ\"\n", + "\n", + "#The answers are slightly different in textbook as they have approximated the values while in Python results are precise\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + " The heat transfer is -2264.0 MJ\n" + ] + } + ], + "prompt_number": 24 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Ex9.10:PG-239" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "# initialization of variables\n", + "\n", + "# The reaction equation for theoritical air is \n", + "#C3H8 + 5(O2 + 3.76N2) ---> 3CO2 + 4H2O + 18.8N2\n", + "\n", + "# for 250% theoritical air reaction becomes\n", + "#C3H8 + 12.5(O2 + 3.76N2) ---> 3CO2 + 4H2O + 47N2 + 7.5O2\n", + "\n", + "# All the enthalpy of formation values are taken from Table B.5 with units in kJ/mol\n", + "\n", + "Np=47+7.5+4+3 # number of moles of product\n", + "hfCO2=-393520 # enthalpy of formation associated with CO2\n", + "hbarCO2=(62963+65271)/2 #enthalpy associated with CO2 at 1380 K from table E.4\n", + "hbarCO2dash=(58381+60666)/2 #enthalpy associated with CO2 at 1300 K by average from table E.4\n", + "hdotbarCO2=9364#enthalpy associated with CO2 at 298K from table E.4\n", + "\n", + "hfC3H8=-103850# ehthalpy of formation associated with C3H8\n", + "\n", + "hfH2O=-241820 # enthalpy of formation associated with gaseous H2O\n", + "hbarH2O=(51521+53351)/2 #enthalpy associated with H20 at 1380 K by taking average from table E.6\n", + "hbarH2Odash=48807 #enthalpy associated with H20 at 1300 K from table E.6\n", + "hdotbarH2O=9904#enthalpy associated with H20 at 298K from table E.6\n", + "\n", + "hbarN2=42920 #enthalpy associated with N2 at 1380K from table E.2 by interpolating enthalpy between 1020K and 980K \n", + "hbarN2dash=40170 #enthalpy associated with N2 at 1300 K from table E.2 \n", + "hdotbarN2=8669#enthalpy associated with N2 at 298K from table E.2\n", + "\n", + "hfO2=(44198+45648)/2 # enthalpy associated with O2 at 1380 Kby taking average from table E.3\n", + "hfO2dash=48807 # enthalpy associated with O2 at 1380 Kby taking average from table E.3\n", + "hdotbarO2=8682#enthalpy associated with O2 at 298K table E.3\n", + "\n", + "# for adiabatic flame temperature first assume products composed only of nitrogen and Q=0 as adiabatic\n", + "hp=(hfC3H8-3*(hfCO2)-4*(hfH2O))/Np +hdotbarN2\n", + "# using hp we assume temp=1380 K\n", + "# then energy for 1380 k is\n", + "H1=3*(hfCO2+hbarCO2-hdotbarCO2)+4*(hfH2O+hbarH2O-hdotbarH2O)+7.5*(hfO2-hdotbarO2)+47*(hbarN2-hdotbarN2) # energy assuming temperature to be 1380 K\n", + "\n", + "#this is very large \n", + "\n", + "# now at 1300 K adiabatic temperature\n", + "H2=3*(hfCO2+hbarCO2dash-hdotbarCO2)+4*(hfH2O+hbarH2Odash-hdotbarH2O)+7.5*(hfO2dash-hdotbarO2)+47*(hbarN2dash-hdotbarN2) # energy assuming temperature to be 1300 K\n", + " \n", + " # now interpolation between these two temperatures\n", + "Tp=1300-((hp+H2)/(H1-H2))*(1380-1300) # adiabatic temperature by interpolation\n", + "print \"The adiabatic flame temperature is\",round(Tp),\"K\"\n", + "\n", + "#The answers is different in textbook as they have printed the value of hfCO2 with positive sign while calculating H2\n", + "\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "The adiabatic flame temperature is 1311.0 K\n" + ] + } + ], + "prompt_number": 26 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Ex9.11:PG-240" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "# initialization of variables\n", + "\n", + "# The reaction equation for theoritical air is \n", + "#C3H8 + 5(O2 + 3.76N2) ---> 3CO2 + 4H2O + 18.8N2\n", + "\n", + "# All the enthalpy of formation values are taken from Table B.5 with units in kJ/mol\n", + "\n", + "Np=18.8+4+3 # number of moles of product\n", + "hfCO2=-393520 # enthalpy associated with CO2\n", + "hbarCO2=137400 #enthalpy associated with CO2 at 2600 K from table E.4 by interpolation\n", + "hbarCO2dash=125152 #enthalpy associated with CO2 at 2400 K from table E.4\n", + "hdotbarCO2=9364#enthalpy associated with CO2 at 298K from table E.4\n", + "\n", + "hfC3H8=-103850# ehthalpy associated with C3H8\n", + "\n", + "hfH2O=-241820 # enthalpy associated with gaseous H2O\n", + "hbarH2O=114273 #enthalpy associated with H20 at 2600 K from table E.6\n", + "hbarH2Odash=103508 #enthalpy associated with H20 at 2400 K from table E.6\n", + "hdotbarH2O=9904#enthalpy associated with H20 at 298K from table E.6\n", + "\n", + "hbarN2=86600 #enthalpy associated with N2 at 2600 K from table E.2 by interpolation\n", + "hbarN2dash=79320 #enthalpy associated with N2 at 2400 K from table E.2 \n", + "hdotbarN2=8669#enthalpy associated with N2 at 298K from table E.2\n", + "\n", + "# for adiabatic flame temperature first assume products composed only of nitrogen and Q=0 as adiabatic\n", + "hp=(hfC3H8-3*(hfCO2)-4*(hfH2O))/Np +hdotbarN2 \n", + "\n", + "# using hp we assume temp=2600 K\n", + "# then energy for 2600 k is\n", + "H1=3*(hfCO2+hbarCO2-hdotbarCO2)+4*(hfH2O+hbarH2O-hdotbarH2O)+18.8*(hbarN2-hdotbarN2) # energy assuming temperature to be 2600 K\n", + "\n", + "# now at 2400 K adiabatic temperature\n", + "H2=3*(hfCO2+hbarCO2dash-hdotbarCO2)+4*(hfH2O+hbarH2Odash-hdotbarH2O)+18.8*(hbarN2dash-hdotbarN2) # energy assuming temperature to be 2400 K\n", + " \n", + " # now interpolation between these two temperatures\n", + "Tp=2400-((hp+H2)/(H1-H2))*(2600-2400) # adiabatic temperature by interpolation\n", + "print \"The adiabatic flame temperature is\",round(Tp),\"K\"\n", + "\n", + "#The answers are slightly different in textbook as they have approximated the values while in Python results are precise\n", + "\n", + "\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "The adiabatic flame temperature is 2409.0 K\n" + ] + } + ], + "prompt_number": 27 + } + ], + "metadata": {} + } + ] +} \ No newline at end of file -- cgit