Computational Methods in Chemical Engineering CHEE 390
Department of Chemical Engineering McGill University
Term Project Pressure-equilibrium phase composition for
hydrogen / propane system
Instructor: Professor Phillip Servio (398-1026) Instructions:
This computer project must be done using MATLAB®. You must work independently and submit one report electronically as a PDF along with all the m-files. All the files must be contained within 1 zip file. Instructions necessary to execute your code must be imbedded as comments in your m-files. In order to submit your assignment, you will click on the reply to all in the project submission email that I will send out approximately 1 week before the project is due.
© 2023 Phillip Servio
1/3
Problem Statement
A 2-phase flash calculation is required in order to predict the behaviour of the hydrogen/propane system. The phase diagram is given in figure 4 of the manuscript concerning the Soave-Redlich-Kwong equation of state. Your initial guess for equilibrium constants should be taken from the Wilson equation (Wilson, 1968), which is given by the following:
Solution Method
ln(Ki)=ln(Pci )+5.37(1+ωi)(1−Tci ) PT
K i ⇒ ideal equilibrium constants
Pci⇒critical pressure (1)
T ci ⇒ critical temperature T ⇒temperature ωi⇒acentric factor
-
See the 2-phase flash diagram given in class and available online.
-
Use zero-order continuation to obtain the next values of x1 and y1. This is done by stepping
up/down the pressure by a small amount ΔP , and using the values of x1 and y1 at the previous temperature, P p , as the initial guess xp = [x1 ; y1]. In other words,
xguess(Pp±ΔP)=xp(Pp) (2) Note: Equation (1) is only used once at the beginning of your program! After you locate the
first solution, you then implement zero-order continuation and use equation (2).
-
Also note that you will have to change your feed fraction in order to obtain other regions of the phase diagram. As mentioned in class, you can not obtain all possible equilibriums at a given pressure and temperature with a fixed feed composition. You must devise a strategy to do this in order to complete the phase diagram.
Report
Each student is required to submit one report. In your report you must discuss the following:
-
The method used to update your equilibrium constants during each iteration
-
The need for interaction parameters
-
How you test for the existence of 1 or 2 phases at the specified temperature and pressure
that you run your simulation
-
How you calculate the molar volume of the liquid and vapour phases
-
© 2023 Phillip Servio 2/3
In addition, you are also required to reproduce figure 4 and also explain the importance of the initial guess in such a technique and give examples of initial guesses that failed to converge and explain why. The format of the report should be as follows:
-
Title page
-
Objective
-
Flowchart
-
Results & Discussion
-
Conclusion
-
Nomenclature
-
Separate m-files with instructions on how to execute your code.
References
• Wilson, G., “A modified Redlich-Kwong equation of state applicable to general physical data calculations,” Paper No15C, 65th AIChE National meeting, May, (1968)
© 2023 Phillip Servio 3/3