Consistency checks of Helmholtz free energy models (ArModel).
This module contains tools to validate the analityc derivatives of implmented Helmholtz free energy models (ArModel). Also, allows to evaluate the consistency tests described in Thermodynamic Models: Fundamentals & Computational Aspects 2 ed. by Michelsen and Mollerup Chapter 2 section 3.
Available tools:
numeric_ar_derivatives: From an instantiated ArModel evaluate all the Helmholtz free energy derivatives from the central finite difference method.
ar_consistency: From an instantiated ArModel evaluate all the Michelsen and Mollerup consistency tests.
models consistency tests.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(ArModel), | intent(in) | :: | eos |
Equation of state |
||
real(kind=pr), | intent(in) | :: | n(:) |
Moles number vector |
||
real(kind=pr), | intent(in) | :: | V |
Volume [L] |
||
real(kind=pr), | intent(in) | :: | T |
Temperature [K] |
||
real(kind=pr), | intent(out), | optional | :: | eq31 |
MM Eq. 31 |
|
real(kind=pr), | intent(out), | optional | :: | eq33(size(n),size(n)) |
MM Eq. 33 |
|
real(kind=pr), | intent(out), | optional | :: | eq34(size(n)) |
MM Eq. 34 |
|
real(kind=pr), | intent(out), | optional | :: | eq36 |
MM Eq. 36 |
|
real(kind=pr), | intent(out), | optional | :: | eq37 |
MM Eq. 37 |
Evaluate the Helmholtz derivatives with central finite difference.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(ArModel), | intent(in) | :: | eos |
Equation of state |
||
real(kind=pr), | intent(in) | :: | n(:) |
Moles number vector |
||
real(kind=pr), | intent(in) | :: | V |
Volume [L] |
||
real(kind=pr), | intent(in) | :: | T |
Temperature [K] |
||
real(kind=pr), | intent(in) | :: | d_n |
Moles finite difference step |
||
real(kind=pr), | intent(in) | :: | d_v |
Volume finite difference step |
||
real(kind=pr), | intent(in) | :: | d_t |
Temperature finite difference step |
||
real(kind=pr), | intent(out) | :: | Ar |
Residual Helmoltz energy |
||
real(kind=pr), | intent(out), | optional | :: | ArV |
|
|
real(kind=pr), | intent(out), | optional | :: | ArT |
|
|
real(kind=pr), | intent(out), | optional | :: | Arn(size(n)) |
|
|
real(kind=pr), | intent(out), | optional | :: | ArV2 |
|
|
real(kind=pr), | intent(out), | optional | :: | ArT2 |
|
|
real(kind=pr), | intent(out), | optional | :: | ArTV |
|
|
real(kind=pr), | intent(out), | optional | :: | ArVn(size(n)) |
|
|
real(kind=pr), | intent(out), | optional | :: | ArTn(size(n)) |
|
|
real(kind=pr), | intent(out), | optional | :: | Arn2(size(n),size(n)) |
|