Reaktoro  v2.1.1
A unified framework for modeling chemically reactive systems
ControlVariableQ Struct Reference

Used to define a q control variable in a chemical equilibrium problem. More...

#include <EquilibriumSpecs.hpp>

Collaboration diagram for ControlVariableQ:
[legend]

Public Types

using ChemicalPotentialFn = Fn< real(ChemicalProps const &props, VectorXrConstRef const &p, VectorXrConstRef const &w)>
 The signature of functions that evaluate the prescribed chemical potential of a substance. More...
 

Public Attributes

String name
 The unique name for this q control variable (required).
 
ChemicalFormula substance
 The chemical formula of the substance associated to this q control variable (required).
 
String id
 The unique identifier for the chemical potential constraint associated to this q control variable (required).
 
ChemicalPotentialFn fn
 The chemical potential function associated to this q control variable (required).
 

Detailed Description

Used to define a q control variable in a chemical equilibrium problem.

q control variables are used to specify the chemical potential of a species at equilibrium. Its introduction in a chemical equilibrium problem implies that the system is open to a titrant with same formula of the species whose chemical potential needs to be prescribed. A q control variable can also be used to specify the activity of a species. It can also be used to prescribe pH. This can be achieved by converting the given activity value (or pH value) to a chemical potential value of the species.

Member Typedef Documentation

◆ ChemicalPotentialFn

using ChemicalPotentialFn = Fn<real(ChemicalProps const& props, VectorXrConstRef const& p, VectorXrConstRef const& w)>

The signature of functions that evaluate the prescribed chemical potential of a substance.

Parameters
propsThe current chemical properties of the system in the equilibrium calculation.
pThe control variables p in the chemical equilibrium calculation.
wThe input variables w in the chemical equilibrium calculation.

The documentation for this struct was generated from the following file: