teqp 0.22.0
Loading...
Searching...
No Matches
teqp::VLLE Namespace Reference

Classes

struct  SelfIntersectionSolution
 
struct  VLLEFinderOptions
 
struct  VLLETracerOptions
 

Enumerations

enum class  VLLE_return_code { unset , xtol_satisfied , functol_satisfied , maxiter_met }
 

Functions

auto mix_VLLE_T (const AbstractModel &model, double T, const EArrayd &rhovecVinit, const EArrayd &rhovecL1init, const EArrayd &rhovecL2init, double atol, double reltol, double axtol, double relxtol, int maxiter)
 
auto mix_VLLE_p (const AbstractModel &model, double p, double Tinit, const EArrayd &rhovecVinit, const EArrayd &rhovecL1init, const EArrayd &rhovecL2init, double atol, double reltol, double axtol, double relxtol, int maxiter)
 
template<typename Iterable >
auto get_self_intersections (Iterable &x, Iterable &y)
 
template<typename Iterable >
auto get_cross_intersections (Iterable &x1, Iterable &y1, Iterable &x2, Iterable &y2)
 
auto find_VLLE_gen_binary (const AbstractModel &model, const std::vector< nlohmann::json > &traces, const std::string &key, const std::optional< VLLEFinderOptions > options=std::nullopt)
 
auto find_VLLE_T_binary (const AbstractModel &model, const std::vector< nlohmann::json > &traces, const std::optional< VLLEFinderOptions > &options=std::nullopt)
 Given an isothermal VLE trace(s) for a binary mixture, obtain the VLLE solution.
 
auto find_VLLE_p_binary (const AbstractModel &model, const std::vector< nlohmann::json > &traces, const std::optional< VLLEFinderOptions > &options=std::nullopt)
 Given an isobaric VLE trace(s) for a binary mixture, obtain the VLLE solution.
 
auto get_drhovecdT_VLLE_binary (const AbstractModel &model, double T, const EArrayd &rhovecV, const EArrayd &rhovecL1, const EArrayd &rhovecL2)
 
auto trace_VLLE_binary (const teqp::VLLE::AbstractModel &model, const double Tinit, const EArrayd &rhovecVinit, const EArrayd &rhovecL1init, const EArrayd &rhovecL2init, const std::optional< VLLETracerOptions > &options_=std::nullopt)
 Given an initial VLLE solution, trace the VLLE curve. We know the VLLE curve is a function of only one state variable by Gibbs' rule.
 

Enumeration Type Documentation

◆ VLLE_return_code

enum class teqp::VLLE::VLLE_return_code
strong
Enumerator
unset 
xtol_satisfied 
functol_satisfied 
maxiter_met 

Definition at line 6 of file VLLE_types.hpp.

Function Documentation

◆ find_VLLE_gen_binary()

auto teqp::VLLE::find_VLLE_gen_binary ( const AbstractModel & model,
const std::vector< nlohmann::json > & traces,
const std::string & key,
const std::optional< VLLEFinderOptions > options = std::nullopt )
inline

Definition at line 300 of file VLLE.hpp.

◆ find_VLLE_p_binary()

auto teqp::VLLE::find_VLLE_p_binary ( const AbstractModel & model,
const std::vector< nlohmann::json > & traces,
const std::optional< VLLEFinderOptions > & options = std::nullopt )
inline

Given an isobaric VLE trace(s) for a binary mixture, obtain the VLLE solution.

Parameters
modelThe Model to be used for the thermodynamics
tracesThe nlohmann::json formatted information from the traces, perhaps obtained from trace_VLE_isobar_binary

Definition at line 477 of file VLLE.hpp.

◆ find_VLLE_T_binary()

auto teqp::VLLE::find_VLLE_T_binary ( const AbstractModel & model,
const std::vector< nlohmann::json > & traces,
const std::optional< VLLEFinderOptions > & options = std::nullopt )
inline

Given an isothermal VLE trace(s) for a binary mixture, obtain the VLLE solution.

Parameters
modelThe Model to be used for the thermodynamics
tracesThe nlohmann::json formatted information from the traces, perhaps obtained from trace_VLE_isotherm_binary

Definition at line 468 of file VLLE.hpp.

◆ get_cross_intersections()

template<typename Iterable >
auto teqp::VLLE::get_cross_intersections ( Iterable & x1,
Iterable & y1,
Iterable & x2,
Iterable & y2 )
inline

Definition at line 277 of file VLLE.hpp.

◆ get_drhovecdT_VLLE_binary()

auto teqp::VLLE::get_drhovecdT_VLLE_binary ( const AbstractModel & model,
double T,
const EArrayd & rhovecV,
const EArrayd & rhovecL1,
const EArrayd & rhovecL2 )
inline

Definition at line 481 of file VLLE.hpp.

◆ get_self_intersections()

template<typename Iterable >
auto teqp::VLLE::get_self_intersections ( Iterable & x,
Iterable & y )
inline

Derived from https://stackoverflow.com/a/17931809

Definition at line 255 of file VLLE.hpp.

◆ mix_VLLE_p()

auto teqp::VLLE::mix_VLLE_p ( const AbstractModel & model,
double p,
double Tinit,
const EArrayd & rhovecVinit,
const EArrayd & rhovecL1init,
const EArrayd & rhovecL2init,
double atol,
double reltol,
double axtol,
double relxtol,
int maxiter )
inline

Definition at line 134 of file VLLE.hpp.

◆ mix_VLLE_T()

auto teqp::VLLE::mix_VLLE_T ( const AbstractModel & model,
double T,
const EArrayd & rhovecVinit,
const EArrayd & rhovecL1init,
const EArrayd & rhovecL2init,
double atol,
double reltol,
double axtol,
double relxtol,
int maxiter )
inline

Definition at line 30 of file VLLE.hpp.

◆ trace_VLLE_binary()

auto teqp::VLLE::trace_VLLE_binary ( const teqp::VLLE::AbstractModel & model,
const double Tinit,
const EArrayd & rhovecVinit,
const EArrayd & rhovecL1init,
const EArrayd & rhovecL2init,
const std::optional< VLLETracerOptions > & options_ = std::nullopt )
inline

Given an initial VLLE solution, trace the VLLE curve. We know the VLLE curve is a function of only one state variable by Gibbs' rule.

Definition at line 519 of file VLLE.hpp.