diff options
Diffstat (limited to 'Mechanical_Engineering_Thermodynamics_by_D_A_Mooney/11-Properties_of_Gases.ipynb')
-rw-r--r-- | Mechanical_Engineering_Thermodynamics_by_D_A_Mooney/11-Properties_of_Gases.ipynb | 233 |
1 files changed, 233 insertions, 0 deletions
diff --git a/Mechanical_Engineering_Thermodynamics_by_D_A_Mooney/11-Properties_of_Gases.ipynb b/Mechanical_Engineering_Thermodynamics_by_D_A_Mooney/11-Properties_of_Gases.ipynb new file mode 100644 index 0000000..3dac179 --- /dev/null +++ b/Mechanical_Engineering_Thermodynamics_by_D_A_Mooney/11-Properties_of_Gases.ipynb @@ -0,0 +1,233 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 11: Properties of Gases" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.1: example_1.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"//initialization of varaibles\n", +"P1=15 //psia\n", +"T1=80+460 //R\n", +"dm=3 //lb\n", +"T2=75+460 //R\n", +"P2=25 //psia\n", +"//calculations\n", +"mratio=P1*T2/(P2*T1)\n", +"m2=dm/(1-mratio)\n", +"V2=m2*55.16*T2/(P2*144)\n", +"//results\n", +"printf('Volume of the apparatus = %.1f cu ft',V2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.2: example_2.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"//initialization of varaibles\n", +"R=48.3 //ft lb/lb R\n", +"k=1.4\n", +"//calculations\n", +"dc=R/778\n", +"cp=k*dc/(k-1)\n", +"cv=cp/k\n", +"//results\n", +"printf('Specific heat at constant volume = %.3f B/lb R',cv)\n", +"printf('Specific heat at constant pressure = %.3f B/lb R',cp)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.4: example_4.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"//initialization of varaibles\n", +"P1=100 //psia\n", +"P2=10 //psia\n", +"T1=140 +460 //R\n", +"g=1.4\n", +"cp=0.248\n", +"//calculations\n", +"dh=g*55.16*T1*((P2/P1)^((g-1)/g) -1)/(g-1)\n", +"T2=T1*(P2/P1)^((g-1)/g)\n", +"dh2=cp*(T2-T1)\n", +"//results\n", +"printf('In method 1, Enthalpy = %d Btu/lb',dh*0.01286)\n", +"printf('\n In method 2, Enthalpy = %.1f ft lb/lb',dh2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.5_a: example_5.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"//initialization of varaibles\n", +"P1=100 //psia\n", +"T1=2000+460 //R\n", +"P2=15 //psia\n", +"g=1.4\n", +"cp=0.24\n", +"//calculations\n", +"v1=53.34*T1/(P1*144)\n", +"v2=53.34*T1*(P1/P2)^(1/g) /(P1*144)\n", +"T2=T1*P2*v2/(P1*v1)\n", +"dh=cp*(T2-T1)\n", +"dv=v2-v1\n", +"//results\n", +"printf('Change in enthalpy = %d B/lb',dh)\n", +"printf('\n Specific volume change = %.1f cu ft/lb',dv)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.5_b: example_6.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"//initialization of varaibles\n", +"P1=100 //psia\n", +"T1=2000+460 //R\n", +"P2=15 //psia\n", +"g=1.4\n", +"cp=0.276\n", +"cv=0.207\n", +"T2=1520 //R\n", +"//calculations\n", +"k=cp/cv\n", +"v1=53.34*T1/(P1*144)\n", +"v2=v1*(P1/P2)^(1/k)\n", +"dh=cp*(T2-T1)\n", +"dv=v2-v1\n", +"//results\n", +"printf('Enthalpy change = %d B/lb',dh)\n", +"printf('\n Volume change = %.1f cu t/lb',dv)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.5_c: example_7.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"//initialization of varaibles\n", +"P1=100 //psia\n", +"T1=2000+460 //R\n", +"P2=15 //psia\n", +"g=1.4\n", +"cp=0.276\n", +"cv=0.207\n", +"T2=1520 //R\n", +"//calculations\n", +"h1=634.4\n", +"pr1=407.3\n", +"pr2=pr1*P2/P1\n", +"disp('From table 1,')\n", +"T2=1535 //R\n", +"h2=378.44\n", +"dh=h2-h1\n", +"v2=53.34*T2/(P2*144)\n", +"dv=v2-v1\n", +"//results\n", +"printf('Enthalpy change = %.2f B/lb',dh)\n", +"printf('\n Volume change = %.1f cu ft/lb',dv)" + ] + } +], +"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 +} |