Reaktoro  A unified framework for modeling chemically reactive systems
Reaktoro::MineralReaction Class Reference

## Public Member Functions

MineralReaction ()
Construct a default MineralReaction instance.

MineralReaction (std::string mineral)
Construct a MineralReaction instance with the mineral name.

auto setMineral (std::string mineral) -> MineralReaction &
Set the name of the mineral species in the reaction.

auto setEquation (const ReactionEquation &equation) -> MineralReaction &
Set the equation of the mineral reaction. More...

auto setEquation (std::string equation) -> MineralReaction &
Set the equation of the mineral reaction. More...

auto setEquilibriumConstant (const ThermoScalarFunction &lnk) -> MineralReaction &
Set the equilibrium constant of the mineral reaction (in natural log scale). More...

auto setSpecificSurfaceArea (double value, std::string unit) -> MineralReaction &
Set the specific surface area of the mineral. More...

auto addMechanism (std::string mechanism) -> MineralReaction &
Adds a mineral mechanism to the kinetic rate model of the mineral reaction. More...

auto addMechanism (const MineralMechanism &mechanism) -> MineralReaction &
Adds a mineral mechanism to the kinetic rate model of the mineral reaction. More...

auto setMechanisms (const std::vector< MineralMechanism > &mechanisms) -> MineralReaction &
Set the mineral mechanisms of the kinetic rate model of the mineral reaction. More...

auto mineral () const -> std::string
Return the name of the mineral species in the reaction.

auto equation () const -> const ReactionEquation &
Return the equation of the mineral reaction as a string. More...

auto equilibriumConstant () const -> const ThermoScalarFunction &
Return the equilibrium constant of the mineral reaction.

auto specificSurfaceArea () const -> double
Return the specific surface area of the mineral (in units of m2/kg).

auto volumetricSurfaceArea () const -> double
Return the volumetric surface area of the mineral (in units of m2/m3).

auto mechanisms () const -> const std::vector< MineralMechanism > &
Return the mineral mechanisms of the kinetic rate model of the mineral reaction. More...

## Member Function Documentation

 auto Reaktoro::MineralReaction::setEquation ( const ReactionEquation & equation ) -> MineralReaction&

Set the equation of the mineral reaction.

ReactionEquation
 auto Reaktoro::MineralReaction::setEquation ( std::string equation ) -> MineralReaction&

Set the equation of the mineral reaction.

The format of equation can be found in ReactionEquation.

Parameters
 equation The string defining the reaction equation
ReactionEquation
 auto Reaktoro::MineralReaction::setEquilibriumConstant ( const ThermoScalarFunction & lnk ) -> MineralReaction&

Set the equilibrium constant of the mineral reaction (in natural log scale).

If no equilibrium contant is provided, it will be calculated from the standard Gibbs energies of the species in the reaction.

 auto Reaktoro::MineralReaction::setSpecificSurfaceArea ( double value, std::string unit ) -> MineralReaction&

Set the specific surface area of the mineral.

The specific surface area of the mineral can be set using units that are convertible to either m2/g or m2/m3. Whichever unit is used, the specified specific surface area will be automatically converted to a molar surface area with units of m2/mol.

Parameters
 value The value of the specific surface area unit The units of the specific surface area (must be convertible to either m2/g or m2/m3)
 auto Reaktoro::MineralReaction::addMechanism ( std::string mechanism ) -> MineralReaction&

Adds a mineral mechanism to the kinetic rate model of the mineral reaction.

MineralMechanism
 auto Reaktoro::MineralReaction::addMechanism ( const MineralMechanism & mechanism ) -> MineralReaction&

Adds a mineral mechanism to the kinetic rate model of the mineral reaction.

Parameters
 mechanism The mechanism to be considered in the kinetic rate model
MineralMechanism
 auto Reaktoro::MineralReaction::setMechanisms ( const std::vector< MineralMechanism > & mechanisms ) -> MineralReaction&

Set the mineral mechanisms of the kinetic rate model of the mineral reaction.

Parameters
 mechanisms The mechanisms of the kinetic rate model
MineralMechanism
 auto Reaktoro::MineralReaction::equation ( ) const -> const ReactionEquation&

Return the equation of the mineral reaction as a string.