{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# Chapter 11: Hypersonic vehicles"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Example 11.1"
]
},
{
"cell_type": "code",
"execution_count": 1,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Percentage efficiency: 30.3 %\n"
]
}
],
"source": [
"# -*- coding: utf8 -*-\n",
"from __future__ import division\n",
"#Example: 11.1\n",
"'''Determine the efﬁciency of a Rankine cycle using steam as the working ﬂuid in which the\n",
"condenser pressure is 10 kPa. The boiler pressure is 2 MPa. The steam leaves the boiler\n",
"as saturated vapor.\n",
"In solving Rankine-cycle problems, we let w p denote the work into the pump per\n",
"kilogram of ﬂuid ﬂowing and q L denote the heat rejected from the working ﬂuid per\n",
"kilogram of ﬂuid ﬂowing.\n",
"To solve this problem we consider, in succession, a control surface around the pump,\n",
"the boiler, the turbine, and the condenser. For each, the thermodynamic model is the steam\n",
"tables, and the process is steady state with negligible changes in kinetic and potential\n",
"energies. First, consider the pump:\n",
"Control volume:\n",
"Inlet state:\n",
"Exit state:\n",
"Pump.\n",
"P 1 known, saturated liquid; state ﬁxed.\n",
"P 2 known.'''\n",
"\n",
"#Variable Declaration: \n",
"P2 = 2000\t\t\t#Exit pressure in kPa\n",
"P1 = 10\t\t\t\t#Inlet pressure in kPa\n",
"v = 0.00101\t\t\t#specific weight of water in m**3/kg\n",
"h1 = 191.8\t\t\t#Enthalpy in kJ/kg from table\n",
"h3 = 2799.5\t\t\t#Enthalpy in kJ/kg\n",
"s4 = 6.3409\t\t\t#kJ/kg\n",
"sf = 0.6493\t\t\t#Entropy at liquid state in kJ/kg\n",
"sfg = 7.5009\t\t#Entropy difference for vapor and liquid state in kJ/kg\n",
"hfg = 2392.8\t\t#Enthalpy difference in kJ/kg for turbine\n",
"\n",
"#Calculations:\n",
"wp = v*(P2-P1)\t\t#work done in pipe in kJ/kg\n",
"h2 = h1+wp\t\t\t#enthalpy in kJ/kg\n",
"x4 = (s4-sf)/sfg\t#x-factor\n",
"h4 = h1+x4*hfg\t\t#Enthalpy in kJ/kg\n",
"nth = ((h3-h2)-(h4-h1))/(h3-h2)\n",
"\n",
"#Results:\n",
"print 'Percentage efficiency: ',round(nth*100,1),\"%\""
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Example 11.2"
]
},
{
"cell_type": "code",
"execution_count": 8,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Percentage efficiency: 35.3 %\n"
]
}
],
"source": [
"# -*- coding: utf8 -*-\n",
"from __future__ import division\n",
"#Example: 11.2\n",
"''' In a Rankine cycle, steam leaves the boiler and enters the turbine at 4 MPa and 400\n",
"◦\n",
"C.\n",
"The condenser pressure is 10 kPa. Determine the cycle efﬁciency.\n",
"To determine the cycle efﬁciency, we must calculate the turbine work, the pump\n",
"work, and the heat transfer to the steam in the boiler. We do this by considering a control\n",
"surface around each of these components in turn. In each case the thermodynamic model\n",
"is the steam tables, and the process is steady state with negligible changes in kinetic and\n",
"potential energies.\n",
"Control volume:\n",
"Inlet state:\n",
"Exit state:\n",
"Pump.\n",
"P 1 known, saturated liquid; state ﬁxed.\n",
"P 2 known.'''\n",
"\n",
"#Variable Declaration: \n",
"P2 = 4000\t\t\t#Exit pressure in kPa\n",
"P1 = 10\t\t\t\t#Inlet pressure in kPa\n",
"v = 0.00101\t\t\t#specific weight of water in m**3/kg\n",
"h1 = 191.8\t\t\t#Enthalpy in kJ/kg from table\n",
"h3 = 3213.6\t\t\t#Enthalpy in kJ/kg from table\n",
"s4 = 6.7690\t\t\t#Entropy in kJ/kg from table\n",
"sf = 0.6493\t\t\t#Entropy at liquid state in kJ/kg from table\n",
"sfg = 7.5009\t\t#Entropy difference for vapor and liquid state in kJ/kg from table\n",
"hfg = 2392.8\t\t#Enthalpy difference in kJ/kg for turbine\n",
"\n",
"#Calculations:\n",
"wp = v*(P2-P1)\t\t#work done in pipe in kJ/kg\n",
"h2 = h1+wp\t\t\t#Enthalpy in kJ/kg\n",
"x4 = (s4-sf)/sfg\t#x-factor\n",
"h4 = h1+x4*hfg\t\t#Enthalpy in kJ/kg\n",
"nth = ((h3-h2)-(h4-h1))/(h3-h2)\n",
"\n",
"#Results:\n",
"print 'Percentage efficiency: ',round(nth*100,1),'%'"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Example 11.3"
]
},
{
"cell_type": "code",
"execution_count": 3,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Percentage efficiency: 35.9 %\n"
]
}
],
"source": [
"# -*- coding: utf8 -*-\n",
"from __future__ import division\n",
"#Example: 11.3\n",
"''' Consider a reheat cycle utilizing steam. Steam leaves the boiler and enters the turbine at\n",
"4 MPa, 400\n",
"◦\n",
"C. After expansion in the turbine to 400 kPa, the steam is reheated to 400\n",
"◦\n",
"C\n",
"and then expanded in the low-pressure turbine to 10 kPa. Determine the cycle efﬁciency.\n",
"For each control volume analyzed, the thermodynamic model is the steam tables,\n",
"the process is steady state, and changes in kinetic and potential energies are negligible.\n",
"For the high-pressure turbine,\n",
"Control volume:\n",
"Inlet state:\n",
"Exit state:\n",
"High-pressure turbine.\n",
"P 3 , T 3 known; state ﬁxed.\n",
"P 4 known.'''\n",
"\n",
"#Variable Declaration: \n",
"P2 = 4000\t\t\t#Exit pressure in kPa\n",
"P1 = 10\t\t\t\t#Inlet pressure in kPa\n",
"v = 0.00101\t\t\t#specific weight of water in m**3/kg\n",
"h1 = 191.8\t\t\t#Enthalpy in kJ/kg from table\n",
"h3 = 3213.6\t\t\t#Enthalpy in kJ/kg from table\n",
"s4 = 6.7690\t\t\t#Entropy in kJ/kg from table\n",
"sf1 = 1.7766\t\t#Entropy at liquid state in kJ/kg from table\n",
"sfg1 = 5.1193\t\t#Entropy difference for vapor and liquid state in kJ/kg from table\n",
"hf = 604.7\t\t\t#Enthalpy of liquid state in kJ/kg\n",
"hfg1 = 2133.8\t\t#Enthalpy difference in kJ/kg for turbine\n",
"sf = 0.6493\t\t\t#Entropy in liquid state in kJ/kg for turbine\n",
"h5 = 3273.4\t\t\t#Enthalpy in kJ/kg \n",
"s5 = 7.8985\t\t\t#Entropy in kJ/kg\n",
"sfg = 7.5009\t\t#Entropy diff in kJ/kg \n",
"hfg = 2392.8\t\t#Enthalpy difference for low pressure turbine in kj/kg\n",
"\n",
"#Calculations:\n",
"wp = round(v*(P2-P1))#Work done in pipe in kJ/kg\n",
"h2 = h1+wp\t\t\t#Enthalpy in kJ/kg\n",
"x4 = (s4-sf1)/sfg1\t#x-factor\n",
"h4 = hf+x4*hfg1\t\t#Enthalpy in kJ/kg\n",
"x6 = (s5-sf)/sfg\t#x-factor\n",
"h6 = h1+x6*hfg\t\t#Entropy in kg/kg\n",
"wt = (h3-h4)+(h5-h6)#Work output in kJ/kg\n",
"qh = (h3-h2)+(h5-h4)\n",
"nth = (wt-wp)/qh\n",
"\n",
"#Results:\n",
"print 'Percentage efficiency: ',round(nth*100,1),'%'"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Example 11.4"
]
},
{
"cell_type": "code",
"execution_count": 4,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Refrigerator Efficiency: 37.5 %\n"
]
}
],
"source": [
"# -*- coding: utf8 -*-\n",
"from __future__ import division\n",
"#Example: 11.4\n",
"''' Consider a regenerative cycle using steam as the working ﬂuid. Steam leaves the boiler\n",
"and enters the turbine at 4 MPa, 400\n",
"◦\n",
"C. After expansion to 400 kPa, some of the steam is\n",
"extracted from the turbine to heat the feedwater in an open feedwater heater. The pressure\n",
"in the feedwater heater is 400 kPa, and the water leaving it is saturated liquid at 400 kPa.\n",
"The steam not extracted expands to 10 kPa. Determine the cycle efﬁciency.\n",
"The line diagram and T–s diagram for this cycle are shown in Fig. 11.12.\n",
"As in previous examples, the model for each control volume is the steam tables, the\n",
"process is steady state, and kinetic and potential energy changes are negligible.\n",
"From Examples 11.2 and 11.3 we have the following properties:\n",
"h 5 = 3213.6 h 6 = 2685.6\n",
"h 7 = 2144.1 h 1 = 191.8\n",
"For the low-pressure pump,\n",
"Control volume:\n",
"Inlet state:\n",
"Exit state:\n",
"Low-pressure pump.\n",
"P 1 known, saturated liquid; state ﬁxed.\n",
"P 2 known.'''\n",
"\n",
"#Variable Declaration: \n",
"h1 = 191.8\t\t\t#kJ/kg\n",
"h5 = 3213.6\t\t\t#kg/kg\n",
"h6 = 2685.7\t\t\t#kJ/kg\n",
"h7 = 2144.1\t\t\t#kJ/kg\n",
"h3 = 604.7\t\t\t#kJ/kg\n",
"P2 = 400\t\t\t#Exit pressure in kPa\n",
"P1 = 10 \t\t\t#Inlet pressure in kPa\n",
"v = 0.00101\t\t\t#Specific weight of water in m**3/kg\n",
"h1 = 191.8\t\t\t#Enthalpy in kJ/kg from table\n",
"P3 = 400\t\t\t#KPa\n",
"P4 = 4000\t\t\t#KPa\n",
"v = 0.001084\t\t#Specific heat for 3-4 process in m**3/kg\n",
"\n",
"#Calculations:\n",
"wp1 = v*(P2-P1)\t\t#work done for low pressure pump in kJ/kg\n",
"h2 = h1+wp1\t\t\t#Enthalpy in kJ/kg\n",
"y = (h3-h2)/(h6-h2)\t#Extraction fraction\n",
"wt = (h5-h6)+(1-y)*(h6-h7)#Turbine work in kJ/kg\n",
"wp2 = v*(P4-P3)\t\t#Work done for high pressure pump\n",
"h4 = h3+wp2\t\t\t#Enthalpy in kJ/kg\n",
"wnet = wt-(1-y)*wp1-wp2\n",
"qh = h5-h4\t\t\t#Heat output in kJ/kg\n",
"nth = wnet/qh\n",
"\n",
"#Results:\n",
"print 'Refrigerator Efficiency: ',round(nth*100,1),'%'\n"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Example 11.5"
]
},
{
"cell_type": "code",
"execution_count": 5,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Cycle Efficiency: 29.2 %\n"
]
}
],
"source": [
"# -*- coding: utf8 -*-\n",
"from __future__ import division\n",
"#Example: 11.5\n",
"''' A steam power plant operates on a cycle with pressures and temperatures as designated in\n",
"Fig. 11.17. The efﬁciency of the turbine is 86%, and the efﬁciency of the pump is 80%.\n",
"Determine the thermal efﬁciency of this cycle.'''\n",
"\n",
"#Variable Declaration: \n",
"h5 = 3169.1\t\t\t\t#kJ/kg\n",
"s5 = 6.7235\t\t\t\t#kJ/kg\n",
"sf = 0.6493\t\t\t\t#Entropy for liquid state in kJ/kg\n",
"sfg = 7.5009\t\t\t#Entropy difference in kJ/kg\n",
"hf = 191.8\t\t\t\t#kJ/kg\n",
"hfg = 2392.8\t\t\t#Enthalpy difference in kJ/kg\n",
"nt = 0.86\t\t\t\t#turbine efficiency given\n",
"np = 0.80\t\t\t\t#pump efficiency given\n",
"v = 0.001009\t\t\t#specific heat in m**3/kg\n",
"P2 = 5000\t\t\t\t#kPa\n",
"P1 = 10\t\t\t\t\t#kPa\n",
"h3 = 171.8\t\t#in kJ/kg from table\n",
"h4 = 3213.6\t\t#kJ/kg from table\n",
"\n",
"#Calculations:\n",
"s6s = s5\n",
"x6s = (s6s-sf)/sfg\t\t#x-factor\n",
"h6s = hf+x6s*hfg\t\t#kJ/Kg at state 6s\n",
"wt = nt*(h5-h6s)\n",
"wp = v*(P2-P1)/np\t\t#Work done in pump in kJ/kg\n",
"wnet = wt-wp\t\t\t#net work in kJ/kg\n",
"qh = h4-h3\n",
"nth = wnet/qh\n",
"\n",
"#Results:\n",
"print 'Cycle Efficiency: ',round(nth*100,1),'%'"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Example 11.6"
]
},
{
"cell_type": "code",
"execution_count": 6,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Refrigeration Capacity: 3.89 KW\n"
]
}
],
"source": [
"# -*- coding: utf8 -*-\n",
"from __future__ import division\n",
"#Example: 11.6\n",
"''' Consider an ideal refrigeration cycle that uses R-134a as the working ﬂuid. The temperature\n",
"of the refrigerant in the evaporator is −20\n",
"◦\n",
"C, and in the condenser it is 40\n",
"◦\n",
"C. The refrigerant\n",
"is circulated at the rate of 0.03 kg/s. Determine the COP and the capacity of the plant in\n",
"rate of refrigeration.\n",
"The diagram for this example is shown in Fig. 11.21. For each control volume\n",
"analyzed, the thermodynamic model is as exhibited in the R-134a tables. Each process is\n",
"steady state, with no changes in kinetic or potential energy.\n",
"Control volume:\n",
"Inlet state:\n",
"Exit state:\n",
"Compressor.\n",
"T 1 known, saturated vapor; state ﬁxed.\n",
"P 2 known (saturation pressure at T 3 ). \n",
"'''\n",
"\n",
"#Variable Declaration: \n",
"P2 = 1017\t\t\t#KJ/Kg\n",
"h1 = 386.1 \t\t\t#KJ/Kg\n",
"s1 = 1.7395 \t\t#KJ/Kg\n",
"T2 = 47.7 \t\t\t#°C\n",
"h2 = 428.4 \t\t\t#KJ/Kg\n",
"h3 = 256.5 \t\t\t#KJ/Kg\t\n",
"\n",
"#Calculations:\n",
"s2 = s1\n",
"wc = h2-h1\t\t\t\t#Work done by compressor in KJ/Kg\n",
"h4 = h3\n",
"qL = h1-h4 \t\t\t\t#From Energy equation in KJ/Kg\n",
"B = round(qL/wc)\n",
"RC = qL*B/100\t\t\t#Refrigeration capacity in KW\n",
"\n",
"#Results:\n",
"print 'Refrigeration Capacity: ', round(RC,2), 'KW'"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Example 11.7"
]
},
{
"cell_type": "code",
"execution_count": 7,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"COP of refrigerator : 1.45\n"
]
}
],
"source": [
"# -*- coding: utf8 -*-\n",
"from __future__ import division\n",
"#Example: 11.7\n",
"'''A refrigeration cycle utilizes R-134a as the working ﬂuid. The following are the properties\n",
"\tat various points of the cycle designated in Fig. 11.22:\n",
"\tP 1 = 125 kPa,\n",
"\tP 2 = 1.2 MPa,\n",
"\tP 3 = 1.19 MPa,\n",
"\tP 4 = 1.16 MPa,\n",
"\tP 5 = 1.15 MPa,\n",
"\tP 6 = P 7 = 140 kPa,\n",
"\tP 8 = 130 kPa,\n",
"\tT 1 = −10 ◦C\n",
"\tT 2 = 100◦C\n",
"\tT 3 = 80◦C\n",
"\tT 4 = 45◦C\n",
"\tT 5 = 40◦C\n",
"\tx 6 = x 7\n",
"\tT 8 = −20◦C\n",
"\tThe heat transfer from R-134a during the compression process is 4 kJ/kg. Determine\n",
"\tthe COP of this cycle.\n",
"\tFor each control volume, the R-134a tables are the model. Each process is steady\n",
"\tstate, with no changes in kinetic or potential energy.\n",
"\tAs before, we break the process down into stages, treating the compressor, the\n",
"\tthrottling value and line, and the evaporator in turn.\n",
"\tControl volume:\n",
"\tInlet state:\n",
"\tExit state:\n",
"\tCompressor.\n",
"\tP 1 , T 1 known; state ﬁxed.\n",
"\tP 2 , T 2 known; state ﬁxed.\n",
"'''\n",
"\n",
"#Variable Declaration: \n",
"h1 = 394.9 \t\t\t#KJ/Kg\n",
"h2 = 480.9 \t\t\t#KJ/Kg\n",
"q = -4 \t\t\t\t#KJ/Kg\n",
"h5 = 256.4 \t\t\t#KJ/Kg\t\n",
"h8 = 386.6\t\t\t#KJ/Kg\n",
"\n",
"#Calculations:\n",
"wc = h2-h1-q\t\t#Work done by compressor in KJ/Kg\n",
"h6 = h5\n",
"h7 = h6\n",
"qL = h8-h7\n",
"B = qL/wc\t\t\t#Coefficient of performance\n",
"\n",
"#Results:\n",
"print 'COP of refrigerator : ', round(B,2)"
]
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 2",
"language": "python",
"name": "python2"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 2
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython2",
"version": "2.7.6"
}
},
"nbformat": 4,
"nbformat_minor": 0
}