Chapter 11 - Properties of Gases

Example 1 - Pg 172

In [1]:
#calculate the volume of the appratus
#initialization of varaibles
P1=15. #psia
T1=80+460. #R
dm=3. #lb
T2=75+460. #R
P2=25. #psia
#calculations
mratio=P1*T2/(P2*T1)
m2=dm/(1-mratio)
V2=m2*55.16*T2/(P2*144.)
#results
print '%s %.1f %s' %("Volume of the apparatus =",V2,"cu ft")
print '%s' %("The answer is a bit different due to rounding off error in textbook")
Volume of the apparatus = 60.6 cu ft
The answer is a bit different due to rounding off error in textbook

Example 2 - Pg 176

In [2]:
#Calculate the specific heats at constant pressure and volume
#initialization of varaibles
R=48.3 #ft lb/lb R
k=1.4
#calculations
dc=R/778.
cp=k*dc/(k-1)
cv=cp/k
#results
print '%s %.3f %s' %("Specific heat at constant volume = ",cv,"B/lb R")
print '%s %.3f %s' %("\n Specific heat at constant pressure = ",cp,"B/lb R")
Specific heat at constant volume =  0.155 B/lb R

 Specific heat at constant pressure =  0.217 B/lb R

Example 3 - Pg 177

This is a theoretical example.

Example 4 - Pg 180

In [3]:
#Calculate the enthalpy generated
#initialization of varaibles
import math
P1=100. #psia
P2=10. #psia
T1=140. +460 #R
g=1.4
cp=0.248
#calculations
dh=g*55.16*T1*(math.pow((P2/P1),((g-1)/g)) -1)/(g-1)*0.01286 #0.01286 is the conversion factor
T2=T1*math.pow((P2/P1),((g-1)/g))
dh2=cp*(T2-T1)
#results
print '%s %d %s' %("In method 1, Enthalpy = ",dh,"Btu/lb")
print '%s %.1f %s' %("\n In method 2, Enthalpy =",dh2,"ft lb/lb")
In method 1, Enthalpy =  -718 Btu/lb

 In method 2, Enthalpy = -71.7 ft lb/lb

Example 5a - Pg 186

In [2]:
#Calculate the changes in Enthalpy and Specific Volume
#initialization of varaibles
import math
P1=100. #psia
T1=2000.+460 #R
P2=15. #psia
g=1.4
cp=0.24
#calculations
v1=53.34*T1/(P1*144.)
v2=53.34*T1*math.pow((P1/P2),(1/g)) /(P1*144)
T2=T1*P2*v2/(P1*v1)
dh=cp*(T2-T1)
dv=v2-v1
#results
print '%s %d %s' %("Change in enthalpy =",dh,"B/lb")
print '%s %.1f %s' %("\n Specific volume change = ",dv,"cu ft/lb")
print '%s' %("The answer is a bit different due to rounding off error in textbook")
Change in enthalpy = -247 B/lb

 Specific volume change =  26.2 cu ft/lb
The answer is a bit different due to rounding off error in textbook

Example 5b - Pg 186

In [5]:
#Calculate the changes in Enthalpy and Specific Volume
#initialization of varaibles
import math
P1=100. #psia
T1=2000.+460 #R
P2=15. #psia
g=1.4
cp=0.276
cv=0.207
T2=1520. #R
#calculations
k=cp/cv
v1=53.34*T1/(P1*144)
v2=v1*math.pow((P1/P2),(1/k))
dh=cp*(T2-T1)
dv=v2-v1
#results
print '%s %d %s' %("Enthalpy change =",dh,"B/lb")
print '%s %.1f %s' %("\n Volume change =",dv,"cu t/lb")
Enthalpy change = -259 B/lb

 Volume change = 28.7 cu t/lb

Example 5c - Pg 186

In [6]:
#Calculate the changes in Enthalpy and Specific Volume
#initialization of varaibles
import math
P1=100. #psia
T1=2000.+460 #R
P2=15. #psia
g=1.4
cp=0.276
cv=0.207
T2=1520. #R
#calculations
h1=634.4
pr1=407.3
pr2=pr1*P2/P1
print '%s' %("From table 1,")
T2=1535. #R
h2=378.44
dh=h2-h1
v1=53.34*T1/(P1*144)
v2=53.34*T2/(P2*144.)
dv=v2-v1
#results
print '%s %.2f %s' %("Enthalpy change = ",dh,"B/lb")
print '%s %.1f %s' %("\n Volume change =",dv,"cu ft/lb")
From table 1,
Enthalpy change =  -255.96 B/lb

 Volume change = 28.8 cu ft/lb