Reaktoro
A unified framework for modeling chemically reactive systems
AqueousPhase Class Reference

A type used to describe an aqueous phase. More...

#include <AqueousPhase.hpp>

Inheritance diagram for AqueousPhase:
[legend]
Collaboration diagram for AqueousPhase:
[legend]

Public Member Functions

 AqueousPhase ()
 Construct a default AqueousPhase instance.
 
 AqueousPhase (const AqueousMixture &mixture)
 Construct an AqueousPhase instance with given aqueous mixture.
 
auto setInterpolationPoints (const std::vector< double > &temperatures, const std::vector< double > &pressures) -> AqueousPhase &
 Set the temperature and pressure interpolation points for calculation of water density and water dielectric constant. More...
 
auto setChemicalModelIdeal () -> AqueousPhase &
 Set the chemical model of the phase with the ideal aqueous solution equation of state.
 
auto setChemicalModelDebyeHuckel () -> AqueousPhase &
 Set the chemical model of the phase with the Debye-Huckel equation of state. More...
 
auto setChemicalModelDebyeHuckel (const DebyeHuckelParams &params) -> AqueousPhase &
 
auto setChemicalModelHKF () -> AqueousPhase &
 } More...
 
auto setChemicalModelPitzerHMW () -> AqueousPhase &
 Set the chemical model of the phase with the Pitzer equation of state. More...
 
auto setActivityModel (std::string species, const AqueousActivityModel &activity) -> AqueousPhase &
 Set the activity model of a species. More...
 
auto setActivityModelIdeal (std::string species) -> AqueousPhase &
 Set the activity model of the species to be the ideal one. More...
 
auto setActivityModelSetschenow (std::string species, double b) -> AqueousPhase &
 Set the activity model of the species to be the Setschenow one. More...
 
auto setActivityModelDuanSunCO2 () -> AqueousPhase &
 Set the activity model of CO2(aq) to be the one of Duan and Sun (2003).
 
auto setActivityModelDrummondCO2 () -> AqueousPhase &
 Set the activity model of CO2(aq) to be the one of Drummond (1981).
 
auto setActivityModelRumpfCO2 () -> AqueousPhase &
 Set the activity model of CO2(aq) to be the one of Rumpf et al. (1994).
 
auto mixture () const -> const AqueousMixture &
 Return the AqueousMixture instance.
 
- Public Member Functions inherited from Phase
 Phase ()
 Construct a default Phase instance.
 
 Phase (std::string name, PhaseType type)
 Construct a Phase instance with given fluid name and PhaseType.
 
auto setName (std::string name) -> void
 Set the name of the phase.
 
auto setType (PhaseType type) -> void
 Set the type of the phase.
 
auto setSpecies (const std::vector< Species > &species) -> void
 Set the species of the phase.
 
auto setThermoModel (const PhaseThermoModel &model) -> void
 Set the function that calculates the standard thermodynamic properties of the phase.
 
auto setChemicalModel (const PhaseChemicalModel &model) -> void
 Set the function that calculates the chemical properties of the phase.
 
auto numElements () const -> unsigned
 Return the number of elements in the phase.
 
auto numSpecies () const -> unsigned
 Return the number of species in the phase.
 
auto name () const -> std::string
 Return the name of the phase.
 
auto type () const -> PhaseType
 Return the type of the phase.
 
auto elements () const -> const std::vector< Element > &
 Return the elements of the phase.
 
auto elements () -> std::vector< Element > &
 Return the elements of the phase.
 
auto species () const -> const std::vector< Species > &
 Return the species of the phase.
 
auto species () -> std::vector< Species > &
 Return the species of the phase.
 
auto species (Index index) const -> const Species &
 Return the species of the phase with a given index.
 
auto isFluid () const -> bool
 Return true if the state of matter of the phase is fluid, i.e., liquid, gas, or plasma.
 
auto isSolid () const -> bool
 Return true if the phase type is solid.
 
auto thermoModel () const -> const PhaseThermoModel &
 Return the thermodynamic model function of the phase. More...
 
auto chemicalModel () const -> const PhaseChemicalModel &
 Return the chemical model function of the phase. More...
 
auto indexSpecies (std::string name) const -> Index
 Return the index of a species in the phase. More...
 
auto indexSpeciesWithError (std::string name) const -> Index
 Return the index of a species in the system. More...
 
auto indexSpeciesAny (const std::vector< std::string > &names) const -> Index
 Return the index of the first species in the phase with any of the given names. More...
 
auto indexSpeciesAnyWithError (const std::vector< std::string > &names) const -> Index
 Return the index of the first species in the phase with any of the given names. More...
 
auto properties (PhaseThermoModelResult &res, double T, double P) const -> void
 Calculate the standard thermodynamic properties of the species in the phase. More...
 
auto properties (PhaseChemicalModelResult &res, double T, double P, VectorConstRef n) const -> void
 Calculate the thermodynamic and chemical properties of the chemical system. More...
 

Detailed Description

A type used to describe an aqueous phase.

Member Function Documentation

◆ setInterpolationPoints()

auto setInterpolationPoints ( const std::vector< double > &  temperatures,
const std::vector< double > &  pressures 
) -> AqueousPhase&

Set the temperature and pressure interpolation points for calculation of water density and water dielectric constant.

Use this method if temperature-pressure interpolation should be used for the calculation of water density and water dielectric constant. This should be done if the cost of the analytical calculation of these properties is prohibitive for your application.

Parameters
temperaturesThe temperature points (in units of K)
pressuresThe pressure points (in units of Pa)

◆ setChemicalModelDebyeHuckel()

auto setChemicalModelDebyeHuckel ( ) -> AqueousPhase&

Set the chemical model of the phase with the Debye-Huckel equation of state.

{

◆ setChemicalModelHKF()

auto setChemicalModelHKF ( ) -> AqueousPhase&

}

Set the chemical model of the phase with the HKF equation of state.

◆ setChemicalModelPitzerHMW()

auto setChemicalModelPitzerHMW ( ) -> AqueousPhase&

Set the chemical model of the phase with the Pitzer equation of state.

Uses the Pitzer equation of state described in: Harvie, C.E., Møller, N., Weare, J.H. (1984). The prediction of mineral solubilities in natural waters: The Na-K-Mg-Ca-H-Cl-SO4-OH-HCO3-CO3-CO2-H2O system to high ionic strengths at 25°C. Geochimica et Cosmochimica Acta, 48(4), 723–751.

◆ setActivityModel()

auto setActivityModel ( std::string  species,
const AqueousActivityModel activity 
) -> AqueousPhase&

Set the activity model of a species.

Parameters
speciesThe name of the species
activityThe activity function
See also
AqueousActivityModel

◆ setActivityModelIdeal()

auto setActivityModelIdeal ( std::string  species) -> AqueousPhase&

Set the activity model of the species to be the ideal one.

Parameters
speciesThe name of species to have its activity model set

◆ setActivityModelSetschenow()

auto setActivityModelSetschenow ( std::string  species,
double  b 
) -> AqueousPhase&

Set the activity model of the species to be the Setschenow one.

Parameters
speciesThe name of species to have its activity model set
bThe Setschenow constant

The documentation for this class was generated from the following files:
  • Reaktoro/Thermodynamics/Phases/AqueousPhase.hpp
  • Reaktoro/Thermodynamics/Phases/AqueousPhase.cpp