TQCEG

Fortran

TQCEG(IWSG, IWSE)

C-interface

tq_ceg(TC_INT* iwsg,TC_INT* iwse);

Full name:

Calculate Equilibrium Global.

Purpose:

Calculate Equilibrium using Global Minimization Algorithm.

Comments:

The use of global minimization algorithm is meant to avoid metastable or unstable equilibrium and to obtain truly stable equilibrium. This is mainly due to its ability to find automatically miscibility gap and create accordingly new composition sets. As a consequence, the number of phases may increase after calling TQCEG. The newly added phases (new composition sets of old phases) are always put in the end of the phase list. In this way, the indexes of old phases remain the same as before

See Example 13.

The global minimization technique starts with discretizing the composition space and calculating Gibbs energy values at each grid point for each phase at a given temperature. This usually leads to a significant increase of computation time. Therefore, it is not recommended to use TQCEG in time-critical application programs. In the cases where phases involved are well known, for example, identifying the local equilibrium at a phase interface, it is absolutely not necessary to use TQCEG. If TQCEG is needed, irrelevant phases should better be rejected in the beginning when fetching thermodynamic data from a database.

Arguments

Name

Type

Value set on call or returned

IWSG

Integer array

Workspace

IWSE

Integer array

Workspace