Skip to content

Adding a thermodynamic model in NeqSim

Even Solbraa edited this page May 27, 2021 · 13 revisions

A thermodynamc model is added to NeqSim by adding three classes:

  1. A system class implementing the SystemInterface
  2. A phase class implementing the PhaseInterface
  3. A component class implementing the ComponentInterface.

A number of attractive/repulsive/mixing rules are implemented in NeqSim. If new terms (eg. attractive/repulsive) of EoS should be implemented, see the description below.

The SRK-EoS is implemented by adding the classes: SystemSrkEos, PhaseSrkEosand ComponentSrk

The implementation of an Equation of State is typically based on Michelsen F-functions - and is described in this thesis: https://ntnuopen.ntnu.no/ntnu-xmlui/handle/11250/231326

Most F-function implementation details are found in the PhaseEoS class and the ComponentEoS class.

Alternative examples of adding a new EoS are:

  1. The sSAFT-EoS (system, phase, component)
  2. UMR-EoS (system, phase, component)

A new alpha term of the EoS is added as described in the following examples: https://github.com/equinor/neqsim/tree/master/src/main/java/neqsim/thermo/component/atractiveEosTerm

Mixing rules are implemented in the following classes: https://github.com/equinor/neqsim/tree/master/src/main/java/neqsim/thermo/mixingRule

Clone this wiki locally