From 92cca121f959c6616e3da431c1e2d23c4fa5e886 Mon Sep 17 00:00:00 2001 From: hardythe1 Date: Tue, 7 Apr 2015 15:58:05 +0530 Subject: added books --- .../Chapter18-Non-ideal_solutions.ipynb | 208 +++++++++++++++++++++ 1 file changed, 208 insertions(+) create mode 100755 Thermodynamics:_From_concepts_to_applications/Chapter18-Non-ideal_solutions.ipynb (limited to 'Thermodynamics:_From_concepts_to_applications/Chapter18-Non-ideal_solutions.ipynb') diff --git a/Thermodynamics:_From_concepts_to_applications/Chapter18-Non-ideal_solutions.ipynb b/Thermodynamics:_From_concepts_to_applications/Chapter18-Non-ideal_solutions.ipynb new file mode 100755 index 00000000..86e6ded4 --- /dev/null +++ b/Thermodynamics:_From_concepts_to_applications/Chapter18-Non-ideal_solutions.ipynb @@ -0,0 +1,208 @@ +{ + "metadata": { + "name": "", + "signature": "sha256:388411b55217b773ab745745bb0334d4f921763a66e2059d0e5fb20a6dddb702" + }, + "nbformat": 3, + "nbformat_minor": 0, + "worksheets": [ + { + "cells": [ + { + "cell_type": "heading", + "level": 1, + "metadata": {}, + "source": [ + "Chapter18-Non-ideal solutions" + ] + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example2-pg 385" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "import math\n", + "#what is saturation pressure\n", + "##initialisation of variables\n", + "T= 80. ##C\n", + "p= 30. ##percent\n", + "pw= 47.39 ##kPa\n", + "psat= 36 ##kPa\n", + "##RESULTS\n", + "print'%s %.1f %s'%(' Saturation pressure=',psat,'kPa')\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + " Saturation pressure= 36.0 kPa\n" + ] + } + ], + "prompt_number": 3 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example3-pg 385" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "import math\n", + "#what is temperature of pure water and saturation pressure\n", + "##initialisation of variables\n", + "T= 120. ##C\n", + "p= 30. ##percent\n", + "T2= 80. ##C\n", + "psat= 36. ##kPa\n", + "Tw= 73. ##C\n", + "##RESULTS\n", + "print'%s %.1f %s'% ('Temperature of pure water=',Tw,'C')\n", + "print'%s %.1f %s'% ('Saturation pressure=',psat,'kPa')\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "Temperature of pure water= 73.0 C\n", + "Saturation pressure= 36.0 kPa\n" + ] + } + ], + "prompt_number": 4 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example5-pg 395" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "import math\n", + "#calculate enthalpys at 4 point and maximum temperature and new enthalpy\n", + "##initialisation of variables\n", + "p= 10. ##bar\n", + "P= 40. ##percent\n", + "x= 0.4\n", + "H1= 16. ##kcal/kg\n", + "H2= 31. ##kcal/kg\n", + "H3= 64. ##kcal/kg\n", + "H4= 140. ##kcal/kg\n", + "T= 157. ##C\n", + "He= 580. ##kcal/kg\n", + "##RESULTS\n", + "print'%s %.f %s'% ('Enthalpy=',H1,'kcal/kg')\n", + "print'%s %.f %s'% ('Enthalpy=',H2,'kcal/kg')\n", + "print'%s %.f %s'% ('Enthalpy=',H3,'kcal/kg')\n", + "print'%s %.f %s'% ('Enthalpy=',H4,'kcal/kg')\n", + "print'%s %.f %s'% ('Maximum temperature=',T,'C')\n", + "print'%s %.f %s'% ('Enthalpy =',He,'kcal/kg')\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "Enthalpy= 16 kcal/kg\n", + "Enthalpy= 31 kcal/kg\n", + "Enthalpy= 64 kcal/kg\n", + "Enthalpy= 140 kcal/kg\n", + "Maximum temperature= 157 C\n", + "Enthalpy = 580 kcal/kg\n" + ] + } + ], + "prompt_number": 6 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example6-pg 397" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "import math\n", + "#what is enthalpy and circulation ratio and COP and COPcarnot\n", + "##initialisation of variables\n", + "v= 0.0011 ##m^3\n", + "P1= 1200 ##Mpa\n", + "P2= 140 ##Mpa\n", + "h5= -103 ##kJ/kg\n", + "x4= 0.860\n", + "x7= 0.253\n", + "x5= 0.337\n", + "h1= 1658.1 ##kJ/kg\n", + "h7= 343.7 ##kJ/kg\n", + "h6= -1008 ##kJ/kg\n", + "h4= 639. ##kJ/kg\n", + "h3= 40. ##kJ/kg\n", + "Tc= -10. ##C\n", + "Th= 125. ##C\n", + "Ta= 25. ##C\n", + "m1= 1. ##kg/s\n", + "m7= 6.23 ##kg/s\n", + "m6= 7.23 ##kg/s\n", + "##CALCULATIONS\n", + "h6= h5+v*(P1-P2)\n", + "cr= (x4-x7)/(x5-x7)\n", + "Qhbym= h1+(m7/m1)*h7-(m6/m1)*h6\n", + "Qcbym= h4-h3\n", + "COP= Qcbym/Qhbym\n", + "COPcarnot= ((273.15+Tc)/(273.15+Th))*((Th-Ta)/(Ta-Tc))\n", + "##RESULTS\n", + "print'%s %.1f %s'% (' Enthalpy=',h6,'kJ/kg')\n", + "print'%s %.3f %s'% (' circulation ratio=',cr,'')\n", + "print'%s %.3f %s'% (' COP=',COP,'')\n", + "print'%s %.3f %s'% (' COP carnot=',COPcarnot,'')\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + " Enthalpy= -101.8 kJ/kg\n", + " circulation ratio= 7.226 \n", + " COP= 0.132 \n", + " COP carnot= 1.888 \n" + ] + } + ], + "prompt_number": 7 + } + ], + "metadata": {} + } + ] +} \ No newline at end of file -- cgit