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 /Heat_And_Thermodynamics_by_A_Manna | |
parent | abb52650288b08a680335531742a7126ad0fb846 (diff) | |
parent | 476705d693c7122d34f9b049fa79b935405c9b49 (diff) | |
download | all-scilab-tbc-books-ipynb-06b09e7d29d252fb2f5a056eeb8bd1264ff6a333.tar.gz all-scilab-tbc-books-ipynb-06b09e7d29d252fb2f5a056eeb8bd1264ff6a333.tar.bz2 all-scilab-tbc-books-ipynb-06b09e7d29d252fb2f5a056eeb8bd1264ff6a333.zip |
Initial commit
Diffstat (limited to 'Heat_And_Thermodynamics_by_A_Manna')
12 files changed, 4873 insertions, 0 deletions
diff --git a/Heat_And_Thermodynamics_by_A_Manna/10-Thermodynamic_relations.ipynb b/Heat_And_Thermodynamics_by_A_Manna/10-Thermodynamic_relations.ipynb new file mode 100644 index 0000000..920e6d9 --- /dev/null +++ b/Heat_And_Thermodynamics_by_A_Manna/10-Thermodynamic_relations.ipynb @@ -0,0 +1,366 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 10: Thermodynamic relations" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 10.10: The_change_in_melting_point.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t=353;//temperature in K\n", +"p=76*13.6*981;//pressure in dynes/sq.cm\n", +"v=0.146;//specific volume in cc/kg\n", +"l=35.6;//latent heat of fusion in cal/gm\n", +"j=4.18*10^7;//joules constant in ergs/cal\n", +"\n", +"//CALCULATIONS\n", +"dt=t*p*v/(l*j);//change in melting point per atmosphere\n", +"\n", +"//OUTPUT\n", +"mprintf('the rate of change in melting point is %3.3f per atmosphere',dt)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 10.11: The_change_in_freezing_point_of_water.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"l=79.6*4.18*10^7;//latent heat of water in ergs/gm\n", +"t=273.16;//temperature of water in K\n", +"v1=1.0001;//specific volume of water at 0deg.C in cc\n", +"v2=1.0908;//specific volume of ice at 0deg.C in cc\n", +"p=1.013*10^6;//pressure of atmosphere in dyne/sq.cm\n", +"\n", +"//CALCULATIONS\n", +"dt=t*(v1-v2)*p/l;//change in freezing point of water in deg.C\n", +"\n", +"//OUTPUT\n", +"mprintf('change inn freezing point of water is %3.4f deg.C',dt)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 10.1: The_latent_heat_of_fusion.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t=289.6;//temperature in K\n", +"dt=0.0244;//raise in temperature in deg.C\n", +"v1=0.00095;//volume occupied in liquid state in litres\n", +"v2=0.00079;//volume occupied in solid state in litres\n", +"\n", +"//CALCULATIONS\n", +"l=t*(v1-v2)/dt;//latent heat of fusion in lit.atm\n", +"\n", +"//OUTPUT\n", +"mprintf('the latent heat of fusion is %3.2f lit.atm',l)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 10.2: The_value_of_specific_heat.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t=295;//temperature of water in K\n", +"dp=10^6;//cahnge in pressure in dyne/sq.cm\n", +"j=4.2*10^7;//joules constant in ergs/cal\n", +"\n", +"//CALCULATIONS\n", +"dc=-t*10^-5*dp/j;//change in specific heat\n", +"\n", +"//OUTPUT\n", +"mprintf('the change in specific heat is %3.7f cal/degree',dc)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 10.3: The_specific_heat_of_copper.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"cp=0.0909;//specific heat at constant pressure in cal/degree\n", +"t=273;//temperature in K\n", +"v=0.112;//specific volume in lit/deg.C\n", +"a=5.01*10^(-6);//coefficient of linear expansion\n", +"k=8*10^-7;//compressibility of copper in per atoms\n", +"\n", +"//CALCULATIONS\n", +"cv=cp+(9*a^2*v*t*0.024142*10^3/k);//specific heat at constant volume in cal/deg.C\n", +"\n", +"mprintf('specific heat at constant volume is %3.2f cal/deg.C',cv)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 10.5: The_latent_heat_of_fusion.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t=289.6;//temperature in K\n", +"dt=0.0244;//raise in temperature in deg.C\n", +"v1=0.00095;//volume occupied in liquid state in litres\n", +"v2=0.00079;//volume occupied in solid state in litres\n", +"\n", +"//CALCULATIONS\n", +"l=t*(v1-v2)/dt;//latent heat of fusion in lit.atm\n", +"\n", +"//OUTPUT\n", +"mprintf('the latent heat of fusion is %3.2f lit.atm',l)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 10.6: The_rate_of_change_of_saturation_pressure.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"l=539;//latent heat of water at 100deg.C in cal\n", +"j=4.2*10^7;//joules constant in ergs/cal\n", +"t=373;//temperature of water in K\n", +"v2=1670;//volume of steam formed in cc\n", +"v1=1;//intial volume in cc\n", +"g=981;//acceleration due to gravity in cm/sec^2\n", +"d=13.6;//specific gravity of hg\n", +"\n", +"//CALCULATIONS\n", +"dp=l*j/(t*(v2-v1)*g*d);//rate of change of saturation pressure in cm of mercury\n", +"\n", +"//OUTPUT\n", +"mprintf('the rate of change of saturation pressure is %3.2f cm of hg',dp)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 10.7: The_volume_of_gram_of_steam.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"p1=77.371;//pressure at 100.5deg.C in cm of hg\n", +"p2=74.650;//pressure at 99.5deg.C in cm of hg\n", +"g=981;//universal gas constant in cm/sec^2\n", +"d=13.6;//specific gravity\n", +"l=537;//latent heat of vapourisation in cal/gm\n", +"t=373;//temperature of water in K\n", +"j=4.2*10^7;//joules constant in ergs/cal\n", +"v1=1;//intial volume in cc\n", +"\n", +"//CALCULATIONS\n", +"v2=v1+(l*j/(t*(p1-p2)*g*d));//volume of gram of steam at 100deg.C in cc\n", +"\n", +"//OUTPUT\n", +"mprintf('volume of gram of steam at 100deg.C is %3.2f cc',v2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 10.8: The_specific_volume.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t=350;//boiling point temperature in K\n", +"l=46;//latent heat of vapourisation in cal/gm\n", +"v1=1/1.6;//intial volume in cc\n", +"dp=2.3;//change in pressure with temperature in cm of hg/deg.C\n", +"d=13.6;//specific gravity of mercury\n", +"g=981;//acceleration due to gravity in cm/sec^2\n", +"j=4.2*10^7;//joukes constant in ergs/cal\n", +"\n", +"//CALCULTIONS\n", +"v2=v1+(l*j)/(t*dp*d*g);//specific volume in cc\n", +"\n", +"//OUTPUT\n", +"mprintf('specific volume of vapour of carbon is %3.3f cc',v2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 10.9: The_change_in_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"l=536;//latent heat of vapourisation in cal/gm\n", +"v1=1;//volume of 1 gm of water in cc\n", +"v2=1600;//volume of steam in cc\n", +"t=373;//boiling point of water in K\n", +"p=1;//pressure in cm of hg\n", +"d=13.6;//specific gravity of mercury\n", +"g=981;//gravitational constant in cm/sec^2s/cal\n", +"j=4.2*10^7;//joules constant in erg/cal\n", +"\n", +"//CALCULATIONS\n", +"dt=(t*(v2-v1)*d*g)/(l*j);//change in temperature in deg.C\n", +"\n", +"//OUTPUT\n", +"mprintf('change in temperature is %3.2f deg.C',dt)" + ] + } +], +"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 +} diff --git a/Heat_And_Thermodynamics_by_A_Manna/11-Conduction_of_heat.ipynb b/Heat_And_Thermodynamics_by_A_Manna/11-Conduction_of_heat.ipynb new file mode 100644 index 0000000..cc6100f --- /dev/null +++ b/Heat_And_Thermodynamics_by_A_Manna/11-Conduction_of_heat.ipynb @@ -0,0 +1,376 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 11: Conduction of heat" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.10: The_distance.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t1=15;//temperature of the one end of the slab in deg.C\n", +"t2=45;//temperature of the other end of the slab in deg.C\n", +"k=0.3;//thermal conductivity in cgs unit\n", +"d=7;//density of the material in gm/cc\n", +"cp=1;//specific heat of the material in kj/kg.K\n", +"t=5*3600;//time in sec\n", +"dt=1/10;//thermometer reading in deg.C\n", +"\n", +"//CALCULATIONS\n", +"b=(3.14*d*cp/(t*k))^(0.5);\n", +"x=(log((t2-t1)/dt))/b;//distance from which temparature variation can be detected in cm\n", +"\n", +"//OUTPUT\n", +"mprintf('the distance from which temparature variation can be detected is %3.1f cm',x)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.1: The_amount_of_heat_conducted.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"k=0.12;//thermal conductivity in cgs unit\n", +"t1=200;//temperature at one side in deg.C\n", +"t2=50;//temperature at other side in deg.C\n", +"t=3600;//time in sec\n", +"a=1;//area in sq.cm\n", +"t3=3;//thickness of the plate in cm\n", +"\n", +"//CALCULATIONS\n", +"q=k*a*(t1-t2)*t/t3;//amount of heat conducted in cal\n", +"\n", +"//OUTPUT\n", +"mprintf('the amount of heat conducted is %3.2f cal',q)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.2: The_rate_of_flow_of_water.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"k=0.9;//thermal conductivity in cgs unit\n", +"a=10;//area of the copper bar in sq.cm\n", +"t1=100;//hot side temperature in deg.C\n", +"t2=20;//cool side temperature in deg.C\n", +"d=25;//thickness of the bar in cm\n", +"t3=14;//temperature of water when entering in deg.C\n", +"\n", +"//CALCULATIONS\n", +"m=k*a*(t1-t2)/(d*(t2-t3));//rate flow of water in gm/sec\n", +"\n", +"//OUTPUT\n", +"mprintf('rate flow of water is %3.2f gm/sec',m)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.3: The_thermal_conductivity_of_cork.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"i=1.18;//current in amperes\n", +"e=20;//potential difference across its ends in volts\n", +"j=4.2;//joules constant in joule/cal\n", +"a=2*10^4;//area of the slab in sq.cm\n", +"t=5;//thickness of the plate in cm\n", +"t1=12.5;//temperature at hot side in K\n", +"t2=0;//temperature at cold side in k\n", +"\n", +"//CALCULATIONS\n", +"k=e*i*t/(j*a*(t1-t2));//thermal conductivity in cgs unit\n", +"\n", +"//OUTPUT\n", +"mprintf('thermal conductivity of slab is %3.5f cgs unit',k)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.4: The_thermal_conductivity_of_glass.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"l=30;//length of the tube in cm\n", +"t=100;//temperature at outside in deg.C\n", +"t1=40;//tempertaure of water when leaving tube in deg.C\n", +"t2=20;//temperature of water when entering tube in deg.C\n", +"m=165/60;//mass flow rete of water in cc/sec\n", +"r1=6;//internal radii in mm\n", +"r2=8;//external radii in mm\n", +"\n", +"//CALCULATIONS\n", +"k=m*(t1-t2)*log(r2/r1)/(2*3.14*l*(t-((t1+t2)/2)));//thermal conductivity in cgs unit\n", +"\n", +"//OUTPUT\n", +"mprintf('thermal conductivity of the tube is %3.4f cgs unit',k)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.5: The_thermal_conductivity_of_nickel.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"l1=1.9;//length of the first bar in cm\n", +"l2=5;//length of the second bar in cm\n", +"k2=0.92;//thermal conductivity in cgs unit\n", +"\n", +"//CALCULATIONS\n", +"k1=k2*(l1/l2)^2;//thermal conductivity if first bar in cgs unit\n", +"\n", +"//OUTPUT\n", +"mprintf('thermal conductivity of first bar is %3.3f cgs unit',k1)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.6: The_temperature_of_the_welded_interface.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"k1=0.92;//thermal conductivity of copper in cgs unit\n", +"k2=0.5;//thermal conductivity of alluminium in cgs unit\n", +"t1=100;//temperature of copper in deg.C\n", +"t2=0;//temperature of alluminium in deg.C\n", +"\n", +"//CALCULATIONS\n", +"t=k1*t1/(k1+k2);//welded teperature in deg.C\n", +"\n", +"//OUTPUT\n", +"mprintf('welded temperature is %3.2f deg.C',t)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.7: The_conductivity_of_rubber.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"w=23;//thermal capacity of calorimeter in cal\n", +"m=440;//mass of water in gm\n", +"l=14.6;//lenght of the rubber tube in cm\n", +"dt=0.019;//rate of change in temperature in deg.C/sec\n", +"t=100;//temperature of steam in deg.C\n", +"t1=22;//temperature of the water in deg.C\n", +"t2=t1;//temperature of calorimeter in deg.C\n", +"r1=1;//external radii in cm\n", +"r2=0.75;//internal radii in cm\n", +"\n", +"//CALCULATIONS\n", +"k=(w+m)*dt*log(r1/r2)/(2*3.14*l*(t-((t1+t2)/2)));//thermal conductivity in cgs unit\n", +"\n", +"//OUTPUT\n", +"mprintf('thermal cnductivity of rubber tube is %3.5f cgs unit',k)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.8: Heat_lost_per_hour.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"ti=18;//inside temperature in deg.C\n", +"to=4;//outside temperature in deg.C\n", +"k1=0.008;//thermal conductivity of stone in cgs unit\n", +"k2=0.12;//thermal conductivity of steel in cgs unit\n", +"t=3600;//time in sec\n", +"t1=25;//thickness of the stone in cm\n", +"t2=2;//thickness of the steel in cm\n", +"a=10^4;//area of the cottage in sq.cm\n", +"\n", +"//CALCULATIONS\n", +"q1=k1*a*(ti-to)*t/(t1);//heat lost by stone per hour in cal\n", +"q2=k2*a*(ti-to)*t/t2;//heat lost by steel per hour in cal\n", +"\n", +"//OUTPUT\n", +"mprintf('heat lost by stone is %3.2f cal \n heat lost by steel is %3.2f cal',q1,q2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.9: The_temperature_of_the_surface.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"l1=4;//length of the slab1 in cm\n", +"l2=2;//length of the slab2 in cm\n", +"k1=0.5;//thermal conductivity in cgs unit\n", +"k2=0.36;//thermal conductivity in cgs unit\n", +"t1=100;//temperature of the slab1 in deg.C\n", +"t2=0;//temperature of the slab2 in deg.C\n", +"\n", +"//CALCULATIONS\n", +"t=k1*l2*t1/((k2*l1)+(k1*l2));//temperature of the commaon surface in deg.C\n", +"\n", +"//OUTPUT\n", +"mprintf('the temperature of the common surface is %3.0f deg.C',t)" + ] + } +], +"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 +} diff --git a/Heat_And_Thermodynamics_by_A_Manna/12-Radiation.ipynb b/Heat_And_Thermodynamics_by_A_Manna/12-Radiation.ipynb new file mode 100644 index 0000000..5f91908 --- /dev/null +++ b/Heat_And_Thermodynamics_by_A_Manna/12-Radiation.ipynb @@ -0,0 +1,325 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 12: Radiation" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 12.1: The_ratio_of_rates_at_which_heat_lost.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t1=300;//temperature of the surroundings in K\n", +"t2=900;//temperature of the hot body p in K\n", +"t3=500;//temperature of the hot body q in K\n", +"a=5.67*10^-8;//stefan boltzmann constant in W/m^2.K^4\n", +"\n", +"//CALCULATIONS\n", +"q1=a*(t2^4-t1^4);//heat lost from hot body p in w/m^2\n", +"q2=a*(t3^4-t1^4);//heat lost from hot body q in w/m^2\n", +"q=q1/q2;//ratio of heat lost from two substances\n", +"\n", +"//OUTPUT\n", +"mprintf('ratio of heat lost from two substances is %3.2f',q)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 12.2: The_stefan_constant.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t1=573;//temperature of the hot side in K\n", +"t2=273;//temperature of the coll side in K\n", +"m=82;//mass of the black body in gm\n", +"cp=0.1;//specific heat of the black body kj/kg.K\n", +"dt=0.35;//ice melting at a rate of temperature in deg.C/sec\n", +"a=8;//area of black body in sq.cm\n", +"\n", +"//CALCULATIONS\n", +"s=m*cp*dt/(a*(t1^4-t2^4));//boltzmann constant in cal/sq.cm/sec/deg^4\n", +"\n", +"//OUTPUT\n", +"mprintf('boltzmann constant is %3.13f cal/sq.cm/sec/deg^4',s)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 12.3: The_ratio_of_intensities.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"r1=60;//distance of first black body in cm\n", +"r2=30;//distance of second black body in cm\n", +"t1=873;//temperature of first black body in K\n", +"t2=573;//temperature of the second black body in K\n", +"\n", +"//CALCULATIONS\n", +"i=(t2^4/t1^4)*(r1^2/r2^2);//ratio of intensity of radition\n", +"\n", +"//OUTPUT\n", +"mprintf('ratio of intensity of radition is %3.2f',i)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 12.4: The_heat_radiated_per_second.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t1=1373;//temperature of the sphere in K\n", +"t2=283;//temperature of the black body in K\n", +"r=4.17*10^5;//rate of heat radiate in ergs/sq.cm/sec\n", +"a=4*3.14*(6^2);//surface area of the sphere in sq.cm\n", +"\n", +"//CALCULATIONS\n", +"tr=r*a*(t1^4/t2^4)*(2.39005736*10^(-8));//total heat radiated in cal/sec\n", +"\n", +"//OUTPUT\n", +"mprintf('total heat radiated is %3.2f cal/sec',tr)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 12.5: The_time_for_sun_rays_to_fall.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"h=2*3.14*100;//heat received by the lens per min in cal\n", +"m=25;//mass of the ice in gm\n", +"l=80;//latent heat of ice in cal/gm\n", +"\n", +"//CALCULATIONS\n", +"t=m*l/h;//time for which the sun rays falls in min\n", +"\n", +"//OUTPUT\n", +"mprintf('time for which the sun rays falls is %3.2f min',t)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 12.6: The_amount_of_heat_reeived.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"d=0.35;//diameter of the mirror in m\n", +"t=5;//time in min\n", +"T=16;//temperature of water found to be in deg.C\n", +"m=60;//mass of water in gm\n", +"mc=30;//mass of calorimeter in gm\n", +"cp=0.1;//specific heat of copper in cal/gm/deg.C\n", +"\n", +"//CALCULATIONS\n", +"q=(m+cp*mc)*T*4/(5*3.14*d^2);//amount of heat received by earth in cal\n", +"\n", +"//OUTPUT\n", +"mprintf('amount of heat received by earth is %3.2f cal',q)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 12.7: Rate_of_heat_lost.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"r1=5;//radius of first sphere in cm\n", +"r2=10;//radius of second sphere in cm\n", +"t1=700;//temperature of the first sphere in K\n", +"t2=500;//temperature of the second sphere in K\n", +"t=300;//temperature of the enclousure in K\n", +"\n", +"//CALCULATIONS1\n", +"dc=(r2/r1)*(t1^4-t^4)/(t2^4-t^4);//ratio of c1/c2\n", +"r=r1^3*dc/r2^3;//rate of heat loss\n", +"\n", +"//OUTPUT\n", +"mprintf('rate of loss of heat is %3.2f',r)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 12.8: The_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t1=600;//temperature of the black body in K\n", +"t0=300;//temperature of the surroundings in K\n", +"d=6;//deflections in galvanometer\n", +"d1=400;//deflection in divisions\n", +"\n", +"//CALCULATIONS\n", +"dt=(d1/d)*(t1^4-t0^4);//change of temperature\n", +"t2=(dt+t0^4)^(1/4);//end temperature in K\n", +"\n", +"//OUTPUT\n", +"mprintf('end temperature of the temperature is %3.2f K',t2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 12.9: The_temperature_of_the_regel.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"n=17000;//luminosity of star compared to sun\n", +"t=6000;//temperature of the sun in K\n", +"\n", +"//CALCULATIONS\n", +"t1=(n*t^4)^(1/4);//temperature of the star in K\n", +"\n", +"//OUTPUT\n", +"mprintf('the temperature of the star is %3.2f K',t1)" + ] + } +], +"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 +} diff --git a/Heat_And_Thermodynamics_by_A_Manna/13-Introduction_to_statistical_thermodynamics.ipynb b/Heat_And_Thermodynamics_by_A_Manna/13-Introduction_to_statistical_thermodynamics.ipynb new file mode 100644 index 0000000..7287e76 --- /dev/null +++ b/Heat_And_Thermodynamics_by_A_Manna/13-Introduction_to_statistical_thermodynamics.ipynb @@ -0,0 +1,159 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 13: Introduction to statistical thermodynamics" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 13.1: The_probability.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"p1=1/6;//probability for the first throw gives 6\n", +"p2=1/6;//probability for the first throw gives 5\n", +"n=2;//the no.of dice are two\n", +"\n", +"//CALCULATIONS\n", +"p=p1*p2*n;//the required probability is\n", +"\n", +"//OUTPUT\n", +"mprintf('the required probability is %3.2f',p)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 13.2: The_probability_of_drawing_four_aces.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"p1=4/52;//the probability for getting ace in first draw is\n", +"p2=3/51;//the probability for getting ace in second draw is\n", +"p3=2/50;//the probability for getting ace in third draw is\n", +"p4=1/49;//the probability for getting ace in fourth draw is\n", +"\n", +"//CALCULATIONS\n", +"p=p1*p2*p3*p4;//total probability is\n", +"\n", +"//OUTPUT\n", +"mprintf('total probability is %3.7f',p)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 13.3: The_probability_of_distributio.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"n=12;//no.of particles\n", +"n1=8;\n", +"n2=4;\n", +"\n", +"//CALCULATIONS\n", +"p=n*(n-1)*(n-2)*(n-3)/(n2*(n2-1)*(n2-2)*(2^n));//probability of distribution (8,4)\n", +"\n", +"//OUTPUT\n", +"mprintf('probability of distribution (8,4) is %3.5f',p)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 13.4: The_probability.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"m=32;//mass of the oxygen molecule in gm\n", +"n=1.67*10^-27;//mass of one electron\n", +"k=1.38*10^-23;//boltzzmann constant in ergs/cal\n", +"t=200;//temperature of the oxygen in K\n", +"c=(100+101)/2;//average speed of the oxygen molecule in m/s\n", +"\n", +"//CALCULATIONS\n", +"a=m*n/(2*3.14*k*t);\n", +"p=4*3.14*(a^(3/2))*(c^2)*(2.303^(-a));//probability that the oxygen speed is lies between in m/sec\n", +"\n", +"//OUTPUT\n", +"mprintf('probability that the oxygen speed is lies between is %3.16f m/sec',p)" + ] + } +], +"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 +} diff --git a/Heat_And_Thermodynamics_by_A_Manna/2-Thermometry.ipynb b/Heat_And_Thermodynamics_by_A_Manna/2-Thermometry.ipynb new file mode 100644 index 0000000..c6b0b12 --- /dev/null +++ b/Heat_And_Thermodynamics_by_A_Manna/2-Thermometry.ipynb @@ -0,0 +1,204 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 2: Thermometry" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.1: Temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"li=1.23;//length of melting ice in mm\n", +"lf=18.56;//length of melting ice reading in pressure of 74.24cm of mercury in mm\n", +"l=10.75;//length of melting ice at which temperature to be calculated\n", +"mp=0;//melting point in deg.C\n", +"T=50;//temperature of melting ice at which length to be calculated in deg.C\n", +"//boiling point of water changes by 1 deg.C for change of pressure of 27mm of mercury\n", +"\n", +"//CALCULATIONS\n", +"sp=100-(76-74.24)/(2.7);//76cm of mercury steam point is 100 deg.C so at 74.24cm of mercury the steam point in deg.C\n", +"t=(l-li)*(sp-mp)/(lf-li);//temperature at 10.75mm of melting ice in deg.C\n", +"lt=((T*(lf-li))/(sp-mp))+li;//length of ice at 50 deg.C\n", +"\n", +"//OUTPUT\n", +"mprintf('the temperature of melting ice at 10.75mm of hg is %3.2f deg.C \n the length of ice corresponding to 50 deg.C is %3.2f mm',t,lt)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.2: Temperature_of_the_liquid_air.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"p1=23.5;//pressure when immersed in liquid air in cm\n", +"p2=75;//pressure when immersed in ice in cm\n", +"p3=102.4;//pressure when immersed in steam in cm\n", +"T=100;//boiling point of temperature in deg.C\n", +"\n", +"//CALCULATIONS\n", +"t=(p1-p2)*T/(p3-p2);//temperature of the liquid air in deg.C\n", +"\n", +"//OUTPUT\n", +"mprintf('the temperature of liquid of air is %3.2f deg.C',t)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.3: Height_of_the_barometer.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t1=283;//temperature of bulb when pressure is h-2cm of hg in k\n", +"t2=546;//temperature of bulb when pressure is h-22cm of hg in k\n", +"h1=2;//differnce of mercury level at 283k in cm\n", +"h2=22;//differnce of mercury level at 546k in cm\n", +"//let h is the barometer height,then h-2cm at 283k and h-22 at 546k\n", +"\n", +"//CALCULATIONS\n", +"h=((h2*t1)+(h1*t2))/(t2-t1);//height of the barometer in cm\n", +"\n", +"//OUTPUT\n", +"mprintf('height of the barometer is %3.2f cm',h)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.4: Temperature_of_the_furnace.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"p0=76;//pressure at 0 deg.C in cm of hg\n", +"p1=228;//pressure (76+152) at T deg.C in cm of hg\n", +"t0=273;//temperature of bulb in K\n", +"\n", +"//CALCULATIONS\n", +"T=p1*t0/p0;//temperature at 228 cm of hg pressure in K\n", +"\n", +"//OUTPUT\n", +"mprintf('the temperature of bulb is %3.2f K',T)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.5: The_temperature_of_the_bath.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t1=0;//temperature in deg.C\n", +"t2=100;//temperature in deg.C\n", +"t3=208;//temperature in deg.C\n", +"r1=3.5;//resistance in ohms\n", +"r2=5.2;//resistance in ohms\n", +"r3=6.9;//resistance in ohms\n", +"r4=9.4;//resistance in ohms\n", +"\n", +"//CALCULATIONS\n", +"t4=(r3-r1)*100/(r2-r1);//temperature in deg.C\n", +"d=(t3-t4)/(2.08*1.08);//deflection\n", +"t5=(r4-r1)*100/(r2-r1);//temperature in deg.C\n", +"t6=(d*(((t5/100)^2)-t5/100))+t5;//temperature in deg.C\n", +"t7=(d*(((t6/100)^2)-t6/100))+t5;//temperature in deg.C\n", +"t8=(d*(((t7/100)^2)-t7/100))+t5;//temperature in deg.C\n", +"t9=(d*(((t8/100)^2)-t8/100))+t5;//temperature in deg.C\n", +"\n", +"//CALCULATIONS\n", +"mprintf('the temperature of the bath is %3.2f deg.C',t9)" + ] + } +], +"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 +} diff --git a/Heat_And_Thermodynamics_by_A_Manna/3-The_mechanical_equivalent_of_heat.ipynb b/Heat_And_Thermodynamics_by_A_Manna/3-The_mechanical_equivalent_of_heat.ipynb new file mode 100644 index 0000000..ecab644 --- /dev/null +++ b/Heat_And_Thermodynamics_by_A_Manna/3-The_mechanical_equivalent_of_heat.ipynb @@ -0,0 +1,803 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 3: The mechanical equivalent of heat" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.10: The_rise_in_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT DATA \n", +"cp=0.03;//specific heat of lead in kj/kg.k\n", +"v=10000;//initial velocity of bullet in cm/sec\n", +"J=4.2*10^7;//joules constant in ergs/cal\n", +"\n", +"//CALCULATIONS\n", +"//let mass of the bullet in gm\n", +"ke=(v^2)/2;//kinetic energy of the bullet per unit mass in (cm/sec)^2\n", +"//T is the rise in temperature,then heat produced is m*cp*T\n", +"//95% of kinetic energy is converted to heat\n", +"T=ke*95/(cp*J*100);//rise in temperature in deg.C\n", +"\n", +"mprintf('the rise in temperature is %3.1f deg.C',T)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.11: The_difference_in_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT DATA \n", +"h=5000;//height of the niagara falls in cm\n", +"J=4.2*10^7;//joules constant in ergs per cal\n", +"g=981;//accelaration due to gravity in cm/sec^2\n", +"\n", +"//CALCULATIIONS\n", +"w=h*g;//work done per unit mass in ergs/gn\n", +"T=w/J;//rise in temperature in deg.C\n", +"\n", +"//OUTPUT\n", +"mprintf('the rise in temperature is %3.2f deg.C',T)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.12: The_value_of_J.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT DATA \n", +"//callender and barnes continous flow method\n", +"V1=3;//potential difference in v\n", +"V2=3.75;//potential differnce in v\n", +"i1=2;//current in amp\n", +"i2=2.5;//current in amp\n", +"T=2.7;//the rise in temperature of the water in deg.C\n", +"m1=30;//water flow rate at 3 volts in gm/min\n", +"m2=48;//water flow rate at 3.75volts in gm/min\n", +"s=1;//specific heat of the water kj/kg-K\n", +"\n", +"//CALCULATIONS\n", +"J=(V1*i1-V2*i2)/(s*T*(m1-m2)/60);//the mechanical equivalent in j/cal\n", +"\n", +"//OUTPUT\n", +"mprintf('the mechanical equivalent is %3.3f j/cal',J)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.13: The_rise_in_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT DATA \n", +"R=64*10^7;//mean radius of the earth in cm\n", +"cp=0.15;//specific heat of earth in kj/kg-K\n", +"J=4.2*10^7;//joules constant in erg/cal\n", +"\n", +"//CALCULATIONS\n", +"i=2/5*R^2;//moment of inertia of the earth per unit mass in joules\n", +"w=(2*3.14)/(24*60*60);//angular velocity of the earth in rad/sec\n", +"T=(i*w^2)/(2*J*cp);//rise in temperature in deg.C\n", +"\n", +"//OUTPUT\n", +"mprintf('the rise in the temperature is %3.1f deg,C',T)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.14: The_mechanical_equivalent_of_heat.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT DATA \n", +"cp=1.25;//specific heat of helium inkj/kg-K\n", +"v=1000;//volume of the gas in ml\n", +"w=0.1785;//mass of the gas at N.T.P in gm\n", +"p=76*13.6*981;//pressure of the gas at N.T.P in dynes\n", +"T=273;//temperature at N.T.P in K\n", +"\n", +"//CALCULATIONS\n", +"V=1000/w;//volume occupied by the 1gm of helium gas in cc\n", +"cv=cp/1.66;//specific heat at constant volume it is monatomuc gas kj/kg-K\n", +"r=p*V/T;//gas constant in cm^3.atm./K.mol\n", +"J=r/(cp-cv);//mechanical equivalent of heat in erg/cal\n", +"\n", +"//OUTPUT\n", +"mprintf('the mechanical equivalent of heat is %3.2f ergs/calories',J)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.15: The_mechanical_equivalent_of_heat.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT DATA \n", +"n=1/273;//coefficent of expaaansion of air\n", +"a=0.001293;//density of air in gm/cc\n", +"cp=0.2389;//specific heat at constant pressure in kj/kg.K\n", +"p=76*13.6*981;//pressure at 0 deg.C in dynes\n", +"\n", +"//CALCULATIONS\n", +"J=(p*n)/(a*(cp-(cp/1.405)));//mechanical equivalent of heat\n", +"\n", +"//OUTPUT\n", +"mprintf('mechanical equivalent of heat is %3.2f ergs/cal',J)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.16: The_value_of_J.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT DATA \n", +"//continous flow calorimeter\n", +"r=120/60;//rate of flow of water in gm/sec\n", +"T1=27.30;//temperature at initial in deg.C\n", +"T2=33.75;//temperature at final in deg.C\n", +"v=12.64;//potential drop in volts\n", +"s=1;//specific heat of water in kj/kg-K\n", +"i=4.35;//current through the heating element in amp\n", +"\n", +"//CALCULATIONS\n", +"J=(v*i)/(r*s*(T2-T1));//the mechanical equivalent of heat in joule/calorie\n", +"\n", +"//OUTPUT\n", +"mprintf('the mechanical equivalent of heat is %3.2f j/cal',J)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.17: the_value_of_J.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT DATA \n", +"cp=6.865;//molar specific heat of hydrogen at constant pressure in kj/kg-K\n", +"cv=4.880;//molar specific heat of hydrogen at constant volume in kj/kg-K\n", +"p=1.013*10^6;//atmospheric pressure in dynes/cm^2\n", +"v=22.4*10^3;//gram molar volume in ml\n", +"T=273;//temperature at N.T.P in kelvins\n", +"\n", +"//CALCULATIONS\n", +"J=(p*v)/(T*(cp-cv));//mechanical equivalent of heat\n", +"\n", +"//OUTPUT\n", +"mprintf('the mechanical equivalent of heat is %3.2f j/cal',J)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.18: The_value_of_J.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT DATA\n", +"v=1000;//volume of hydrogen in ml\n", +"t=273;//tempature of hydrogen in kelvin\n", +"p=760;//pressure of hydrogen in mm of hg\n", +"w=0.0896;//weigh of hydrogen in gm\n", +"cp=3.409;//specific heat of hydogen in kj/kg-K\n", +"cv=2.411;//specific heat of hydrogen in kj/kg-K\n", +"g=981;//accelaration due to gravity in cm/sec^2\n", +"a=13.6;//density of mercury in gm/cm^2\n", +"\n", +"//CALCULATIONS\n", +"J=(p*v*g*a)/(w*t*(cp-cv));//mechanical equivalent of heat in ergs/cals\n", +"//OUTPUT\n", +"printf('mechanical equivalent of heat is %3.2f ergs/calorie',J)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.19: The_specific_heat_at_constant_volume.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT DATA\n", +"cp=0.23;//specific heat at constant pressure in kj/kg-K\n", +"a=1.18;//density of air in gm/lit\n", +"J=4.2*10^7;//mechanical equivalent of heat in ergs/cal\n", +"t=300;//temperature of air in kelvin\n", +"p=73*13.6*981;//pressure of air in dynes\n", +"//cp-cv=(r/J)=pv/(tj)\n", +"\n", +"//CALCULATON\n", +"cv=cp-(p*1000/(a*t*J));//specific heat at constant volume in calories\n", +"\n", +"//OUTPUT\n", +"mprintf('the specific heat at constant volume is %3.5f calories',cv)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.1: Rise_in_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT DATA \n", +"m=20;//calorimeter of water equivalent in gm\n", +"n=1030;//weight of water in gm\n", +"p=2;//no.of paddles\n", +"a=10;//weight of each paddle in kg\n", +"s=80;//distance between paddles in m\n", +"g=980;//accelaration due to gravity in cm/sec^2\n", +"\n", +"//CALCULATIONS\n", +"E=(p*a*1000*g*s*100);//potential energy in dyne cm\n", +"T=(E)/(1050*4.18*10^7);//rise in temperature in deg.C\n", +"//if the rise in temp be T,then heat gained by the calorimeter and its contets is 1050T so J=(E)/(1050*T) where (j=4.18*10^7erg/cal)\n", +"\n", +"//OUTPUT\n", +"mprintf('the rise in temperature of water is %3.2f deg.C',T)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.20: The_height_from_which_it_falle.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t1=0;//temperature of water in deg.C\n", +"t2=0;//temperature of ice in deg.C\n", +"J=4.18*10^7;//the joules thomson coefficent in erg/cal\n", +"l=80;//latent heat og fusion kj/kg\n", +"g=981;//accelaration due to gravity in cm/sec^2\n", +" \n", +"//CALCULATIONS\n", +"h=l*J/(15*g);//height from which ice has fallen\n", +"//1/15 ice has been melted \n", +"\n", +"//OUTPUT\n", +"mprintf('the height from which ice has fallen is %3.2f cm',h)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.21: The_velocity_of_bullet.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT DATA\n", +"T=80;//temperature of bullet in deg.C\n", +"cp=0.03;//specific heat of lead in kj/kg-K\n", +"J=4.2;//mechanical equivalent of heat in j/cal\n", +"\n", +"//CALCULATIONS\n", +"//90 percent of kinetic energy is converted to heat \n", +"h=T*cp;//heat developed per unit mass in calorie\n", +"v=(J*10^7*h*2/0.9)^0.5;//velocity of bullet in cm/sec\n", +"\n", +"//OUTPUT\n", +"mprintf('the velocity of bullet is %3.2f cm/sec',v)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.22: The_rise_in_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc \n", +"clear\n", +"\n", +"//INPUT DATA\n", +"w=5.0;//weight of lead ball in lb\n", +"cp=0.032;//specific heat of lead in Btu/lbdeg.F\n", +"h=50;//height at which ball thrown in feets\n", +"v=20;//vertical speed in ft/sec\n", +"g=32;//accelararion due to gravity in ft/sec^2\n", +"\n", +"//CALCULATIONS\n", +"//half the kinetic energy is converted into heat after instant impact with ground\n", +"u=(v^2)+2*g*h\n", +"ke=(w/2*(u));//kinetic energy of the ball at ground\n", +"T=ke/(2*32*778*w*cp);//rise of temperature in deg.F\n", +"\n", +"//OUTPUT\n", +"mprintf('the rise in temperature is %3.2f deg.F',T)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.2: The_mechanical_equivalent_of_heat.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT DATA \n", +"cp=0.1;//specific heat of copper in kj/kg-K\n", +"w=120;//weight of copper calorimeter in gm\n", +"a=1400;//weight of paraffin oil in gm\n", +"cp1=0.6;//specific of parafin oil in kj/kg-K\n", +"b=10^8;//force to rotate the paddle in dynes\n", +"T=16;//rise in temperature in deg.C\n", +"n=900;//no.of revolutions stirred \n", +"pi=3.14;//value of pi\n", +"\n", +"//CALCULATIONS\n", +"c=2*pi*b;//work done by a rotating paddle per rotation in dyne cm per rotation\n", +"d=c*n;//total work done in dyne cm \n", +"hc=w*cp*16;//heat gained by calorimeter in calories\n", +"hp=a*cp1*16;//heat gaained by paraffin oil in calories \n", +"J=d/(hc+hp);//mecanical equivalent of heat in erg/cal\n", +"\n", +"//OUTPUT\n", +"mprintf('mecanical equivalent of heat is %3.0f erg/cal',J)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.3: The_mechanical_equivalent_of_heat.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT DATA \n", +"cp=0.12;//specific heat of iron in kj/kg-K\n", +"m=25;//mass of iron in lb\n", +"h=0.4;//horse power developed in 3 min\n", +"t=3;//time taken to develop the horse power in min\n", +"T=17;//raise in temp in deg.C\n", +"\n", +"//CALCULATIONS\n", +"w=h*33000*t;//total work done in ft-lb\n", +"H=m*cp*T;//aount of heat developed in B.Th.U\n", +"J=(w)/H;//the value of mechanical equivalent of heat\n", +"\n", +"//OUTPUT\n", +"mprintf('the mechanical equivalent of water is %3.1f ft-lb/B.Th.U',J)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.4: Kinetic_energy_of_each_block_and_Mean_rise_of_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT DATA \n", +"n=2;//no.of lead blocks\n", +"m=210;//mass of each lead block in gm\n", +"v=20000;//velocity of block relative to earth in cm/sec\n", +"J=4.2*10^7;//mechanical equivalent of heat in ergs/calorie\n", +"cp=0.03;//specific heat of lead in kj/kg-K\n", +"\n", +"//CALCULATIONS\n", +"E=(m*v^2)/2;//kinetic energy of each block in ergs\n", +"E2=n*E;//total kinetic energy in ergs\n", +"T=E2/(J*m*n*cp);//mean rise in temperature in T\n", +"\n", +"//OUTPUT\n", +"mprintf('the mean rise in temperature is %3.1f deg.C',T)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.5: Rise_of_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT DATA \n", +"h=150;//height froom which ball fallen in ft\n", +"cp=0.03;//specific heat of lead in kj/kg-K\n", +"J=778;//mechanical equivalent of heat in ft lb/B.Th.U\n", +"\n", +"//CALCULATIONS\n", +"//assume m be the mass of the lead\n", +"//work done in falling through 160 feet in ft-lb w=160*m\n", +"//heat absorbed by the ball in B.Th.U h=m*cp*T\n", +"//work done in falling is equal to heat absorbed by the ball\n", +"T=160/(J*cp)*(5/9);//the raise in temperature in T\n", +"\n", +"//OUTPUT\n", +"mprintf('the raise in temperature is %3.1f deg.C',T)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.6: The_rate_at_which_the_horse_worked.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT DATA \n", +"w=26.6;//work done one horse in to raise the temperature in lb\n", +"T1=32;//temperature at initial in deg.F\n", +"T2=212;//temperature at final in deg.F\n", +"t=2.5;//time to raise the tmperature in hrs\n", +"p=25;//percentage of heat lossed \n", +"\n", +"//CALCULATIONS\n", +"//let x ft-lb per min be the rate at which horse worked//total work done in ft-lb wt W=x*150\n", +"//amount of heat generated in lb deg.F H=W/778\n", +"//only 75% of heat is utillised\n", +"x=w*180*100*778/((100-p)*150);//the rate at which horse worked\n", +"\n", +"//OUTPUT\n", +"mprintf('the rate at which horse worked is %3.0f ft-lb wt/min',x)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.7: The_rise_in_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT DATA \n", +"l=100;//length of glass tube in cm\n", +"m=500;//mass of mercury in glass tube in gm\n", +"n=20;//number of times inverted i succession\n", +"cp=0.03;//specific heat of mercury in cal/gm/deg.C\n", +"J=4.2;//joule's equivalent in j/cal\n", +"g=981;//accelaration due to gravity in cm/s^2\n", +"\n", +"//CALCULATIONS\n", +"PE=m*g*l;//potential energy for each time in ergs\n", +"TE=PE*n;//total loss in ergs\n", +"T=TE/(m*cp*J*10^7);//rise in temperature in deg.C\n", +"//if T is the rise in temperature,then heat devoloped is m*cp*T\n", +"\n", +"//OUTPUT\n", +"mprintf('the rise in temperature is %3.2f deg.C',T)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.8: Calories_emitted_per_second.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT DATA \n", +"d=0.02;//diameter of the copper wire in cm\n", +"i=1;//current in amp\n", +"T=100;//maximum steady temperature in deg.C\n", +"r=2.1;//resistance of the wire in ohm cm\n", +"J=4.2;//mechanical equivalent of heat in j/cal\n", +"a=3.14*d^2/4;//area of the copper wire in sq.cm\n", +"a2=1;//area of the copper surface in sq.cm\n", +"\n", +"//CALCULATIONS \n", +"//we know that if r is the resistance of the wire through which current i flows,then the electrical energy spent =i^2*r j/sec\n", +"l=1/(2*3.14*d/2);//length corresponding to the area in cm\n", +"R=r*l/a;//resistance of the copper wirein ohm\n", +"w=R*a2^2;//work done in joule\n", +"h=w/J;//heat devoleped in cal\n", +"\n", +"//OUTPUT\n", +"mprintf('the heat developed is %3f calories',h)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.9: The_quantity_of_heat_produced_and_The_rise_in_temperature_of_water.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT DATA\n", +"h=10000;//vertical height of water fall in cm\n", +"v=5;//volume disharged per sec in litres\n", +"J=4.18;//joule's constant in j/cal\n", +"g=981;//accelaration due to gravity in cm/sec^2\n", +"\n", +"//CALCULATIONS\n", +"m=v*1000;//mass of water disharged per sec in gm\n", +"w=m*h*g;//work done in falling through 100m in erg\n", +"H=w/(J*10^7);//quantity of heat produced in cal\n", +"T=H/m;//rise in temperature in deg.C\n", +"\n", +"//OUTPUT\n", +"mprintf('the quantity of heat produced is %3f cal \n the rise in temperature is %3.2f deg.C',H,T)" + ] + } +], +"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 +} diff --git a/Heat_And_Thermodynamics_by_A_Manna/4-Kinetic_theory_of_gases.ipynb b/Heat_And_Thermodynamics_by_A_Manna/4-Kinetic_theory_of_gases.ipynb new file mode 100644 index 0000000..e109af6 --- /dev/null +++ b/Heat_And_Thermodynamics_by_A_Manna/4-Kinetic_theory_of_gases.ipynb @@ -0,0 +1,911 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 4: Kinetic theory of gases" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.10: The_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t1=273;//temperature of the hydrogen molecule at n.t.p in K\n", +"//rms value of hydrogen molecule is double to its rms value at n.t.p, so 3rt/m=4(3rt/m)\n", +"\n", +"//CALCULATIONS\n", +"t2=4*t1;//temperature of the hydrogen molecule in K\n", +"\n", +"//OUTPUT\n", +"mprintf('the temperature of the hydrogen molecule is %3f',t2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.11: The_RMS_velocity.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t1=273;//temperature of the hydrogen molecule in K\n", +"t2=373;//temperature of the hydrogen molecule in K\n", +"d=0.0000896;//density of the hydrogen molecule in gm/cc\n", +"p=76*13.6*981;//pressure of the hydrogen molecule in gm/cm/sec^2\n", +"\n", +"//CALCULATIONS\n", +"v0=(3*p/d)^(0.5);//rms velocity at 0deg.C\n", +"v100=v0*(t2/t1)^(0.5);//rms velocity at 100deg.C\n", +"\n", +"//OUTPUT\n", +"mprintf('the rms velocity at 0deg.C is %3f cm/sec \n the rms velocity at 100deg.C is %3f cm/sec',v0,v100)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.12: The_RMS_velocity.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"cp=6.84;//specific heat at constant pressure in cal/gm mole/deg.C\n", +"r=8.31*10^7;//universal gas constant in ergs/gm mole/deg.C\n", +"v=130000;//velocity of sound in cm/sec\n", +"j=4.2*10^7;//joules constant in ergs/cal\n", +"\n", +"//CALCULATION\n", +"cv=cp-(r/j);//specific heat at constant volume in gm-mole/deg.C\n", +"y=(cp/cv);//index of co-efficient\n", +"v1=(3/y)^(0.5)*v;//rms velocity in cm/sec\n", +"\n", +"//OUTPUT\n", +"mprintf('the rms velocity of gas molecule is %3fcm/sec',v1)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.13: The_average_velocity_of_the_molecule.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t=300;//temperature of the oxygen molecule in K\n", +"n=6.02*10^23;//avagdrao's number\n", +"m=32/n;//mass of each molecule in oxygen\n", +"k=1.38*10^(-16);//boltzmann constant in erg/deg\n", +"\n", +"//OUTPUT\n", +"v=(8*k*t/(3.14*m))^(0.5);//average velocity of oxygen molecule in cm/sec\n", +"v2=v*0.022384;//velocity in miles/hrs\n", +"\n", +"mprintf('the avg velocity of oxygen molecule is %3.1f miles/hour',v2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.14: The_ratio_of_RMS_velocity_to_average_velocity.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"v1=2.4;//velocity of first particle in km/sec\n", +"v2=2.6;//velocity of second particle in km/sec\n", +"v3=3.7;//velocity of third particle in km/sec\n", +"\n", +"//CALCULATIONS\n", +"rv=((v1^2+v2^2+v3^2)/(3))^(0.5);//rms velocity of the particles in km/sec\n", +"mv=(v1+v2+v3)/(3);//mean velocity of the particles in km/sec\n", +"r=rv/mv;//ratio of the rms to mean velocity\n", +"\n", +"mprintf('the ratio of rms to mean velocity is %3.3f',r)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.15: The_mean_free_path.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"n=2.76*10^19;//no.of molecules per cc\n", +"d=3.36*10^(-8);//diameter of the helium molecule in cm\n", +"\n", +"//CALCULATIONS\n", +"mf=1/((2^(0.5))*3.14*(d^2)*n)\n", +"\n", +"//OUTPUT\n", +"mprintf('the mean free path of the hydrogen molecue is %3.8f cm',mf)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.16: The_mean_free_path_collision_rate_molecular_diameter.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"n=85*10^(-6);//coefficent of viscosity in dynes/cm^2/velocity gradient\n", +"c=16*10^4;//velocity in cm/sec\n", +"p=0.000089;//density in gm/cc\n", +"N=6.06*10^23/22400;//avagadro number\n", +"a=(2)^(0.5)*(22/7);//constant\n", +"\n", +"//CALCULATIONS\n", +"mf=(3*n/(p*c));//mean free path in cm\n", +"cr=c/mf;//collision rate\n", +"d=(1/(a*N*mf))^(0.5);//molecular diameter of hydrogen gas in cm\n", +"\n", +"mprintf('the mean free path is %3.6fcm \n hte collision rate is %3.2f \n the molecular diameter of hydrogen gas is %3.10fcm',mf,cr,d)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.17: The_mean_free_path.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"d=2*10^(-8);//diameter of the molecule in cm\n", +"k=1.38*10^(-6);//boltzmann constant in ergs/deg\n", +"t=273;//temperature at ntp in K\n", +"p=76*13.6*981;//pressure at ntp in gm/cm/sec^2\n", +"\n", +"//CALCULATIONS\n", +"mf=((k*t)/(2^(0.5)*3.14*(d^2)*p));//mean free path in cm\n", +"//since p=nkt\n", +"\n", +"//OUTPUT\n", +"mprintf('mean free path at ntp is %3.6fcm',mf)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.18: The_diameter.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t=288;//temperature in K\n", +"k=1.38*10^(-16);//boltzmann constant in erg/deg\n", +"N=6.02*10^23;//avagadro number\n", +"m=32/N;//mass of each oxygen molecule in gm\n", +"v=196*10^-6;//viscosity in poise\n", +"\n", +"//CALCULATIONS\n", +"av=((8*k*t/(3.14*m))^0.5);//average velocity in cm/sec\n", +"d=(m*av/(3*3.14*2^(0.5)*v))^0.5;//diameter of the molecule in cm\n", +"\n", +"mprintf('diameter of the molecule is %3.10f cm',d)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.19: The_pressure.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"mf=15;//mean free path in cm\n", +"t=300;//temperature of oxygen molecule in K\n", +"d=3*10^(-8);//diameter of the molecule in cm\n", +"N=6.02*10^23;//avagadro number\n", +"r=8.32*10^7;//universal gas constant in ergs/mole/deg\n", +"a=(2^(0.5))*(22/7);\n", +"\n", +"//CSLCULATIONS\n", +"p=(r*t)/(N*a*(d^2)*mf);//pressure of the oxygen molecule in dynes/sq.cm\n", +"\n", +"//OUTPUT\n", +"mprintf('the pressure of the oxygen molecule is %3.3f dynes/sq.cm',p)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.1: The_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t=273;//temperture of the oxygen molecule in K\n", +"m=32;//molecular mass of the gas in gm\n", +"r=8.32*10^7;//molar gas constant in ergs per mole\n", +"v2=33200;//velocity of the gas in cm/sec\n", +"\n", +"//CALCULATIONS\n", +"v1=((3*r*t)/m)^(1/2);//rms velocity of the molecule in cm/s\n", +"T=((v2*v2*m)/(3*r));//temperature of the molecule with sound has velocity in K\n", +"\n", +"//OUTPUT\n", +"mprintf('the rms velocity of the molecule is %3.2fcm/s \n the temperature of the molecule is %3.0fK',v1,T)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.20: The_avagadro_number.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"k=5.64*10^-14;//kinetic energy of the hydrogen molecule ergs\n", +"t=273;//temperature of the oxygen molecule in K\n", +"r=8.32*10^7;//universal gas constant in ergs \n", +"\n", +"//CALCULATIONS\n", +"N=(3/2)*(r*t/k);//avagadro number\n", +"\n", +"//OUTPUT\n", +"mprintf('the avagadro number is %3.2f',N)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.21: The_number_which_will_be_travelling_undeflected.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"q=5000;//total number of molecules\n", +"e=2.7183;//constant value\n", +"t1=0.5;//distance travled to the mean free path\n", +"t2=1;//distance travelled to the mean free path\n", +"\n", +"//CALCULATONS\n", +"p1=q*(e^-t1);//n0.of molecules having no collision in traversing a distance t1\n", +"p2=q*(e^-t2);//n0.of molecules having no collision in traversing a distance t2\n", +"\n", +"//OUPUT\n", +"mprintf('the no. of molecules having no collision in traversing a distance o.5 is %3f \n the no. of molecules having no collision in traversing a distance 1 is %3f',p1,p2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.22: The_mean_kinetic_energy.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t=38380;//temperature of the molecule in K\n", +"k=1.38*10^-16;//boltzman constant of one electron in ergs/K\n", +"e=1.6*10^-12;//charge of one electron volts\n", +"\n", +"//CALCULATIOS\n", +"mk=1.5*k*t/e;//mean kinetic energy per atom in ev\n", +"\n", +"//OUTPUT\n", +"mprintf('the mean kinetic energy of the molecule is %3.3f ev',mk) " + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.23: The_mean_free_path_and_the_collision_frequency.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"v=1.7*10^-4;//viscosity of the air molecule in cgs\n", +"d=0.00129;//density of the molecule in gm/ml\n", +"p=76*13.6*981;//pressure of the molecule in gm/cm/sec^2\n", +"\n", +"//CALCULATIONS\n", +"r=(3*p/d)^(0.5);//rms velocity of the molecule in cm/sec\n", +"mf=(3*v/(d*r));//mean free path in cm\n", +"cf=r/mf;//collision frequency\n", +"\n", +"//OUTPUT\n", +"mprintf('the mean free path is %3.7f cm \n the collision frequency is %3f',mf,cf)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.24: The_pressure_of_the_gas.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t2=296.4;//temperature of the first plate in K\n", +"t1=304.7;//temperature of the second plate in K\n", +"f=1.6*10^-2;//force repelled cold is dynes/sq.cm\n", +"\n", +"//CALCULATIONS\n", +"p=(4*f*t2/(t1-t2));//pressure of the gas in dynes/sq.cm\n", +"\n", +"//OUTPUT\n", +"mprintf('the pressure of the gas is %3.3f dynes/sq.cm',p)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.25: The_size_of_helium_atom.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"mf=28.5*10^-6;//mean free path in cm\n", +"d=0.000178;//density of helium in gm/ml\n", +"m=6*10^-24;//mass of the helium atom in gm\n", +"a=(2^(0.5))*3.14;//constant\n", +"\n", +"//CALCULATIONS\n", +"d=(m/(a*d*mf))^(0.5);//diameter of the size in cm\n", +"\n", +"//OUTPUT\n", +"mprintf('the size of the helium atom is %3.10f cm',d)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.26: The_value_avagadro_number.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"a1=0*10^-4;//first horizontal displacement in cm\n", +"a2=5.6*10^-4;//second horizontal displacement in cm\n", +"a3=-4.7*10^-4;//third horzontal displacement in cm\n", +"a4=-10.8*10^-4;//fourth horizontal displacement in cm\n", +"a5=6.6*10^-4;//fifth horizontal displacement displacement in cm\n", +"a6=-9.8*10^-4;//sixth horizontal displacement in cm\n", +"a7=-11.2*10^-4;//7th horizontal displacement in cm\n", +"a8=-4.0*10^-4;//8th horizontal displacement in cm\n", +"a9=15.0*10^-4;//9thhorizontal displacement in cm\n", +"a10=19.1*10^-4;//10th horizontal displacement in cm\n", +"a11=16.0*10^-4;//11ht horizontal displacement in cm\n", +"T=293;//temperature of the particle in K\n", +"v=0.01;//viscosity in cgs\n", +"r=1.15*10^-5;//radius of the particle in cm\n", +"R=8.32*10^7;//universal gas constant in kj/kg mole\n", +"t=30;//time for observation of each in sec\n", +"\n", +"//CALCULATIONS\n", +"x=(a1^2+a2^2+a3^2+a4^2+a5^2+a6^2+a7^2+a8^2+a9^2+a10^2+a11^2)/11\n", +"n=R*T*t/(x*3*3.14*v*r);//no.of molecules in the observation \n", +"\n", +"//OUTPUT\n", +"mprintf('the value of n is %3f',n)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.27: The_fractional_change_in_the_number_of_helium_atoms.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"m=6*10^-24;//mass of the helium atom in gm\n", +"k= 1.38*10^-16;//boltzmann constant in erg\n", +"t1=100;//temperature in K\n", +"t2=900;//temperature in K\n", +"\n", +"//CALCULATIONS\n", +"r=(t1/t2)^(3/2)*(2.7183^(m*(1/(2*k))*10^8*(1-(1/9))));//fractional change in the no.of helium atoms\n", +"\n", +"//OUPUT\n", +"mprintf('the fractional change in the no.of helium atoms %3.4f',r)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.2: The_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t1=308;//temperature of the nitrogen molecule in K\n", +"m1=28;//molecular mass of the nitrogen in gm\n", +"m2=2;//molecular mass of the hydrogen molecule in gm\n", +"\n", +"//CALCULATIONS\n", +"t2=(t1*m2/m1);//temperature of the hydrogen molecule in K\n", +"//GIVEN avg.speed of both the molecules are same\n", +"\n", +"//OUTPUT\n", +"mprintf('the temperature of the hydrogen molecule is %3.0fK',t2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.3: The_RMS_velocity_at_NTP.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"y=0.00129;//density of the air in gm/cc\n", +"p=76;//pressure of the nitrogen molecule in cm\n", +"g=981;//accelaration due to gravity in cm/sec^2\n", +"m=13.6;//density of the mercury in gm/cc\n", +"\n", +"//CALCULATIONS\n", +"v=((3*p*g*m)/y)^(1/2);//rms velocity of air at ntp in cm/sec\n", +"\n", +"//OUTPUT\n", +"mprintf('the rms velocity of the air is %3.2fcm/sec',v)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.4: The_rms_velocity.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"d=16*0.000089;//density of the oxygen molecule in gm/cc\n", +"p=76;//pressure of the air in cm\n", +"g=981;//gravitaitonal accelaration in cm/sec^2\n", +"m=13.6;//density of the mercury in gm/cc\n", +"\n", +"//CALCULATIONS\n", +"v=((3*p*g*m)/d)^(1/2);//velocuty of the oxygen molecule in cm/sec\n", +"\n", +"//OUTPUT\n", +"mprintf('velocity of oxygen molecule is %3.2fcm/sec',v)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.5: The_kinetic_energy_of_hydrogen_molecule.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t=273;//temperature of the hydrogen molecule in K\n", +"n=6.03*10^23;//1 mole of hydrogen molecules\n", +"r=8.31*10^7;//universal gas constant in erg/K/mole\n", +"\n", +"//CALCULATIONS\n", +"e=(1.5*r*t)/n;//kinetic energy of the hydrogen molecule in erg\n", +"\n", +"//OUTPUT\n", +"mprintf('the kinetic energy of the hydrogen molecule is %3.16ferg',e)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.6: The_kinetic_energy.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"m=1;//mass of the oxygen in gm\n", +"r=8.31*10^7;//universal gas constant in erg/K/mole\n", +"t=320;//temperature of the oxygen in K\n", +"//for 1gm mole k.e is 1.5rt then for 1 gm oxygen (1/32)(k.e)\n", +"\n", +"//CALCULATIONS\n", +"e=(m/32)*(3*r*t/2);//kinetic energy of the oxygen in erg\n", +"\n", +"//OUTPUT\n", +"mprintf('the kinetic energy of the oxygen is %3.2ferg',e)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.7: The_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t=273;//temperature at ntp in K\n", +"//rms velocity of oxygen is 3/2 times its rms velocity at ntp then e1=(3/2)*e\n", +"\n", +"//CALCULATIONS\n", +"t1=(9*t/4);//temperature of the oxygen molecule in K\n", +"\n", +"//OUTPUT\n", +"mprintf('temperature of the oxygen in %3.2fK',t1)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.8: The_kinetic_energy.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"p=10;//pressure of the gas in atm\n", +"v=5000;//volume of the gas in ml\n", +"l=76;//length of the mercury in barometer in cm\n", +"g=981;//accelaration due to gravity in cm/sec^2\n", +"d=13.6;//density of the mercury in gm/cc\n", +"\n", +"//CALCULATIONS\n", +"e=3*p*v*l*g*d;//kinetic energy of the molecule in ergs\n", +"\n", +"//OUTPUT\n", +"mprintf('the kinetic energy of the molecule is %3.2fergs',e)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.9: The_molecular_energy.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t=323;//temperature of the hydrogen molecule in K\n", +"m1=1;//mass of the hydrogen molecule in gm\n", +"m2=2;//molecular weight of the hydrogen in gm\n", +"r=8.3*10^7;//universal gas constant in erg/K/mole\n", +"\n", +"//CALCULATIONS\n", +"e=(m1*r*t*3/(m2*2));//kinetic enrgy of the hydrogen molecule in ergs\n", +"\n", +"//OUTPUT\n", +"mprintf('the kinetic energy of the molecule is %3.2fergs',e)" + ] + } +], +"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 +} diff --git a/Heat_And_Thermodynamics_by_A_Manna/5-Equations_of_state.ipynb b/Heat_And_Thermodynamics_by_A_Manna/5-Equations_of_state.ipynb new file mode 100644 index 0000000..99daf91 --- /dev/null +++ b/Heat_And_Thermodynamics_by_A_Manna/5-Equations_of_state.ipynb @@ -0,0 +1,127 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 5: Equations of state" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.1: The_values_of_constant_a_and_b_in_vanderwaal_equation.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t=304;//temperature of the gas in k\n", +"p=73;//pressure of the gas in atm\n", +"r=0.00366;//universal gas constant in j/K/mole\n", +"//ct=8a/27br;cp=a/27b^2\n", +"\n", +"//CALCULATIONS\n", +"b=(t*r/(8*p));\n", +"a=p*27*b^2;\n", +"\n", +"//OUTPUT\n", +"mprintf('the value of the constant b is %3.7f \n the value of the constant a is %3.5f',b,a)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.4: Vanderwaal_constants.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"tc=132;//critical temperature in K\n", +"pc=37.2;//critical pressure in atm\n", +"r=82.07;//universal gas constant in cm^3atm/mole/K\n", +"\n", +"//CALCULATIONS\n", +"a=27*(r^2)*(tc^2)/(64*pc);//value of a in atm/cm^6/mol^2\n", +"b=r*tc/(8*pc);//value of b in cm^3/mol\n", +"\n", +"//OUTPUT\n", +"mprintf('the value of is %3.2f atm/cm^6/mol^2 \n the value of b is %3.2f cm^3/mol',a,b)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.5: Temperature_of_the_gas.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"p=2.26*1.013*10^5;//critical pressure in N/m^2\n", +"v=4/69;//critical volume in m^3/kmol\n", +"r=8.31*10^3;//universal gas constant in J/kmol.K\n", +"\n", +"//CALCULATIONS\n", +"t=(8*p*v/(3*r));//critical temperature in K\n", +"\n", +"//OUTPUT\n", +"mprintf('critical temperature of the given problem is %3.2f K',t)" + ] + } +], +"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 +} diff --git a/Heat_And_Thermodynamics_by_A_Manna/6-Change_of_state.ipynb b/Heat_And_Thermodynamics_by_A_Manna/6-Change_of_state.ipynb new file mode 100644 index 0000000..3a99ebc --- /dev/null +++ b/Heat_And_Thermodynamics_by_A_Manna/6-Change_of_state.ipynb @@ -0,0 +1,200 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 6: Change of state" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 6.1: The_change_in_melting_point.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"vl=1;//volume of water in cc\n", +"vs=1.0908;//volume of ice in cc\n", +"t=273;//temperature in k\n", +"p=76*13.6*981;//pressure in dynes/sq.cm\n", +"l=80;//latent heat of fusion in cal\n", +"j=4.2*10^7;//joules constant in erg/cal\n", +"\n", +"//CALCULATIONS\n", +"v=vl-vs;//change in volume\n", +"T=(v*t*p)/(j*l);//change in melting point of water\n", +"\n", +"//OUTPUT\n", +"mprintf('the change in melting point of water is %3.11f',T)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 6.2: The_latent_heat_of_vapourisation.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"vv=1674;//volume of vapour in cc\n", +"vl=1;//volume of liquid in cc\n", +"p=760;//pressure of steam and water in mm\n", +"t=373;//temperature in K\n", +"p1=27.12;//superincumbent pressure in mm\n", +"\n", +"//CALCULATIONS\n", +"v=vv-vl;//change in volume\n", +"l=(v*p1*t*0.024203/(p));//latent heat of vapourisation in cal\n", +"\n", +"//OUTPUT\n", +"mprintf('the latent heat of vapourisation is %3.1f cal',l)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 6.3: The_value_of_K.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"m=1/(342*100);//molar concentration of water\n", +"t=289;//temperature in K\n", +"p=53.5*13.6*981;//pressure in dynes/sq.cm\n", +"\n", +"//CALCULATIONS\n", +"k=p/(t*m);//the value of k in ergs/mol.deg\n", +"\n", +"//OUTPUT\n", +"mprintf('the value of k is %3.2f ergs/mol.deg',k)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 6.4: The_temperature_for_the_triple_point.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"p1=4.60;//presure at 0deg.C in mm per deg.C\n", +"p2=4.94;//pressure at 1deg.C in mm per deg.C\n", +"t=0.0072;//lowering the melting point in deg.C\n", +"t1=7.1563979*10^(-3);//rise in melting point in deg.C\n", +"p=760;//atmospheric pressure in mm hg\n", +"\n", +"//CALCULATIONS\n", +"dp=p2-p1;//rate of increase of pressure in mm per deg.C\n", +"p3=(t1*p)/t;//pressure in mm\n", +"dt=(755.4-p3)/dp;//tmperature for the triple point in deg.C\n", +"\n", +"//OUTPUT\n", +"mprintf('temperature for the triple point is %3.6f deg.C',dt)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 6.5: The_slopes_of_vapourisatio.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"v=21*10^4;//change in volume from vapour to liquid in cc\n", +"Ls=687;//latent heat of sublimation in cal\n", +"lv=607;//latent heat of vapourisation in cal\n", +"t=273;//temperature of water in deg.C\n", +"j=4.2*10^7;//joules constant in ergs/cal\n", +"\n", +"//CALCULATIONS\n", +"sv=lv*j/(t*(v));//slope of vapourisation curve at 0 deg.C in dyne/sq.cm/deg.C\n", +"ss=Ls*j/(t*(v));//slope of sublimation curve at 0 deg.C in dyne/sq.cm/deg.C\n", +"\n", +"//OUTPUT\n", +"mprintf('the slope of vapourisation curve is %3.2f dyne/sq.cm/deg.C \n the slope of sublimation curve is %3.2f dyne/sq.cm/deg.C',sv,ss)" + ] + } +], +"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 +} diff --git a/Heat_And_Thermodynamics_by_A_Manna/7-The_joule_thomson_cooling_efect.ipynb b/Heat_And_Thermodynamics_by_A_Manna/7-The_joule_thomson_cooling_efect.ipynb new file mode 100644 index 0000000..882d5c6 --- /dev/null +++ b/Heat_And_Thermodynamics_by_A_Manna/7-The_joule_thomson_cooling_efect.ipynb @@ -0,0 +1,291 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 7: The joule thomson cooling efect" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.1: The_temperature_of_inversion.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t=33.18;//critical temperature in K\n", +"pc=12.80*76*981*13.6;//critical pressure in dynes/sq.cm\n", +"r=83.15;//universal gas constant in kj/kg.K\n", +"d=0.08987;//density of hydrogen in gm/lit\n", +"v=2000/0.08987;//gram molecular volune of hydrogen in cc\n", +"\n", +"//CALCULATIONS\n", +"b=r*10^6*t/(8*pc);//vanderwaal constant in cm^3/mol\n", +"to=2*27*t*(1-(b/v))/8;//inversion temperature of the hydrogen in K\n", +"\n", +"//OUTPUT\n", +"mprintf('the inversion temperature of hydrogen is %3.2f K',to)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.2: The_change_of_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"b=0.00136;//vanderwaal constant in suv/gm\n", +"a=0.011;//vanderwaal constant in atm(suv)^2/gm^2\n", +"r=0.003696;//universal gas constant in atm(suv)/gm.deg\n", +"t=423;//temperature of steam in K\n", +"cp=-0.674/0.024205;//specific heat at 423K in atm(cc)gm(deg)\n", +"\n", +"//CALCULATIONS\n", +"dt=(-b+(2*a/(r*t)))/cp;//change of temperature per atm drop of pressure in deg/atm\n", +"\n", +"//OUTPUT\n", +"mprintf('the change of temperature per atmosphere drop of pressure is %3.7f deg/atm',dt)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.3: The_change_in_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"r=8.3*10^7;//universal gas constant in ergs/deg.C\n", +"a=1.36*10^6*76*13.6*981;//vanderwaal constant in atm.(suv^2)/(gm^2)\n", +"b=32;//vanderwaal constant in cc\n", +"cp=7.03;//specific heat at constant pressure in cal\n", +"j=4.18*10^7;//joules constant in ergs/cal\n", +"t=273;//temperature of the gas in K\n", +"\n", +"//CALCULATIONS\n", +"dt=((2*a/(r*t))-b)*10^6/(cp*j);//change of temperature in atmosphere drop of pressure in deg/atm/cm^3\n", +"\n", +"//OUTPUT\n", +"mprintf('the change of temperature in atmosphere drop of pressure is %3.2f deg/atm/cm^3',dt)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.4: The_change_in_enthalpy.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"u=1.08;\n", +"cp=8.6;//specific heat in kj/kg.K\n", +"j=4.2;//joules constant in j/cal\n", +"p1=1*1.013*10^6;//pressure at intial in N/sq.m\n", +"p2=20*1.013*10^6;//pressure at final in N/sq.m\n", +"\n", +"//CALCULATIONS\n", +"dh=-u*cp*j*(p1-p2);//change in enthalpy in joules\n", +"\n", +"//OUTPUT\n", +"mprintf('the change in enthalpy is %3.2fjoules',dh)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.5: The_inversion_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"tc=5.26;//critical temperature of the helium in K\n", +"\n", +"//CALCULATIONS\n", +"ti=27*tc/4;//inversion temperature of the helium in K\n", +"\n", +"//OUTPUT\n", +"mprintf('the inversion temperature of the helium is %3.2f K',ti)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.6: The_temperature_of_inversion.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"a=0.245*10^6*10^6;//vanderwaal constant in cm^4.dyne/mole^2\n", +"b=2.67*10;//vanderwaal constant in cc/mole\n", +"r=2*4.2*10^7;//universal gas constant in ergs/mole.K\n", +"\n", +"//CALCULATIONS\n", +"ti=2*a/(b*r);//inversion temperature in K\n", +"\n", +"//OUTPUT\n", +"mprintf('inversion temperature of hydrogen is %3.2f K',ti)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.7: The_drop_in_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"dp=50*10^6;//change in pressure in dynes/sq.cm\n", +"cp=7*4.2*10^7;//specific heat constant pressure in ergs/mole.K\n", +"a=1.32*10^12;//vanderwaal constant in cm^4.dyne/mole^2\n", +"b=31.2;//vanderwaal constant in cm^2/mole\n", +"t=300;//inital temperature in K\n", +"r=2*4.2*10^7;//ergs/mole.K\n", +"\n", +"//CALCULATIONS\n", +"dt=((2*a/(r*t))-b)*dp/cp;//change in temperature in K\n", +"\n", +"//OUTPUT\n", +"mprintf('the change in temperature is %3.2f K',dt)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.8: The_drop_in_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"p1=1;//inital pressure in atm\n", +"p2=51;//final pressure in atm\n", +"t1=300;//inital temperature in K\n", +"y=1.4;//coefficient of expansion\n", +"\n", +"//CALCULATIONS\n", +"t2=t1*(p2/p1)^((1-y)/y);//final temperature in K\n", +"dt=t1-t2;//drop in temperature in K\n", +"\n", +"mprintf('the drop in temperature is %3.2f K',dt)" + ] + } +], +"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 +} diff --git a/Heat_And_Thermodynamics_by_A_Manna/8-First_law_of_thermodynamics.ipynb b/Heat_And_Thermodynamics_by_A_Manna/8-First_law_of_thermodynamics.ipynb new file mode 100644 index 0000000..b2fd7f2 --- /dev/null +++ b/Heat_And_Thermodynamics_by_A_Manna/8-First_law_of_thermodynamics.ipynb @@ -0,0 +1,622 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 8: First law of thermodynamics" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.10: The_final_temperature_and_pressure.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"p1=76;//inital pressure in cm\n", +"t1=290;//inital temperature in K\n", +"y=1.4;//coefficent of expansion\n", +"dv=2;//ratio of inital to fianl volume when air expands isothermally \n", +"dv1=2;//ratio of inital to final volume when air expands adiabatically\n", +"\n", +"//CALCULATIONS\n", +"p2=p1/dv;//final pressure when air expands isothermally in cm of hg\n", +"t2=t1;//final temperature when air expands isothermally in K\n", +"t3=t2*(1/dv1)^(y-1);//temprature when air expands adiabatically in K\n", +"p3=p2*(1/dv1)^(y);//final pressure when air expands adiabatically in mm of hg\n", +"\n", +"//OUTPUT\n", +"mprintf('final pressure when air expands isothermally in cm of hg %3.2f mm of hg \n final temperature when air expands isothermally is %3.2f K \n temprature when air expands adiabatically is %3.2f K \n final pressure when air expands adiabatically is %3.2f mm of hg',p2,t2,t3,p3)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.11: The_work_done.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"p=76*13.6*981;//pressure of air in dynes/sq.cm\n", +"v=11100;//volume expanded in ml\n", +"t1=273;//inital temperature in K\n", +"t2=274;//final temperature in K\n", +"cv=2.411;//specific heat at constant volume in cal/K\n", +"j=4.2*10^7;//joules constant in ergs/cal\n", +"//CALCULATIONS\n", +"w=p*v*log(t2/t1);//work done in ergs\n", +"h=cv*(t2-t1)+w/j;//heat supplied in cal\n", +"\n", +"//OUTPUT\n", +"mprintf('the work done is %3.2f erg \n the heat supplied is %3.3f cal',w,h)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.12: The_work_done.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"p=10^6;//pressure of air in dynes\n", +"d=0.0001293;//density of air in gm/cc\n", +"t1=273;//inital temperature in K\n", +"dv=2;//ratio of inital volume to final volume\n", +"y=1.4;//coefficient of expansion\n", +"\n", +"//CALCULATIONS\n", +"r=p/(d*t1);//universal gas constant in dynes.cc/gm.K\n", +"t2=t1*(dv)^(y-1);//final temperature in K\n", +"w=r*(t2-t1)/(y-1);//work done in adiabatic compression in ergs\n", +"\n", +"//OUTPUT\n", +"mprintf('work done in adiabatic compression is %3.2f ergs',w)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.13: The_change_in_internal_energy.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"m=5;//mass of air in gm\n", +"cv=0.172;//specific heat at constant volume cal/gm\n", +"dt=10;//changi in temperature in K\n", +"\n", +"//CALCULATIONS\n", +"ie=m*cv*dt;//change in internal energy in cal\n", +"\n", +"//OUTPUT\n", +"mprintf('change in internal energy is %3.2f cal',ie)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.14: The_heat_supplied.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"v1=10^3;//inital volume in cc\n", +"v2=2*v1;//final volume in cc\n", +"p1=76*13.6*981;//pressure in dyne/sq.cm\n", +"t1=273;//intial temperature in K\n", +"d=1.29;//density of the gas gm/lit\n", +"cv=0.168;//specific heat at constant volume in cal/gm\n", +"\n", +"//CALCULATIONS\n", +"t2=(v2/v1)*t1;//final temperature in K\n", +"r=0.068;//universal gas constant in cal\n", +"cp=cv+r;//specific heat at constant pressure in cal\n", +"q=d*cp*(t2-t1);//heat supplied in cal\n", +"\n", +"//OUTPUT\n", +"mprintf('the heat supplied to the gas is %3.2f cal',q)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.15: The_maximum_work_done.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t=303;//temperature of the one mole of the argon in K\n", +"v1=1;//intial volume in litres\n", +"v2=10;//final volume in litres\n", +"r=8.31*10^7;//universal gas constant in ergs/K.mol\n", +"\n", +"//CALCULATIONS\n", +"w=r*t*log(v2/v1);//work done in isothermal expansion in ergs\n", +"\n", +"//OUTPUT\n", +"mprintf('the work done in isothermal expansion is %3.2f ergs',w)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.16: The_amount_of_heat_absorbed.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"dv=4;//final volume of neon in lit\n", +"t=273;//temperature of the gas in K\n", +"n=2.6/22.4;//the no.of moles of neon\n", +"r=1.98;//universal gas constant in cal/K.mol\n", +"\n", +"//CALCULATIONS\n", +"w=n*t*r*log(dv);//work done by gas in ergs\n", +"\n", +"//OUTPUT\n", +"mprintf('the work done by 2.6lit of neon is %3.2f ergs',w)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.18: The_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"dv=10^(-3);//ratio of initial and final volume\n", +"t1=10^5;//initial temperature in K\n", +"y=1.66;//coefficient of expansion\n", +"\n", +"//CALCULATIONS\n", +"t2=t1*(dv)^(y-1);//final temperature in K\n", +"\n", +"//OUTPUT\n", +"mprintf('final temperature of the gas is %3.2f K',t2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.19: The_value_coefficient_of_expansion.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"p1=8;//intial pressure in cm of hg\n", +"p2=6;//final pressure in cm of hg\n", +"v1=1000;//intial volume in cc\n", +"v2=1190;//final volume in cc\n", +"\n", +"//CALCULATIONS\n", +"y=log(p1/p2)/log(v2/v1);//coefficient of expansion\n", +"\n", +"//OUTPUT\n", +"mprintf('the coefficent of expansion is %3.2f',y)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.1: The_change_in_internal_energy.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"l=80;//latent heat of fusion in cal\n", +"j=4.2*10^7;//joules constant in ergs/cal\n", +"w=-0.092*10^6;//work done in changing phase change in ergs\n", +"\n", +"//CALCULATIONS\n", +"q=l*j;//heat added in ergs\n", +"du=q-w;//internal energy in ergs\n", +"\n", +"//OUTPUT\n", +"mprintf('the change in internal energy is %3.2f ergs',du)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.2: The_change_in_internal_energy.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"m=1;//mass in gm\n", +"l=536;//latent heat in cal/gm\n", +"j=4.2*10^7;//joules constant in ergs/cal\n", +"v=1649;//volume of water in cc\n", +"p=76*13.6*981;//pressure of water in dynes/sq.cm\n", +"\n", +"//CALCULATIONS\n", +"dq=m*l*j;//heat supplied in ergs\n", +"dw=p*v;//work done in ergs\n", +"du=dq-dw;//internal energy developed in ergs\n", +"\n", +"//OUTPUT\n", +"mprintf('internal energy of water is %3.2f ergs',du)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.3: The_temperature_immediately_after_the_compressio.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"dv=10;//ratio of original volume to final volume\n", +"t1=293;//inital temperature in K\n", +"y=1.41;//coefficent of expansion\n", +"\n", +"//CALCULATIONS\n", +"t2=t1*(dv)^(y-1);//final temperature in K\n", +"\n", +"//OUTPUT\n", +"mprintf('the final temperature is %3.2f K',t2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.4: The_change_in_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t=273;//temperature of earth at height h in K\n", +"p=760;//pressure in mm of hg\n", +"dp=1;//change in pressure in mm of hg\n", +"y=1.418;//coefficient of expansion\n", +"\n", +"//CALCULATIONS\n", +"dt=((y-1)/y)*dp*t/p;//change in temperature in deg.C\n", +"\n", +"//OUTPUT\n", +"mprintf('the change in temperature is %3.3f deg.C',dt)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.5: The_resulting_drop_in_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"p1=2;//pressure initial in atm\n", +"p2=1;//pressure final in atm\n", +"t1=288;//inital temperature in K\n", +"y=1.4;//coefficent of expansion\n", +"\n", +"//CALCULATIONS\n", +"t2=t1*(p2/p1)^((y-1)/y);//final temperature in K\n", +"dt=t1-t2;//drop in temperature in K\n", +"\n", +"//OUTPUT\n", +"mprintf('drop in temperature is %3.2f K',dt)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.6: The_resultant_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t1=288;//inital temperature in K\n", +"dv=1/2;//ratio of inital to final volume\n", +"y=1.4;//coefficient of expansion\n", +"\n", +"//CALCULATIONS\n", +"t2=t1*(dv)^(y-1);//final temperature in K\n", +"\n", +"//OUTPUT\n", +"mprintf('the final temperature is %3.1f K',t2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.7: The_resultant_rise_in_temperatures_in_both_the_cases.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"y=1.4;//coefficent of exapnsion\n", +"p1=1;//standard pressure in atm\n", +"dv=50;//ratio of initial volume to final volume\n", +"t1=273;//standard temperature in K\n", +"\n", +"//CALCULATIONS\n", +"p2=p1*dv;//final pressure when slowly compressed in atm\n", +"p3=p1*(dv)^(y);//final pressure when suddenly compressed in atm\n", +"t2=t1*(dv)^(y-1);//rise in temperature when it is suddenly compressed in K\n", +"\n", +"//OUTPUT\n", +"mprintf('the final pressure when it is compressed slowly is %3fatm \n the final pressure when it is compressed suddenly is %3.2fatm \n the rise in temperature when it is suddenly compressed is %3.0fK',p2,p3,t2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.8: The_rise_in_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"y=1.5;//coefficient of expansion\n", +"dp=1/8;//ratio of inital pressure to final pressure\n", +"t1=300;//inital tempreature in K\n", +"\n", +"//CALCULATIONS\n", +"t2=t1*(dp)^((1-y)/y);//change in temperature in K\n", +"t3=t2-t1;//rise in temperature in K\n", +"\n", +"//OUTPUT\n", +"mprintf('the rise in temperature is %3.2f K',t3)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.9: The_amount_of_work_done.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t1=400;//inital temperature in K\n", +"dv=2;//ratio of volumes final and inital\n", +"r=8.31*10^7;//universal gas constant in ergs/kg.K\n", +"\n", +"//CALCULATIONS\n", +"w=r*t1*log(2);//work done in expanding isothermally in ergs\n", +"\n", +"//OUTPUT\n", +"mprintf('the work done in expanding isothermally is %3.2f ergs',w)" + ] + } +], +"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 +} diff --git a/Heat_And_Thermodynamics_by_A_Manna/9-Second_law_of_thermodynamics.ipynb b/Heat_And_Thermodynamics_by_A_Manna/9-Second_law_of_thermodynamics.ipynb new file mode 100644 index 0000000..2fee260 --- /dev/null +++ b/Heat_And_Thermodynamics_by_A_Manna/9-Second_law_of_thermodynamics.ipynb @@ -0,0 +1,489 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 9: Second law of thermodynamics" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.10: The_indicated_thermal_efficiency.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"ip=16.3*500*778/33000;//input power of the engine in HP\n", +"me=0.72;//mechanical efficiency of the engine\n", +"bhp=31;//brake horse power in b.h.p\n", +"ihp=bhp/me;//indicated horse power in HP\n", +"\n", +"//CALCULATIONS\n", +"i=ihp/ip;//indicated thermal efficiency\n", +"\n", +"//OUTPUT\n", +"mprintf('the indicted thermal efficiency is %3.3f',i)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.11: The_horse_power_of_the_steam_engine.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"p=200;//horse power of steam engine in lbs coal per hour\n", +"j=770;//joules constant in ft lbs per B.Th.U\n", +"\n", +"//CALCULATIONS\n", +"w=12500*p*j;//equivalent work in ft.lb.per.hr\n", +"hp=w/(60*33000);//horse power\n", +"\n", +"//OUTPUT\n", +"mprintf('hoose power of the engine is %3.2f',hp)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.12: The_maximum_pressure.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t1=340;//temperature of the atmosphere in K\n", +"t2=612;//temperature of the compression stroke in K\n", +"y=1.39;//adiabatic expansion \n", +"t3=2040;//temperature after constant volume ignition in K\n", +"\n", +"//CALCULATIONS\n", +"d=(t2/t1)^(1/(y-1));//density in gm/cc\n", +"n=1-(1/d)^(y-1);//efficiency of the engine\n", +"p=((d)^(y))*(t3/t2);//maximum temperature of the temperature in atm\n", +"\n", +"//OUTPUT\n", +"mprintf('the maximum pressure of the engine is %3.2f atm',p)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.13: The_efficiency_of_the_engine.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t1=915;//temperature at the beggining in K\n", +"t2=2040;//temperature at the end in K\n", +"d=12.6;//adiabatic expansion ratio\n", +"y=1.39;//coefficent of expansion\n", +"\n", +"//CALCULATIONS\n", +"x=t2/t1;//ratio temparatures\n", +"n=1-(1/d)^(y-1)*((x^y)-1)/(y*(x-1));//efficiency of the engine\n", +"\n", +"//OUTPUT\n", +"mprintf('the efficiency of the engine is %3.3f',n)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.14: The_pressure_and_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"p1=15;//intial pressure in lb/sq.inch\n", +"dv=15;//ratio of intial to final volume\n", +"t1=520;//temperature at intial in K\n", +"y=1.4;//coefficient of expansion\n", +"\n", +"//CALCULATIONS\n", +"p2=p1*(dv)^(y);//final pressure in lb/sq.inch\n", +"t2=t1*(dv)^(y-1);//final temperatire in K\n", +"\n", +"//OUTPUT\n", +"mprintf('the final pressure is %3.2f lb/sq.inch \n the final temperature is %3.2f K',p2,t2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.1: The_temperature.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t2=300;//temperature of the sink in K\n", +"n1=0.4;//efficiency of the engine\n", +"n2=0.6;//efficiency of the engine\n", +"\n", +"//CALCULATIONS\n", +"t1=t2/(1-n1);//temperature of the source in K\n", +"t3=t2/(1-n2);//temperature of the source in K\n", +"\n", +"//OUTPUT\n", +"mprintf('the temperature of the source when 0.4 efficiency is %3.2f K \n the temperature of the source when 0.6 efficiency is %3.2f K',t1,t3)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.2: The_work_done_heat_rejected_and_efficiency.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t2=273;//temperature of the sink in K\n", +"t1=373;//temperature of the source in K\n", +"q1=840;//heat supplied in joules\n", +"j=4.2;//joukes constant in erg/cal\n", +"\n", +"//CALCULATIONS\n", +"w=(q1/t1)*(t1-t2);//work done in joules\n", +"q2=(q1/j)*(t2/t1);//heat rejected in calories\n", +"n=1-(t2/t1);//efficiency of the engine\n", +"\n", +"//OUTPUT\n", +"mprintf('work done is %3.2f j \n heat rejected is %3.2f cal \n the efficiency of the engine is %3.2f',w,q2,n)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.3: The_temperature_of_the_source.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t1=90;//temperature of the oxygen boils in K\n", +"t2=20;//temperature of the liquid hydrogen in K\n", +"t3=300;//temperature of the sink in K\n", +"\n", +"//CALCULATIONS\n", +"n=(t1-t2)/t1;//efficiency of the engine\n", +"t4=t3/(1-n);//temperature of the source in K\n", +"\n", +"//OUTPUT\n", +"mprintf('the efficiency of the engine is %3.2f \n the temperature of the source is %3.2f K',n,t4)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.4: The_quantity_of_heat.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t1=373;//temperature of the source in K\n", +"t2=273;//temperature of the sink in K\n", +"w=1200*10^5*980;//work done in ergs\n", +"j=4.18*10^7;//joules constant in ergs/cal\n", +"\n", +"//CALCULATIONS\n", +"q=(w/j)*(t1/(t1-t2));//heat added in cal\n", +"\n", +"//OUTPUT\n", +"mprintf('the heat added is %3.2f cal',q)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.5: The_efficiency_and_energy_to_be_supplied.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t1=273;//temperature of the source in K\n", +"t2=290;//temperature of the sink in K\n", +"l=8*10^11;//latent of fusion in ergs/cal\n", +"\n", +"//CALCULATIONS\n", +"n=(t2-t1)/t1;//efficiency of the engine\n", +"w=n*l;//energy to be supplied in ergs\n", +"\n", +"//OUTPUT\n", +"mprintf('efficiency of the engine is %3.2f \n energy to be supplied is %3.2f ergs',n,w)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.6: The_work_done.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"t1=373;//temperature in K\n", +"t2=273;//temperature of sink in K\n", +"q=10^4;//heat taken at higher temperature in cal\n", +"j=4.2*10^7;//joules constant in ergs/cal\n", +"\n", +"//CALCULATIONS\n", +"w=q*j*(t1-t2)/t1;//work done in ergs\n", +"\n", +"//OUTPUT\n", +"mprintf('work done is %3.2f ergs',w)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.7: The_heat_supplied_rejected_and_efficiency.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"p=100*746/4.2;//power developed in cal/sec\n", +"t1=300;//temperature of the sink in K\n", +"t2=500;//temperature of the source in K\n", +"\n", +"//CALCULATIONS\n", +"n=1-(t1/t2);//efficiency of the engine\n", +"q1=p/n;//heat supplied in cal/sec\n", +"q2=q1*(1-n);//heat rejected to the sink in cal/sec\n", +"\n", +"//OUTPUT\n", +"mprintf('the efficiency of the engine is %3.2f \n the heat supplied is %3.2f cal/sec \n the heat rejected is %3.2f cal/sec',n,q1,q2)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.8: The_lowest_temperature_work_done_and_efficiency.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"y=1.4;//coefficent of expansion\n", +"t1=600;//intial temperature in K\n", +"dv=1/6;//ratio of intial to final volume\n", +"p=12*1.013*10^6;//pressure in dyne/sq.cm\n", +"v=1000;//intial voluume in cc\n", +"\n", +"//CALCULATIONS\n", +"t2=t1*(dv)^(y-1);//final temperature in K\n", +"r=(p*v)/t1;//universal gas constant in ergs/kg.K\n", +"w=r*(t1-t2)*log(1/dv);//work done in ergs\n", +"n=1-(t2/t1);//efficiency of the engine\n", +"\n", +"//OUTPUT\n", +"mprintf('the lowest temperature is %3.2f K \n work done is %3.2f ergs \n the efficiency of the engine is %3.2f',t2,w,n)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.9: Percentage_of_heat_produced_wasted.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"clc\n", +"clear\n", +"\n", +"//INPUT\n", +"l=964.8;//latent heat of steam in B.Th.U per lb\n", +"q=4*15*l*778;//heat developed in ft lbs\n", +"w=30000*60;//work done is ft lbs\n", +"\n", +"//CALCULATIONS\n", +"n=(w/q)*100;//efficiency of the engine\n", +"p=100-n;//percentage of heat wasted\n", +"\n", +"//OUTPUT\n", +"mprintf('the percentage of the heat wasted is %3.2f',p)" + ] + } +], +"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 +} |