화학공학소재연구정보센터
Industrial & Engineering Chemistry Research, Vol.50, No.10, 6404-6412, 2011
An Object-Oriented Approach for Structure Design of Property Calculation Programs Using Equations of State
A new object-oriented approach for designing general property calculation programs using different types of equations of state (EoS) is presented in this work. It helps to ease the programs' extensibility, reusability, and maintainability and, at the same time, minimize the code redundancy. The approach consists of two parts: (a) the total Helmholtz free energy function is separated into specific terms, based on physical meanings or mathematical expressions, independent of the properties of interest, and the same or similar specific terms used in different equations of state are abstracted to general algorithms; (b) the general relationships between these algorithms and the properties of interest are implemented at the highest level of the program. According to this strategy, a general cubic algorithm can be abstracted for all of the cubic EoS. The general hard-sphere, hard-chain, and association algorithms can be aggregated into different Statistical Associating Fluid Theory (SAFT) family EoS with different dispersion algorithms. Similarly, the general cubic and association algorithms can be aggregated into Cubic Plus Association (CPA) EoS. Taking Perturbed-Chain SAFT (PC-SAFT) EoS as an example, this manuscript demonstrates a clear object-oriented structure for developers, with regard to how to design a complete thermodynamic model package using this approach.