Nodes of different colours represent the following:
Solid arrows point from a submodule to the (sub)module which it is
descended from. Dashed arrows point from a module or program unit to
modules which it uses.
Cubic EoS volume solver
Volume solver optimized for Cubic Equations of State.
@warn
This routine intends to use the analyitical solution of the cubic
equation, but due to errors in the solutions it is not used. And
the general volume solver by Michelsen is used instead.
@endwarn
Description
Cubic equations can be analytically solved. Using an anallytical
solution provides the best possible solution in terms of speed and
precision. This subroutine uses the modified cardano method proposed
by Rosendo.
Examples
use yaeos,only:CubicEoS,PengRobinsontype(CubicEoS)::eoseos=PengRobinson(tc,pc,w)! Possible roots to solvecall eos%volume(n,P,T,V,"liquid")call eos%volume(n,P,T,V,"vapor")call eos%volume(n,P,T,V,"stable")
References
[1] “Thermodynamic Models: Fundamental and Computational Aspects”,
Michael L. Michelsen, Jørgen M. Mollerup.
Tie-Line Publications, Denmark (2004)
doi
[2] “A Note on the Analytical Solution of Cubic Equations of State
in Process Simulation”, Rosendo Monroy-Loperena
doi
Nodes of different colours represent the following:
Solid arrows point from a procedure to one which it calls. Dashed
arrows point from an interface to procedures which implement that interface.
This could include the module procedures in a generic interface or the
implementation in a submodule of an interface in a parent module.
Nodes of different colours represent the following:
Solid arrows point from a procedure to one which it calls. Dashed
arrows point from an interface to procedures which implement that interface.
This could include the module procedures in a generic interface or the
implementation in a submodule of an interface in a parent module.