Chapter 6 : The second law of thermodynamics¶

Example 6.1 pg : 140¶

In [1]:

# Variables
m = 5. 	    	    	#lbm
P = 50. 	    		#psia
T = 500. + 460 			#R

# Calculations
s1 = 0.4110 			#B/lbm R
s2 = 1.7887 			#B/lbm R
dS = m*(s2-s1)

# Results
print "Change in entropy  =  %.3f B/R"%(dS)

Change in entropy  =  6.888 B/R


Example 6.2 pg : 140¶

In [2]:

# Variables
P = 20.          			#psia
T = 227.96+ 459.69 			#R

# Calculations
sfg = 1.3962 			#B/ R lbm
Q = T*sfg

# Results
print "heat transfer  =  %.1f B/lbm"%(Q)

heat transfer  =  960.1 B/lbm


Example 6.3 pg : 141¶

In [4]:
import math

# Variables
T1 = 100.+460 			#R
P1 = 15.    			#psia
P2 = 50. 	    		#psia
n = 1.3
cp = 0.24

# Calculations
T2 = T1*(P2/P1)**((n-1)/n)
dS = cp*math.log(T2/T1) - 53.35/778 *math.log(P2/P1)

# Results
print "Change in entropy  =  %.3f B/lbm R"%(dS)
#the answer given in textbook is wrong. Please check it using a calculator

Change in entropy  =  -0.016 B/lbm R


Example 6.4 pg : 141¶

In [5]:
import math

# Variables
T1 = 85.+460 			#R
T2 = T1
cp = 0.24
P2 = 15. 			#psia
P1 = 30. 			#psia

# Calculations
dS = cp*math.log(T2/T1) - 53.35/778 *math.log(P2/P1)

# Results
print "Change in entropy  =  %.4f B/lbm R"%(dS)

Change in entropy  =  0.0475 B/lbm R


Example 6.5 pg : 142¶

In [6]:

# Variables
Qh = -1000. 			#Btu
Ql = 1000.   			#Btu
Th = 1460. 	    		#R
Tl = 960. 		    	#R

# Calculations
Sh = Qh/Th
Sl = Ql/Tl
S = Sh+Sl

# Results
print "Change in entropy of the universe  =  %.3f B/R"%(S)

Change in entropy of the universe  =  0.357 B/R


Example 6.6 pg : 143¶

In [7]:

# Variables
h1 = 1416.4 			#B/lbm
s1 = 1.6842 			#B/lbm R

# Calculations
s2 = s1
P2 = 50. 			#psia
T2 = 317.5 			#F
h2 = 1193.7
W = h2-h1

# Results
print "Work calculated  =  %.1f B/lbm"%(W)

Work calculated  =  -222.7 B/lbm