# Chapter 7 : Phase Equilibia 2 Fugacity¶

## Example 7.1 Page No : 397¶

In [1]:
import math

# Variables
h_cap_H2O = 2676.0 ; 			#[kJ/kg],From steam table
S_cap_H2O = 7.3548 ; 			#[kJ/kgK],From steam table
h_cap_0_H2O = 2687.5 ; 			#[kJ/kg],From Appendix B
S_cap_0_H2O = 8.4479 ; 			#[kJ/kgK],From Appendix B
P_0_H2O = 10. ;			#[kPa]
T = 373.15 ;			#[K]
R = 8.314 / 18 ;
P_sys = 101.35 ;			#[kPa]

# Calculations
g_cap_H2O = h_cap_H2O - T * S_cap_H2O ;
g_cap_0_H2O = h_cap_0_H2O - T * S_cap_0_H2O ;

f_H2O = P_0_H2O * math.exp((g_cap_H2O - g_cap_0_H2O ) / (R * T)) ;

Sai_H2O = f_H2O / P_sys ;

# Results
print "The fugacity = %.2f kPa  The fugacity coefficient = %.3f"%(f_H2O,Sai_H2O);

The fugacity = 99.73 kPa  The fugacity coefficient = 0.984


## Example 7.3 Page No : 402¶

In [2]:
# Variables
P = 50.      			#[bar]
T = 25. + 273.2			#[K]
P_c = 48.7 ; 			#[bar] , From Appendix A.1 Table C.7 & C.8
T_c = 303.5 ; 			#[K] , From Appendix A.1 Table C.7 & C.8
w = 0.099 ; 			# From Appendix A.1 Table C.7 & C.8
log_w_0 = -0.216 ;			# By interpolation
log_w_1 = -0.060 ;			# By interpolation

# Calculations
X = log_w_0 + w * log_w_1 ;
sai_eth = 10**(X) ;
f_eth = sai_eth * P ;

# Results
print "Fugacity = %.f bar"%(f_eth);


Fugacity = 30 bar


## Example 7.10 Page No : 435¶

In [4]:
# Variables
import math
gama_a_inf = 0.88 ;
gama_b_inf = 0.86 ;
R =  8.314 ;
T = 39.33 + 273 ;

# Calculations
A_1 = R * T * math.log(gama_a_inf) ;
A_2 = R * T * math.log(gama_b_inf) ;
A = (A_1 + A_2) / 2 ;

# Results
print "The average value of two-suffix Margules parameter A = %.f J/mol"%(A);

The average value of two-suffix Margules parameter A = -362 J/mol


## Example 7.13 Page No : 448¶

In [2]:
# Variables
A_T1 = 1401. ; 			#[J/mol]
T1 = 10 + 273. ;			#[K]
T2 = 60 + 273. ; 			#[K]
C = 3250. ;
A_T2_prev = 1143. ;			#[J/mol]

# Calculations and Results
A_T2 = T2 * (C *(1./T2 - 1./T1) + A_T1 / T1);
print "Value of A at 60*C = %.f J/mol"%(A_T2) ;

x = (A_T2_prev - A_T2) / A_T2_prev* 100 ;
print "The values differ by = %.f %%"%(x)

# Note: Answer may vary because of rounding off error.

Value of A at 60*C = 1074 J/mol
The values differ by = 6 %