{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# Chapter 8: Thermodynamic Cycles" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 8.10: Determination_of_temperature_of_air.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "funcprot(0);\n", "\n", "//Example - 8.10\n", "//Page number - 307\n", "printf('Example - 8.10 and Page number - 307\n\n');\n", "\n", "//Given\n", "P_high = 40;//[bar]\n", "P_low = 5;//[bar]\n", "m_1 = 0.5;//[kg/s] - Rate of mass moving through the expander\n", "m_2 = 0.1;//[kg/s] - Rate of mass of vapour mixing with air\n", "e = 0.7;//Efficiency\n", "\n", "//At state 3,(40 bar and 200 K),enthalpy and entropy is given by\n", "H_3 = 179.7;//[kJ/kg]\n", "S_3 = 5.330;//[kJ/kg-K]\n", "\n", "//If isentropic conditions exits in the turbine then state 11 is at 5 bar\n", "S_11 = 5.330;//[kJ/kg-K]\n", "//From given compressed air tables at 5 bar and 120 K,\n", "H_11_1 = 113.6;//[kJ/kg]\n", "S_11_1 = 5.455;//[kJ/kg-K]\n", "//At 5 bar and 100 K \n", "H_11_2 = 90.6;//[kJ/kg]\n", "S_11_2 = 5.246;//[kJ/kg-K]\n", "//The enthalpy has to be determined when S = S_3\n", "//Solving by interpolation we get\n", "H_11_s = ((H_11_1 - H_11_2)*(S_3 - S_11_2))/(S_11_1 - S_11_2) + H_11_2;//[kJ/kg]\n", "\n", "//The adiabatic efficiency of tyrbine is given by\n", "//(H_3 - H_11_a)/(H_3 - H_11_s) = e\n", "H_11_a = H_3 - e*(H_3 - H_11_s);//[kJ/kg] - Actual enthalpy\n", "\n", " //At 5 bar,the saturated enthalpy is given to be\n", "H_8 = 88.7;//[kJ/kg]\n", "//From enthalpy balance during mixing we get,\n", "//0.1*H_8 + 0.5*H_11_a = 0.6*H_9\n", "H_9 = (m_2*H_8 + m_1*H_11_a)/(m_1 + m_2);//[kJ/kg]\n", "\n", "//From given compressed air tables at 5 bar and 140 K,\n", "H_9_1 = 135.3;//[kJ/kg]\n", "//At 5 bar and 120 K \n", "H_9_2 = 113.6;//[kJ/kg]\n", "//By interpolation we get\n", "T_9 = ((H_9 - H_11_1)*(140 - 120))/(H_9_1 - H_11_1) + 120;//[K]\n", "\n", "printf(' The temperature of air entering the second heat exchanger is %f K\n\n',T_9);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 8.1: Calculation_of_work_done.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "//Example - 8.1\n", "//Page number - 287\n", "printf('Example - 8.1 and Page number - 287\n\n');\n", "//Given\n", "P_1 = 30;//[bar]\n", "P_2 = 0.04;//[bar]\n", "//(1).Carnot cycle\n", "//It has been reported in the book that at 30 bar pressure (saturated) :\n", "H_liq_1 = 1008.42;//[kJ/kg]\n", "H_vap_1 = 2804.2;//[kJ/kg]\n", "S_liq_1 = 2.6457;//[kJ/kg-K]\n", "S_vap_1 = 6.1869;//[kJ/kh-K]\n", "//Therefore, H_1 = H_liq_1, H_2 = H_vap_1, S_1 = S_liq_1 and S_2 = S_vap_1\n", "H_1 = H_liq_1;\n", "H_2 = H_vap_1;\n", "S_1 = S_liq_1;\n", "S_2 = S_vap_1;\n", "//At 0.04 bar pressure (saturated) :\n", "H_liq_2 = 121.46;//[kJ/kg]\n", "H_vap_2 = 2554.4;//[kJ/kg]\n", "S_liq_2 = 0.4226;//[kJ/kg-K]\n", "S_vap_2 = 8.4746;//[kJ/kh-K]\n", "//Dryness fraction at state 3 can be found the fact that S_3 = S_2 \n", "x_3 = (S_2 - S_liq_2)/(S_vap_2 - S_liq_2);\n", "H_3 = H_liq_2*(1 - x_3) + x_3*H_vap_2;//[kJ/kg]\n", "//Dryness fraction at state 4 can be found the fact that S_4 = S_1\n", "x_4 = (S_1 - S_liq_2)/(S_vap_2 - S_liq_2);\n", "H_4 = H_liq_2*(1 - x_4) + x_4*H_vap_2;//[kJ/kg]\n", "//Work done by turbine W_tur = -delta_H = -(H_3 - H_2)\n", "W_tur = H_2 - H_3;//[kJ/kg]\n", "//Work supplied by boiler,\n", "q_H = H_2 - H_1;//[kJ/kg]\n", "//Work transfer in compressor is given by\n", "W_com = -(H_1 - H_4);//[kJ/kg]\n", "//Efficiency can now be calculated as\n", "//n = (Net work done/Work supplied by boiler)\n", "n_carnot = (W_tur + W_com)/q_H;\n", "//Efficiency of the Carnot cycle can also be determined from the formula\n", "// n = 1 - (T_L/T_H), Where T_L is saturated temperature at 0.04 bar and T_H is saturated temperature at 30 bar\n", "printf('(1).Carnot cycle\n\n');\n", "printf('The work done by the turbine is %f kJ/kg\n\n',W_tur);\n", "printf('The heat transfer in the boiler is %f kJ/kg\n\n',q_H);\n", "printf('The cycle efficiency is %f\n\n\n',n_carnot);\n", "//(2).Rankine cycle\n", "//The enthalpies at state 2 and 3 remain as in the Carnot cycle\n", "//Saturated liquid enthalpy at 0.04 bar is \n", "H_4_prime = H_liq_2;\n", "//Saturated liquid volume at 0.04 bar as reported in the book is\n", "V_liq = 0.001004;//[m^(3)/kg]\n", "//Work transfer in pump can be calculated as\n", "W_pump = -V_liq*(P_1 - P_2)*100;//[kJ/kg]\n", "//Work transfer around pump gives, W_pump = -delta_H = -(H_1_prime - H_4_prime);\n", "H_1_prime = H_4_prime - W_pump;//[kJ/kg]\n", "//Heat supplied to boiler is\n", "q_H_prime = H_2 - H_1_prime;//[kJ/kg]\n", "//Work done by turbine is\n", "W_tur_prime = H_2 - H_3;//[kJ/kg]\n", "//Efficiency can now be calculated as\n", "//n = (Net work done/Heat input)\n", "n_rankine = (W_tur_prime + W_pump)/q_H_prime;//\n", "printf('(2).Rankine cycle\n\n');\n", "printf('The work done by the turbine is %f kJ/kg\n\n',W_tur_prime);\n", "printf('The heat transfer in the boiler is %f kJ/kg\n\n',q_H_prime);\n", "printf('The cycle efficiency is %f',n_rankine);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 8.2: Calculation_of_efficiency_of_Rankine_cycle.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "\n", "//Example - 8.2\n", "//Page number - 288\n", "printf('Example - 8.2 and Page number - 288\n\n');\n", "\n", "//Given\n", "T_max = 700+273.15;//[K] - Maximum temperature.\n", "P_boiler = 10*10^(6);//[Pa] - Constant pressure in the boiler\n", "P_condenser = 10*10^(3);//[Pa] - Constant pressure in the condenser\n", "\n", "//At state 2 i.e, at 700 C and 10 MPa,it has been reported in the book that from steam table\n", "S_2 = 7.1687;//[kJ/kg-K] - Entropy\n", "H_2 = 3870.5;//[kJ/kg] - Enthalpy\n", "\n", "//At state 3 i.e, at 700 C and 10 KPa,\n", "S_3 = S_2;//[kJ/kg-K]- Entropy \n", "\n", "//For sturated steam at 10 kPa, it has been reported in the book that from steam table\n", "S_liq = 0.6493;//[kJ/kg-K]- Entropy of saturated liquid\n", "S_vap = 8.1502;//[kJ/kg-K] - Enthalpy of saturated liquid\n", "//Therefore steam is saturated and its dryness factor can be calculated as\n", "x = (S_2 - S_liq)/(S_vap - S_liq);\n", "\n", "//The enthalpy at state 3 is now calculated. For steam at 10 kPa,it has been reported in the book that from steam table\n", "H_liq = 191.83;//[kJ/kg]\n", "H_vap = 2584.7;//[kJ/kg]\n", "//Therefore enthalpy at state 3 is\n", "H_3 = H_liq*(1-x) + H_vap*x;//[kJ/kg]\n", "\n", "//Work done by the turbine \n", "W_tur = -(H_3 - H_2);//[kJ/kg]\n", "\n", "//Now we have to calculate work input to the pump\n", "//State 4:Saturated liquid at 10 kPa\n", "//State 4:Compressed liquid at 10 MPa\n", "//Since volume of liquid does not get affected by pressure we take volume of saturated liquid at 10 kPa,\n", "V_liq = 0.001010;//[m^(3)/kg]\n", "\n", "//Work transfer in the pump is\n", "W_pump = -V_liq*(P_boiler - P_condenser)*10^(-3);//[kJ/kg]\n", "\n", "//Energy balance around pump gives, W_pump = -delta_H = -(H_1 - H_4)\n", "H_4 = H_liq;// Enthalpy at state 4 (saturated liquid at 10 kPa)\n", "H_1 = H_4 - W_pump;//[kJ/kg]\n", " \n", "//Heat supplied to boiler is\n", "q_H = H_2 - H_1;//[kJ/kg]\n", "\n", "//Efficiency can now be calculated as\n", "//n = (Net work done/Heat input)\n", "n_rankine = (W_tur + W_pump)/q_H;\n", "\n", "printf('The efficiency of the Rankine cycle is found to be %f',n_rankine);\n", "\n", "//Now let us determine the efficiency of Carnot cycle. The maximun temperature is 700 C and minimum temperature is that of saturated steam at 10 kPa,\n", "T_min = 45.81 + 273.15;//[K] - From steam table as reported in the book\n", "n_carnot = 1-(T_min/T_max);\n", "//Note that the efficiency of Rankine cycle is less than that of carnot cycle.\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 8.3: Calculatrion_of_COP_of_carnot_refrigerator_and_heat_rejected.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "\n", "//Example - 8.3\n", "//Page number - 291\n", "printf('Example - 8.3 and Page number - 291\n\n');\n", "\n", "//Given\n", "W = 1.1;//[kW] - Work done per ton of refrigeration \n", "//1 ton refrigeration = 3.517 kW, therefore\n", "H = 3.517;//[kW] - Heat absorbed\n", "T_low = -30 + 273.15;//[K] - Low temperature maintained\n", "\n", "//COP can be calculated as\n", "//COP = (Heat absorbed/Work done)\n", "COP = H/W;\n", "\n", "//For reversed carnot cycle, COP = T_low/(T_high - T_low). Solving this we get\n", "T_high = (T_low/COP) + T_low;//[K] - Higher temperature\n", "\n", "//Heat rejected is\n", "H_rej = W + H;//[kW];\n", "\n", "printf('The COP is %f\n\n',COP);\n", "printf('The higher temperature of the cycle is %f K\n\n',T_high);\n", "printf('The heat rejected per ton of refrigeration is %f kW\n\n',H_rej);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 8.4: Calculation_of_minimum_power_required.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "\n", "//Example - 8.4\n", "//Page number - 292\n", "printf('Example - 8.4 and Page number - 292\n\n');\n", "\n", "//Given\n", "T_high = 20 + 273.15;//[K] - High temperature\n", "T_low = 0 + 273.15;//[K] - Low temperature\n", "Q_H = 10;//[kW] - Heat supplied\n", "\n", "//If 'Q_H' is the rate at which heat is taken from surrounding and 'W' is the rate at which work is done,then\n", "// Q_H = W + Q_L\n", "//(Q_H/Q_L) = (T_high/T_low)\n", "//Also for a reversible cycle, (Q_H/Q_L) = 1 + (W/Q_L). Solving we get,\n", "Q_L = (T_low/T_high)*Q_H;//[kW]\n", "W = (Q_H - Q_L) ;//[kW]\n", " \n", "printf('The minimum power required is %f kW',W);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 8.5: Determination_of_COP_and_power_required.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "\n", "//Example - 8.5\n", "//Page number - 292\n", "printf('Example - 8.5 and Page number - 292\n\n');\n", "\n", "//Given\n", "T_high = 40 + 273.15;//[K] - High temperature\n", "T_low = -20 + 273.15;//[K] - Low temperature\n", "C = 10;//[tons of refrigeration] - Capacity\n", "//1 ton refrigeration = 3.517 kW, therefore\n", "H = C*3.517;//[kW] - Heat absorbed\n", "\n", "//For reversed carnot cycle, COP = T_low/(T_high - T_low)\n", "COP = T_low/(T_high - T_low);\n", "\n", "// COP = (Refrigerating effect)/(Work input), therefore power required is given by\n", "P = (H/COP);//[kW]\n", "\n", "printf('The COP is %f\n\n',COP);\n", "printf('The power required is %f kW',P);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 8.6: Determination_of_maximum_refrigeration_effect.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "\n", "//Example - 8.6\n", "//Page number - 292\n", "printf('Example - 8.6 and Page number - 292\n\n');\n", "\n", "//Given\n", "COP = 4;//Coefficient of performance\n", "P = 10;//[kW] - Work done on the cycle\n", "\n", "//For reversed carnot cycle, COP = T_low/(T_high - T_low)\n", "//ratio = (T_high/T_low),therefore\n", "ratio = -1/(COP + 1);\n", "\n", "// Refrigerating effect = (COP)*Work input, therefore refrigeration is given by\n", "H = COP*P;//[kW]\n", "\n", "//Maximum refrigearation in tons is given by\n", "H_max = (H/3.517);\n", "\n", "printf('The maximum refrigeration value is %f ton',H_max);\n", "" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 8.7: Determination_of_refrigeration_effect_power_consumed_and_COP_of_refrigerator.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "\n", "//Example - 8.7\n", "//Page number - 292\n", "printf('Example - 8.7 and Page number - 292\n\n');\n", "\n", "//Given\n", "m = 0.6;//[kg/s] - mass flow rate\n", "T_low = -20+273.15;//[K] - Temperature at which vapour enters the compressor\n", "T_high = 30+273.15;//[K] - Temperature at which vapour leaves the condenser\n", "\n", "//From saturated refrigeration-12 tables we get,at -20 C\n", "H_1 = 178.74;//[kJ/kg] - (H_1 = H_vap)\n", "P_1 = 0.15093;//[MPa] - (P_1 = P_sat)\n", "P_4 = P_1;\n", "S_1 = 0.7087;//[kJ/kg-K] - (S_1 = S_vap)\n", "S_2 = S_1;\n", "\n", "//At 30 C\n", "P_2 = 0.7449;//[MPa] - (P_2 = P_sat)\n", "P_3 = P_2;\n", "H_3 = 64.59;//[kJ/kg] - (H_3 = H_liq)\n", "H_4 = H_3;\n", "S_3 = 0.24;//[kJ/kg-K] - (S_3 = S_liq)\n", "\n", "//It is assumed that presssure drop in the evaporator and condenser are negligible. The heat transfer rate in the evaporator is\n", "Q_L = m*(H_1 - H_4);\n", "\n", "printf('The heat transfer rate in the evaporator is %f kW\n\n',Q_L);\n", "\n", "//At state 2 (P = 0.7449 MPa and S = 0.7087 kJ/kg-K) and looking in the superheated tables we have to calculate the enthalpy at state 2\n", "\n", "//At P = 0.7 MPa and S = 0.6917 kJ/kg-K,\n", "H_11 = 200.46;//[kJ/kg]\n", "\n", "//At P = 0.7 MPa and S = 0.7153 kJ/kg-K,\n", "H_12 = 207.73;//[kJ/kg]\n", "\n", "//Thus at P = 0.7 MPa and S = 0.7087 kJ/kg-K, enthalpy is given by\n", "H_13 = ((S_2 -0.6917)/(0.7153 - 0.6917))*(H_12 - H_11) + H_11;//[kJ/kg]\n", "\n", "//At P = 0.8 MPa and S = 0.7021 kJ/kg-K,\n", "H_21 = 206.07;//[kJ/kg]\n", "\n", "//At P = 0.8 MPa and S = 0.7253 kJ/kg-K,\n", "H_22 = 213.45;//[kJ/kg]\n", "\n", "//Thus at P = 0.8 MPa and S = 0.7087 kJ/kg-K, enthalpy is given by\n", "H_23 = ((S_2 -0.7021)/(0.7253 - 0.7021))*(H_22 - H_21) + H_21;//[kJ/kg]\n", "\n", "//At P = 0.7449 MPa, S = 0.7087 kJ/kg-K, the enthalpy is\n", "H_2 = ((0.7449 - 0.7)/(0.8 - 0.7))*(H_23 - H_13) + H_13;//[kJ/kg]\n", "\n", "//Power consumed by the compressor is\n", "W_comp = m*(H_2 - H_1);//[kW]\n", "\n", "printf('The power consumed by the compressor is %f kW\n\n',W_comp);\n", "\n", "//Heat removed in evaporator/work done on compressor\n", "COP_R = Q_L/W_comp;\n", "\n", "printf('The COP the refrigerator is %f kW\n\n',COP_R);\n", "\n", "\n", "//At -20 C,saturated conditions \n", "H_liq = 17.82;//[kJ/kg]\n", "H_vap = 178.74;//[kJ/kg]\n", "x_4 = (H_4 - H_liq)/(H_vap - H_liq);\n", "\n", "printf('The dryness factor of refrigerant after the expansion valve is %f\n\n',x_4);\n", "\n", "//The heat transfer rate in the condenser is\n", "Q_H = m*(H_3 - H_2);//[kW]\n", "\n", "printf('The heat transfer rate in the condenser is %f kW\n\n',Q_H);\n", "\n", "//If the cycle would have worked as a pump then,\n", "//COP_HP = (Heat supplied from condenser/Work done on compressor)\n", "COP_HP = (-Q_H)/W_comp;\n", "\n", "printf('The COP if cycle would work as a heat pump is %f kW\n\n',COP_HP);\n", "\n", "//If the cycle would have been a reversed Carnot cycle then\n", "COP_C = T_low/(T_high - T_low);\n", "\n", "printf('The COP if cycle would run as reversed Carnot cycle is %f kW\n\n',COP_C);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 8.8: Calculation_of_amount_of_air.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "\n", "//Example - 8.8\n", "//Page number - 300\n", "printf('Example - 8.8 and Page number - 300\n\n');\n", "\n", "//Given\n", "//From compressor to the expansion valve the pressure is 200 bar and from expansion valve to the inlet of compressor the pressure is 1 bar.\n", "//Point 5 is saturated liquid at 1 bar and point 6 is saturated vapour at 1 bar\n", "\n", "//It has been reported in the book that at state 1 (310 K, 1 bar)\n", "H_1 = 310.38;//[kJ/kg]\n", "//At state 2 (310 K, 200 bar)\n", "H_2 = 277.7;//[kJ/kg]\n", "//At state 5 (1 bar,saturated liquid)\n", "H_5 = -122.6;//[kJ/kg]\n", "//At state 6 (1 bar,saturated vapur)\n", "H_6 = 77.8;//[kJ/kg]\n", "\n", "//The enthalpy at point 3 is same at point 4 as the expansion is isenthalpic\n", "\n", "//The mass condensed is 1 kg and therefore m_1 = m+6 + 1\n", "\n", "//Enthalpy balance around heat exchanger\n", "//m_2*H_2 + m_2*H_6 = m_3*H_3 + m_7*H_7\n", "\n", "//Enthalpy balance around separator\n", "//m_4*H_4 = m_5*H_5 + m_6*H_6\n", "//It can be seen that m_1 = m_2 = m_3 = m_4\n", "//and m_6 = m_7 = m_1 - 1\n", "\n", "//Substituting the values for enthalpy balance around heat exchanger we get,\n", "//m_1*H_2 + (m_1 - 1)*(H_6) = m_1*H_3 + (m_1 - 1)*H_1\n", "//and substituting the values for enthalpy balance around seperator we get\n", "//m_1*H_3 = (1)*(-122.6) + (m_1 - 1)*77.8\n", "//H_3 = ((1)*(-122.6) + (m_1 - 1)*77.8)/m_1\n", "//Substituting the expression for 'H_3' in the above equation and then solving for m_1, we get\n", "deff('[y]=f(m_1)','y=m_1*H_2+(m_1-1)*(H_6)-m_1*(((1)*(-122.6) + (m_1 - 1)*77.8)/m_1)-(m_1-1)*H_1');\n", "m_1 = fsolve(4,f);//[kg]\n", "//Thus to liquify 1 kg of air compression of m_1 kg of air is carried out.\n", "\n", "//Now substituting this value of m_1 to get the value of H_3,\n", "H_3 = ((1)*(-122.6) + (m_1 - 1)*77.8)/m_1;//[kJ/kg]\n", "\n", "//From given compressed air table we see at 200 bar and 160 K,\n", "H_3_1 = 40.2;//[kJ/kg]\n", "\n", "//At 200 bar and 180 K,\n", "H_3_2 = 79.8;//[kJ/kg]\n", "//By interpolation we get,\n", "T_3 = ((H_3 - H_3_1)*(180 - 160))/(H_3_2 - H_3_1) + 160;//[K]\n", "\n", "printf('Temperature before throttling is %f',T_3);" ] } , { "cell_type": "markdown", "metadata": {}, "source": [ "## Example 8.9: Calculation_of_amount_of_air_and_temperature.sce" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "clear;\n", "clc;\n", "funcprot(0);\n", "\n", "//Example - 8.9\n", "//Page number - 304\n", "printf('Example - 8.9 and Page number - 304\n\n');\n", "\n", "//Given\n", "//At 1 bar, 310 K \n", "H_1 = 310.38;//[kJ/kg]\n", "//At 200 bar, 310 K\n", "H_2 = 277.7;//[kJ/kg]\n", "//At 1 bar, Saturated liquid\n", "H_7 = -122.6;//[kJ/kg]\n", "//At 1 bar, Saturated vapour\n", "H_8 = 77.8;//[kJ/kg]\n", "//At 200 bar, 200 K\n", "H_3 = 117.6;//[kJ/kg]\n", "//At 1 bar, 100 K\n", "H_11 = 98.3;//[kJ/kg]\n", "\n", "//(1)\n", "//For 1 kg of liquid air obtained,the overall enthalpy balance is\n", "//m_2*H_2 = W - 122.6 + (m_2 - 1)*H_1\n", "//W = - 0.8*m_2*(H_11 - H_3)\n", "//Overall enthalpy balance equation becomes\n", "//H_2*m_2 = 15.44*m_2 - H_7 + (m_2 - 1)*H_1, solving\n", "m_2_prime = (H_7 - H_1)/(H_2 - 15.44 - H_1);\n", "\n", "printf('The number of kilograms of air compressed per kg of liquid air produced is %f kg\n\n',m_2_prime);\n", "\n", "//(2)\n", "//Enthalpy balance around separator is \n", "//0.2*m_2*H_5 = -H_7 + (0.2*m_2 - 1)*H_8, solving\n", "m_2 = m_2_prime;\n", "H_5_prime = ((0.2*m_2-1)*H_8 - H_7)/(0.2*m_2);\n", "\n", "//At point 5, P = 200 bar and enthalpy is\n", "H_5_1 = -33.53;//[kJ/kg]\n", "//From compressed air tables at 200 bar and 140 K,\n", "H_5_2 = 0.2;//[kJ/kg]\n", "//At 200 bar and 120 K,\n", "H_5_3 = -38.0;//[kJ/kg]\n", "//Solving by interpolation we get\n", "T_5 = ((H_5_1 - H_5_3)*(140 - 120))/(H_5_2 - H_5_3) + 120;//[K]\n", "\n", "printf('The temperature of air before throttling is %f K\n\n',T_5);\n", "\n", "//(3)\n", "//During mixing of streams 8 and 11 to produce stream 9, the enthalpy balance is\n", "// (0.2*m_2 - 1)*H_8 + 0.8*m_2*H_11 = (m_2 - 1)*H_9,Solving for H_9\n", "\n", "H_9_prime = ((0.2*m_2-1)*H_8+0.8*m_2*H_11)/(m_2 - 1);\n", "\n", "//From given compressed air tables at 1 bar and 100 K,\n", "H_9_1 = H_11;\n", "//At 1 bar and 90 K \n", "H_9_2 = 87.9;//[kJ/kg]\n", "//Solving by interpolation we get\n", "T_9 = ((H_9_prime - H_9_2)*(100 - 90))/(H_9_1 - H_9_2) + 90;//[K]\n", "\n", "printf('The temperature of stream entering second heat exchanger is %f K\n\n',T_9);\n", "\n", "//(4)\n", "//Enthalpy balance around first heat exchanger is\n", "//H_2*m_2 + (m_2 - 1)*H_10 = H_3*m-2 + (m-2 - 1)*H_1, solving for H_10\n", "\n", "H_10_prime = ((m_2 - 1)*H_1 + H_3*m_2 - H_2*m_2)/(m_2 - 1);\n", "\n", "//From given compressed air tables at 1 bar and 140 K,\n", "H_10_1 = 139.1;//[kJ/kg]\n", "//At 1 bar and 120 K \n", "H_10_2 = 118.8;//[kJ/kg]\n", "//Solving by interpolation we get\n", "T_10 = ((H_10_prime - H_10_2)*(140 - 120))/(H_10_1 - H_10_2) + 120;//[K]\n", "\n", "printf('The temperature of stream exiting second heat exchanger is %f K\n\n',T_10);" ] } ], "metadata": { "kernelspec": { "display_name": "Scilab", "language": "scilab", "name": "scilab" }, "language_info": { "file_extension": ".sce", "help_links": [ { "text": "MetaKernel Magics", "url": "https://github.com/calysto/metakernel/blob/master/metakernel/magics/README.md" } ], "mimetype": "text/x-octave", "name": "scilab", "version": "0.7.1" } }, "nbformat": 4, "nbformat_minor": 0 }