diff options
author | Prashant S | 2020-04-14 10:25:32 +0530 |
---|---|---|
committer | GitHub | 2020-04-14 10:25:32 +0530 |
commit | 06b09e7d29d252fb2f5a056eeb8bd1264ff6a333 (patch) | |
tree | 2b1df110e24ff0174830d7f825f43ff1c134d1af /Basic_Engineering_Thermodynamics_by_R_Joel/2-Systems.ipynb | |
parent | abb52650288b08a680335531742a7126ad0fb846 (diff) | |
parent | 476705d693c7122d34f9b049fa79b935405c9b49 (diff) | |
download | all-scilab-tbc-books-ipynb-master.tar.gz all-scilab-tbc-books-ipynb-master.tar.bz2 all-scilab-tbc-books-ipynb-master.zip |
Initial commit
Diffstat (limited to 'Basic_Engineering_Thermodynamics_by_R_Joel/2-Systems.ipynb')
-rw-r--r-- | Basic_Engineering_Thermodynamics_by_R_Joel/2-Systems.ipynb | 266 |
1 files changed, 266 insertions, 0 deletions
diff --git a/Basic_Engineering_Thermodynamics_by_R_Joel/2-Systems.ipynb b/Basic_Engineering_Thermodynamics_by_R_Joel/2-Systems.ipynb new file mode 100644 index 0000000..13741d6 --- /dev/null +++ b/Basic_Engineering_Thermodynamics_by_R_Joel/2-Systems.ipynb @@ -0,0 +1,266 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 2: Systems" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.1: Change_in_total_energy.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clear;\n", +"clc;\n", +"disp('Example 2.1');\n", +"// Given values\n", +"Q = 2500; // Heat transferred into the system, [kJ]\n", +"W = 1400; // Work transferred from the system, [kJ]\n", +" \n", +"// solution\n", +"// since process carried out on a closed system, so using equation [4]\n", +"del_E = Q-W; // Change in total energy, [kJ]\n", +"mprintf('\n The Change in total energy is, del_E = %f kJ\n',del_E);\n", +"if(del_E>0)\n", +" disp('Since del_E is positive, so there is an increase in total enery')\n", +"else\n", +" disp('Since del_E is negative, so there is an decrease in total enery')\n", +"end\n", +"// There is mistake in the book's results unit\n", +"// End" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.2: Heat_transferred.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clear;\n", +"clc;\n", +"disp('Example 2.2');\n", +"// Given values\n", +"del_E = 3500; // Increase in total energy of the system, [kJ]\n", +"W = -4200; // Work transfer into the system, [kJ]\n", +"// solution\n", +"// since process carried out on a closed system, so using equation [3]\n", +"Q = del_E+W;// [kJ]\n", +"mprintf('\n The Heat transfer is, Q = %f kJ \n',Q);\n", +"if(Q>0)\n", +" disp('Since Q>0, so heat is transferred into the system')\n", +"else\n", +" disp('Since Q<0, so heat is transferred from the system')\n", +"end\n", +"// End" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.3: Work_done.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clear;\n", +"clc;\n", +"disp('Example 2.3');\n", +"// Given values\n", +"Q = -150; // Heat transferred out of the system, [kJ/kg]\n", +"del_u = -400; // Internal energy decreased ,[kJ/kg]\n", +"// solution\n", +"// using equation [3],the non flow energy equation\n", +"// Q=del_u+W\n", +"W = Q-del_u; // [kJ/kg]\n", +"mprintf('\n The Work done is, W = %f kJ/kg \n',W);\n", +"if(W>0)\n", +" disp('Since W>0, so Work done by the engine per kilogram of working substance')\n", +"else\n", +" disp('Since <0, so Work done on the engine per kilogram of working substance')\n", +"end\n", +"// End" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.4: Power_of_the_system.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clear;\n", +"clc;\n", +"disp('Example 2.4');\n", +"// Given values\n", +"m_dot = 4; // fluid flow rate, [kg/s]\n", +"Q = -40; // Heat loss to the surrounding, [kJ/kg]\n", +"// At inlet \n", +"P1 = 600; // pressure ,[kn/m^2]\n", +"C1 = 220; // velocity ,[m/s]\n", +"u1 = 2200; // internal energy, [kJ/kg]\n", +"v1 = .42; // specific volume, [m^3/kg]\n", +"// At outlet\n", +"P2 = 150; // pressure, [kN/m^2]\n", +"C2 = 145; // velocity, [m/s]\n", +"u2 = 1650; // internal energy, [kJ/kg]\n", +"v2 = 1.5; // specific volume, [m^3/kg]\n", +"// solution\n", +"// for steady flow energy equation for the open system is given by\n", +"// u1+P1*v1+C1^2/2+Q=u2+P2*v2+C2^2/2+W\n", +"// hence\n", +"W = (u1-u2)+(P1*v1-P2*v2)+(C1^2/2-C2^2/2)*10^-3+Q; // [kJ/kg]\n", +"mprintf('\n workdone is, W = %f kJ/kg ',W);\n", +"if(W>0)\n", +" disp('Since W>0, so Power is output from the system')\n", +"else\n", +" disp('Since <0, so Power is input to the system')\n", +"end\n", +" \n", +"// Hence\n", +"P_out = W*m_dot; // power out put from the system, [kW]\n", +"mprintf('\n The power output from the system is = %f kW \n',P_out);\n", +"// End" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.5: Temperature_rise.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clear;\n", +"clc;\n", +"disp('Example 2.5');\n", +"// Given values\n", +"del_P = 154.45; // pressure difference across the die, [MN/m^2]\n", +"rho = 11360; // Density of the lead, [kg/m^3]\n", +"c = 130; // specific heat capacity of the lead, [J/kg*K]\n", +"// solution\n", +"// since there is no cooling and no externel work is done, so energy balane becomes\n", +"// P1*V1+U1=P2*V2+U2 ,so\n", +"// del_U=U2-U1=P1*V1-P2*V2\n", +"// also, for temperature rise, del_U=m*c*t, where, m is mass; c is specific heat capacity; and t is temperature rise\n", +"// Also given that lead is incompressible, so V1=V2=V and assuming one m^3 of lead\n", +"// using above equations\n", +"t = del_P/(rho*c)*10^6 ;// temperature rise [C]\n", +"mprintf('\n The temperature rise of the lead is = %f C\n',t);\n", +"// End" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.6: Area_velocity_and_power.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clear;\n", +"clc;\n", +"disp('Example 2.6');\n", +"// Given values\n", +"m_dot = 4.5; // mass flow rate of air, [kg/s]\n", +"Q = -40; // Heat transfer loss, [kJ/kg]\n", +"del_h = -200; // specific enthalpy reduce, [kJ/kg]\n", +"C1 = 90; // inlet velocity, [m/s]\n", +"v1 = .85; // inlet specific volume, [m^3/kg]\n", +"v2 = 1.45; // exit specific volume, [m^3/kg]\n", +"A2 = .038; // exit area of turbine, [m^2]\n", +"// solution\n", +"// part (a)\n", +"// At inlet, by equation[4], m_dot=A1*C1/v1\n", +"A1 = m_dot*v1/C1;//inlet area, [m^2]\n", +"mprintf('\n (a) The inlet area is, A1 = %f m^2 \n',A1);\n", +"// part (b), \n", +"// At outlet, since mass flow rate is same, so m_dot=A2*C2/v2, hence\n", +"C2 = m_dot*v2/A2; // Exit velocity,[m/s]\n", +"mprintf('\n (b) The exit velocity is, C2 = %f m/s \n',C2);\n", +"// part (c)\n", +"// using steady flow equation, h1+C1^2/2+Q=h2+C2^2/2+W\n", +"W = -del_h+(C1^2/2-C2^2/2)*10^-3+Q; // [kJ/kg]\n", +"// Hence power developed is\n", +"P = W*m_dot;// [kW]\n", +"mprintf('\n (c) The power developed by the turbine system is = %f kW \n',P);\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 +} |