{ "metadata": { "name": "Chapter 12" }, "nbformat": 2, "worksheets": [ { "cells": [ { "cell_type": "markdown", "source": [ "#Chapter 12 :- Ideal Gas Mixtures: General Considerations" ] }, { "cell_type": "markdown", "source": [ "##Example 12.1 Page no-560" ] }, { "cell_type": "code", "collapsed": false, "input": [ "", "# Given:-", "n1 = 0.08 # mole fraction of CO2", "n2 = 0.11 # mole fraction of H2O", "n3 = 0.07 # mole fraction of O2", "n4 = 0.74 # mole fraction of N2", "", "# Part(a)", "M1 = 44.0 # molar mass of CO2 in kg/kmol", "M2 = 18.0 # molar mass of H2O in kg/kmol", "M3 = 32.0 # molar mass of O2 in kg/kmol", "M4 = 28.0 # molar mass of N2 in kg/kmol", "", "# Calculations", "M = M1*n1 + M2*n2 + M3*n3 + M4*n4 # in kg/kmol", "# Result", "print 'The apparent molecular weight of the mixture in kg/kmol is: ',M", "", "# Part(b)", "mf1 = (M1*n1/M)*100.0 # mass fraction of CO2 in percentage ", "mf2 = (M2*n2/M)*100.0 # mass fraction of H2O in percentage", "mf3 = (M3*n3/M)*100.0 # mass fraction of O2 in percentage", "mf4 = (M4*n4/M)*100.0 # mass fraction of N2 in percentage", "", "# Results", "print 'The mass fraction of CO2 in percentage is: ',mf1", "print 'The mass fraction of H2O in percentage is: ',mf2", "print 'The mass fraction of O2 in percentage is: ',mf3", "print 'The mass fraction of N2 in percentage is: ',mf4" ], "language": "python", "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The apparent molecular weight of the mixture in kg/kmol is: 28.46", "The mass fraction of CO2 in percentage is: 12.3682361209", "The mass fraction of H2O in percentage is: 6.95713281799", "The mass fraction of O2 in percentage is: 7.87069571328", "The mass fraction of N2 in percentage is: 72.8039353479" ] } ], "prompt_number": 1 }, { "cell_type": "markdown", "source": [ "##Example 12.2 Page no-561" ] }, { "cell_type": "code", "collapsed": false, "input": [ "", "# Given:-", "mf1 = 0.1 # mass fractiion of H2", "mf2 = 0.6 # mass fraction of N2", "mf3 = 0.3 # mass fraction of CO2", "", "# Part(a)", "M1 = 2.0 # molar mass of H2 in kg/kmol", "M2 = 28.0 # molar mass of N2 in kg/kmol", "M3 = 44.0 # molar mass of CO2 in kg/kmol", "", "# Calculations", "n1 = (mf1/M1)/(mf1/M1 + mf2/M2 + mf3/M3) # mole fraction of H2 ", "n2 = (mf2/M2)/(mf1/M1 + mf2/M2 + mf3/M3) # mole fraction of N2", "n3 = (mf3/M3)/(mf1/M1 + mf2/M2 + mf3/M3) # mole fraction of CO2", "", "# Results", "print 'The mole fraction of H2 in percentage is: ',n1*100", "print 'The mole fraction of N2 in percentage is: ',n2*100", "print 'The mole fraction of CO2 in percentage is: ',n3*100", "", "# Part(b)", "# Calculation", "M = n1*M1 + n2*M2 + n3*M3 # in kg/kmol", "# Result", "print 'The apparent molecular weight of the mixture in kg/kmol is: ',M" ], "language": "python", "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The mole fraction of H2 in percentage is: 63.9004149378", "The mole fraction of N2 in percentage is: 27.3858921162", "The mole fraction of CO2 in percentage is: 8.71369294606", "The apparent molecular weight of the mixture in kg/kmol is: 12.7800829876" ] } ], "prompt_number": 2 }, { "cell_type": "markdown", "source": [ "##Example 12.3 Page no-569" ] }, { "cell_type": "code", "collapsed": false, "input": [ "", "# Given:-", "m1 = 0.3 # mass of CO2 in kg", "m2 = 0.2 # mass of N2 in kg", "p1 = 1.0 # in bar", "T1 = 300.0 # in kelvin", "p2 = 3.0 # in bar", "n = 1.25", "", "# Part(a)", "# Calculation", "T2 = T1*(p2/p1)**((n-1)/n) # in kelvin", "# Result", "print 'The final temperature in Kelvin is: ',T2", "", "# Part(b)", "Rbar = 8.314 # universal gas constant in SI units", "# Calculations", "M = (m1+m2)/(m1/44 + m2/28) # molar mass of mixture in kg/kmol", "W = ((m1+m2)*(Rbar/M)*(T2-T1))/(1-n) # in kj", "# Result", "print 'The work in kj is: ',W ", "", "# Part(c)", "# From table A-23", "uCO2T1 = 6939.0 # internal energy of CO2 on molar mass basis at temperature T1", "uCO2T2 = 9198.0 # internal energy of CO2 on molar mass basis at temperature T2", "uN2T1 = 6229.0 # internal energy of N2 on molar mass basis at temperature T1", "uN2T2 = 7770.0 # internal energy of N2 on molar mass basis at temperature T2", "deltaU = (m1/44)*(uCO2T2-uCO2T1) + (m2/28)*(uN2T2-uN2T1) # internal energy change of the mixture in KJ", "", "# With assumption, The changes in kinetic and potential energy between the initial and final states can be ignored", "Q = deltaU + W", "# Result", "print 'The heat transfer in kj is: ',Q", "", "# Part(d)", "# From table A-23", "sbarT2CO2 = 222.475", "sbarT1CO2 = 213.915 ", "sbarT2N2 = 198.105", "sbarT1N2 = 191.682", "Rbar = 8.314 # universal gas constant", "# Calculation", "import math", "deltaS = (m1/44)*(sbarT2CO2-sbarT1CO2-Rbar*math.log(p2/p1)) + (m2/28)*(sbarT2N2-sbarT1N2-Rbar*math.log(p2/p1))", "# Result", "print 'The change in entropy of the mixture in kj/k is: ',deltaS" ], "language": "python", "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The final temperature in Kelvin is: 373.719281885", "The work in kj is: -34.2270009251", "The heat transfer in kj is: -7.81758534069", "The change in entropy of the mixture in kj/k is: -0.0232760033842" ] } ], "prompt_number": 3 }, { "cell_type": "markdown", "source": [ "## Example 12.4 Page no-571" ] }, { "cell_type": "code", "collapsed": false, "input": [ "", "# Given:-", "y1 = 0.8 # mole fraction of CO2", "y2 = 0.2 # mole fraction of O2", "T1 = 700.0 # in kelvin", "p1 = 5.0 # in bars", "V1 = 3.0 # in m/s", "p2 = 1.0 # in bars", "", "", "# Part(a)", "# From table A-23", "sO2barT1 = 231.358", "sCO2barT1 = 250.663", "# Calculations", "import math", "RHS = y2*sO2barT1 + y1*sCO2barT1 + 8.314*math.log(p2/p1)", "# Using table A-23", "LHSat510K = y2*221.206 + y1*235.7", "LHSat520K = y2*221.812 + y1*236.575", "# Using linear interpolation,", "T2 = 510 +((520-510)/(LHSat520K-LHSat510K))*(RHS-LHSat510K)", "# Result ", "print 'The temperature at the nozzle exit in K is: ',T2", "", "# Part(b)", "# From table A-23", "sbarO2T2 = 221.667 # in kj/kmol.K", "sbarO2T1 = 231.358 # in kj/kmol.K", "sbarCO2T2 = 236.365 # in kj/kmol.K", "sbarCO2T1 = 250.663 # in kj/kmol.K", "# Calculations", "deltasbarO2 = sbarO2T2-sbarO2T1-8.314*math.log(p2/p1) # in kj/kmol.K", "deltasbarCO2 = sbarCO2T2-sbarCO2T1-8.314*math.log(p2/p1) # in kj/kmol.K", "# Results", "print 'The entropy changes of the CO2 from inlet to exit, in KJ/Kmol.K is: ',deltasbarCO2", "print 'The entropy change of the O2 from inlet to the exit in kj/kmol.k is: ',deltasbarO2", "", "# Part(c)", "# From table A-23, the molar specific enthalpies of O2 and CO2 are", "h1barO2 = 21184.0", "h2barO2 = 15320.0", "h1barCO2 = 27125.0", "h2barCO2 = 18468.0", "# Calculations", "M = y1*44.0 + y2*32.0 # apparent molecular weight of the mixture in kg/kmol", "deltah = (1.0/M)*(y2*(h1barO2-h2barO2) + y1*(h1barCO2-h2barCO2))", "V2 = math.sqrt(V1**2+ 2*deltah*10**3)", "# Result", "print 'The exit velocity in m/s is: ',V2" ], "language": "python", "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The temperature at the nozzle exit in K is: 517.549113444", "The entropy changes of the CO2 from inlet to exit, in KJ/Kmol.K is: -0.917133196023", "The entropy change of the O2 from inlet to the exit in kj/kmol.k is: 3.68986680398", "The exit velocity in m/s is: 623.983296128" ] } ], "prompt_number": 4 }, { "cell_type": "markdown", "source": [ "##Example 12.5 Page no-574" ] }, { "cell_type": "code", "collapsed": false, "input": [ "", "# Given:-", "nN2 = 0.79 # initial moles of nitrogen in kmol", "pN2 = 2.0 # initial pressure of nitrogen in bars", "TN2 = 250.0 # initial temperature of nitrogen in kelvin", "nO2 = 0.21 # initial moles of oxygen in kmol", "pO2 = 1.0 # initial pressure of oxygen in bars", "TO2 = 300.0 # initial temperature of oxygen in kelvin", "", "# Part(a)", "MN2 = 28.01 # molar mass of nitrogen in kg/kmol", "MO2 = 32.0 # molar mass of oxygen in kg/kmol", "# Calculations", "# With the help of table A-20", "cvbarN2 = MN2*0.743 # in kj/kmol.K", "cvbarO2 = MO2*0.656 # in kj/kmol.K", "T2 = (nN2*cvbarN2*TN2+nO2*cvbarO2*TO2)/(nN2*cvbarN2+nO2*cvbarO2)", "# Result", "print 'The final temperature of the mixture in kelvin is: ',T2", "", "# Part(b)", "# Calculation", "p2 = ((nN2+nO2)*T2)/(nN2*TN2/pN2 + nO2*TO2/pO2)", "# Result", "print 'The final pressure of the mixture in bar is: ',p2", "", "# Part(c)", "Rbar = 8.314 # universal gas constant", "# Calculations", "import math", "cpbarN2 = cvbarN2 + Rbar", "cpbarO2 = cvbarO2 + Rbar", "yN2 = nN2/(nN2+nO2) # mole fraction of N2", "yO2 = nO2/(nN2+nO2) # mole fraction of O2", "sigma = nN2*(cpbarN2*math.log(T2/TN2)-Rbar*math.log(yN2*p2/pN2)) + nO2*(cpbarO2*math.log(T2/TO2)-Rbar*math.log(yO2*p2/pO2))", "# Result", "print 'The amount of entropy produced in the mixing process, in kJ/K is: ',sigma" ], "language": "python", "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The final temperature of the mixture in kelvin is: 260.571840521", "The final pressure of the mixture in bar is: 1.61095419179", "The amount of entropy produced in the mixing process, in kJ/K is: 4.94715526048" ] } ], "prompt_number": 5 }, { "cell_type": "markdown", "source": [ "## Example 12.6 Page no-577" ] }, { "cell_type": "code", "collapsed": false, "input": [ "", "# Given:-", "T1 = 32.0 # temperature of dry air in degree celcius", "p1 = 1.0 # pressure of dry air in bar", "AV1 = 100.0 # volume rate of dry air in m^3/min", "T2 = 127.0 # temperature of oxygen stream in degree celcius", "p2 = 1.0 # pressure of oxygen stream in bar", "T3 = 47.0 # temperature of mixed stream in degree celcius", "p3 = 1.0 # pressure of mixed stream in bar", "", "# Part(a)", "Rbar = 8314.0 # universal gas constant", "Ma = 28.97 # molar mass of air", "Mo = 32.0 # molar mass of oxygen", "# From table A-22 and A-23", "haT3 = 320.29 # in kj/kg", "haT1 = 305.22 # in kj/kg", "hnotT2 = 11711.0 # in kj/kmol", "hnotT1 = 9325.0 # in kj/kmol", "", "# Calculations", "va1 = (Rbar/Ma)*(T1+273.0)/(p1*10**5) # specific volume of air in m^3/kg", "ma1dot = AV1/va1 # mass flow rate of dry air in kg/min", "modot = ma1dot*(haT3-haT1)/((1/Mo)*(hnotT2-hnotT1)) # in kg/min", "# Results", "print 'The mass flow rate of dry air in kg/min is: ',ma1dot", "print 'The mass flow rate of oxygen in kg/min is: ',modot", "", "# Part(b)", "nadot = ma1dot/Ma # molar flow rate of air in kmol/min", "nodot = modot/Mo # molar flow rate of oxygen in kmol/min", "ya = nadot/(nadot+nodot) # mole fraction of air", "yo = nodot/(nadot+nodot) # mole fraction of oxygen", "# Results", "print 'The mole fraction of dry air in the exiting mixture is: ',ya", "print 'The mole fraction of dry oxygen in the exiting mixture is: ',yo", "", "# Part(c)", "# With the help of tables A-22 and A-23", "sanotT3 = 1.7669 # in kj/kg.K", "sanotT1 = 1.71865 # in kj/kg.K", "sbarT3 = 207.112 # in kj/kmol.K", "sbarT2 = 213.765 # in kj/kmol.K", "# Calculations", "import math", "sigmadot = ma1dot*(sanotT3-sanotT1-(8.314/Ma)*math.log(ya))+ (modot/Mo)*(sbarT3-sbarT2-8.314*math.log(yo))", "# Result", "print 'The time rate of entropy production, in kJ/K . min is: ',sigmadot" ], "language": "python", "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The mass flow rate of dry air in kg/min is: 114.245377144", "The mass flow rate of oxygen in kg/min is: 23.0903984383", "The mole fraction of dry air in the exiting mixture is: 0.845326536426", "The mole fraction of dry oxygen in the exiting mixture is: 0.154673463574", "The time rate of entropy production, in kJ/K . min is: 17.4180498088" ] } ], "prompt_number": 6 }, { "cell_type": "markdown", "source": [ "## Example 12.7 Page no-584" ] }, { "cell_type": "code", "collapsed": false, "input": [ "", "# Given:-", "m =1.0 # mass of sample in kg", "T1 = 21.0 # initial temperature in degree celcius", "psi1 = 0.7 # initial relative humidity", "T2 = 5.0 # final temperature in degree celcius", "", "# Part(a)", "# From table A-2", "pg = 0.02487 # in bar", "# Calculations ", "pv1 = psi1*pg # partial pressure of water vapor in bar", "omega1 = 0.622*(0.2542)/(14.7-0.2542)", "# Result ", "print 'the initial humidity ratio is: ',omega1", "", "# Part(b)", "# The dew point temperature is the saturation temperature corresponding to the partial pressure, pv1. Interpolation in Table A-2 gives", "T = 15.3 # the dew point temperature in degree celcius", "# Result", "print 'The dew point temperature in degree celcius is: ',T", "", "# Part(c)", "# The partial pressure of the water vapor remaining in the system at the final state is the saturation pressure corresponding to 5\u0004C:", "# Calculations", "mv1 = 1/((1/omega1)+1) # initial amount of water vapor in the sample in kg", "ma = m-mv1 # mass of dry air present in kg", "pg = 0.00872 # in bar", "omega2 = 0.622*(pg)/(1.01325-pg) # humidity ratio after cooling", "mv2 = omega2*ma # The mass of the water vapor present at the final state", "mw = mv1-mv2", "", "# Result", "print 'The amount of water vapor that condenses, in kg. is: ',mw" ], "language": "python", "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "the initial humidity ratio is: 0.0109452159105", "The dew point temperature in degree celcius is: 15.3", "The amount of water vapor that condenses, in kg. is: 0.00548579192846" ] } ], "prompt_number": 7 }, { "cell_type": "markdown", "source": [ "## Example 12.8 Page no-586" ] }, { "cell_type": "code", "collapsed": false, "input": [ "", "# Given:-", "V = 35.0 # volume of the vessel in m^3", "p1 = 1.5 # in bar", "T1 = 120.0 # in degree celcius", "psi1 = 0.1 ", "T2 = 22.0 # in degree celcius", "", "# Part(a)", "# The dew point temperature at the initial state is the saturation temperature corresponding to the partial pressure pv1. With the given relative humidity and the saturation pressure at 120\u0004C from Table A-2", "pg1 = 1.985", "# Interpolating in Table A-2 gives the dew point temperature as", "T = 60.0 # in degree celcius", "# Calculation", "pv1 = psi1*pg1 # partial pressure in bar", "# Result", "print 'The dew point temperature corresponding to the initial state, in degee celcius is: ',T", "", "# Part(b)", "Rbar = 8314.0 # universal gas constant", "Mv = 18.0 # molar mass of vapor in kj/kmol", "# Interpolation in Table A-2", "Tdash = 56.0 # in degrees", "vv1 =((Rbar/Mv)*(T1+273))/(pv1*10**5) # the specific volume of the vapor at state 1 in m^3/kg", "# Result", "print 'The temperature at which condensation actually begins in degree celcius is: ',Tdash", "", "# Part(c)", "# From table ", "vf2 = 1.0022e-3", "vg2 = 51.447", "vv2 = vv1 # specific volume at final state", "# Calculations", "mv1 = V/vv1 # initial amount of water vapor present in kg", "x2 = (vv2-vf2)/(vg2-vf2) # quality", "mv2 = x2*mv1 # the mass of the water vapor contained in the system at the final state", "mw2 = mv1-mv2", "# Result", "print 'The amount of water condense in kg is: ',mw2" ], "language": "python", "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The dew point temperature corresponding to the initial state, in degee celcius is: 60.0", "The temperature at which condensation actually begins in degree celcius is: 56.0", "The amount of water condense in kg is: 3.14710226995" ] } ], "prompt_number": 8 }, { "cell_type": "markdown", "source": [ "##Example 12.9 Page no-587" ] }, { "cell_type": "code", "collapsed": false, "input": [ "", "# Given:-", "V = 35.0 # volume of vessel in m^3", "p1 = 1.5 # initial pressure in bar", "T1 = 120.0 # initial temperature in degree celcius", "psi = 0.1", "T2 = 22.0 # in degree celcius", "Rbar = 8314.0 # universal gas constant", "Ma = 28.97 # molar mass of air", "pv1 = 0.1985 # in bar, from example 12.8", "mv2 = 0.681 # in kg, from examples 12.8", "mv1 = 3.827 # in kg, from example 12.8", "mw2 = 3.146 # in kg, from example 12.8", "# evaluating internal energies of dry air and water from Tables A-22 and A-2, respectively", "ua2 = 210.49 # in kj/kg", "ua1 = 281.1 # in kj/kg", "ug2 = 2405.7 # in kj/kg", "uf2 = 92.32 # in kj/kg", "ug1 = 2529.3 # in kj/kg", "", "# Calculations", "ma =( ((p1-pv1)*10**5)*V)/((Rbar/Ma)*(T1+273)) # mass of dry air in kg", "Q = ma*(ua2-ua1) + mv2*ug2 + mw2*uf2 - mv1*ug1", "", "# Result", "print 'The heat transfer during the process, in kJ is: ',Q" ], "language": "python", "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The heat transfer during the process, in kJ is: -10602.7454057" ] } ], "prompt_number": 9 }, { "cell_type": "markdown", "source": [ "##Example 12.10 Page no-595" ] }, { "cell_type": "code", "collapsed": false, "input": [ "", "# Given :-", "AV1 = 150.0 # entry volumetric flow rate in m^3/min", "T1 = 10.0 # entry temperature in degree celcius", "psi1 = 0.8 ", "T2 = 30.0 # exit temperature in degree celcius", "p = 1.0 # in bar", "", "# Part(a)", "Rbar = 8314.0 # universal gas constant", "Ma = 28.97 # molar mass of air", "# The specific enthalpies of the dry air are obtained from Table A-22 at the inlet and exit temperatures T1 and T2, respectively:", "ha1 = 283.1 # in kj/kg", "ha2 = 303.2 # in kj/kg", "# The specific enthalpies of the water vapor are found using hv \u0004 hg and data from Table A-2 at T1 and T2, respectively:", "hv1 = 2519.8 # in kj/kg", "hv2 = 2556.3 # in kj/kg", "# From table A-2", "pg1 = 0.01228 # in bar", "# Calculations", "pv1 = psi1*pg1 # the partial pressure of the water vapor in bar", "pa1 = p-pv1", "va1 = (Rbar/Ma)*(T1+273)/(pa1*10**5) # specific volume of the dry air in m^3/kg", "madot = AV1/va1 # mass flow rate of the dry air in kg/min", "omega = 0.622*(pv1/(p-pv1)) # humidity ratio", "Qcvdot = madot*((ha2-ha1)+omega*(hv2-hv1)) # in kj/min", "# Result", "print 'Rate of heat transfer, in kJ/min is: ',Qcvdot", "", "# Part(b)", "# From Table A-2 at 30\u0004C", "pg2 = 0.04246 # in bar", "# Calculations", "pv2 = pv1", "psi2 = pv2/pg2 # relative humidity at the exit", "# Result", "print 'The relative humidity at the exit is: ',psi2" ], "language": "python", "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "Rate of heat transfer, in kJ/min is: 3716.99116097", "The relative humidity at the exit is: 0.231370701837" ] } ], "prompt_number": 10 }, { "cell_type": "markdown", "source": [ "## Example 12.11 Page no-600" ] }, { "cell_type": "code", "collapsed": false, "input": [ "", "# Given:-", "T1 = 30.0 # in degree celcius", "AV1 = 280.0 # in m^3/min", "psi1 = 0.5 # relative humidity at the inlet", "T2 = 10.0 # in degree celcius", "p = 1.013 # pressure in bar", "", "# Part(a)", "# From table A-2", "pg1 = 0.04246 # in bar", "Rbar = 8314 # universal gas constant", "Ma = 28.97 # molar mass of air", "# Calculations", "pv1 = psi1*pg1 # in bar", "pa1 = p-pv1 # partial pressure of the dry air in bar", "madot = AV1/((Rbar/Ma)*((T1+273)/(pa1*10**5))) # common mass flow rate of the dry air in kg/min", "# Result", "print 'The mass flow rate of the dry air in kg/min is: ',madot", "", "# Part(b)", "# From table A-2", "pv2 = 0.01228 # in bar", "# Calculations", "omega1 = 0.622*(pv1/(p-pv1))", "omega2 = 0.622*(pv2/(p-pv2))", "mwdotbymadot = omega1-omega2 ", "# Result", "print 'The rate at which water is condensed, in kg per kg of dry air flowing through the control volume is: ',mwdotbymadot", "", "# Part(c)", "# From table A-2 and A-22", "ha2 = 283.1 # in kg/kj", "ha1 = 303.2 # in kg/kj", "hg1 = 2556.3 # in kg/kj", "hg2 = 2519.8 # in kg/kj", "hf2 = 42.01 # in kg/kj", "# Calculations", "Qcvdot = madot*((ha2-ha1)-omega1*hg1+omega2*hg2+(omega1-omega2)*hf2) # in kj/min", "# Result", "print 'The required refrigerating capacity, in tons is: ',Qcvdot/211" ], "language": "python", "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The mass flow rate of the dry air in kg/min is: 319.348473885", "The rate at which water is condensed, in kg per kg of dry air flowing through the control volume is: 0.00568197500137", "The required refrigerating capacity, in tons is: -52.4650572692" ] } ], "prompt_number": 11 }, { "cell_type": "markdown", "source": [ "## Example 12.12 Page no-602" ] }, { "cell_type": "code", "collapsed": false, "input": [ "", "# Given:-", "T1 = 22.0 # entry temperature of moist air in degree celcius", "Twb = 9.0 # wet-bulb temperature of entering moist air in degree celcius", "madot = 90.0 # mass flow rate of dry air in kg/min", "Tst = 110.0 # temperature of injected saturated water vapor in degree celcius", "mstdot = 52.0 # mass flow rate of injected saturated water vapor in kg/h", "p = 1.0 # pressure in bar", "", "# Part(a)", "# By inspection of the psychrometric chart", "omega1 = 0.002", "# Calculation", "omega2 = omega1 + mstdot/(madot*60)", "# Result", "print 'The humidity ratio at the exit is: ',omega2", "", "# Part(b)", "# The steady-state form of the energy rate balance can be rearranged as", "# (ha + omega*hg)2 = (ha + omega*hg)1 + (omega2-omega1)*hg3", "# On putting values in the above equation from tables and figures, temperature at the exit can then be read directly from the chart", "T2 = 23.5 # in degree celcius", "# Result", "print 'The temperature at the exit in degree celcius is: ',T2" ], "language": "python", "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The humidity ratio at the exit is: 0.0116296296296", "The temperature at the exit in degree celcius is: 23.5" ] } ], "prompt_number": 12 }, { "cell_type": "markdown", "source": [ "##Example 12.13 Page no-604" ] }, { "cell_type": "code", "collapsed": false, "input": [ "", "# Given:-", "T1 = 38.0 # temperature of entering air in degree celcius", "psi1 = 0.1 # relative humidity of entering air ", "AV1 = 140.0 # volumetric flow rate of entering air in m^3/min", "Tw = 21.0 # temperature of added water in degree celcius", "T2 = 21.0 # temperature of exiting moist air in degree celcius", "p = 1.0 # pressure in atm", "", "# Part(a)", "# From table A-2", "pg1 = 0.066 # in bar", "# The specific volume of the dry air can be evaluated from the ideal gas equation of state. The result is", "va1 = .887 # in m^3/kg", "cpa = 1.005", "# From table A-2", "hf = 88.14", "hg1 = 2570.7", "hg2 = 2539.94", "# Calculations", "pv1 = psi1*pg1 # the partial pressure of the moist air entering the control volume in bar", "omega1 = 0.622*(pv1/(p*1.01325-pv1))", "omega2 = (cpa*(T1-T2)+omega1*(hg1-hf))/(hg2-hf)", "madot = AV1/va1 # mass flow rate of the dry air in kg/min", "mwdot = madot*60*(omega2-omega1) # in kg/h", "# Result", "print 'The mass flow rate of the water to the soaked pad in kj/h is: ',mwdot", "", "# Part(b)", "pv2 = (omega2*p*1.01325)/(omega2+0.622) # in bars", "# At 21\u0004C, the saturation pressure is", "pg2 = 0.02487", "psi2 = pv2/pg2", "# Result", "print 'The relative humidity of the moist air at the exit to the evaporative cooler is: ',psi2" ], "language": "python", "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The mass flow rate of the water to the soaked pad in kj/h is: 66.4756578168", "The relative humidity of the moist air at the exit to the evaporative cooler is: 0.714165693403" ] } ], "prompt_number": 13 }, { "cell_type": "markdown", "source": [ "##Example 12.14 Page no-607" ] }, { "cell_type": "code", "collapsed": false, "input": [ "", "# Given:-", "AV1 = 142.0 # in m^3/min", "T1 = 5.0 # in degree celcius", "omega1 = 0.002", "AV2 = 425.0 # in m^3/min", "T2 = 24.0 # in degree celcius", "psi2 = 0.5", "p = 1.0 # in bar", "", "", "# Part(a)", "# From the psychrometric chart, Fig. A-9.", "va1 = 0.79 # in m^3/kg", "va2 = 0.855 # in m^3/kg", "omega2 = 0.0094", "# Calculations", "ma1dot = AV1/va1 # in kg/min", "ma2dot = AV2 /va2 # in kg/min", "omega3 = (omega1*ma1dot+omega2*ma2dot)/(ma1dot + ma2dot) ", "# Result", "print 'The humidity ratio is: ',omega3", "", "# Part(b)", "# Reduction of the energy rate balance gives", "# (ha + omega*hv)3 = [ma1dot*(ha + omega*hv)1 + ma2dot*(ha + omega*hv)2]/(ma1dot+ma2dot)", "# With (ha + omega*hv)1 = 10kj/kg and (ha + omega*hv)2 = 47.8kj/kg from figure A-9", "LHS = (ma1dot*10+ma2dot*47.8)/(ma1dot + ma2dot)", "", "# This value for the enthalpy of the moist air at the exit, together with the previously determined value for omega3, fixes the state of the exiting moist air. From inspection of Fig. A-9,", "T3 = 19.0 # in degree celcius", "# Result", "print 'The temperature of the exiting mixed stream in degree celcius is: ',T3" ], "language": "python", "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The humidity ratio is: 0.0074347493219", "The temperature of the exiting mixed stream in degree celcius is: 19.0" ] } ], "prompt_number": 14 }, { "cell_type": "markdown", "source": [ "## Example 12.15 Page no-610" ] }, { "cell_type": "code", "collapsed": false, "input": [ "", "# Given:-", "T1 = 38.0 # in degree celcius", "m1dot = 4.5e7 # in kg/h", "T2 = 30.0 # in degree celcius", "m2dot = 4.5e7 # in kg/h", "T3 = 25.0 # in degree celcius", "psi3 = 0.35", "T4 = 35.0 # in degree celcius", "psi4 = 0.9", "T5 = 20.0 # in degree celcius", "", "# Analysis", "# The humidity ratios omega3 and omega4 can be determined using the partial pressure of the water vapor obtained with the respective relative humidity", "omega3 =0.00688", "omega4 = 0.0327", "# From tables A-2 and A-22", "hf1 = 159.21", "hf2 = 125.79", "ha4 = 308.2", "ha3 = 298.2", "hg4 = 2565.3", "hg3 = 2547.2", "hf5 = 83.96", "# Calculations", "madot = (m1dot*(hf1-hf2))/(ha4-ha3+omega4*hg4-omega3*hg3-(omega4-omega3)*hf5) # in kg/h", "m5dot = madot*(omega4-omega3) # in kg/h", "# Results", "print 'The mass flow rate of dry air in kg/h is: ',madot", "print 'The mass flow rate of makeup water in kg/h is: ',m5dot" ], "language": "python", "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The mass flow rate of dry air in kg/h is: 20270180.9849", "The mass flow rate of makeup water in kg/h is: 523376.07303" ] } ], "prompt_number": 15 } ] } ] }