Chapter 4 : principles of energy analysis

Example 4.1 pg : 79

In [1]:
			
# Variables
m = 1.
he = 1148.8 			#B/lbm
hi = 1357. 			#B/lbm
Ve = 100. 			#ft/sec
Vi = 800. 			#ft/sec
			
# Calculations
dW =  m*(he-hi) + m*(Ve**2 - Vi**2)/(2*32.2*778)
dWhr = dW*3600
hp = -dWhr/2545.
			
# Results
print "Horsepower output  =  %d hp"%(hp+1)
Horsepower output  =  313 hp

Example 4.2 pg:79

In [2]:
			
# Variables
rate = 80. 			#lbm/min
T1 = 100. 			#F
P1 = 100. 			#psia
P2 = 1000. 			#psia
			
# Calculations
v = 0.01613 			#ft**3/lbm
W = rate*(P2-P1)*144*v
			
# Results
print "Work done  =  %.2f ft-lbf/min"%(round(W,-3))
Work done  =  167000.00 ft-lbf/min

Example 4.3 pg : 81

In [3]:
			
# Variables
hi = 1279.1 			#B/lbm
			
# Calculations
u2 = hi
T2 = 564. 			#F
			
# Results
print "Temperature of steam  =  %d F"%(T2)
Temperature of steam  =  564 F

Example 4.4 pg : 82

In [5]:
			
# Variables
import math 
P1 = 20. 			#psia
P2 = 100. 			#psia
V = 3. 	    		#ft**3
T = 560. 			#R
ma = 0.289
			
# Calculations
ma = P1*V/(53.35*T)
Wa = -ma*53.35*T*math.log(P1/P2)
Qa = -Wa
Va2 = 3/5.
V2s = V-Va2
hi = 1279.1 			#B/lbm
T2s = 536. 			#F
			
# Results
print "Final temperature  =  %d F"%(T2s)
Final temperature  =  536 F

Example 4.5 pg : 87

In [7]:
import math

# Variables
P1 = 200. 			#psia
P2 = 100. 			#psia
T1 = 300.+460 			#R
g = 1.4
cp = 0.24
			
# Calculations
T2 = (T1)*(P2/P1)**((g-1)/g)
V2 = math.sqrt(2*32.2*778*cp*(T1-T2))
			
# Results
print "Final velocity   =  %d ft/sec"%(V2)

# check answer using calculator
Final velocity   =  1281 ft/sec

Example 4.6 pg : 88

In [8]:
			
# Variables
T1 = 500.+460 			#R
P1 = 50. 			#psia
P2 = 15. 			#psia
g = 1.4
cp = 0.24
			
# Calculations
T2 = T1*(P2/P1)**((g-1)/g)
W = cp*(T2-T1) + (T1-460)**2 /(2*32.2*778)
			
# Results
print "Net work output from turbine  =  %.1f B/lbm"%(W)
Net work output from turbine  =  -62.1 B/lbm

Example 4.7 pg : 91

In [9]:
			
# Variables
T1 = 150.+460 			#R
T1 = 40.+460 			#R
			
# Calculations
h2 = 43.850 			#B/lbm
hf2 = 17.273
hfg2 = 64.163
x2 = (h2-hf2)/hfg2
			
# Results
print "Quality of freon vapor  =  %.3f"%(x2)
Quality of freon vapor  =  0.414