summaryrefslogtreecommitdiff
path: root/Basic_Mechanical_Engineering
diff options
context:
space:
mode:
authorJovina Dsouza2014-06-18 12:43:07 +0530
committerJovina Dsouza2014-06-18 12:43:07 +0530
commit206d0358703aa05d5d7315900fe1d054c2817ddc (patch)
treef2403e29f3aded0caf7a2434ea50dd507f6545e2 /Basic_Mechanical_Engineering
parentc6f0d6aeb95beaf41e4b679e78bb42c4ffe45a40 (diff)
downloadPython-Textbook-Companions-206d0358703aa05d5d7315900fe1d054c2817ddc.tar.gz
Python-Textbook-Companions-206d0358703aa05d5d7315900fe1d054c2817ddc.tar.bz2
Python-Textbook-Companions-206d0358703aa05d5d7315900fe1d054c2817ddc.zip
adding book
Diffstat (limited to 'Basic_Mechanical_Engineering')
-rw-r--r--Basic_Mechanical_Engineering/README.txt10
-rw-r--r--Basic_Mechanical_Engineering/bme1.ipynb1510
-rw-r--r--Basic_Mechanical_Engineering/bme2.ipynb1447
-rw-r--r--Basic_Mechanical_Engineering/bme6.ipynb942
-rw-r--r--Basic_Mechanical_Engineering/screenshots/ravi1.pngbin0 -> 65309 bytes
-rw-r--r--Basic_Mechanical_Engineering/screenshots/ravi2.pngbin0 -> 45601 bytes
-rw-r--r--Basic_Mechanical_Engineering/screenshots/ravi3.pngbin0 -> 40175 bytes
7 files changed, 3909 insertions, 0 deletions
diff --git a/Basic_Mechanical_Engineering/README.txt b/Basic_Mechanical_Engineering/README.txt
new file mode 100644
index 00000000..9d51031d
--- /dev/null
+++ b/Basic_Mechanical_Engineering/README.txt
@@ -0,0 +1,10 @@
+Contributed By: Ravi Garg
+Course: btech
+College/Institute/Organization: Gurgaon College of Engineering , MDU Rohtak
+Department/Designation: ECE
+Book Title: Basic Mechanical Engineering
+Author: G K Pathak and D K Chavan
+Publisher: Rajsons Publications, New Delhi
+Year of publication: 2009
+Isbn: 9788189401313
+Edition: 1 \ No newline at end of file
diff --git a/Basic_Mechanical_Engineering/bme1.ipynb b/Basic_Mechanical_Engineering/bme1.ipynb
new file mode 100644
index 00000000..fa3c24cb
--- /dev/null
+++ b/Basic_Mechanical_Engineering/bme1.ipynb
@@ -0,0 +1,1510 @@
+{
+ "metadata": {
+ "name": ""
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "Chapter 1: Fundamental Concepts and Definitions"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.1 Page No. 34"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find the work done\n",
+ "\n",
+ "#Input data\n",
+ "p=700\t\t #pressure of fluid in kN/m**2\n",
+ "v1=0.28\t\t#Initial volume of fluid in m**3\n",
+ "v2=1.68\t\t#Final volume of fluid in m**3\n",
+ "\n",
+ "#Calculations\n",
+ "W=p*(v2-v1)\t#Work done in kJ\n",
+ "\n",
+ "#Output\n",
+ "print'The Work done is',round(W,1),'KJ or',round(W/1000,3),'MJ'\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The Work done is 980.0 KJ or 0.98 MJ\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.2 Page No.35"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find the new volume of gas\n",
+ "\n",
+ "#Input data\n",
+ "p1=138.0\t\t#Initial pressure of gas in kN/m**2\n",
+ "p2=690.0\t\t#Final pressure of gas in kN/m**2\n",
+ "v1=0.112\t\t#Initial volume in m**3\n",
+ "\n",
+ "#Calculations\n",
+ "P=p1/p2\t\t#Pressure ratio\n",
+ "v2=v1*(P**(1/1.4))\t#Final volume of gas in m**3\n",
+ "\n",
+ "#Output\n",
+ "print'The new volume of the gas is',round(v2,3),\"m**3\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The new volume of the gas is 0.035 m**3\n"
+ ]
+ }
+ ],
+ "prompt_number": 9
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.3 Page No. 35"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find (a)Final volume of gas . \n",
+ "#(b)Work done by the gas during the expansion \n",
+ "\n",
+ "#Input data\n",
+ "p1=2070\t\t#Initial pressure of gas in kN/m**2\n",
+ "p2=207\t\t#Final pressure of gas in kN/m**2\n",
+ "v1=0.014\t\t#Initial volume of gas in m**3\n",
+ "n=1.35\t\t#constant\n",
+ "\n",
+ "#Calculations\n",
+ "P=p1/p2\t\t#Pressure ratio\n",
+ "v2=v1*(P**(1/1.35))\t#Final volume of gas in m**3\n",
+ "W=(p1*v1-p2*v2)/(n-1)\t#Work done in kJ\n",
+ "\n",
+ "#Output\n",
+ "print'(a)Final volume of gas ',round(v2,3),\"m**3 \"\n",
+ "print'(b)Work done by the gas during the expansion is',round(W,2),\"kJ\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)Final volume of gas 0.077 m**3 \n",
+ "(b)Work done by the gas during the expansion is 37.22 kJ\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.4 Page No.36"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find(a)Final pressure and the work done on gas\n",
+ "\n",
+ "#Input data\n",
+ "v1=0.056\t\t#Initial volume of gas in m**3\n",
+ "v2=0.007\t\t#Final volume of gas in m**3\n",
+ "p1=100\t\t#Initial perssure compressed Isothermally in kN/m**2\n",
+ "\n",
+ "#Calculations\n",
+ "p2=(p1*v1)/v2\t#Final pressure in kN/m**2\n",
+ "W=p1*v1*(math.log(v2/v1))\t#Work done in kJ\n",
+ "\n",
+ "#Output\n",
+ "print'(a)Final pressure is',round(p2,0),\"kN/m**2 \"\n",
+ "print'(b)The work done on gas is',round(-W,2), \"kJ\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)Final pressure is 800.0 kN/m**2 \n",
+ "(b)The work done on gas is 11.64 kJ\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ " Example 1.5 Page No. 37"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find the work done\n",
+ "\n",
+ "#Input data\n",
+ "v1=1.0\t\t#Initial volume in m**3\n",
+ "v2=3.0\t\t#Final volume in m**3\n",
+ "\n",
+ "#Calculations\n",
+ "import math\n",
+ "W=10**5*(((v2**3-v1**3)/3)+8*(math.log(v2/v1)))\t#Work done in J\n",
+ "\n",
+ "#Output\n",
+ "print'The work done is',round(W,0),\"Nm\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The work done is 1745556.0 Nm\n"
+ ]
+ }
+ ],
+ "prompt_number": 7
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.6 Page No. 38"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find The work done by the gas .\n",
+ "\n",
+ "#Input data\n",
+ "v1=0.2\t#Initial volume in m**3\n",
+ "v2=0.5\t#Final volume in m**3\n",
+ "\n",
+ "#Calculations\n",
+ "W=1500*(((v2**2-v1**2)/200)+(v2-v1))/1000\t#Work done in kJ\n",
+ "\n",
+ "#Output\n",
+ "print'The work done by the gas is',round(W,4),\"KJ\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The work done by the gas is 0.4516 KJ\n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.8 Page No. 39"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find The work done by the gas \n",
+ "\n",
+ "#Input data\n",
+ "v1=1.5\t\t#Initial volume in m**3\n",
+ "v2=2\t\t#Final volume in m**3\n",
+ "w1=2\t\t#Work receiving in Nm\n",
+ "p=6\t\t#constsnt pressure of gas in N/m**2\n",
+ "\n",
+ "#Calculations\n",
+ "w2=p*(v2-v1)\t#Work done in Nm\n",
+ "W=w2-w1\t\t#Net work done by the system in Nm\n",
+ "\n",
+ "#Output\n",
+ "print'Net work done by the system is',round(W,2),\"Nm\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Net work done by the system is 1.0 Nm\n"
+ ]
+ }
+ ],
+ "prompt_number": 20
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.9 Page No. 40"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find(a)Pressure of 80cm and 40 cm of Hg \n",
+ "#(c)Pressure due to 1.5m of water coloumn \n",
+ "#(d)Pressure in kPa for 5.2bar \n",
+ "\n",
+ "#Input data\n",
+ "d=13596\t\t#Density of Hg in kg/m**3\n",
+ "g=9.806\t\t#gravity in m/sec**2\n",
+ "z=760.0\t\t#Barometer pressure in mm of Hg\n",
+ "Pv=40.0\t\t#Vaccum pressure in cm\n",
+ "dw=1000.0\t\t#Density of water in kg/m**3\n",
+ "Zw=1.5\t\t#Level of water in m\n",
+ "\n",
+ "#Calculations\n",
+ "p=(d*g*z)/10**6\t#Pressure in kPa\n",
+ "p1=(80/76.0)*p\t#Pressure in kPa\n",
+ "Pa=p-Pv\t\t#Absolute pressure in kPa\n",
+ "p2=(36/76.0)*p\t#Pressure in kPa\n",
+ "p3=(dw*g*Zw)/1000.0\t\t#pressure in kPa\n",
+ "p4=(5.2*10**5)/1000.0\t#pressure in kPa\n",
+ "\n",
+ "#Output\n",
+ "print'(a)Pressure of 80cm of Hg is',round(p1,2),\"kPa\" \n",
+ "print'(b)Pressure of 40cm of Hg vaccum is',round(p2,2), \"kPa \"\n",
+ "print'(c)Pressure due to 1.5m of water coloumn is',round(p3*1000,4),\"N/m**2or Pa\" \n",
+ "print'(d)Pressure in kPa for 5.2bar is',round(p4,2),\"kPa\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)Pressure of 80cm of Hg is 106.66 kPa\n",
+ "(b)Pressure of 40cm of Hg vaccum is 48.0 kPa \n",
+ "(c)Pressure due to 1.5m of water coloumn is 14709.0 N/m**2or Pa\n",
+ "(d)Pressure in kPa for 5.2bar is 520.0 kPa\n"
+ ]
+ }
+ ],
+ "prompt_number": 10
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.10 Page No.41"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find the pressure at different conditions.\n",
+ "\n",
+ "\n",
+ "#Input data \n",
+ "z=750\t\t#Barometric pressure in mm of Hg\n",
+ "g=9.81\t\t#Gravity in m/sec**2\n",
+ "Pa=101.325\t#one atm pressure in kN/m**2\n",
+ "Pg=3.3\t\t#Pressure in atm\n",
+ "Pf=3.2\t\t#Pressure in m of water\n",
+ "d=13596\t\t#Density of Hg in kg/m**3\n",
+ "\n",
+ "#calculations\n",
+ "Pp=(d*g*z)/10**6\t\t #Pressure in kPa\n",
+ "p1=(d*g*0.55)/1000.0\t\t #Pressure in kPa\n",
+ "p2=Pp+(Pg*101.325)\t #Pressure in kPa\n",
+ "p3=Pp+(Pf*g*100)/1000.0\t#Pressure in kPa\n",
+ "p4=4.6*100\t\t #Pressure in kPa\n",
+ "\n",
+ "#Output\n",
+ "print'(a)Pressure of 55cm of Hg (Abs)',round(p1,1),\"KPa\"\n",
+ "print'(b)Pressure at 3.3 atm (Gauge)',round(p2,1),\"kPa\" \n",
+ "print'(c)Pressure of 3.2m of water (Gauge)',round(p3,1),\"kPa\" \n",
+ "print'NOTE: In the book there is mistake in calculation p3 '\n",
+ "print'(d)Pressure of 4.6bar (Abs)',round(p4,1),\"kPa\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)Pressure of 55cm of Hg (Abs) 73.4 KPa\n",
+ "(b)Pressure at 3.3 atm (Gauge) 434.4 kPa\n",
+ "(c)Pressure of 3.2m of water (Gauge) 103.2 kPa\n",
+ "NOTE: In the book there is mistake in calculation p3 \n",
+ "(d)Pressure of 4.6bar (Abs) 460.0 kPa\n"
+ ]
+ }
+ ],
+ "prompt_number": 13
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.11 Page No. 42"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find the absolute pressure\n",
+ "\n",
+ "#Input data\n",
+ "Zw=50\t\t#Manometer reading of water in cm\n",
+ "Zo=763\t\t#Atmospheric pressure in mm of Hg\n",
+ "d=13.6*10**3\t#Density of Hg in kg/m**3\n",
+ "dw=1000\t\t#Density of water in kg/m**3\n",
+ "g=9.81\t\t#Gravity in m/sec**2\n",
+ "\n",
+ "#Calculations\n",
+ "Pa=(d*g*Zo)/10**6\t\t#Atmospheric pressure in kPa\n",
+ "Pg=(dw*g*Zw)/10**5\t#Gauge pressure in kPa\n",
+ "Pab=Pa+Pg\t\t#Absolute pressure in kPa\n",
+ "\n",
+ "#Output\n",
+ "print'Absolute pressure is',round(Pab,2),\"kPa\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Absolute pressure is 106.7 kPa\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.12 Page No. 42"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find the absolute pressure\n",
+ "\n",
+ "#Input data\n",
+ "Z=70\t\t\t#Vaccum gauge reading in cm of Hg\n",
+ "Pa=101.325\t\t#Atmospheric pressure in kPa\n",
+ "d=13.6*10**3\t\t#Density of Hg in kg/m**3\n",
+ "g=9.81\t\t\t#Gravity in m/sec**2\n",
+ "\n",
+ "#Calculations\n",
+ "Pv=(d*g*Z)/10**5\t\t#Vaccum pressure in kPa\n",
+ "Pab=Pa-Pv\t\t#Absolute pressure in kPa\n",
+ "\n",
+ "#Output\n",
+ "print'Absolute pressure is',round(Pab,2),\"kPa\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Absolute pressure is 7.93 kPa\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.13 Page No. 43"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find the absolute pressure\n",
+ "\n",
+ "#Input data\n",
+ "Pv=30\t\t#Vaccum pressure in kPa\n",
+ "Z=755\t\t#Barometer reading in mm of Hg\n",
+ "d=13590\t\t#Density of Hg in kg/m**3\n",
+ "g=9.81\t\t#Gravity in m/sec**2\n",
+ "\n",
+ "#calculations \n",
+ "Pa=(d*g*Z)/10**6\t#Atmospheric perssure in kPa\n",
+ "Pab=Pa-Pv\t#Absolute pressure in kPa\n",
+ "\n",
+ "#Output\n",
+ "print'Asolute pressure in the tank is',round(Pab,2),\"kPa\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Asolute pressure in the tank is 70.66 kPa\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.14 Page No. 43"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ " #Find the gas pressure\n",
+ "\n",
+ "#Input data\n",
+ "Z=0.562\t\t#Level of open limb in m\n",
+ "Z1=0.761\t\t#Barometer reading in m of Hg\n",
+ "g=9.79\t\t#Gravity in m/sec**2\n",
+ "d=13640\t\t#Density of Hg in kg/m**2\n",
+ "\n",
+ "#Calculations\n",
+ "Pa=(d*g*Z1)/1000.0\t#Atmospheric pressure in kPa\n",
+ "Ph=(d*g*Z)/1000.0\t#Pressure exercterd due to height in kPa\n",
+ "Pab=Pa+Ph\t#Absolute pressure in kPa\n",
+ "\n",
+ "#Output\n",
+ "print'The gas pressure is',round(Pab,3),\"kN/m**2\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The gas pressure is 176.668 kN/m**2\n"
+ ]
+ }
+ ],
+ "prompt_number": 14
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.15 Page No. 44"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#What is Absolute pressure of the gas\n",
+ "\n",
+ "#Input data \n",
+ "d=13.596*10**3\t#Density of Hg in kg/m**3\n",
+ "dl=800\t\t#Density of liquid in kg/m**3\n",
+ "Z=30\t\t#Level of the liquid in the arm in cm\n",
+ "Z1=0.75\t\t#Barometric pressure in m\n",
+ "g=9.81\t\t#Gravity in m/sec**2\n",
+ "\n",
+ "#Calculatins\n",
+ "Pg=(dl*g*Z)/10**7\t#Gauge pressure in bar\n",
+ "Pa=(d*g*Z1)/10**5\t#Atmospheric pressure in bar\n",
+ "Pab=Pa+Pg #Absolute pressure in bar\n",
+ "\n",
+ "#Output\n",
+ "print'Absolute pressure of the gas is',round(Pab,2),\"bar\"\n",
+ "print'NOTE:In the book there is calculation mistake in last step'"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Absolute pressure of the gas is 1.02 bar\n",
+ "NOTE:In the book there is calculation mistake in last step\n"
+ ]
+ }
+ ],
+ "prompt_number": 16
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.16 Page No. 45"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Determine Absolute pressure of the gas\n",
+ "\n",
+ "#Input data\n",
+ "Z1=0.17\t\t#Level of liquid in m\n",
+ "Z=0.76\t\t#Barometer readings in m\n",
+ "d=13596\t\t#Density of Hg in kg/m**3\n",
+ "g=9.806\t\t#Gravity in m/sec**2\n",
+ "s=0.8\t\t#Specific gravity \n",
+ "d1=1000\t\t#Density of water in kg/m**3\n",
+ "\n",
+ "#Calculations\n",
+ "dl=s*d1\t\t#Density of given liquid in kg/m**3\n",
+ "Pa=d*g*Z\t\t#Atmospheric pressure in N/m**2\n",
+ "p=dl*g*Z1\t#Pressure in N/m**2\n",
+ "Pab=(Pa-p)/10**5\t#Absolute pressure in bar\n",
+ "\n",
+ "#Output\n",
+ "print'Absolute pressure of the gas is',round(Pab),\"bar\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Absolute pressure of the gas is 1.0 bar\n"
+ ]
+ }
+ ],
+ "prompt_number": 18
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.17 Page No. 46"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#determine Absolute pressure of the steam\n",
+ "\n",
+ "#Input data\n",
+ "g=9.806\t\t#Gravity in m/sec**2\n",
+ "d=13596\t\t#Density of Hg in kg/m**3\n",
+ "Z=9.75\t\t#Level of Hg in cm\n",
+ "dw=1000\t\t#Density of water in kg/m**3\n",
+ "Zw=0.034\t\t#Coloumn of condensate in m\n",
+ "Zo=0.76\t\t#Atmospheric pressure in m of Hg\n",
+ "\n",
+ "#Calculations\n",
+ "P=dw*g*Zw\t #Pressure in N/m**2\n",
+ "Pa=d*g*Zo\t #Atmospheric pressure in N/m**2\n",
+ "Pg=(d*g*Z)/100.0\t#Gauge pressure in N/m**2\n",
+ "Pab=(Pa+Pg-P)/10**5\t#Absolute pressure in bar\n",
+ "\n",
+ "#Output\n",
+ "print'Pressure due to height is',round(P,3),'N/m**2'\n",
+ "print'Atmospheric Pressure is ',round(Pa,0),'N/m**2'\n",
+ "print'Absolute pressure of steam is',round(Pab,4),\"bar\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Pressure due to height is 333.404 N/m**2\n",
+ "Atmospheric Pressure is 101325.0 N/m**2\n",
+ "Absolute pressure of steam is 1.1399 bar\n"
+ ]
+ }
+ ],
+ "prompt_number": 23
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.18 Page No. 47"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#determine Absolute pressure of the steam\n",
+ "\n",
+ "#Input data\n",
+ "g=9.7\t\t #Gravity in m/sec**2\n",
+ "d=13.69*10**3\t#Density of Hg in kg/m**3\n",
+ "dw=1000\t\t #Density of water in kg/m**3\n",
+ "Pa=98\t \t#Atmospheric pressure in kPa\n",
+ "Z=0.6\t \t#Manometer level difference in m of Hg\n",
+ "Zw=0.04\t\t #Water coloumn level in m\n",
+ "\n",
+ "#Calculations \n",
+ "Pw=(dw*g*Zw)/1000.0\t#Pressure due to water in kPa\n",
+ "Pg=(d*g*Z)/1000.0\t\t#Pressure in kPa\n",
+ "Pab1=Pa+Pg-Pw\t\t#Absolute pressure in kPa\n",
+ "Pab=Pab1/100.0\t\t #Absolute pressure in bar\n",
+ "\n",
+ "#Output \n",
+ "print'The absolute pressure of steam is',round(Pab,2),\"bar\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The absolute pressure of steam is 1.77 bar\n"
+ ]
+ }
+ ],
+ "prompt_number": 16
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.19 Page No. 48"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#find Absolute pressure of the steam\n",
+ "\n",
+ "#Input data\n",
+ "Z=0.76\t\t#Actual height of mercury coloumn in m\n",
+ "g=9.806\t\t#Gravity in m/sec**2\n",
+ "d=13596\t\t#Density of Hg in kg/m**3\n",
+ "dw=1000\t\t#Density of water in kg/m**3\n",
+ "Zw=0.035\t\t#Height of condensate coloumn in m\n",
+ "Zh=0.10\t\t#Height of mercury coloumn in m\n",
+ "\n",
+ "#Calculations\n",
+ "Pa=d*g*Z\t\t#Atmospheric pressure in N/m**2\n",
+ "Pw=dw*g*Zw\t#Pressure due to water in N/m**2\n",
+ "Ph=d*g*Zh\t#Pressure due to Hg in N/m**2\n",
+ "Pab=(Pa+Ph-Pw)/10**5\t#Absolute pressure in bar\n",
+ "\n",
+ "#Output \n",
+ "print'Absolute pressure of steam in the pipe is',round(Pab,2),\"bar\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Absolute pressure of steam in the pipe is 1.14 bar\n"
+ ]
+ }
+ ],
+ "prompt_number": 17
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.20Page No. 49"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#What is Absolute pressure of the gas\n",
+ "\n",
+ "#Input data\n",
+ "dk=800\t\t#Density of kerosene in kg/m**3\n",
+ "g=9.81\t\t#gravity in m/sec**2\n",
+ "Zk=0.051\t\t#Kerosene vapour on Hg coloumn in m\n",
+ "d=13600\t\t#Density of Hg in kg/m**3\n",
+ "Zh=0.1\t\t#Hg level in m\n",
+ "Z=0.755\t\t#Atmospheric pressure in m of Hg\n",
+ "\n",
+ "#Calculations\n",
+ "Pk=dk*g*Zk\t\t #Pressure of kerosene in N/m**2\n",
+ "Pa=d*g*Z\t\t #Atmospheric pressure in N/m**2\n",
+ "Ph=d*g*Zh \t#Pressure due to Hg in N/m**2\n",
+ "Pab=(Pa+Ph-Pk)/1000.0\t#Absolute pressure in kPa\n",
+ "\n",
+ "#Output \n",
+ "print'Absolute pressure of vapour is ',round(Pab,2),\"kPa\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Absolute pressure of vapour is 113.67 kPa\n"
+ ]
+ }
+ ],
+ "prompt_number": 19
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.21 Page No. 50"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#find (a)The Absolute pressure of the gas in pipe line and \n",
+ "#(b)If the fluid used is Hg then the difference of height of Hg coloumn in the 2 arms .\n",
+ "\n",
+ "#Input data\n",
+ "d=13596\t\t#Density of Hg in kg/m**3\n",
+ "g=9.806\t\t#Gravity in m/sec**2\n",
+ "df=0.8*1000\t#Density of fluid in kg/m**3\n",
+ "Z=0.76\t\t#Atmospheric pressure in m of Hg\n",
+ "Zf=0.3\t\t#Height of fluid coloumn in m\n",
+ "\n",
+ "#Calculations\n",
+ "Pa=d*g*Z\t\t#Atmospheric perssure in N/m**2\n",
+ "P=df*g*Zf\t#Pressure due to fluid in N/m**2\n",
+ "Pab=(Pa+P)/10**5\t#Absolute pressure in bar\n",
+ "Zh=((Pab*10**5-Pa)/(d*g))*100\t#Difference between the height of Hg coloumn in 2 arms in m\n",
+ "\n",
+ "#Output\n",
+ "print'(a)The Absolute pressure of the gas in pipe line Pab',round(Pab,2),\" bar\" \n",
+ "print'(b)If the fluid used is Hg then the difference of height of Hg coloumn in the 2 arms is',round(Zh,2),\"cm\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ " (a)The Absolute pressure of the gas in pipe line Pab 1.04 bar\n",
+ "(b)If the fluid used is Hg then the difference of height of Hg coloumn in the 2 arms is 1.77 cm\n"
+ ]
+ }
+ ],
+ "prompt_number": 21
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.22 Page No. 51"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find the pressure at the bottom and inner surface of oil and water\n",
+ "\n",
+ "#Input data\n",
+ "Pa=1\t\t#Atmospheric pressure in bar\n",
+ "g=9.81\t\t#Gravity in m/sec**2\n",
+ "do=0.8*1000\t#Density of oil in kg/m**3\n",
+ "Zo=0.8\t\t#Level of oil in m\n",
+ "dw=1000\t\t#Density of water in kg/m**3\n",
+ "Zw=0.65\t\t#Level of water in m\n",
+ "d=13.6*10**3\t#Density of Hg in kg/m**3\n",
+ "Z=0.45\t\t#Level of Hg in m\n",
+ "\n",
+ "#Calculations\n",
+ "Po=(do*g*Zo)/10**5\t#Pressure of oil in bar\n",
+ "Pw=(dw*g*Zw)/10**5\t#Pressure of water in bar\n",
+ "P=(d*g*Z)/10**5\t\t#Pressure of Hg in bar\n",
+ "Pab=Pa+Po+Pw+P\t\t#Pressure at the bottom of the coloumn in bar\n",
+ "Pow=Pa+Po\t\t#Pressure at the interface of oil and water in bar\n",
+ "Poh=Pa+Po+Pw\t\t#Pressure at the interface of water and Hg\n",
+ "\n",
+ "#Output\n",
+ "print'(a)Pressure at the bottom of the coloumn is',round(Pab,2),\"bar\" \n",
+ "print'(b)Pressure at the inter surface of oil and water ia',round(Pow,3),\"bar \" \n",
+ "print'(c)Pressure at the inter surface of water and Hg ',round(Poh,3),\"bar\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)Pressure at the bottom of the coloumn is 1.73 bar\n",
+ "(b)Pressure at the inter surface of oil and water ia 1.063 bar \n",
+ "(c)Pressure at the inter surface of water and Hg 1.127 bar\n"
+ ]
+ }
+ ],
+ "prompt_number": 24
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.23 Page No. 52"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find the height of fluid for oil , water and Hg manometer\n",
+ "\n",
+ "#Input data\n",
+ "Z=0.76\t\t#Barometer reading in m\n",
+ "g=9.81\t\t#Gravity in m/sec**2\n",
+ "d=13.6*10**3\t#Density of Hg in kg/m**3\n",
+ "Pab=1.2*10**5\t#Absolute pressure in N/m**2\n",
+ "do=0.8*1000\t#Density of oil in kg/m**3\n",
+ "dw=1000\t\t#Density of water in kg/m**3\n",
+ "dh=13.6*10**3\t#Density of Hg in kg/m**3\n",
+ "\n",
+ "#calculations\n",
+ "Pa=dh*g*Z\t#Atmospheric pressure in N/m**2\n",
+ "Pg=Pab-Pa\t#Gauge pressure in N/m**2\n",
+ "Zo=Pg/(do*g)\t#Height of oil in manometer in m\n",
+ "Pw=Pab-Pa\t#Pressure exercted by water in N/m**2\n",
+ "Zw=Pw/(dw*g)\t#Height of water in manometer in m\n",
+ "P=Pab-Pa\t\t#Pressure of Hg in N/m**2\n",
+ "Zh=P/(d*g)\t#Height of Hg in manometer in m\n",
+ "\n",
+ "#Output\n",
+ "print'(a)The height of fluid for oil Manometer',round(Zo,2),\"m \"\n",
+ "print'(b)The height of fluid for water Manometer ia',round(Zw,2),\"m\" \n",
+ "print'(c)The height of fluid for Hg Manometer is',round(Zh,3),\"m\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)The height of fluid for oil Manometer 2.37 m \n",
+ "(b)The height of fluid for water Manometer ia 1.9 m\n",
+ "(c)The height of fluid for Hg Manometer is 0.139 m\n"
+ ]
+ }
+ ],
+ "prompt_number": 26
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.24 Page No. 54"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find The altitude of the plane from ground level \n",
+ "\n",
+ "#Input data\n",
+ "Zg=0.753\t\t#Barometer reading at ground level in m\n",
+ "Zp=0.690\t\t#Pilots barometer reading in the plane in m\n",
+ "d=13600\t\t#Density of Hg in kg/m**3\n",
+ "g=9.81\t\t #Gravity in m/sec**2\n",
+ "da=1.25\t\t#Density of air in kg/m**3\n",
+ "\n",
+ "#Calculations\n",
+ "Pg=d*g*Zg\t#Pressure at ground level in N/m**2\n",
+ "Pp=d*g*Zp\t#Pressure at plane level in N/m**2\n",
+ "P=Pg-Pp\t\t#Change of pressure at ground level and that of plane level in N/m**2\n",
+ "Za=P/(da*g)\t#Altitude of plane from ground in m\n",
+ "\n",
+ "#Output \n",
+ "print'The altitude of the plane from ground level is',round(Za,1),\"m\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The altitude of the plane from ground level is 685.4 m\n"
+ ]
+ }
+ ],
+ "prompt_number": 26
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.25 Page No. 54"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find Pressure exercted \n",
+ "\n",
+ "#Input data\n",
+ "dw=1000\t\t#Density of water in kg/m**3\n",
+ "dh=13590\t\t#Density of Hg in kg/m**3\n",
+ "Pa=400\t\t#Pressure at A in kPa\n",
+ "g=9.81\t\t#Gravity in N/m**2\n",
+ "Zw1=2.5\t\t#First level of water in m\n",
+ "Zw2=0.4\t\t#Second level of water in m\n",
+ "Zh=0.6\t\t#Level of Hg in m\n",
+ "\n",
+ "#Calculations \n",
+ "Pw1=dw*g*Zw1\t#First level of water pressure in N/m**2\n",
+ "Pw2=dw*g*Zw2\t#Second level of water pressure in n/m**2\n",
+ "Ph=dh*g*Zh\t#Pressure of Hg in N/m**2\n",
+ "Pb=((Pa*1000)+Pw1+Pw2-Ph)/1000\t#Pressure exercted at B in kPa\n",
+ "\n",
+ "#Output\n",
+ "print'Pressure exercted at B is',round(Pb,2),\"KPa\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Pressure exercted at B is 348.46 KPa\n"
+ ]
+ }
+ ],
+ "prompt_number": 29
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.26 Page No. 55"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#What is The total weight of piston and slab \n",
+ "\n",
+ "#Input data\n",
+ "do=0.902*10**3\t#Density of oil in kg/m**3\n",
+ "Pg=2*10**5\t #Gauge pressure in N/m**2\n",
+ "g=9.81\t\t #Gravity in m/sec**2\n",
+ "ho=2\t\t #Level of oil in m\n",
+ "d=2\t\t #Diameter of cylinder in m\n",
+ "pi=3.141595\t#Constant value of pi\n",
+ "\n",
+ "#Calculations\n",
+ "A=(pi/4.0)*d**2 #Area of cylinder \n",
+ "Po=do*g*ho\t # Pressure due to oil in N/m**2\n",
+ "W=(Pg+Po)*A\t #Weight of the piston in N\n",
+ "\n",
+ "#Output\n",
+ "print'The total weight of piston and slab is',round(W,2),\"N\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The total weight of piston and slab is 683916.56 N\n"
+ ]
+ }
+ ],
+ "prompt_number": 27
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.27 Page No. 56"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#What is The pressure in the gas \n",
+ "\n",
+ "#Input data\n",
+ "m=21\t\t#Mass of piston in kg\n",
+ "P1=600\t\t#Pressure in the pipe 1 in kPa\n",
+ "P2=170\t\t#Pressure in the pipe 2 in kPa\n",
+ "d1=0.10\t\t#Diameter of the piston 1 in m\n",
+ "d2=0.20\t\t#Diameter of the piston 2 in m\n",
+ "pi=3.14155\t#Constant value of pi\n",
+ "\n",
+ "#Calculations\n",
+ "F=(m*9.81)/1000\t\t#Force due to mass in kN\n",
+ "F1=(pi/4)*d1**2*P1\t\t#Force 1 acting on 10 cm diameter piston in kN\n",
+ "F2=(pi/4)*(d2**2-d1**2)*P2\t#Force 2 acting on 20 cm diameter piston in kN\n",
+ "F3=F+F1+F2\t\t#Total downward force in kN\n",
+ "P3=F3/((pi/4)*d2**2)\t#Pressure 3 in the gas in kPa\n",
+ "\n",
+ "#Output\n",
+ "print'The pressure in the gas is ',round(P3,2),\"KPa\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The pressure in the gas is 284.06 KPa\n"
+ ]
+ }
+ ],
+ "prompt_number": 35
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.28 Page No. 57"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#What is The height of the building\n",
+ "\n",
+ "#Input data\n",
+ "P1=0.755\t\t#Barometric reading at the bottom of the building in m\n",
+ "P2=0.73\t\t#Barometric reading at the top of the building in m\n",
+ "da=1.18\t\t#Density of air in kg/m**3\n",
+ "g=9.81\t\t#Gravitalional constant in m/sec**2\n",
+ "d=13600\t\t#Density of Hg in kg/m**3\n",
+ "\n",
+ "#Calculations\n",
+ "h=((P1-P2)*d*g)/(da*g) #The height of the building in m\n",
+ "\n",
+ "#Output\n",
+ "print'The height of the building ',round(h,1),\"m\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The height of the building 288.1 m\n"
+ ]
+ }
+ ],
+ "prompt_number": 37
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.29 Page No. 58"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find The absolute pressure in the container A and B\n",
+ "\n",
+ "#Given\n",
+ "PA=200\t\t#Gauge pressure reading for A in kPa\n",
+ "PB=120\t\t#Gauge pressure reading for B in kPa\n",
+ "hb=750\t\t#Barometer reading in mm of Hg\n",
+ "g=9.806\t\t#Gravitational constant in m/sec**2\n",
+ "d=13597\t\t#Density of Hg in barometer in kg/m**3\n",
+ "\n",
+ "#Calculations\n",
+ "Pa=d*g*hb/10**6\t#Atmospheric pressure in kPa\n",
+ "Pab1=PA+Pa\t#Absolute pressure in container A in kPa\n",
+ "Pab2=PB+Pab1\t#Absolute pressure in container B in kPa\n",
+ "\n",
+ "#Output \n",
+ "print'(a)The absolute pressure in the container A is',round(Pab1,1),\"kPa\" \n",
+ "print'(b)The absolute pressure in the container B is ',round(Pab2,2),\"kPa\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)The absolute pressure in the container A is 300.0 kPa\n",
+ "(b)The absolute pressure in the container B is 420.0 kPa\n"
+ ]
+ }
+ ],
+ "prompt_number": 38
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.30 Page No. 59"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Determine the temprature in fahreneheit\n",
+ "\n",
+ "#Input data\n",
+ "C1=40\t\t #Temperature 1 in degree centigrade\n",
+ "C2=-20\t\t#Temperature 2 in degree centigrade \n",
+ "\n",
+ "#calculations\n",
+ "F1=((C1/100.0)*180)+32\t#Temperature 1 in Fahrenheit\n",
+ "F2=((C2/100.0)*180)+32\t#Temperature 2 in Fahrenheit\n",
+ "\n",
+ "#Output\n",
+ "print'(a)Temperature after converting 40 degree C is',round(F1,2),\"F\"\n",
+ "print'(b)Temperature after convertibg -20 degree C is ',round(F2,2),\"F\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)Temperature after converting 40 degree C is 104.0 F\n",
+ "(b)Temperature after convertibg -20 degree C is -4.0 F\n"
+ ]
+ }
+ ],
+ "prompt_number": 27
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.31 Page No. 59"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find The temperature which has the same value on both the centrigrade and fahrenheit scales\n",
+ "\n",
+ "#Given that the temperature has the same value on both the centrigrade and fahrenheit scales\n",
+ "#(C/100)=((F-32)/180)\n",
+ "\n",
+ "#Putting C=F\n",
+ "C=(-32/180.0)/((1/100.0)-(1/180.0))\t#Centrigade temperature in degree C\n",
+ "F=C\t\t\t#Fahrenheit temperature in degree Fahrenheit\n",
+ "\n",
+ "print'The temperature which has the same value on both the centrigrade and fahrenheit scales is',C\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The temperature which has the same value on both the centrigrade and fahrenheit scales is -40.0\n"
+ ]
+ }
+ ],
+ "prompt_number": 40
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.32 Page No. 59"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Determine the temprature\n",
+ "\n",
+ "#Input data\n",
+ "P1=1.5\t\t#Thermometric properties at ice point\n",
+ "P2=7.5\t\t#Thermometric properties at steam point\n",
+ "P3=3.5\t\t#Thermometric property\n",
+ "\n",
+ "#Calculations\n",
+ "import math\n",
+ "M = array([[math.log(P2), 1], [math.log(P1), 1]])\n",
+ "N=([100,0])\n",
+ "X=inv(M)*N #Inverse matrix\n",
+ "a=X[0,0]\n",
+ "b=X[1,0]\n",
+ "t=(a*math.log(P3)+b)\t#Required temperature in degree C\n",
+ "\n",
+ "#Output\n",
+ "print'The required temperature is ',round(t,2),\"C\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The required temperature is 52.65 C\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.33 Page No. 60"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#What is Temperature corresponding to the thermometric property\n",
+ "\n",
+ "#Input data\n",
+ "T1=100\n",
+ "T2=300 #Temperature of ice and steam point in the scale\n",
+ "P1=1.86\t\t #Values of thermometric properties at ice point nad steam point respectively\n",
+ "P2=6.8\n",
+ "P=2.5\t\t\t #Thermometric property\n",
+ "\n",
+ "#Calculations\n",
+ "import math\n",
+ "#aln(P2)+b=300 #Costants in the temprature scale reading, a and b\n",
+ "#aln(P1)+b=100\n",
+ "#Solving above two equations\n",
+ "a=(T2-T1)/(math.log(P2/P1)) \n",
+ "b=T2-a*math.log(P2)\n",
+ "t=(a*math.log(P)+b)\t#Required temperature in degree C\n",
+ "\n",
+ "#Output\n",
+ "print'Temperature corresponding to the thermometric property is ',round(t,1),\"C\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Temperature corresponding to the thermometric property is 145.6 C\n"
+ ]
+ }
+ ],
+ "prompt_number": 21
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.34 Page No. 60"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Determine the required temprature\n",
+ "\n",
+ "#Input data\n",
+ "p1=32.0\t\t #Pressure in mm of Hg at triple point of water\n",
+ "p2=76.0\t\t #Pressure in mm of Hg above atmospheric pressure\n",
+ "p3=752.0\t\t#Barometric pressure in mm of Hg\n",
+ "T=273.16\t\t#Triple point of water in K\n",
+ "\n",
+ "#Calculations\n",
+ "P1=p3+p1\t#Total pressure in mm of Hg\n",
+ "P2=p2+p3\t#Total pressure in mm of Hg\n",
+ "T2=((T*P2)/P1)-273.16\t#Temperture in degree C\n",
+ "\n",
+ "#Output\n",
+ "print'Temperature is ',round(T2,2),\"C\"\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Temperature is 15.33 C\n"
+ ]
+ }
+ ],
+ "prompt_number": 20
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 1.35 Page No.61"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Determine Temperature corresponding to the thermometric property \n",
+ "\n",
+ "#Input data\n",
+ "T1=32\t\t#Temperatures of ice point and steam point respectively\n",
+ "T2=212\n",
+ "P1=1.86\t\t #P values at ice point and steam point respectively\n",
+ "P2=6.81\n",
+ "P=2.5\t\t\t#Reading on the thermometer\n",
+ "\n",
+ "#Calculations\n",
+ "import math\n",
+ "#aln(P1)+b=32 #Costants in the given temprature scale reading, a and b\n",
+ "#aln(P2)+b=212\n",
+ "#Solving above two equations\n",
+ "a=(T2-T1)/(math.log(P2/P1)) \n",
+ "b=T2-a*math.log(P2)\n",
+ "t=(a*math.log(P)+b)\t#Required temperature in degree C\n",
+ "\n",
+ "#Output\n",
+ "print'Temperature corresponding to the thermometric property is ',round(t,0),\"C\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Temperature corresponding to the thermometric property is 73.0 C\n"
+ ]
+ }
+ ],
+ "prompt_number": 39
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Basic_Mechanical_Engineering/bme2.ipynb b/Basic_Mechanical_Engineering/bme2.ipynb
new file mode 100644
index 00000000..71e898ae
--- /dev/null
+++ b/Basic_Mechanical_Engineering/bme2.ipynb
@@ -0,0 +1,1447 @@
+{
+ "metadata": {
+ "name": ""
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "Chapter 2:First Law of Thermodynamics"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.1 Page No.90"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#What is net work transfer in a cycle\n",
+ "\n",
+ "#Input data\n",
+ "h1=60\t\t#The heat transfer in the process in kJ\n",
+ "h2=-8\t\t#The heat transfer in the process in kJ\n",
+ "h3=-34\t\t#The heat transfer in the process in kJ\n",
+ "h4=6\t\t#The heat transfer in the process in kJ\n",
+ "\n",
+ "#Calculations\n",
+ "Q=h1+h2+h3+h4\t\t#Net work transfer in a cycle in kJ\n",
+ "\n",
+ "#Output\n",
+ "print'Net work transfer in a cycle is',round(Q,2),\"KJ\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Net work transfer in a cycle is 24.0 KJ\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.2 Page No. 90"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#FinThe work done on the system\n",
+ "\n",
+ "#Input data\n",
+ "Q=-300\t\t#Heat transfer in the system consisting of the gas in kJ\n",
+ "u=0\t\t#Internal energy is constant\n",
+ "\n",
+ "#Calculations\n",
+ "W=Q-u\t\t#Work done of the system in kJ\n",
+ "\n",
+ "#Output\n",
+ "print'The work done of the system W = %3.0f kJ ',round(W,1),\"KJ\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The work done of the system W = %3.0f kJ -300.0 KJ\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.3 Page No. 90"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Input data\n",
+ "v1=1.5\t\t#Initial volume of the process in m**3\n",
+ "v2=4.5\t\t#Final volume of the process in m**3\n",
+ "Q=2000\t\t#Amount of heat added in kJ\n",
+ "\n",
+ "#Calculations\n",
+ "W=100*((3.5*math.log(v2/v1))+(3*(v2-v1)))\t#Amount of work done in kJ\n",
+ "U=Q-W\t\t\t\t\t#The change in internal energy in kJ\n",
+ "\n",
+ "#Output\n",
+ "print'The change in internal energy is',round(U,2),\"KJ\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The change in internal energy is 715.49 KJ\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.4 Page No.91"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#What is the heat transfer per kg of steam\n",
+ "\n",
+ "#Input data\n",
+ "h1=35\t\t#Enthalpy of water entering the boiler in kJ/kg\n",
+ "h2=705\t\t#Enthalpy of steam leaving the boiler in kJ/kg\n",
+ "C=0\t\t#Change in kinetic energy is neglected\n",
+ "Z=0\t\t#Change in potential energy is neglected\n",
+ "\n",
+ "#Calculations\n",
+ "q=h2-h1\t\t#The heat transfer per kg of steam in kJ/kg\n",
+ "\n",
+ "#Output\n",
+ "print'The heat transfer per kg of steam is',round(q,1),\"kJ/kg\"\t\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The heat transfer per kg of steam is 670.0 kJ/kg\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.5 Page No. 92"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Determine (a)Change in energy in a-b,b-c,c-d,d-a process \n",
+ "#Heat developed in the process d-a \n",
+ "#Work done in the d-a process \n",
+ "#Net rate of work output\n",
+ "\n",
+ "#Input data\n",
+ "Q=-170\t\t#Sum of all heat transfers per cycle in kJ\n",
+ "N=100\t\t#Total number of cycles per min in cycles/min\n",
+ "Q1=0\t\t#Heat developed in a-b process in kJ/min\n",
+ "Q2=21000\t\t#Heat developed in b-c process in kJ/min\n",
+ "Q3=-2100\t\t#Heat developed in c-d process in kJ/min\n",
+ "W1=2170\t\t#Work done in the process a-b in kJ/min\n",
+ "W2=0\t\t#Work done in the b-c process in kJ/min\n",
+ "E3=-36600\t#Change in energy in the process in kJ/min\n",
+ "\n",
+ "#Calculations\n",
+ "E1=Q1-W1\t\t#Change in energy in process a-b in kJ/min\n",
+ "E2=Q2-W2\t\t#Change in energy in b-c process in kJ/min\n",
+ "W3=Q3-E3\t\t#Work done in the c-d process in kJ/min\n",
+ "Qt=Q*N\t\t\t#Total heat transfer per min in kJ/min \n",
+ "Q4=Qt-Q1-Q2-Q3\t\t#Heat developed in the process d-a in kJ/min\n",
+ "Et=0\t\t\t#Total change in energy of the cycle\n",
+ "E4=Et-E1-E2-E3\t\t#Energy in the process d-a in kJ/min\n",
+ "W4=Q4-E4\t\t#Work done in the d-a process in kJ/min \n",
+ "Wn=Qt/60.0\t\t#Net rate of work output in kW\n",
+ "\n",
+ "#Output\n",
+ "print'(a)Change in energy in a-b process is',round(E1,2),\"kJ/min\"\n",
+ "print'(b)Change in energy in b-c process is',round(E2,2),\"kJ/min\"\n",
+ "print'(c)Work done in the c-d process is',round(W3,2),\"kJ/min\"\n",
+ "print'(d)Heat developed in the process d-a is',round(Q4,2),\"kJ/min\"\n",
+ "print'(e)Energy in the process d-a is',round(E4,2),\"kJ/min\"\n",
+ "print'(f)Work done in the d-a process is',round(W4,2),\"kJ/min\"\n",
+ "print'(g)Net rate of work output is',round(Wn,2),\"kW\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)Change in energy in a-b process is -2170.0 kJ/min\n",
+ "(b)Change in energy in b-c process is 21000.0 kJ/min\n",
+ "(c)Work done in the c-d process is 34500.0 kJ/min\n",
+ "(d)Heat developed in the process d-a is -35900.0 kJ/min\n",
+ "(e)Energy in the process d-a is 17770.0 kJ/min\n",
+ "(f)Work done in the d-a process is -53670.0 kJ/min\n",
+ "(g)Net rate of work output is -283.33 kW\n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.6 Page No. 93"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Determine (a)Change in work done in 1-2,2-3,3-1 process \n",
+ "#change in energy in the process 2-3 \n",
+ "#mass flow rate and rate of power and heat developed\n",
+ "\n",
+ "#Input data\n",
+ "Q1=50\t\t#Heat developed in the 1-2 process in kJ/kg\n",
+ "U1=20\t\t#Change in energy in the 1-2 process in kJ/kg\n",
+ "Q2=-30\t\t#Heat developed in the 2-3 process in kJ/kg\n",
+ "W2=-40\t\t#Work done in the 2-3 process in kj/kg\n",
+ "U3=-30\t\t#Change in energy in the 3-1 process in kJ/kg\n",
+ "Wt=30\t\t#Net work done per kg of fluid in kJ/kg\n",
+ "m=0.1\t\t#Mass of fluid in the cycle in kg\n",
+ "N=10\t\t#Number of cycles per sec in cycles/sec\n",
+ "\n",
+ "#Calculations\n",
+ "W1=Q1-U1\t#Work done in the 1-2 process in kJ/kg\n",
+ "U2=Q2-W2\t#Change in energy in the 2-3 process in kJ/kg\n",
+ "W3=Wt-W1-W2\t#Work done in the 3-1 process in kJ/kg\n",
+ "Q3=W3+U3\t#Heat developed in the process in kJ/kg\n",
+ "m1=m*N\t\t#mass flow rate per sec in kg/sec\n",
+ "P=Wt*m1\t\t#Rate of power in kW\n",
+ "\n",
+ "#Output\n",
+ "print'(a)Work done in the 1-2 process is',round(W1,1),\"kJ/kg\"\n",
+ "print'(b)Change in energy in the 2-3 process is',round(U2,1),\"kJ/kg\"\n",
+ "print'(c)Work done in the 3-1 process is',round(W3,1),\"kJ/kg\"\n",
+ "print'(d)Heat developed in the processis',round(Q3,1),\"kJ/kg\"\n",
+ "print'(e)mass flow rate per sec ',round(m1,1), \"kg/sec \"\n",
+ "print'(f)Rate of power is',round(P,2),\"kW\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)Work done in the 1-2 process is 30.0 kJ/kg\n",
+ "(b)Change in energy in the 2-3 process is 10.0 kJ/kg\n",
+ "(c)Work done in the 3-1 process is 40.0 kJ/kg\n",
+ "(d)Heat developed in the processis 10.0 kJ/kg\n",
+ "(e)mass flow rate per sec 1.0 kg/sec \n",
+ "(f)Rate of power is 30.0 kW\n"
+ ]
+ }
+ ],
+ "prompt_number": 9
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.7 Page No. 94"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Determine (a)Change in work done in 1-2 process \n",
+ "#total change in energy \n",
+ "#work done and heat developed\n",
+ "\n",
+ "#Input data\n",
+ "m=3.0\t\t#Mass of substance in the system in kg\n",
+ "P1=500.0\t\t#Initial pressure of the system in kPa\n",
+ "P2=100.0\t\t#Final pressure of the system in kPa\n",
+ "V1=0.22\t\t#Initial volume of the system in m**3\n",
+ "n=1.2\t\t#Polytropic index \n",
+ "Q1=30.0\t\t#Heat transfer for the another process\n",
+ "\n",
+ "#Calculations\n",
+ "V2=V1*(P1/P2)**(1/1.2)\t#Final volume of the system in m**3\n",
+ "U=3.56*(P2*V2-P1*V1)\t#Total change in internal energy in kJ\n",
+ "W1=(P2*V2-P1*V1)/(1-n)\t#Work done for the 1-2 process in kJ\n",
+ "Q=U+W1\t\t\t#Heat developed in the process in kJ\n",
+ "W2=Q1-U\t\t#Work done for the another process in kJ\n",
+ "\n",
+ "#Output\n",
+ "print'(a)Total change in internal energy is',round(U,0), \"kJ\" \n",
+ "print'(b)Work done for the 1-2 process is',round(W1,2), \"kJ\" \n",
+ "print'(c)Heat developed in the process is',round(Q,0), \"kJ\" \n",
+ "print'(d)Work done for the another process is',round(W2,0), \"kJ\" \n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)Total change in internal energy is -92.0 kJ\n",
+ "(b)Work done for the 1-2 process is 129.4 kJ\n",
+ "(c)Heat developed in the process is 37.0 kJ\n",
+ "(d)Work done for the another process is 122.0 kJ\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.8 Page No. 96"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find heat transfer and total change in internal energy\n",
+ "\n",
+ "#Input data\n",
+ "m=5\t\t#Mass of the substance in the system in kg\n",
+ "P1=500\t\t#Initial pressure of the system in kPa\n",
+ "P2=100\t\t#Final pressure of the system in kPa\n",
+ "V1=0.22\t\t#Initial volume of the system in m**3\n",
+ "n=1.2\t\t#Polytropic index\n",
+ "\n",
+ "#Calculations \n",
+ "V2=V1*(P1/P2)**(1/1.2)\t#Final volume of the system in m**3\n",
+ "U=3.5*(P2*V2-P1*V1)\t#Change in the internal energy of the system in kJ\n",
+ "W=(P1*V1-P2*V2)/(n-1)\t#Work developed in the process in kJ\n",
+ "Q=U+W\t\t\t#Heat transfer in the process in kJ\n",
+ "\n",
+ "#Output\n",
+ "print'Total change in Internal Energy is',round(U,0),\"KJ\" \n",
+ "print'Non flow work in the process is',round(W,2),\"KJ\" \n",
+ "print'Heat transfer of the process is',round(Q,0),\"KJ\" \n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Total change in Internal Energy is -91.0 KJ\n",
+ "Non flow work in the process is 129.4 KJ\n",
+ "Heat transfer of the process is 39.0 KJ\n"
+ ]
+ }
+ ],
+ "prompt_number": 7
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.9 Page No. 97"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find the direction and magnitude of work and heat transfer\n",
+ "\n",
+ "#Input data\n",
+ "p1=170\t\t#Initial pressure of the fluid in kPa\n",
+ "p2=400\t\t#Final pressure of the fluid in kPa\n",
+ "v1=0.03\t\t#Initial volume in m**3\n",
+ "v2=0.06\t\t#Final volume in m**3\n",
+ "\n",
+ "#Calculations\n",
+ "dU=3.15*((p2*v2)-(p1*v1))\t#The change in internal energy of the fluid in kJ\n",
+ "#P=a+b*V #Given relation \n",
+ "A = array([[1,v1], \n",
+ " [1,v2]])\n",
+ "b = array([p1,p2])\n",
+ "X = solve(A, b)\n",
+ "W=(X[0]*(v2-v1))+(X[1]*((v2**2-v1**2)/2.0))\t#The work done during the process in kJ\n",
+ "Q=U+W\t\t#The heat transfer in kJ\n",
+ "\n",
+ "#Output\n",
+ "print'(a)The direction and magnitude of work is',round(W,2),\"KJ\"\n",
+ "print'(b)The direction and magnitude of heat transfer is',round(Q,2),\"KJ\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)The direction and magnitude of work is 8.55 KJ\n",
+ "(b)The direction and magnitude of heat transfer is 68.08 KJ\n"
+ ]
+ }
+ ],
+ "prompt_number": 30
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.11 Page No. 99"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#What is power capacity of the system\n",
+ "\n",
+ "#Input data\n",
+ "E1=4000\t\t#Enthalpy at entrance in kJ/Kg\n",
+ "E2=4100\t\t#Enthalpy at exit in kJ/kg\n",
+ "V1=50\t\t#Velocity at entrance in m/s\n",
+ "V2=20\t\t#Velocity at exit in m/s\n",
+ "h1=50\t\t#Height at the entrance \n",
+ "h2=10\t\t#Height at the exit\n",
+ "m=1\t\t#mass flow rate to the system in kJ/s\n",
+ "Q=200\t\t#Heat transfer rate to the system in kJ/s\n",
+ "g=9.8\t\t#Gravitational constant in m/s**2\n",
+ "\n",
+ "#Calculations\n",
+ "P=m*(((V1**2-V2**2)/(2000.0))+(g*(h2-h1)/1000.0)+(E1-E2))+Q\n",
+ "print'Power capacity of the system ',round(P,0),\"KW\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Power capacity of the system 101.0 KW\n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.12 Page No. 101"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#What is specific internal energy\n",
+ "\n",
+ "#Input data\n",
+ "W=135\t\t#Work done by the system in kJ/kg\n",
+ "V1=0.37\t\t#Specific volume of fluid at inlet in m**3/kg\n",
+ "V2=0.62\t\t#Specific volume of fluid at outlet in m**3/kg\n",
+ "P1=600\t\t#Pressure at the inlet in kPa\n",
+ "P2=100\t\t#Pressure at the outlet in kPa\n",
+ "C1=16\t\t#Velocity at the inlet in m/s\n",
+ "C2=270\t\t#Velocity at the outlet in m/s\n",
+ "Z1=32\t\t#Inlet height from floor level in m\n",
+ "Z2=0\t\t#Outlet height from floor level in m\n",
+ "q=-9\t\t#Heat loss between inlet and discharge in kJ/kg\n",
+ "g=9.81\t\t#Gravitational constant in m/s**2\n",
+ "\n",
+ "#Calculations\n",
+ "U=((C2**2-C1**2)/2000.0)+(g*(Z2-Z1))/1000.0+(P2*V2-P1*V1)+W-q\n",
+ "\n",
+ "#Output\n",
+ "print'Specific Internal Energy decreases by ',round(U,2),\"kJ/kg\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Specific Internal Energy decreases by 20.01 kJ/kg\n"
+ ]
+ }
+ ],
+ "prompt_number": 9
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.13 Page No. 102"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#What is Total work done in the system and Power capacity of the system\n",
+ "\n",
+ "#Input data\n",
+ "m=5\t\t#Rate of fluid flow in the system in kg/s\n",
+ "P1=620\t\t#Pressure at the entrance in kPa\n",
+ "P2=130\t\t#Pressure at the exit in kPa\n",
+ "C1=300\t\t#Velocity at the entrance in m/s\n",
+ "C2=150\t\t#Velocity at the exit in m/s\n",
+ "U1=2100\t\t#Internal energy at the entrance in kJ/kg\n",
+ "U2=1500\t\t#Internal energy at the exit in kJ/kg\n",
+ "V1=0.37\t\t#Specific volume at entrance in m**3/kg\n",
+ "V2=1.2\t\t#Specific volume at exit in m**3/kg\n",
+ "Q=-30\t\t#Heat loss in the system during flow in kJ/kg\n",
+ "Z=0\t\t#Change in potential energy is neglected in m\n",
+ "g=9.81\t\t#Gravitational constant in m/s**2\n",
+ "\n",
+ "#Calculations\n",
+ "W=((C1**2-C2**2)/(2*1000))+(g*Z)+(U1-U2)+(P1*V1-P2*V2)+Q\n",
+ "P=W*m#Power capacity of the system in kW\n",
+ "\n",
+ "#Output\n",
+ "print'(a)Total work done in the system ',round(W,1),\"kJ/kg\"\n",
+ "print'(b)Power capacity of the system',round(P,1),\"KW\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ " (a)Total work done in the system 676.4 kJ/kg\n",
+ "(b)Power capacity of the system 3382.0 KW\n"
+ ]
+ }
+ ],
+ "prompt_number": 16
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.14 Page No. 103"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find The power required to drive the compressor\n",
+ "\n",
+ "#Input Data\n",
+ "P1=100\t\t#Pressure at Inlet in kPa\n",
+ "P2=500\t\t#Pressure at Exit in kPa\n",
+ "V1=0.6\t\t#Specific volume at Inlet in m**3/kg\n",
+ "V2=0.15\t\t#Specific volume at Exit in m**3/kg\n",
+ "U1=50\t\t#Specific internal energy at inlet in kJ/kg\n",
+ "U2=125\t\t#Specific internal energy at Exit in kJ/kg\n",
+ "C1=8\t\t#Velocity of air at Inlet in m/s\n",
+ "C2=4\t\t#Velocity of air at Exit in m/s\n",
+ "m=5\t\t#Mass flow rate of air in kg/s\n",
+ "Q=-45\t\t#Heat rejected to cooling water in kW\n",
+ "Z=0\t\t#Change in potential energy is neglected in m\n",
+ "g=9.81\t\t#Gravitational constant in m/s**2\n",
+ "\n",
+ "#Calculations\n",
+ "P=m*(((C1**2-C2**2)/(2*1000.0))+(g*Z)+(U1-U2)+(P1*V1-P2*V2))+Q\n",
+ "P1=-P\n",
+ "\n",
+ "#Output\n",
+ "print'The power required to drive the compressor',round(-P1,2),\"kW\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The power required to drive the compressor -494.88 kW\n"
+ ]
+ }
+ ],
+ "prompt_number": 11
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.15 Page No. 104"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Input data\n",
+ "m1=5000\t\t#Steam flow rate in kg/hr\n",
+ "Q1=-250\t\t#Heat loss from the turbine insulation to surroundings in kj/min\n",
+ "C1=40\t \t#Velocity of steam at entrance in m/s\n",
+ "h1=2500\t\t#Enthalpy of the steam at entrance in kJ/kg\n",
+ "C2=90\t\t #Velocity of the steam at the Exit in m/s\n",
+ "h2=2030\t\t#Enthalpy of the steam at exit in kj/kg\n",
+ "Z=0\t\t #Change in potential energy is neglected in m\n",
+ "g=9.81\t\t#Gravitational constant in m/s**2\n",
+ "\n",
+ "#Calculations\n",
+ "m=m1/3600.0\t #Steam flow rate in kg/s\n",
+ "Q=Q1/60.0\t\t#Heat loss from the turbine to the surroundings\n",
+ "P=m*(((C1**2-C2**2)/(2*1000))+(g*Z)+(h1-h2))+Q\n",
+ "\n",
+ "#Output\n",
+ "print'The power developed by the turbine is',round(P,1),\"KW\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The power developed by the turbine is 643.1 KW\n"
+ ]
+ }
+ ],
+ "prompt_number": 19
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.16 Page No. 105"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find The work output from the turbine \n",
+ "\n",
+ "#Input data \n",
+ "c1=16\t\t#Velocity of steam at entrance in m/s\n",
+ "c2=37\t\t#Velocity of steam at exit in m/s\n",
+ "h1=2990\t\t#Specific enthalpy of steam at entrance in kJ/kg\n",
+ "h2=2530\t\t#Specific enthalpy of steam at exit in kJ/kg\n",
+ "Q=-25\t\t#Heat lost to the surroundings in kJ/kg\n",
+ "m1=360000\t#The steam flow rate in kg/hr\n",
+ "\n",
+ "#Calculations\n",
+ "m=m1/3600.0 #The steam flow rate in kg/s\n",
+ "W=(c1**2-c2**2)/2000.0+(h1-h2)+Q\t#Total work done in the system in kJ/kg\n",
+ "P=m*W\t\t\t\t\t #Power developed by the turbine in kW\n",
+ "\n",
+ "#Output\n",
+ "print'The work output from the turbine is',round(P,1),\"kW \"\n",
+ "print'NOTE: In the book there is Calculation mistake'\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The work output from the turbine is 43444.3 kW \n",
+ "NOTE: In the book there is Calculation mistake\n"
+ ]
+ }
+ ],
+ "prompt_number": 11
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.17 Page No.106"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find The external work output of the turbine\n",
+ "\n",
+ "#Input data\n",
+ "p1=720\t\t#Pressure at the entrance in kPa\n",
+ "t1=850\t\t#Temperature at the entrance in degree centigrade \n",
+ "c1=160\t\t#Velocity of the gas at entrance in m/s\n",
+ "Q=0\t\t#Insulation (adiabatic turbine)\n",
+ "P2=115\t\t#Pressure at the exit in kPa\n",
+ "t2=450\t\t#Temperature at the exit in degree centigrade\n",
+ "c2=250\t\t#Velocity of the gas at exit in m/s\n",
+ "cp=1.04\t\t#Specific heat of gas at constant pressure in kJ/kg-K\n",
+ "\n",
+ "#Calculations\n",
+ "H=cp*(t1-t2)\t\t\t#Change in Enthalpy of the gas at entrance and exit in kJ/kg\n",
+ "W=((c1**2-c2**2)/(2*1000))+(H)\t#External work output of the turbine in kJ/kg\n",
+ "\n",
+ "#Output\n",
+ "print'The external work output of the turbine is',round(W,0),\"kJ/kg\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The external work output of the turbine is 397.0 kJ/kg\n"
+ ]
+ }
+ ],
+ "prompt_number": 16
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.18 Page No. 107"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find The work done per unit mass of the steam and mass flow rate\n",
+ "\n",
+ "#Input data\n",
+ "p=5000\t\t#Power output of an adiabatic steam turbine in kW\n",
+ "p1=2000\t\t#Pressure at the inlet in kPa\n",
+ "p2=0.15\t\t#Pressure at the exit in bar\n",
+ "t1=400\t\t#temperature at the inlet in degree centigrade\n",
+ "x=0.9\t\t#Dryness at the exit\n",
+ "c1=50\t\t#Velocity at the inlet in m/s\n",
+ "c2=180\t\t#Velocity at the exit in m/s\n",
+ "z1=10\t\t#Elevation at inlet in m\n",
+ "z2=6\t\t#Elevation at exit in m\n",
+ "h1=3248.7\t\t#Enthalpy at the inlet from the steam table corresponding to and 20 bar in kJ/kg\n",
+ "hf=226\t\t#Enthalpy at exit at 0.15 bar from steam tables in kJ/kg\n",
+ "hfg=2373.2\t#Enthalpy at exit at 0.15 bar from steam tables in kJ/kg\n",
+ "g=9.81\t\t#Gravitational constant in m/s**2\n",
+ "\n",
+ "#Calculations\n",
+ "h2=hf+(x*hfg) #Enthalpy at the exit in kJ/kg\n",
+ "W=(h1-h2)+((c1**2-c2**2)/(2*1000))+((g*(z1-z2))/1000.0)\n",
+ "m=p/W\t\t\t\t\t\t \n",
+ "\n",
+ "#Output\n",
+ "print'(a)The work done per unit mass of the steam flowing through turbine is',round(W,1),\"kJ/kg\"\n",
+ "print'(b)The mass flow rate of the steam is',round(m,1),\"kg/s\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)The work done per unit mass of the steam flowing through turbine is 871.9 kJ/kg\n",
+ "(b)The mass flow rate of the steam is 5.7 kg/s\n"
+ ]
+ }
+ ],
+ "prompt_number": 23
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.19 Page No. 108"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find Temperature of air at exit and power output\n",
+ "\n",
+ "#Input Data\n",
+ "p1=1000.0\t\t#Pressure at the inlet in kPa\n",
+ "t1=750.0\t\t#Temperature at the inlet in K\n",
+ "c1=200.0\t\t#Velocity at the inlet in m/s\n",
+ "p2=125.0\t\t#Pressure at the exit in kPa\n",
+ "c2=40.0\t\t #Velocity at the exit in m/s\n",
+ "m1=1000.0\t\t#Mass flow rate of air in kg/hr\n",
+ "cp=1.053\t\t#Specific heat at constant pressure in kJ/kgK\n",
+ "k=1.375\t\t #Adiabatic index\n",
+ "Q=0\t\t #The turbine is adiabatic\n",
+ "\n",
+ "#Calculations\n",
+ "m=m1/3600.0\t#The mass flow rate of air in kg/s\n",
+ "P=p2/p1\t\t#Ratio of the pressure\n",
+ "t2=t1*((p2/p1)**((k-1)/k))\t#Temperature of air at exit in K\n",
+ "h=cp*(t2-t1)\t\t#Change in enthalpy of the system in kJ\n",
+ "p=m*(((c2**2-c1**2)/(2*1000))+h)\t#Power output of the turbine in kW\n",
+ "p1=-p\t\t\t#Power output of the turbine in kW\n",
+ "\n",
+ "#Output\n",
+ "print'(a)Temperature of air at exit is',round(t2,2),\" K \"\n",
+ "print'(b)The power output of the turbine is',round(p1,1),\"kW\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)Temperature of air at exit is 425.37 K \n",
+ "(b)The power output of the turbine is 100.3 kW\n"
+ ]
+ }
+ ],
+ "prompt_number": 24
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.20 Page No. 110"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find The rate of work input to the air and\n",
+ "#The ratio of inlet pipe diameter to the outlet pipe diameter\n",
+ "\n",
+ "#Input data\n",
+ "c1=7\t\t #Velocity of air at entrance in m/s\n",
+ "c2=5\t\t #Velocity of air at exit in m/s\n",
+ "p1=100\t\t #Pressure at the entrance in kPa\n",
+ "p2=700\t\t #Pressure at the exit in kPa\n",
+ "v1=0.95\t\t#Specific volume at entrance in m**3/kg\n",
+ "v2=0.19\t\t#Specific volume at exit in m**3/kg\n",
+ "u=90\t\t # Change in internal energy of the air entering and leaving in kJ/kg\n",
+ "z=0\t\t #Potential energy is neglected \n",
+ "Q=-58\t\t #Heat rejected to the surroundings in kW\n",
+ "m=0.5\t\t #The rate at which air flow in kg/s\n",
+ "g=9.81\t\t #Gravitational constant in m/s**2\n",
+ "\n",
+ "#Calculations\n",
+ "P=m*(((c1**2-c2**2)/(2000.0))+(p1*v1-p2*v2)-u)+(Q)\n",
+ "A=(v1*c2)/(v2*c1)\t#From continuity equation the ratio of areas\n",
+ "D=A**(1/2.0)\t #The ratio of inlet pipe diameter to the outlet pipe diameter\n",
+ "\n",
+ "#Output\n",
+ "print'(a)The rate of work input to the air is ',round(P,2),\"kW\"\n",
+ "print'(b)The ratio of inlet pipe diameter to the outlet pipe diameter is ',round(D,2)\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)The rate of work input to the air is -121.99 kW\n",
+ "(b)The ratio of inlet pipe diameter to the outlet pipe diameter is 1.89\n"
+ ]
+ }
+ ],
+ "prompt_number": 20
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.21 Page No. 112"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find The velocity at exit, mass flow rate area at exit\n",
+ "\n",
+ "#Input data\n",
+ "h1=3000\t\t#Enthalpy of the fluid passing at inlet in kJ/kg\n",
+ "h2=2757\t\t#Enthalpy of the fluid at the discharge in kJ/kg\n",
+ "c1=60\t\t#Velocity of the fluid at inlet in m/s\n",
+ "A1=0.1\t\t#Inlet area of the nozzle in m**2\n",
+ "v1=0.187\t\t#Specific volume at inlet in m**3/kg\n",
+ "v2=0.498\t\t#Specific volume at the outlet in m**3/kg\n",
+ "q=0\t\t#Heat loss during the flow is negligable\n",
+ "z=0\t\t#The nozzle is horizontal so change in PE is constant\n",
+ "w=0\t\t#The work done is also negligable\n",
+ "\n",
+ "#Calculations\n",
+ "c2=(2*1000*((h1-h2)+(c1**2/2000.0)))**(1/2.0)\t#Velocity at the exit in m/s\n",
+ "m=(A1*c1)/v1\t\t\t\t#The mass flow rate in kg/s\n",
+ "A2=(m*v2)/c2\t\t\t\t#Area at the exit of the nozzle in m**3\n",
+ "\n",
+ "#Output\n",
+ "print'(a)The velocity at the exit is',round(c2,1),\"m/s\"\n",
+ "print'(b)The mass flow rateis',round(m,1),\"kg/s\" \n",
+ "print'(c)Area at the exit is',round(A2,3),\"m**2\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)The velocity at the exit is 699.7 m/s\n",
+ "(b)The mass flow rateis 32.1 kg/s\n",
+ "(c)Area at the exit is 0.023 m**2\n"
+ ]
+ }
+ ],
+ "prompt_number": 21
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.22 Page No. 113"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Velocity of the steam at the outlet, mass flow rate and area at nozzle exit\n",
+ "\n",
+ "#Input data\n",
+ "h1=3000\t\t#Specific enthalpy of steam at inlet in kJ/kg\n",
+ "h2=2762\t\t#Specific enthalpy of steam at the outlet in kJ/kg\n",
+ "v1=0.187\t\t#Specific volume of steam at inlet in m**3/kg\n",
+ "v2=0.498\t\t#Specific volume of steam at the outlet in m**3/kg\n",
+ "A1=0.1\t\t#Area at the inlet in m**2\n",
+ "q=0\t\t#There is no heat loss\n",
+ "z=0\t\t#The nozzle is horizontal ,so no change in PE\n",
+ "c1=60\t\t#Velocity of the steam at the inlet in m/s\n",
+ "\n",
+ "#Calculations\n",
+ "c2=((2*1000)*((h1-h2)+(c1**2/2000.0)))**(1/2.0)\t#Velocity of the steam at the outlet in m/s\n",
+ "m=(A1*c1)/v1\t\t\t\t#Mass flow rate of steam in kg/s\n",
+ "A2=(m*v2)/c2\t\t\t\t#Area at the nozzle exit in m**2\n",
+ "\n",
+ "#Output\n",
+ "print'(a)Velocity of the steam at the outlet is ',round(c2,2), \"m/s \"\n",
+ "print'(b)Mass flow rate of steam is ',round(m,2),\"kg/s \"\n",
+ "print'(c)Area at the nozzle exit is',round(A2,3),\"m**2\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)Velocity of the steam at the outlet is 692.53 m/s \n",
+ "(b)Mass flow rate of steam is 32.09 kg/s \n",
+ "(c)Area at the nozzle exit is 0.023 m**2\n"
+ ]
+ }
+ ],
+ "prompt_number": 25
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.23 Page No. 114"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find the exit velocity\n",
+ "#Input data\n",
+ "c1=40\t\t#Velocity of air at the inlet of nozzle in m/s\n",
+ "h=180\t\t#The decrease in enthalpy in the nozzle in kJ/kg\n",
+ "w=0\t\t#Since adiabatic\n",
+ "q=0\t\t#Since adiabatic\n",
+ "z=0\t\t#Since adiabatic\n",
+ "\n",
+ "#Calculations\n",
+ "c2=((2*1000)*((h)+(c1**2/(2*1000))))**(1/2.0)\t#The exit velocity of air in m/s\n",
+ "\n",
+ "#Output\n",
+ "print'The exit velocity of the air is',round(c2,1),\"m/s\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The exit velocity of the air is 600.0 m/s\n"
+ ]
+ }
+ ],
+ "prompt_number": 32
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.24 Page No. 115"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Input data\n",
+ "p1=100\t\t#Pressure at the inlet of the compressor in kPa\n",
+ "p2=500\t\t#Pressure at the outlet of the compressor in kPa\n",
+ "v1=3\t\t#Volume of the air at the inlet of the compressor in m**3/kg\n",
+ "v2=0.8\t\t#Volume of the air at the outlet of the compressor in m**3/kg\n",
+ "c1=25\t\t#The velocity of air at the inlet of the compressor in m/s\n",
+ "c2=130\t\t#The velocity of air at the outlet of the compressor in m/s\n",
+ "z=12\t\t#The height of delivery connection above the inlet in m\n",
+ "g=9.81\t\t#Gravitational constant in m/s**2\n",
+ "n=1.3\t\t#Polytropic index\n",
+ "\n",
+ "#Calculations\n",
+ "W=((n)*(p1*v1-p2*v2))/(n-1)\t#Workdone for open system polytropic process in kJ/kg\n",
+ "K=((c2**2-c1**2)/2000.0)\t#Change in kinetic energy of the system in kJ/kg\n",
+ "P=g*(z)/1000.0 \t\t#Change in potential energy of the system in kJ/kg\n",
+ "w=W-K-P\t\t\t #The shaft work of the compressor in kJ/kg\n",
+ "\n",
+ "#Output\n",
+ "print'The Shaft work of the compressor ',round(w,1),\"kj/kgIt is the power absorbing system\"\n",
+ "if w<0:\n",
+ " print'It is the power absorbing system'\n",
+ "else:\n",
+ " print'It is not power absorbing system'\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The Shaft work of the compressor -441.6 kj/kgIt is the power absorbing system\n",
+ "It is the power absorbing system\n"
+ ]
+ }
+ ],
+ "prompt_number": 38
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.25 Page No. 117"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Determine the power required\n",
+ "\n",
+ "#Input data\n",
+ "m=10\t\t#The rate of fluid compressed adiabatically in kg/s\n",
+ "p1=500\t\t#Initial pressure of the process in kPa\n",
+ "p2=5000\t\t#Final pressure of the process in kPa\n",
+ "v=0.001\t\t#The specific volume of the fluid in m**3/kg\n",
+ "\n",
+ "#Calculations\n",
+ "P=m*v*(p2-p1)\t#The power required in kW\n",
+ "\n",
+ "#Output\n",
+ "print'The power required is',round(P,2),\"kW\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The power required is 45.0 kW\n"
+ ]
+ }
+ ],
+ "prompt_number": 40
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.26 Page No. 117"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Determine the exit temprature\n",
+ "\n",
+ "#Input data\n",
+ "m=2.0\t\t#Mass flow rate of air in kg/s\n",
+ "t1=20\t\t#Initial temperature of the air in degree centigrade\n",
+ "P=-30\t\t#The amount of power consumed in kW\n",
+ "c1=100\t\t#The inlet velocity of air in m/s\n",
+ "c2=150\t\t#The outlet velocity of air in m/s\n",
+ "R=0.287\t\t#The gas constant for air in kJ/kg-K\n",
+ "g=1.4\t\t#It is the adiabatic index\n",
+ "cp=1.005\t\t#Specific heat at constant pressure in kJ/kg-K\n",
+ "q=0\t\t#Heat developed as it is adiabatic condition\n",
+ "z=0\t\t#The change in potential energy is neglected\n",
+ "\n",
+ "#Calculations\n",
+ "h=(P/m)+((c2**2-c1**2)/(2*1000))\t\t#The change in enthalpy of the system in kJ/kg\n",
+ "t=h/cp\t\t#The change in temperature of the system in degree centigrade\n",
+ "t2=t1-t\t\t#The exit air temperature in degree centigrade\n",
+ "\n",
+ "#Output\n",
+ "print'The exit air temperature is is',round(t2,2),\"C\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The exit air temperature is is 28.96 C\n"
+ ]
+ }
+ ],
+ "prompt_number": 26
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.27 Page No. 119"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find The exit air temperature\n",
+ "\n",
+ "#Input data\n",
+ "m=0.6\t\t#Mass flow rate of air in kg/s\n",
+ "W=40\t\t#Power required to run the compressor in kW\n",
+ "p1=100\t\t#Initial pressure at the inlet of the compressor in kPa\n",
+ "t1=30\t\t#Initial temperature at the inlet of the compressor in degree centigrade\n",
+ "z=0\t\t#Change in potential energy is neglected\n",
+ "c=0\t\t#Change in kinetic energy is neglected\n",
+ "q=0.4\t\t#Heat lost to the cooling water ,bearings and frictional effects is 40% of input\n",
+ "cp=1.005\t\t#Specific heat at constant pressure in kJ/kg-K\n",
+ "\n",
+ "#Calculations\n",
+ "Q=q*W\t\t#Net heat losses from the system in kW\n",
+ "H=W-Q\t\t#Change in total enthalpy of the system in kW\n",
+ "t2=(H/(m*cp))+t1\t#The exit air temperature in degree centigrade\n",
+ "\n",
+ "#Output\n",
+ "print'The exit air temperature is',round(t2,0),\"C\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The exit air temperature is 70.0 C\n"
+ ]
+ }
+ ],
+ "prompt_number": 46
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.28 Page No. 120"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find The rate at which the heat is to be removed by cooler X\n",
+ "\n",
+ "#Input data\n",
+ "m1=100\t\t#Air flow rate in kg/hr\n",
+ "q1=600\t\t#The heat generated by each person in kJ/hr\n",
+ "h1=85\t\t#The enthalpy of air entering the room in kJ/kg\n",
+ "h2=60\t\t#The enthalpy of air leaving the room in kJ/kg\n",
+ "Q1=0.2\t\t#The heat added by each lamp in the room in kW\n",
+ "P1=0.2\t\t#The power consumed by each fan in kW\n",
+ "\n",
+ "#Calculations\n",
+ "q=(5*q1)/3600.0\t#The heat generated by 5 persons in the room in kW\n",
+ "Q=3*Q1\t\t #The heat added by three lamps in the room in kW\n",
+ "P=2*P1\t\t #The power consumed by two fans in the room in kW\n",
+ "m=m1/3600.0\t\t #Mass flow rate of air in kg/s\n",
+ "H=(q+Q+P)+(m*(h1-h2))\t#Heat to be removed by the cooler in kW\n",
+ "\n",
+ "#Output\n",
+ "print'The rate at which the heat is to be removed by cooler X is',round(H,1),\"kJ/sec\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The rate at which the heat is to be removed by cooler X is 2.5 kJ/sec\n"
+ ]
+ }
+ ],
+ "prompt_number": 34
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.29 Page No. 121"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find The Heat loss by the system\n",
+ "\n",
+ "#Input data\n",
+ "p1=1000\t\t#Pressure at the inlet of the system in kPa\n",
+ "p2=15\t\t#Pressure at the outlet of the system in kPa\n",
+ "v1=0.206\t\t#Specific volume at the inlet of the system in m**3/kg\n",
+ "v2=8.93\t\t#Specific volume at the outlet of the system in m**3/kg\n",
+ "h1=2827\t\t#Specific enthalpy at the inlet of the system in kJ/kg\n",
+ "h2=2341\t\t#Specific enthalpy at the outlet of the system in kJ/kg\n",
+ "c1=20\t\t#Velocity at the inlet of the system in m/s\n",
+ "c2=120\t\t#Velocity at the outlet of the system in m/s\n",
+ "z1=3.2\t\t#Elevation at the inlet of the system in m\n",
+ "z2=0.5\t\t#Elevation at the outlet of the system in m\n",
+ "m=2.1\t\t#The fluid flow rate in kg/s\n",
+ "W=750\t\t#The work output of the device in kW\n",
+ "g=9.81\t\t#Gravitational constant in m/s**2\n",
+ "\n",
+ "#Calculations\n",
+ "Q=m*(((c2**2-c1**2)/(2*1000))+((g*(z2-z1)/(1000.0)))+(h2-h1))+W #The heat loss/gain by the system in kW\n",
+ "\n",
+ "#Output\n",
+ "print'The Heat loss by the system is',round(Q,1),\"kW\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The Heat loss by the system is -256.0 kW\n"
+ ]
+ }
+ ],
+ "prompt_number": 50
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.30 Page No. 122"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find Rate of heat transfer to the air \n",
+ "\n",
+ "#Input data\n",
+ "t1=15\t\t#The inlet temperature of the air passing through the heat exchanger in degree centigrade\n",
+ "c1=30\t\t#The inlet velocity of air in m/s\n",
+ "t2=800\t\t#The outlet temperature of the air from heat exchanger in degree centigrade \n",
+ "c2=30\t\t#The inlet velocity of air to the turbine in m/s\n",
+ "t3=650\t\t#The outlet temperature of the air from the turbine in degree centigrade\n",
+ "c3=60\t\t#The outlet velocity of the air from turbine in m/s\n",
+ "t4=500\t\t#The temperature at the outlet of the nozzle in degree centigrade\n",
+ "m=2\t\t #Air flow rate in kg/s\n",
+ "cp=1.005\t\t#Specific heat at constant pressure in kJ/kgK\n",
+ "\n",
+ "#Calculations\n",
+ "Qh=m*cp*(t2-t1)\t#Rate of heat transfer to the air in the heat exchanger in kJ/s\n",
+ "P=m*((cp*(t2-t3))+((c2**2-c3**2)/2000.0))\t\t#Power output from the turbine in kW\n",
+ "c4=((2*1000)*(cp*(t3-t4))+c3**2)**(1/2.0)\t\t#Velocity of air at exit from nozzle in m/s\n",
+ "\n",
+ "#Output \n",
+ "print'(a)Rate of heat transfer to the air in the heat exchanger is',round(Qh,1),\"kJ/s\"\n",
+ "print'(b)Power output from the turbine is',round(P,1),\"kW\"\n",
+ "print'(c)Velocity of air at exit from nozzle is',round(c4),\"m/s\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)Rate of heat transfer to the air in the heat exchanger is 1577.8 kJ/s\n",
+ "(b)Power output from the turbine is 298.8 kW\n",
+ "(c)Velocity of air at exit from nozzle is 552.0 m/s\n"
+ ]
+ }
+ ],
+ "prompt_number": 40
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.31 Page No. 123"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Input data\n",
+ "p1=400.0\t\t#Initial pressure of the gas in a turbine in kPa\n",
+ "t1=573.0\t\t#Initial temperature of the gas in a turbine in K\n",
+ "p2=100.0\t\t#Final pressure of the gas in a turbine in kPa\n",
+ "V=2.5\t\t #It is the ratio of final volume to the inlet volume \n",
+ "c2=50.0\t\t#Velocity of the gas at exit in m/s\n",
+ "P=1000.0\t\t#Power developed by the turbine in kW\n",
+ "cp=5.193\t\t#Specific heat of the helium at constant pressure in kJ/kg K\n",
+ "G=8.314\t\t#Gas constant in kNm/kgK\n",
+ "M=4.0\t\t #Molecular weight of the helium\n",
+ "\n",
+ "#Calculations\n",
+ "import math\n",
+ "R=G/M\t\t #Characteristic gas constant in kNm/kgK\n",
+ "v1=(R*t1)/p1\t#Specific volume at the inlet in m**3/kg\n",
+ "v2=V*v1\t \t#Specific volume at the outlet in m**3/kg\n",
+ "n=math.log(p2/p1)/math.log(v1/v2)\t#Polytropic index \n",
+ "t2=((t1)*((p2/p1)**((n-1)/n)))\t\t#Final temperature of the gas in a turbine in K\n",
+ "w=(n/(n-1))*(R*(t1))*(1-((p2*v2)/(p1*v1)))\t#Specific work in kJ/kg\n",
+ "K=c2**2/(2*1000)\t\t\t#Change in kinetic energy in kJ/kg\n",
+ "Ws=w-K\t\t\t#Work done by the shaft in kJ/kg\n",
+ "q=Ws+(cp*(t2-t1))+K\t#The heat transfer during the process in kJ/kg\n",
+ "m=P/Ws\t\t\t#Mass flow rate of gas required in kg/s\n",
+ "A2=(m*v2)/c2\t\t#Exit area of the turbine in m**2\n",
+ "\n",
+ "#Output\n",
+ "print'(a)The mass flow rate of the gas required is',round(m,3),\"kg/s\" \n",
+ "print'(b)The heat transfer during the process is',round(q,1), \"kJ/kg\" \n",
+ "print'(c)Exit area of the turbine is ',round(A2,3),\"m**2\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)The mass flow rate of the gas required is 0.76 kg/s\n",
+ "(b)The heat transfer during the process is 201.5 kJ/kg\n",
+ "(c)Exit area of the turbine is 0.113 m**2\n"
+ ]
+ }
+ ],
+ "prompt_number": 31
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Basic_Mechanical_Engineering/bme6.ipynb b/Basic_Mechanical_Engineering/bme6.ipynb
new file mode 100644
index 00000000..7f3d569b
--- /dev/null
+++ b/Basic_Mechanical_Engineering/bme6.ipynb
@@ -0,0 +1,942 @@
+{
+ "metadata": {
+ "name": "C6ankit"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "Chapter 6:Introduction to Heat Transfer"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.1 Page no:221"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#What is The minimum value of heat transfer coefficient at the outer surface\n",
+ "\n",
+ "#Input data\n",
+ "t1=270\t\t#Temperature inside surface of the furnace wall in degree centigrade\n",
+ "t3=20\t\t#Temperature outside surface is dissipating heat by convection into air in degree centigrade\n",
+ "L=0.04\t\t#Thickness of the wall in m\n",
+ "K=1.2\t\t#Thermal conductivity of wall in W/m-K\n",
+ "t2=70\t\t#Temperature of outside surface should not exceed in degree centigrade\n",
+ "A=1\t\t #Assuming area in m**2\n",
+ "\n",
+ "#Calculations\n",
+ "Q1=(K*A*(t1-t2))/(L)\t#Heat transfer through the furnace wall in W\n",
+ "hc=(Q1)/(A*(t2-t3))\t\t#Heat transfer coefficient in W/m**2K\n",
+ "\n",
+ "#Output\n",
+ "print\"The minimum value of heat transfer coefficient at the outer surface is\",hc,\"W/m**2K\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The minimum value of heat transfer coefficient at the outer surface is 120.0 W/m**2K\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.2 page no:222"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#What is The change in its emissive power.\n",
+ "\n",
+ "#Input data\n",
+ "t1=30\t\t #Normal temperature of black body in degree centigrade\n",
+ "t2=100\t\t#Heated temperature of black body in degree centigrade\n",
+ "s=20.52*10**-8\t#Stefan Boltzmann constant in kJ/hrK**4\n",
+ "A=1\t\t #Assume area in m**2\n",
+ "\n",
+ "#Calculations\n",
+ "T1=273+t1\t#Black body temperatures in kelvin K\n",
+ "T2=273+t2\t#Heated temperature of black body in kelvin K\n",
+ "E=s*(T2**4-T1**4)\t#Increase of emissive power in kJ/hr\n",
+ "\n",
+ "#Output\n",
+ "print'The change in its emissive power',round(E,4),\"kJ/hr\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The change in its emissive power 2242.4228 kJ/hr\n"
+ ]
+ }
+ ],
+ "prompt_number": 82
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.3 page no:222"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find The rate of heat loss \n",
+ "#(b) Overall heat transfer coefficient \n",
+ "#(c) Temperature of the outside surface of tank \n",
+ "#(d)The surface area of the coil\n",
+ "\n",
+ "#Input data\n",
+ "L=0.012 \t#Wall thickness of a mild steel tank in m\n",
+ "t1=100.0\t\t#Temperature of water in tank in degree centigrade\n",
+ "t4=20.0\t \t#Atmospheric temperature of air in degree centigrade\n",
+ "K=50.0\t\t #Thermal conductivity of mild steel in W/m-K\n",
+ "hi=2850.0\t\t#Convection heat transfer coefficient on water side in W/m**2-K\n",
+ "ho=10.0\t\t#Convection heat transfer coefficient on air side in W/m**2-K\n",
+ "Q1=60.0 \t#Heat trasfer from the incandicent lamp in W\n",
+ "s=5.67*10**-8\t#Stefan boltzmann constant in W/m**2/K**4\n",
+ "T1=2500.0\t #Lamp surface temperature in K\n",
+ "T2=300.0\t\t#Room temperature in K\n",
+ "A=1.0\t\t #Assuming area in m**2\n",
+ "\n",
+ "#Calculations\n",
+ "T=t1-t4\t\t#Temperature difference in degree centigrade\n",
+ "Q=(T)/((1/hi)+(L/K)+(1/ho))\t#Rate of heat loss per m**2 area of surface of tank in W\n",
+ "t3=(Q/(ho*A))+(t4)\t\t#Temperature of the outside surface in degree centigrade\n",
+ "U=(Q)/(A*T)\t\t#Overall Heat transfer coefficient in W/m**2/K\n",
+ "a=(Q1)/(s*(T1**4-T2**4))\t#surface area of the coil in m**2\n",
+ "a1=a*10**6#Surface area of the coil in mm**2\n",
+ "\n",
+ "#Output\n",
+ "print'(a) The rate of heat loss per sq m area of the tank is',round(Q,2),\" W \"\n",
+ "print '(b) Overall heat transfer coefficient is ',round(U,2),\" W/m**2/K\" \n",
+ "print '(c) Temperature of the outside surface of tank is ',round(t3,2),\"C\" \n",
+ "print '(d)The surface area of the coil is ',round(a1,3),\"mm**2\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a) The rate of heat loss per sq m area of the tank is 795.3 W \n",
+ "(b) Overall heat transfer coefficient is 9.94 W/m**2/K\n",
+ "(c) Temperature of the outside surface of tank is 99.53 C\n",
+ "(d)The surface area of the coil is 27.096 mm**2\n"
+ ]
+ }
+ ],
+ "prompt_number": 83
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.4 page no:225"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Determine (a)Rate of heat loss . \n",
+ "#(b)Rate of heat loss per hour \n",
+ "\n",
+ "#Input data\n",
+ "A1=3.5\t\t#Area of the boiler plate in m**2\n",
+ "X2=0.02\t\t#Thickness of the plate in m\n",
+ "K2=50.0\t\t#Thermal conductivity of plate in W/m-K\n",
+ "X1=0.002\t #Thickness of layer inside boiler in m\n",
+ "K1=1.0\t\t #Thermal conductivity of layer in W/m-K\n",
+ "t1=250.0\t\t#The hot gas temperature of the plate in degree centigrade\n",
+ "t3=200.0\t\t#Temperature of cold air in degree centigrade\n",
+ "\n",
+ "#Calculations \n",
+ "T=t1-t3\t\t#Temperature difference in degree centigrade\n",
+ "Q=(T*A1)/((X1/K1)+(X2/K2))\t#Rate of heat loss in W\n",
+ "Q1=Q/1000\t\t#Rate of heat loss in kJ/s\n",
+ "Q2=Q1*3600\t\t#Rate of heat loss in kJ/hr\n",
+ "\n",
+ "#Output\n",
+ "print'(a)Rate of heat loss is',round(Q1,2),\" kJ/s \"\n",
+ "print'(b)Rate of heat loss per hour is',round(Q2,2),\"kJ/hr\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)Rate of heat loss is 72.92 kJ/s \n",
+ "(b)Rate of heat loss per hour is 262500.0 kJ/hr\n"
+ ]
+ }
+ ],
+ "prompt_number": 84
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.5 page no:226"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find (a)The rate of heat loss per sq m of the wall \n",
+ "#(b)The temperature at the inner surface \n",
+ "#(c)The temperature at the outer surface\n",
+ "\n",
+ "#Input data \n",
+ "L1=0.225\t\t#Thickness of the brick in m\n",
+ "K1=4.984\t\t#Thermal conductivity of brick in kJ/hr m C/m\n",
+ "L2=0.125\t\t#Thickness of insulating brick in m\n",
+ "K2=0.623\t\t#Thermal conductivity of insulating brick in kJ/hr m C /m\n",
+ "Ti=1650.0\t\t#Temperature inside the furnace in degree centigrade\n",
+ "hl=245.28\t\t#Conductance at inside wall in kJ/hr m**2 C\n",
+ "ho=40.88\t\t#Conductance at outside wall in kJ/hr m**2 C\n",
+ "To=27.0\t\t#Temperature of surrounding atmosphere in degree centigrade \n",
+ "\n",
+ "#Calculations \n",
+ "R=((1.0/hl)+(L1/K1)+(L2/K2)+(1.0/ho))\t#Total resistance of the wall in C hr/kJ\n",
+ "q=(Ti-To)/R\t\t\t#Rate of heat loss per m**2 of the wall in kJ/hr m**2\n",
+ "T1=Ti-(q*(1.0/hl))\t\t\t#Inner surface temperature in degree centigrade\n",
+ "T3=Ti-(q*((1.0/hl)+(L1/K1)+(L2/K2)))\t#Outer surface temperature in degree centigrade\n",
+ "\n",
+ "#Output\n",
+ "print'(a)The rate of heat loss per sq m of the wall is',round(q,1), \"kJ/hr m**2\"\n",
+ "print'(b)The temperature at the inner surface is',round(T1,2),\"C\" \n",
+ "print'(c)The temperature at the outer surface is',round(T3,2),\"C\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)The rate of heat loss per sq m of the wall is 5916.3 kJ/hr m**2\n",
+ "(b)The temperature at the inner surface is 1625.88 C\n",
+ "(c)The temperature at the outer surface is 171.72 C\n"
+ ]
+ }
+ ],
+ "prompt_number": 85
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.6 page no:227"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find(a)The heat transfer by conduction through the wall \n",
+ "#(b)Resistance of the wall \n",
+ "#Conductance of the wall .\n",
+ "\n",
+ "#Input data\n",
+ "x=0.3\t\t#Thickness of the wall in degree centigrade\n",
+ "t1=24.0\t\t#Inside surface temperature of the wall in degree centigrade\n",
+ "t2=-6\t\t#Outside temperature of wall in degree centigrade\n",
+ "h=2.75\t\t#Height of the wall in m\n",
+ "L=6.1\t\t#Length of the wall in m\n",
+ "K=2.6\t\t#Coefficient of conductivity of brick in kJ/hr m C\n",
+ "\n",
+ "#Calculations \n",
+ "A=h*L\t\t#Area of the wall in m**2\n",
+ "A=round(A,1)\n",
+ "T=t2-t1\t\t#Temperature difference in degree centigrade\n",
+ "q=(K*A*(-T))/(x)\t#Heat transfer by conduction in kJ/hr\n",
+ "R=(t1-t2)/q\t#Resistance of the wall in C hr/kJ\n",
+ "C=1.0/R\t\t#Conductance of the wall in kJ/m C\n",
+ "\n",
+ "#Output\n",
+ "print'(a)The heat transfer by conduction through the wall is',q, \"kJ/hr\"\n",
+ "print'(b)Resistance of the wall is',round(R,5),\"C hr/kJ\"\n",
+ "print'(C)Conductance of the wall is',round(C,1),\"kJ/m C\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)The heat transfer by conduction through the wall is 4368.0 kJ/hr\n",
+ "(b)Resistance of the wall is 0.00687 C hr/kJ\n",
+ "(C)Conductance of the wall is 145.6 kJ/m C\n"
+ ]
+ }
+ ],
+ "prompt_number": 86
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.8 page no:230"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Determine Heat received by the unit area of earths surface.\n",
+ "\n",
+ "#Input data \n",
+ "T=300\t\t#Temperature of the earth as a black body in K\n",
+ "s=20.52*10**-8\t#Stefan Boltzmann constant in kJ/hr m**2 T**4\n",
+ "\n",
+ "#Calculations \n",
+ "Q=s*T**4\t#Heat received by unit area on the earths surface perpendicular to solar rays in kJ/hr\n",
+ "\n",
+ "#Output\n",
+ "print'Heat received by the unit area of earths surface',round(Q,2),\"kJ/hr\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Heat received by the unit area of earths surface 1662.12 kJ/hr\n"
+ ]
+ }
+ ],
+ "prompt_number": 87
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.9 page no:230"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#What is The loss of heat by radiation from steel tube\n",
+ "\n",
+ "#Input data\n",
+ "D=0.07\t\t # Diameter of the steel tube in m\n",
+ "L=3.0\t\t #Length of the steel tube\n",
+ "t1=227.0\t\t#Temperature of the steel tube in m\n",
+ "t2=27.0\t \t#Temperature of the room in degree centigrade\n",
+ "s=20.52*10**-8\t#Stefan Boltzmann constant in kJ/hr m**2 T**4\n",
+ "pi=3.1428\t\t#Constant value of pi\n",
+ "\n",
+ "#Calculations \n",
+ "A=2*pi*D*L\t #Surface area of the tube in m**2\n",
+ "Q=(A)*(s)*((t1+273)**4-(t2+273)**4)\t#Loss of heat by radiation in kJ/hr\n",
+ "Q1=Q/3600.0\t #Loss of heat by radiation in kW\n",
+ "\n",
+ "#Output\n",
+ "print'The loss of heat by radiation from steel tube is',round(Q1,3),\"KW\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The loss of heat by radiation from steel tube is 4.093 KW\n"
+ ]
+ }
+ ],
+ "prompt_number": 88
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.10 page no:231"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find The rate of heat removed from the refrigirator\n",
+ "\n",
+ "#Input data\n",
+ "T1=7.0\t\t #Inside temperature of refrigerator in degree centigrade \n",
+ "T0=28.0\t\t#Temperature in the kitchen in degree centigrade\n",
+ "K1=40.0\t\t#Thermal conductivity of mild steel in W/mC\n",
+ "x1=0.03\t\t#Thickness of mild sheets in m\n",
+ "K3=40.0\t\t#Thermal conductivity of the mild steel in W/mC\n",
+ "x3=0.03\t\t#Thickness of another side mild sheet in m\n",
+ "x2=0.05\t\t#Thickness of glass wool insulated in m\n",
+ "hi=10.0\t\t#Heat transfer coefficient in the inner surface of refrigerator in W/m**2 C\n",
+ "ho=12.5\t\t#Heat transfer coefficient in the outer surface of refrigerator in W/m**2 C\n",
+ "K2=0.04\t\t#Thermal conductivity of glass in W/mC\n",
+ "\n",
+ "#Calculations\n",
+ "Q=(T1-T0)/((1/hi)+(x1/K1)+(x2/K2)+(x3/K3)+(1/ho))\t#Heat transfer per unit area in W/m**2\n",
+ "\n",
+ "#Output\n",
+ "print'The rate of heat removed from the refrigirator ',round(Q,3),\"W/m**2\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The rate of heat removed from the refrigirator -14.67 W/m**2\n"
+ ]
+ }
+ ],
+ "prompt_number": 89
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.11 page no:232"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find (a)Heat loss per m**2 area of the furnace wall \n",
+ "#(b)Maximum temperature to which common brick is subjected \n",
+ "\n",
+ "#Input data\n",
+ "x1=0.2\t \t#Thickness of the fire brick\n",
+ "x2=0.2\t \t#Thickness of the common brick\n",
+ "Ti=1400.0 \t#Temperature of hot gases in the inner surface of the brick in degree centigrade\n",
+ "To=50.0\t\t#Temperature of gases in the outer surface of the brick in degree centigrade\n",
+ "h1=16.5\t\t#Convection heat transfer coefficient on gas side in W/mC\n",
+ "h2=17.5\t\t#radiation heat transfer coefficient on gas side in W/mC\n",
+ "h3=12.5\t\t#Convection heat transfer coefficient on outer side in W/mC\n",
+ "h4=6.5 \t\t#Radiation heat transfer coeeficient on outer side in W/mC\n",
+ "K1=4.0 \t\t#Thermal conductivity of fire brick in W/mC\n",
+ "K2=0.65\t\t#Thermal conductivity of common brick in W/mC\n",
+ "\n",
+ "#Calculations \n",
+ "hi=h1+h2\t\t#Total heat transfer coefficient in inner \n",
+ "ho=h3+h4\t\t#Total heat transfer coefficient in outer \n",
+ "Q=(Ti-To)/((1/hi)+(x1/K1)+(x2/K2)+(1/ho))\t#Heat flow through the furnace composite wall per unit area in W/m**2\n",
+ "Q1=Q/1000\n",
+ "T1=Ti-(Q/hi)\t#Temperature at the inside of the fire brick \n",
+ "T2=T1-(Q*(x1/K1))#Maximum temperature to which common brick is subjected in degree centigrade\n",
+ "\n",
+ "#Output\n",
+ "print'(a)Heat loss per m**2 area of the furnace wall is',round(Q)/1000,\"kW/m**2\" \n",
+ "print'(b)Maximum temperature to which common brick is subjec',round(T1,3),\"C\" \n",
+ "print'(c)similarly on other side is',round(T2,3),\"C\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)Heat loss per m**2 area of the furnace wall is 3.07 kW/m**2\n",
+ "(b)Maximum temperature to which common brick is subjec 1309.705 C\n",
+ "(c)similarly on other side is 1156.204 C\n"
+ ]
+ }
+ ],
+ "prompt_number": 90
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.12 page no:234"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#What is The thickness of the red brick layer \n",
+ "\n",
+ "#Input data\n",
+ "K1=0.93\t\t#Thermal conductivity of fire clay in W/mC\n",
+ "K2=0.13\t\t#Thermal conductivity of diatomite brick in W/mC\n",
+ "K3=0.7\t\t#Thermal conductivity of red brick in W/mC\n",
+ "x1=0.12\t\t#Thickness of fire clay in m\n",
+ "x2=0.05\t\t#Thickness of diatomite in m\n",
+ "x3=0.25\t\t#Thickness of brick in m\n",
+ "T=1\t\t#Assume the difference between temperature in degree centigrade\n",
+ "\n",
+ "#Calculations\n",
+ "Q=(T)/((x1/K1)+(x2/K2)+(x3/K3))\t#The heat flow per unit area in W/m**2\n",
+ "X3=K3*((T/Q)-(x1/K1))\t\t#Thickness of the red brick layer in m\n",
+ "X=X3*100\t\t\t#Thickness of the red brick layer in cm\n",
+ "\n",
+ "#Output\n",
+ "print'The thickness of the red brick layer is',round(X,3),\"cm\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The thickness of the red brick layer is 51.923 cm\n"
+ ]
+ }
+ ],
+ "prompt_number": 91
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.13 page no:235"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Determine the rate of heat loss\n",
+ "\n",
+ "#Input data\n",
+ "R1=0.06\t\t#Thickness of material layer in m\n",
+ "R2=0.12\t\t#Thickness of the two insulating materials in m\n",
+ "R3=0.16\t\t#Thickness of material layers with pipe in m\n",
+ "K1=0.24\t\t#Thermal conductivity of one layer in W/mC\n",
+ "K2=0.4\t\t #Thermal conductivity of another layer in W/mC\n",
+ "L=60.0\t\t #Length of the pipe in m\n",
+ "hi=60.0\t\t#Heat transfer coefficient inside in W/m**2C\n",
+ "ho=12.0\t\t#Heat transfer coefficient outside in W/m**2C\n",
+ "ti=65.0\t\t#Temperature of hot air flowing in pipe in degree centigrade\n",
+ "to=20.0\t\t#Atmospheric temperature in degree centigrade\n",
+ "pi=3.1428\t #Constant value of pi\n",
+ "\n",
+ "#Calculations\n",
+ "Q=(ti-to)*(2*pi*L)/((1/(hi*R1))+(math.log(R2/R1)/(K1))+(math.log(R3/R2)/(K2))+(1/(ho*R3)))\t#Rate of heat loss in W\n",
+ "Q1=Q/1000\t#Rate of heat loss in kW\n",
+ "\n",
+ "#Output\n",
+ "print'The rate of heat loss is',round(Q1,4),\"kW\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The rate of heat loss is 3.8519 kW\n"
+ ]
+ }
+ ],
+ "prompt_number": 92
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.14 page no:237"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find (a)The quantity of heat lost per meter length of steam pipe \n",
+ "#(b)The quantity of steam coming out of one meter length pipe.\n",
+ "\n",
+ "#Input data\n",
+ "R1=8.0\t\t #Inner radius of the pipe in cm\n",
+ "R2=8.5\t\t #Outter radius of the pipe in cm\n",
+ "x1=3.0\t\t #Thickness of first layer in cm\n",
+ "x2=5.0\t\t #Thickness of second layer in cm\n",
+ "T1=300.0\t\t#Inner surface temperature of the steam pipe in degree centigrade\n",
+ "pi=3.1428\t #Constant value of pi \n",
+ "T4=50.0\t\t #Temperature at outer surface of insulation in degree centigrade\n",
+ "L=1.0\t\t #Length of the pipe in m\n",
+ "K1=50.0\t \t#Thermal conductivity of pipe in W/mC\n",
+ "K2=0.15\t \t#Thermal conductivity of first layer in W/mC\n",
+ "K3=0.08\t \t#Thermal conductivity of second layer in W/mC\n",
+ "h=2751.0\t\t#Enthalpy of dry and saturated steam at 300 degree centigrade in kJ/kg\n",
+ "q=40.0\t \t#Quantity of steam flow in gm/hr\n",
+ "hf=1345.0\t\t#Enthalpy of fluid at 300 degree centigrade in kJ/kg\n",
+ "hfg=1406.0\t\t#enthalpy at 300 degree centigrade in kJ/kg\n",
+ "\n",
+ "#Calculations\n",
+ "R3=R2+x1\t#Radius of pipe with first layer\n",
+ "R4=R3+x2\t#Radius of pipe with two layers\n",
+ "Q=(2*pi*L*(T1-T4))/((math.log(R2/R1)/(K1))+(math.log(R3/R2)/(K2))+(math.log(R4/R3)/(K3)))\n",
+ "Q1=Q/1000\t#Quantity of heat loss per meter length of pipe in kW\n",
+ "Q2=Q1*3600\t#Quantity of heat loss per meter length of pipe in kJ/hr\n",
+ "hg=((h)-(Q2/q))\t#Enthalpy of steam in kJ/kg\n",
+ "x=(hg-hf)/(hfg)\t#Dryness fraction of steam\n",
+ "\n",
+ "#Output\n",
+ "print'(a)The quantity of heat lost per meter length of steam pipe is',round(Q,2),\"W/m or\",round(Q*3600/1000),\"kJ/hr\"\n",
+ "print'(b)The quantity of steam coming out of one meter length pipe is',round(x,4),\"gm/h\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)The quantity of heat lost per meter length of steam pipe is 240.68 W/m or 866.0 kJ/hr\n",
+ "(b)The quantity of steam coming out of one meter length pipe is 0.9846 gm/h\n"
+ ]
+ }
+ ],
+ "prompt_number": 93
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.15 page no:238"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find(a)The heat transfer by conduction through the wall \n",
+ "#(b)Resistance of the wall \n",
+ "#Conductance of the wall .\n",
+ "\n",
+ "#Input data\n",
+ "x=0.3\t\t#Thickness of brick wall in m\n",
+ "ti=24.0\t\t#Inside surface temperature of wall in degree centigrade\n",
+ "to=-6.0\t\t#Outside surface temperature of wall in degree centigrade\n",
+ "h=2.75\t\t#Height of the wall in m\n",
+ "L=6.1\t\t#Length of the wall in m\n",
+ "K=2.6\t\t#Thermal conductivity of brick material in kJ/m hr C\n",
+ "\n",
+ "#Calculations\n",
+ "T=ti-to\t\t#Temperature difference across the wall in degree centigrade\n",
+ "A=h*L\t\t#Area of the wall in m**2\n",
+ "Q=(K*A*T)/(x)\t#Heat transfer through conduction by the wall per hour in kJ/hr\n",
+ "R=T/Q\t\t#Resistance of the wall in hr C/kJ\n",
+ "C=1.0/R\t\t#Conductance of the wall in kJ/hr C\n",
+ "\n",
+ "#Output\n",
+ "print'(a)The heat transfer by conduction through the wall is',round(Q),\"kJ/hr \"\n",
+ "print'(b)The resistance of the wall is ',round(R,5),\"Chr/Kj \" \n",
+ "print' The conductance of the wall is',round(C,1), \"kJ/hr C \"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)The heat transfer by conduction through the wall is 4362.0 kJ/hr \n",
+ "(b)The resistance of the wall is 0.00688 Chr/Kj \n",
+ " The conductance of the wall is 145.4 kJ/hr C \n"
+ ]
+ }
+ ],
+ "prompt_number": 94
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.16 page no:240"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#What is The reduction in heat loss through the wall\n",
+ "\n",
+ "#Input data\n",
+ "x1=0.3 \t#Thickness of refractory bricks in m\n",
+ "K1=5.66\t\t#Thermal conductivity of refractory bricks in kJ/hr mC\n",
+ "t1=1650.0\t\t#Inner surface temperature of the wall in degree centigrade\n",
+ "t2=320.0\t \t#Outside surface temperature of the wall in degree centigrade\n",
+ "x2=0.3\t \t#Thickness of insulating brick in m\n",
+ "K2=1.26\t\t#Thermal conductivity of insulating brick in kJ/hr mC\n",
+ "A=1.0\t \t#unit surface area in m**2\n",
+ "t3=27.0\t\t#Outside surface temperature of the brick in degree centigrade\n",
+ "\n",
+ "#Calculations \n",
+ "T1=t1-t2\t\t#Temperature difference in degree centigrade\n",
+ "Q1=(K1*A*T1)/(x1)\t#Heat loss without insulation in kJ/hr/m**2\n",
+ "R1=(K1*A)/(x1)\t#Heat loss for the change in temperature for refractory brick wall material in kJ/hrC\n",
+ "R2=(K2*A)/(x2)\t#Heat loss for the change in temperature for insulated brick wall material kJ/hrC\n",
+ "Q2=(t1-t3)/((1.0/R1)+(1.0/R2))\t#Heat loss with insulation in kJ/hr/m**2\n",
+ "Q3=Q1-Q2\t\t#Reduction in heat loss through the wall in kJ/hr/m**2\n",
+ "\n",
+ "#Output\n",
+ "print'The reduction in heat loss through the wall is ',round(Q3,1),\"kJ/hr/m**2\"\n",
+ "print\"\\nNOTE:Answer wrongly written in book as 1951.4\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The reduction in heat loss through the wall is 19517.2 kJ/hr/m**2\n",
+ "\n",
+ "NOTE:Answer wrongly written in book as 1951.4\n"
+ ]
+ }
+ ],
+ "prompt_number": 95
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.17 page no:241"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find (a)The leakage through the wall per 24 hours \n",
+ "#(b)Temperature at the interface \n",
+ "#Temperature at interface \n",
+ "\n",
+ "#Input data\n",
+ "L=4.6\t \t #Length of the wall in m\n",
+ "b=2.3\t \t#Breadth of the wall in m\n",
+ "x1=0.025\t\t#Thickness of the wood in m\n",
+ "x2=0.075\t\t#Thickness of the cork slabbing in m\n",
+ "x3=0.115\t\t#Thickness of the brick in m\n",
+ "t1=18.0\t\t #Exterior temperature of the wall in degree centigrade\n",
+ "t4=-20.0\t\t#Interior temperature of the wall in degree centigrade\n",
+ "K1=7.5 \t\t #Thermal conductivity of the wood in kJ/hr mC\n",
+ "K2=1.9 \t\t #Thermal conductivity of the wood in kJ/hr.mC\n",
+ "K3=41.0\t\t #Thermal conductivity of the brick in kJ/hr mC\n",
+ "\n",
+ "#Calculations\n",
+ "A=L*b\t\t#Area of the wall in m**2\n",
+ "R1=(K1*A)/(x1)\t#Heat loss for the change in temperature for insulated wood material in kJ/hrC\n",
+ "R2=(K2*A)/(x2)\t#Heat loss for the change in temperature for cork material in kJ/hrC\n",
+ "R3=(K3*A)/(x3)\t#Heat loss for the change in temperature for brick in kJ/hrC\n",
+ "Q=(t1-t4)/((1.0/R1)+(1.0/R2)+(1.0/R3))\t#Heat loss with insulation in kJ/hr\n",
+ "Q1=Q*24.0\t\t#Heat loss with insulation in kJ/24hr\n",
+ "t2=t1-(Q/R1)\t#Interface temperature t2 in degree centigrade \n",
+ "t3=t2-(Q/R2)\t#Interface temperature t3 in degree centigrade\n",
+ "\n",
+ "#Output \n",
+ "print'(a)The leakage through the wall per 24 hours is',round(Q,2),\"kJ/hr=\",round(Q,2)*24 \n",
+ "print'(b)Temperature at the interface is',round(t2,3),\"C\" \n",
+ "print'(c)Temperature at interface ',round(t3,3),\"C\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)The leakage through the wall per 24 hours is 8814.37 kJ/hr= 211544.88\n",
+ "(b)Temperature at the interface is 15.223 C\n",
+ "(c)Temperature at interface -17.663 C\n"
+ ]
+ }
+ ],
+ "prompt_number": 96
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.18 page no:243"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find The heat loss per sq metre of surface area for a furnace wall \n",
+ "\n",
+ "#Input data\n",
+ "L=0.3\t\t#Thickness of the wall in m\n",
+ "ti=320\t\t#Inner surface temperature in degree centigrade\n",
+ "to=38\t\t#Outer surface temperature in degree centigrade\n",
+ "A=1\t\t#Assume unit area in m**2\n",
+ "\n",
+ "#Calculations\n",
+ "Q=(A/L)*((0.01256/2)*(ti**2-to**2)-(4.2/3)*10**-6*(ti**3-to**3)) #Heat loss per sq metre of surface area\n",
+ "\n",
+ "#Output\n",
+ "print'The heat loss per sq metre of surface area for a furnace wall is',round(Q,2),\"kJ/hr/m**2 \"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The heat loss per sq metre of surface area for a furnace wall is 1960.68 kJ/hr/m**2 \n"
+ ]
+ }
+ ],
+ "prompt_number": 97
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.19 page no:245"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Input data\n",
+ "d=11.5\t\t#Outer diameter of steam pipe line in cm\n",
+ "t1=5.0\t\t#Thickness of first layer in cm\n",
+ "K1=0.222\t\t#Thermal conductivity of first layer in kJ/hr mC\n",
+ "t2=3.0\t\t#Thickness of second layer in cm\n",
+ "pi=3.1428\t\t#Constant value of pi\n",
+ "K2=3.14\t\t#Thermal conductivity of second layer in kJ/hr mC\n",
+ "T1=235\t\t#Outside surface temperature of steam pipe in degree centigrade\n",
+ "T3=38\t\t#Outer surface of lagging in degree centigrade\n",
+ "L=1.0\t\t#Length of the pipe in m\n",
+ "\n",
+ "#Calculations\n",
+ "I=math.log((d+(2*t1))/d)\t\t\t#For inner layer calculation\n",
+ "O=math.log((d+(2*t1)+(2*t2))/(d+(2*t1)))\t\t#For outer layer calculations\n",
+ "R1=(2.0*pi*L*K1)/I\t\t#Heat loss for change in temperature for first insulated material in kJ/hC\n",
+ "R2=(2.0*pi*L*K2)/O\t\t#Heat loss for the change in temperature for second insulated material in kJ/hC\n",
+ "Q=(T1-T3)/(1.0/R1+1.0/R2)\t#Heat loss per metre length of pipe per hr in kJ/hr\n",
+ "T2=T1-(Q/R1)#Temperature between the two layers of insulation in degree centigrade\n",
+ "\n",
+ "#Output\n",
+ "print'(a)The heat loss per metre length of pipe per hr is',round(Q,2),\" kJ/hr\" \n",
+ "print'(b)Temperature between the two layers of insulation is',round(T2,2),\"C\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "(a)The heat loss per metre length of pipe per hr is 427.45 kJ/hr\n",
+ "(b)Temperature between the two layers of insulation is 43.33 C\n"
+ ]
+ }
+ ],
+ "prompt_number": 98
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.20 page no:247"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#Find the rate of heat flow\n",
+ "\n",
+ "#Input data\n",
+ "t1=24.0 \t#Temperature at the outside surface in degree centigrade \n",
+ "t4=-15.0 \t#Temperature at the inner surface in degree centigrade\n",
+ "A=1.0 \t\t#Assuming unit area in m**2\n",
+ "K1=23.2\t\t#Thermal conductivity of steel in W/mC\n",
+ "K2=0.014\t\t#Thermal conductivity of glasswood in W/mC\n",
+ "K3=0.052\t\t#Thermal conductivity of plywood in W/mC\n",
+ "x1=0.0015\t\t#Thickness of steel sheet at outer surface in m\n",
+ "x2=0.02\t\t#Thickness of glasswood in between in m\n",
+ "x3=0.01\t\t#Thickness of plywood at a inner surface in m\n",
+ "\n",
+ "#Calculations\n",
+ "R1=(K1*A)/x1\t#Heat loss for the change in temperature for first insulated material\n",
+ "R2=(K2*A)/x2\t#Heat loss for the change in temperature for second insulated material\n",
+ "R3=(K3*A)/x3\t#Heat loss for the change in temperature for third insulated material\n",
+ "Q=(t1-t4)/(1/R1+1/R2+1/R3)\t#The rate of heat flow in W/m**2\n",
+ "\n",
+ "#Output\n",
+ "print'The rate of heat flow is',round(Q,2),\"W/m**2 \"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The rate of heat flow is 24.06 W/m**2 \n"
+ ]
+ }
+ ],
+ "prompt_number": 21
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file
diff --git a/Basic_Mechanical_Engineering/screenshots/ravi1.png b/Basic_Mechanical_Engineering/screenshots/ravi1.png
new file mode 100644
index 00000000..e08f066d
--- /dev/null
+++ b/Basic_Mechanical_Engineering/screenshots/ravi1.png
Binary files differ
diff --git a/Basic_Mechanical_Engineering/screenshots/ravi2.png b/Basic_Mechanical_Engineering/screenshots/ravi2.png
new file mode 100644
index 00000000..8807457b
--- /dev/null
+++ b/Basic_Mechanical_Engineering/screenshots/ravi2.png
Binary files differ
diff --git a/Basic_Mechanical_Engineering/screenshots/ravi3.png b/Basic_Mechanical_Engineering/screenshots/ravi3.png
new file mode 100644
index 00000000..be16b4e6
--- /dev/null
+++ b/Basic_Mechanical_Engineering/screenshots/ravi3.png
Binary files differ