summaryrefslogtreecommitdiff
path: root/Basic_Engineering_Thermodynamics_by_R_Joel/14-Air_and_gas_compressors.ipynb
diff options
context:
space:
mode:
authorPrashant S2020-04-14 10:25:32 +0530
committerGitHub2020-04-14 10:25:32 +0530
commit06b09e7d29d252fb2f5a056eeb8bd1264ff6a333 (patch)
tree2b1df110e24ff0174830d7f825f43ff1c134d1af /Basic_Engineering_Thermodynamics_by_R_Joel/14-Air_and_gas_compressors.ipynb
parentabb52650288b08a680335531742a7126ad0fb846 (diff)
parent476705d693c7122d34f9b049fa79b935405c9b49 (diff)
downloadall-scilab-tbc-books-ipynb-master.tar.gz
all-scilab-tbc-books-ipynb-master.tar.bz2
all-scilab-tbc-books-ipynb-master.zip
Merge pull request #1 from prashantsinalkar/masterHEADmaster
Initial commit
Diffstat (limited to 'Basic_Engineering_Thermodynamics_by_R_Joel/14-Air_and_gas_compressors.ipynb')
-rw-r--r--Basic_Engineering_Thermodynamics_by_R_Joel/14-Air_and_gas_compressors.ipynb472
1 files changed, 472 insertions, 0 deletions
diff --git a/Basic_Engineering_Thermodynamics_by_R_Joel/14-Air_and_gas_compressors.ipynb b/Basic_Engineering_Thermodynamics_by_R_Joel/14-Air_and_gas_compressors.ipynb
new file mode 100644
index 0000000..0282db3
--- /dev/null
+++ b/Basic_Engineering_Thermodynamics_by_R_Joel/14-Air_and_gas_compressors.ipynb
@@ -0,0 +1,472 @@
+{
+"cells": [
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# Chapter 14: Air and gas compressors"
+ ]
+ },
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 14.1: EX14_1.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"clear;\n",
+"clc;\n",
+"disp(' Example 14.1');\n",
+"\n",
+"// aim : To determine \n",
+"// (a) the free air delivered\n",
+"// (b) the volumetric efficiency\n",
+"// (c) the air delivery temperature\n",
+"// (d) the cycle power\n",
+"// (e) the isothermal efficiency\n",
+"\n",
+"// given values\n",
+"d = 200*10^-3;// bore, [m]\n",
+"L = 300*10^-3;// stroke, [m]\n",
+"N = 500;// speed, [rev/min]\n",
+"n = 1.3;// polytropic index\n",
+"P1 = 97;// intake pressure, [kN/m^2]\n",
+"T1 = 273+20;// intake temperature, [K]\n",
+"P3 = 550;// compression pressure, [kN/m^2]\n",
+"\n",
+"// solution\n",
+"// (a)\n",
+"P4 = P1;\n",
+"P2 = P3;\n",
+"Pf = 101.325;// free air pressure, [kN/m^2]\n",
+"Tf = 273+15;// free air temperature, [K]\n",
+"SV = %pi/4*d^2*L;// swept volume, [m^3]\n",
+"V3 = .05*SV;// [m^3]\n",
+"V1 = SV+V3;// [m^3]\n",
+"V4 = V3*(P3/P4)^(1/n);// [m^3]\n",
+"ESV = (V1-V4)*N;// effective swept volume/min, [m^3]\n",
+"// using PV/T=constant\n",
+"Vf = P1*ESV*Tf/(Pf*T1);// free air delivered, [m^3/min]\n",
+"mprintf('\n (a) The free air delivered is = %f m^3/min\n',Vf);\n",
+"\n",
+"// (b)\n",
+"VE = Vf/(N*(V1-V3));// volumetric efficiency\n",
+"mprintf('\n (b) The volumetric efficiency is = %f percent\n',VE*100);\n",
+"\n",
+"// (c)\n",
+"T2 = T1*(P2/P1)^((n-1)/n);// free air temperature, [K]\n",
+"mprintf('\n (c) The air delivery temperature is = %f C\n',T2-273);\n",
+"\n",
+"// (d)\n",
+"CP = n/(n-1)*P1*(V1-V4)*((P2/P1)^((n-1)/n)-1)*N/60;// cycle power, [kW]\n",
+" mprintf('\n (d) The cycle power is = %f kW\n',CP);\n",
+"\n",
+"// (e)\n",
+"// neglecting clearence\n",
+"W = n/(n-1)*P1*V1*((P2/P1)^((n-1)/n)-1)\n",
+"Wi = P1*V1*log(P2/P1);// isothermal efficiency\n",
+"IE = Wi/W;// isothermal efficiency\n",
+"mprintf('\n (e) The isothermal efficiency neglecting clearence is = %f percent\n',IE*100);\n",
+"\n",
+"// End"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 14.2: intermediate_pressure_volume_and_cycle_power.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"clear;\n",
+"clc;\n",
+"disp(' Example 14.2');\n",
+"\n",
+"// aim : To determine \n",
+"// (a) the intermediate pressure\n",
+"// (b) the total volume of each cylinder\n",
+"// (c) the cycle power\n",
+"\n",
+"// given values\n",
+"v1 = .2;// air intake, [m^3/s]\n",
+"P1 = .1;// intake pressure, [MN/m^2]\n",
+"T1 = 273+16;// intake temperature, [K]\n",
+"P3 = .7;// final pressure, [MN/m^2]\n",
+"n = 1.25;// compression index\n",
+"N = 10;// speed, [rev/s]\n",
+"\n",
+"// solution\n",
+"// (a)\n",
+"P2 = sqrt(P1*P3);// intermediate pressure, [MN/m^2]\n",
+"mprintf('\n (a) The intermediate pressure is = %f MN/m^2\n',P2);\n",
+"\n",
+"// (b)\n",
+"V1 = v1/N;// total volume,[m^3]\n",
+"// since intercooling is perfect so 2 lie on the isothermal through1, P1*V1=P2*V2\n",
+"V2 = P1*V1/P2;// volume, [m^3]\n",
+"mprintf('\n (b) The total volume of the HP cylinder is = %f litres\n',V2*10^3);\n",
+"\n",
+" // (c)\n",
+" CP = 2*n/(n-1)*P1*v1*((P2/P1)^((n-1)/n)-1);// cycle power, [MW]\n",
+" mprintf('\n (c) The cycle power is = %f MW\n',CP*10^3);\n",
+" \n",
+" // there is calculation mistake in the book so answer is not matching\n",
+" \n",
+" // End"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 14.3: intermediate_pressures_effective_swept_volume_temperature_and_work_done.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"clear;\n",
+"clc;\n",
+"disp(' Example 14.3');\n",
+"\n",
+"// aim : To determine \n",
+"// (a) the intermediate pressures\n",
+"// (b) the effective swept volume of the LP cylinder\n",
+"// (c) the temperature and the volume of air delivered per stroke at 15 bar\n",
+"// (d) the work done per kilogram of air\n",
+"\n",
+"// given values\n",
+"d = 450*10^-3;// bore , [m]\n",
+"L = 300*10^-3;// stroke, [m]\n",
+"cl = .05;// clearence\n",
+"P1 = 1; // intake pressure, [bar]\n",
+"T1 = 273+18;// intake temperature, [K]\n",
+"P4 = 15;// final delivery pressure, [bar]\n",
+"n = 1.3;// compression and expansion index\n",
+"R = .29;// gas constant, [kJ/kg K]\n",
+"\n",
+"// solution\n",
+"// (a)\n",
+"k=(P4/P1)^(1/3); \n",
+"// hence\n",
+"P2 = k*P1;// intermediare pressure, [bar]\n",
+"P3 = k*P2;// intermediate pressure, [bar]\n",
+"\n",
+"mprintf('\n (a) The intermediate pressure is P2 = %f bar\n',P2);\n",
+"mprintf('\n The intermediate pressure is P3= %f bar\n',P3);\n",
+"\n",
+"// (b)\n",
+"SV = %pi*d^2/4*L;// swept volume of LP cylinder, [m^3]\n",
+"// hence\n",
+"V7 = cl*SV;// volume, [m^3]\n",
+"V1 = SV+V7;// volume, [m^3]\n",
+"// also\n",
+"P7 = P2;\n",
+"P8 = P1;\n",
+"V8 = V7*(P7/P8)^(1/n);// volume, [m^3]\n",
+"ESV = V1-V8;// effective swept volume of LP cylinder, [m^3]\n",
+"\n",
+"mprintf('\n (b) The effective swept volume of the LP cylinder is = %f litres\n',ESV*10^3);\n",
+"\n",
+"// (c)\n",
+"T9 = T1;\n",
+"P9 = P3;\n",
+"T4 = T9*(P4/P9)^((n-1)/n);// delivery temperature, [K]\n",
+"// now using P4*(V4-V5)/T4=P1*(V1-V8)/T1\n",
+"V4_minus_V5 = P1*T4*(V1-V8)/(P4*T1);// delivery volume, [m^3]\n",
+" \n",
+"mprintf('\n (c) The delivery temperature is = %f C\n',T4-273);\n",
+"mprintf('\n The delivery volume is = %f litres\n',V4_minus_V5*10^3);\n",
+"\n",
+"// (d)\n",
+"\n",
+"W = 3*n*R*T1*((P2/P1)^((n-1)/n)-1)/(n-1);// work done/kg ,[kJ]\n",
+"mprintf('\n (d) The work done per kilogram of air is = %f kJ\n',W);\n",
+" \n",
+"// End"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 14.4: pressure_temperature_and_energy.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"clear;\n",
+"clc;\n",
+"disp(' Example 14.4');\n",
+"\n",
+"// aim : To determine \n",
+"// (a) the final pressure and temperature\n",
+"// (b) the energy required to drive the compressor\n",
+"\n",
+"// given values\n",
+"rv = 5;// pressure compression ratio\n",
+"m_dot = 10;// air flow rate, [kg/s]\n",
+"P1 = 100;// initial pressure, [kN/m^2]\n",
+"T1 = 273+20;// initial temperature, [K]\n",
+"n_com = .85;// isentropic efficiency of compressor\n",
+"Gama = 1.4;// heat capacity ratio\n",
+"cp = 1.005;// specific heat capacity, [kJ/kg K]\n",
+"\n",
+"// solution\n",
+"// (a)\n",
+"T2_prim = T1*(rv)^((Gama-1)/Gama);// temperature after compression, [K]\n",
+"// using isentropic efficiency=(T2_prim-T1)/(T2-T1)\n",
+"T2 = T1+(T2_prim-T1)/n_com;// final temperature, [K]\n",
+"P2 = rv*P1;// final pressure, [kN/m^2]\n",
+"mprintf('\n (a) The final temperature is = %f C\n',T2-273);\n",
+"mprintf('\n (b) The final pressure is = %f kN/m^2\n',P2);\n",
+"\n",
+"// (b)\n",
+"E = m_dot*cp*(T1-T2);// energy required, [kW]\n",
+"mprintf('\n (b) The energy required to drive the compressor is = %f kW',E);\n",
+"if(E<0)\n",
+" disp('The negative sign indicates energy input');\n",
+"else\n",
+" disp('The positive sign indicates energy output');\n",
+"end\n",
+"\n",
+" // End\n",
+"\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 14.5: power_developed.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"clear;\n",
+"clc;\n",
+"disp(' Example 14.5');\n",
+"\n",
+"// aim : To determine \n",
+"// the power absorbed in driving the compressor\n",
+"\n",
+"// given values\n",
+"FC = .68;// fuel consumption rate, [kg/min]\n",
+"P1 = 93;// initial pressure, [kN/m^2]\n",
+"P2 = 200;// final pressure, [kN/m^2]\n",
+"T1 = 273+15;// initial temperature, [K]\n",
+"d = 1.3;// density of mixture, [kg/m^3]\n",
+"n_com = .82;// isentropic efficiency of compressor\n",
+"Gama = 1.38;// heat capacity ratio\n",
+"\n",
+"// solution\n",
+"R = P1/(d*T1);// gas constant, [kJ/kg K]\n",
+"// for mixture\n",
+"cp = Gama*R/(Gama-1);// heat capacity, [kJ/kg K]\n",
+"T2_prim = T1*(P2/P1)^((Gama-1)/Gama);// temperature after compression, [K]\n",
+"// using isentropic efficiency=(T2_prim-T1)/(T2-T1)\n",
+"T2 = T1+(T2_prim-T1)/n_com;// final temperature, [K]\n",
+"m_dot = FC*15/60;// given condition, [kg/s]\n",
+"P = m_dot*cp*(T2-T1);// power absorbed by compressor, [kW]\n",
+"mprintf('\n The power absorbed by compressor is = %f kW\n',P);\n",
+"\n",
+"// End"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 14.6: power.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"clear;\n",
+"clc;\n",
+"disp(' Example 14.6');\n",
+"\n",
+"// aim : To determine \n",
+"// the power required to drive the blower\n",
+"\n",
+"// given values\n",
+"m_dot = 1;// air capacity, [kg/s]\n",
+"rp = 2;// pressure ratio\n",
+"P1 = 1*10^5;// intake pressure, [N/m^2]\n",
+"T1 = 273+70;// intake temperature, [K]\n",
+"R = .29;// gas constant, [kJ/kg k]\n",
+"\n",
+"// solution\n",
+"V1_dot = m_dot*R*T1/P1*10^3;// [m^3/s]\n",
+"P2 = rp*P1;// final pressure, [n/m^2]\n",
+"P = V1_dot*(P2-P1);// power required, [W]\n",
+"mprintf('\n The power required to drive the blower is = %f kW\n',P*10^-3);\n",
+"\n",
+"// End"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 14.7: power.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"clear;\n",
+"clc;\n",
+"disp(' Example 14.7');\n",
+"\n",
+"// aim : To determine \n",
+"// the power required to drive the vane pump\n",
+"\n",
+"// given values\n",
+"m_dot = 1;// air capacity, [kg/s]\n",
+"rp = 2;// pressure ratio\n",
+"P1 = 1*10^5;// intake pressure, [N/m^2]\n",
+"T1 = 273+70;// intake temperature, [K]\n",
+"Gama = 1.4;// heat capacity ratio\n",
+"rv = .7;// volume ratio\n",
+"\n",
+"// solution\n",
+"V1 = .995;// intake pressure(as given previous question),[m^3/s] \n",
+"// using P1*V1^Gama=P2*V2^Gama, so\n",
+"P2 = P1*(1/rv)^Gama;// pressure, [N/m^2]\n",
+"V2 = rv*V1;// volume,[m^3/s]\n",
+"P3 = rp*P1;// final pressure, [N/m^2]\n",
+"P = Gama/(Gama-1)*P1*V1*((P2/P1)^((Gama-1)/Gama)-1)+V2*(P3-P2);// power required,[W]\n",
+"mprintf('\n The power required to drive the vane pump is = %f kW\n',P*10^-3);\n",
+"\n",
+"// End"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 14.8: power_temperature_and_pressure.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"clear;\n",
+"clc;\n",
+"disp(' Example 14.8');\n",
+"\n",
+"// aim : To determine \n",
+"// the total temperature and pressure of the mixture\n",
+"\n",
+"// given values\n",
+"rp = 2.5;// static pressure ratio\n",
+"FC = .04;// fuel consumption rate, [kg/min]\n",
+"P1 = 60;// inilet pressure, [kN/m^2]\n",
+"T1 = 273+5;// inilet temperature, [K]\n",
+"n_com = .84;// isentropic efficiency of compressor\n",
+"Gama = 1.39;// heat capacity ratio\n",
+"C2 = 120;//exit velocity from compressor, [m/s]\n",
+"rm = 13;// air-fuel ratio\n",
+"cp = 1.005;// heat capacity ratio\n",
+"\n",
+"// solution\n",
+"P2 = rp*P1;// given condition, [kN/m^2]\n",
+"T2_prim = T1*(P2/P1)^((Gama-1)/Gama);// temperature after compression, [K]\n",
+"// using isentropic efficiency=(T2_prim-T1)/(T2-T1)\n",
+"T2 = T1+(T2_prim-T1)/n_com;// final temperature, [K]\n",
+"m_dot = FC*(rm+1);// mass of air-fuel mixture, [kg/s]\n",
+"P = m_dot*cp*(T2-T1);// power to drive compressor, [kW]\n",
+"mprintf('\n The power required to drive compressor is = %f kW\n',P);\n",
+"\n",
+"Tt2 = T2+C2^2/(2*cp*10^3);// total temperature,[K]\n",
+"Pt2 = P2*(Tt2/T2)^(Gama/(Gama-1));// total pressure, [kN/m^2]\n",
+"mprintf('\n The temperature in the engine is = %f C\n',Tt2-273);\n",
+"mprintf('\n The pressure in the engine cylinder is = %f kN/m^2\n',Pt2);\n",
+"\n",
+"// There is calculation mistake in the book\n",
+"\n",
+"\n",
+"// End"
+ ]
+ }
+],
+"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
+}