NRTLHV Derived Type

type, public, extends(GeModel) :: NRTLHV

NRTLHV

Huron-Vidal modification of the NRTL model for excess Gibbs energy.

Description

Huron-Vidal modified the NRTL model, including the covolume parameter into the model. This helps when running the model coupled with a cubic equation of state, because it can be reduced to the classical quadratic mixing rules when its parameters are defined accordingly.

It uses the temperature function:

There is no custom constructor; use the default structure constructor. Energy parameters must be in the units of (R in bar L / (mol K)).

Examples

ge = NRTLHV(b=b, alpha=alpha, gji0=gji0, gjiT=gjiT)

References

Huron, M.-J., and J. Vidal (1979). Fluid Phase Equilibria, 3, 255-271.


Inherits

type~~nrtlhv~~InheritsGraph type~nrtlhv NRTLHV type~gemodel GeModel type~nrtlhv->type~gemodel type~basemodel BaseModel type~gemodel->type~basemodel type~substances Substances type~basemodel->type~substances components

Inherited by

type~~nrtlhv~~InheritedByGraph type~nrtlhv NRTLHV type~hv_nrtl HV_NRTL type~hv_nrtl->type~nrtlhv ge

Components

Type Visibility Attributes Name Initial
real(kind=pr), public, allocatable :: alpha(:,:)

matrix

real(kind=pr), public, allocatable :: b(:)

Covolume parameter

type(Substances), public :: components

Pure-component properties for the model’s component order.

real(kind=pr), public, allocatable :: gji0(:,:)

matrix

real(kind=pr), public, allocatable :: gjiT(:,:)

matrix


Type-Bound Procedures

procedure, public :: excess_Cp

  • public subroutine excess_Cp(self, n, T, Cpe)

    Calculate Excess heat capacity.

    Read more…

    Arguments

    Type IntentOptional Attributes Name
    class(GeModel), intent(in) :: self

    Model

    real(kind=pr), intent(in) :: n(:)

    Moles vector

    real(kind=pr), intent(in) :: T

    Temperature [K]

    real(kind=pr), intent(out) :: Cpe

    Excess heat capacity [bar L / K]

procedure, public :: excess_enthalpy

  • public subroutine excess_enthalpy(self, n, T, He, HeT, Hen)

    Calculate Excess enthalpy and its derivatives.

    Read more…

    Arguments

    Type IntentOptional Attributes Name
    class(GeModel), intent(in) :: self

    Model

    real(kind=pr), intent(in) :: n(:)

    Moles vector

    real(kind=pr), intent(in) :: T

    Temperature [K]

    real(kind=pr), intent(out), optional :: He

    Excess enthalpy

    real(kind=pr), intent(out), optional :: HeT

    real(kind=pr), intent(out), optional :: Hen(:)

procedure, public :: excess_entropy

  • public subroutine excess_entropy(self, n, T, Se, SeT, Sen)

    Calculate Excess entropy and its derivatives.

    Read more…

    Arguments

    Type IntentOptional Attributes Name
    class(GeModel), intent(in) :: self

    Model

    real(kind=pr), intent(in) :: n(:)

    Moles vector

    real(kind=pr), intent(in) :: T

    Temperature [K]

    real(kind=pr), intent(out), optional :: Se

    Excess entropy

    real(kind=pr), intent(out), optional :: SeT

    real(kind=pr), intent(out), optional :: Sen(:)

procedure, public :: excess_gibbs

  • public subroutine excess_gibbs(self, n, T, Ge, GeT, GeT2, Gen, GeTn, Gen2)

    Calculate Excess Gibbs and its derivatives.

    Arguments

    Type IntentOptional Attributes Name
    class(NRTLHV), intent(in) :: self

    Model

    real(kind=pr), intent(in) :: n(:)

    Moles vector

    real(kind=pr), intent(in) :: T

    Temperature [K]

    real(kind=pr), intent(out), optional :: Ge

    Excess Gibbs free energy

    real(kind=pr), intent(out), optional :: GeT

    real(kind=pr), intent(out), optional :: GeT2

    real(kind=pr), intent(out), optional :: Gen(size(n))

    real(kind=pr), intent(out), optional :: GeTn(size(n))

    Mixed temperature-mole-number derivative.

    real(kind=pr), intent(out), optional :: Gen2(size(n),size(n))

    Hessian with respect to mole amounts.

procedure, public :: ln_activity_coefficient

  • public subroutine ln_activity_coefficient(self, n, T, lngamma, dlngammadT, dlngammadn)

    Calculate natural logarithm of activity coefficients.

    Read more…

    Arguments

    Type IntentOptional Attributes Name
    class(GeModel), intent(in) :: self

    Model

    real(kind=pr), intent(in) :: n(:)

    Moles vector

    real(kind=pr), intent(in) :: T

    Temperature [K]

    real(kind=pr), intent(out), optional :: lngamma(:)

    Natural logarithm of activity coefficients

    real(kind=pr), intent(out), optional :: dlngammadT(size(n))

    real(kind=pr), intent(out), optional :: dlngammadn(size(n),size(n))