yaeos__equilibria_boundaries_phase_envelopes_px Module

Phase boundaries line on the plane calculation procedures.



Variables

Type Visibility Attributes Name Initial
real(kind=pr), private :: Vy

Incipient phase volume [L/mol]

real(kind=pr), private :: Vz

Main phase volume [L/mol]


Derived Types

type, public ::  CriticalPoint

Critical point

Components

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

Pressure [bar]

real(kind=pr), public :: alpha

type, public ::  PXEnvel2

Two-phase PX envelope. Phase boundary line of a fluid at constant temperature with variation in composition.

Components

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

Second fluid molar fraction

type(CriticalPoint), public, allocatable :: cps(:)

Critical points found along the line.

type(EquilibriumState), public, allocatable :: points(:)

Each point through the line.

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

Original fluid composition

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

Second fluid composition


Functions

public function px_envelope_2ph(model, z0, alpha0, z_injection, first_point, points, iterations, delta_0, specified_variable_0, solver, stop_conditions) result(envelopes)

PX two-phase envelope calculation procedure.

Read more…

Arguments

Type IntentOptional Attributes Name
class(ArModel), intent(in) :: model

Thermodyanmic model

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

Vector of molar fractions of the global composition (main phase)

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

First point of

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

Vector of molar fractions of the injection fluid

type(EquilibriumState) :: first_point
integer, intent(in), optional :: points

Maxmimum number of points, defaults to 500

integer, intent(in), optional :: iterations

Point solver maximum iterations, defaults to 100

real(kind=pr), intent(in), optional :: delta_0

Initial extrapolation

integer, intent(in), optional :: specified_variable_0

Position of specified variable, since the vector of variables is the values for specification will be for the equilibria constants, for and for .

procedure(continuation_solver), optional :: solver

Specify solver for each point, defaults to a full newton procedure

procedure(continuation_stopper), optional :: stop_conditions

Function that returns true if the continuation method should stop

Return Value type(PXEnvel2)


Subroutines

public subroutine get_z(alpha, z_0, z_inj, z, dzda)

Calculate the fluid composition based on an amount of addition of second fluid.

Read more…

Arguments

Type IntentOptional Attributes Name
real(kind=pr), intent(in) :: alpha

Addition percentaje

real(kind=pr), intent(in) :: z_0(:)
real(kind=pr), intent(in) :: z_inj(:)
real(kind=pr), intent(out) :: z(size(z_0))

New composition

real(kind=pr), intent(out), optional :: dzda(size(z_0))

Derivative wrt