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

Provide a computational representation of the Partition of a chemical system. More...

#include <Partition.hpp>

Public Member Functions

 Partition ()
 Construct a default Partition instance.
 
 Partition (const ChemicalSystem &system)
 Construct a Partition instance. More...
 
auto setEquilibriumSpecies (const Indices &ispecies) -> void
 Set the equilibrium species of the chemical system.
 
auto setEquilibriumSpecies (const std::vector< std::string > &species) -> void
 Set the equilibrium species of the chemical system.
 
auto setEquilibriumPhases (const Indices &iphases) -> void
 Set the equilibrium species of the chemical system as the species in given phases.
 
auto setEquilibriumPhases (const std::vector< std::string > &phases) -> void
 Set the equilibrium species of the chemical system as the species in given phases.
 
auto setKineticSpecies (const Indices &species) -> void
 Set the kinetic species of the chemical system.
 
auto setKineticSpecies (const std::vector< std::string > &species) -> void
 Set the kinetic species of the chemical system.
 
auto setKineticPhases (const Indices &iphases) -> void
 Set the kinetic species of the chemical system as the species in given phases.
 
auto setKineticPhases (const std::vector< std::string > &phases) -> void
 Set the kinetic species of the chemical system as the species in given phases.
 
auto setInertSpecies (const Indices &species) -> void
 Set the inert species of the chemical system.
 
auto setInertSpecies (const std::vector< std::string > &species) -> void
 Set the inert species of the chemical system.
 
auto setInertPhases (const Indices &iphases) -> void
 Set the inert species of the chemical system as the species in given phases.
 
auto setInertPhases (const std::vector< std::string > &phases) -> void
 Set the inert species of the chemical system as the species in given phases.
 
auto setFluidPhases (const Indices &indices) -> void
 Set the fluid phases of the chemical system.
 
auto setFluidPhases (const std::vector< std::string > &names) -> void
 Set the fluid phases of the chemical system.
 
auto setSolidPhases (const Indices &indices) -> void
 Set the solid phases of the chemical system.
 
auto setSolidPhases (const std::vector< std::string > &names) -> void
 Set the solid phases of the chemical system.
 
auto system () const -> const ChemicalSystem &
 Return the chemical system.
 
auto numFluidPhases () const -> unsigned
 Return the number of phases in the fluid partition.
 
auto numFluidSpecies () const -> unsigned
 Return the number of species in the fluid partition.
 
auto numSolidPhases () const -> unsigned
 Return the number of phases in the solid partition.
 
auto numSolidSpecies () const -> unsigned
 Return the number of species in the solid partition.
 
auto numEquilibriumSpecies () const -> unsigned
 Return the number of species in the equilibrium partition.
 
auto numEquilibriumFluidSpecies () const -> unsigned
 Return the number of species in the equilibrium-fluid partition.
 
auto numEquilibriumSolidSpecies () const -> unsigned
 Return the number of species in the equilibrium-solid partition.
 
auto numKineticSpecies () const -> unsigned
 Return the number of species in the kinetic partition.
 
auto numKineticFluidSpecies () const -> unsigned
 Return the number of species in the kinetic-fluid partition.
 
auto numKineticSolidSpecies () const -> unsigned
 Return the number of species in the kinetic-solid partition.
 
auto numInertSpecies () const -> unsigned
 Return the number of species in the inert partition.
 
auto numInertFluidSpecies () const -> unsigned
 Return the number of species in the inert-fluid partition.
 
auto numInertSolidSpecies () const -> unsigned
 Return the number of species in the inert-solid partition.
 
auto numEquilibriumElements () const -> unsigned
 Return the number of elements in the equilibrium partition.
 
auto numEquilibriumFluidElements () const -> unsigned
 Return the number of elements in the equilibrium-fluid partition.
 
auto numEquilibriumSolidElements () const -> unsigned
 Return the number of elements in the equilibrium-solid partition.
 
auto numKineticElements () const -> unsigned
 Return the number of elements in the kinetic partition.
 
auto numKineticFluidElements () const -> unsigned
 Return the number of elements in the kinetic-fluid partition.
 
auto numKineticSolidElements () const -> unsigned
 Return the number of elements in the kinetic-solid partition.
 
auto numInertElements () const -> unsigned
 Return the number of elements in the inert partition.
 
auto numInertFluidElements () const -> unsigned
 Return the number of elements in the inert-fluid partition.
 
auto numInertSolidElements () const -> unsigned
 Return the number of elements in the inert-solid partition.
 
auto indicesFluidPhases () const -> const Indices &
 Return the indices of the phases in the fluid partition.
 
auto indicesFluidSpecies () const -> const Indices &
 Return the indices of the species in the fluid partition.
 
auto indicesSolidPhases () const -> const Indices &
 Return the indices of the phases in the solid partition.
 
auto indicesSolidSpecies () const -> const Indices &
 Return the indices of the species in the solid partition.
 
auto indicesEquilibriumSpecies () const -> const Indices &
 Return the indices of the species in the equilibrium partition.
 
auto indicesEquilibriumFluidSpecies () const -> const Indices &
 Return the indices of the species in the equilibrium-fluid partition.
 
auto indicesEquilibriumSolidSpecies () const -> const Indices &
 Return the indices of the species in the equilibrium-solid partition.
 
auto indicesKineticSpecies () const -> const Indices &
 Return the indices of the species in the kinetic partition.
 
auto indicesKineticFluidSpecies () const -> const Indices &
 Return the indices of the species in the kinetic-fluid partition.
 
auto indicesKineticSolidSpecies () const -> const Indices &
 Return the indices of the species in the kinetic-solid partition.
 
auto indicesInertSpecies () const -> const Indices &
 Return the indices of the species in the inert partition.
 
auto indicesInertFluidSpecies () const -> const Indices &
 Return the indices of the species in the inert-fluid partition.
 
auto indicesInertSolidSpecies () const -> const Indices &
 Return the indices of the species in the inert-solid partition.
 
auto indicesEquilibriumElements () const -> const Indices &
 Return the indices of the elements in the equilibrium partition.
 
auto indicesEquilibriumFluidElements () const -> const Indices &
 Return the indices of the elements in the equilibrium-fluid partition.
 
auto indicesEquilibriumSolidElements () const -> const Indices &
 Return the indices of the elements in the equilibrium-solid partition.
 
auto indicesKineticElements () const -> const Indices &
 Return the indices of the elements in the kinetic partition.
 
auto indicesKineticFluidElements () const -> const Indices &
 Return the indices of the elements in the kinetic-fluid partition.
 
auto indicesKineticSolidElements () const -> const Indices &
 Return the indices of the elements in the kinetic-solid partition.
 
auto indicesInertElements () const -> const Indices &
 Return the indices of the elements in the inert partition.
 
auto indicesInertFluidElements () const -> const Indices &
 Return the indices of the elements in the inert-fluid partition.
 
auto indicesInertSolidElements () const -> const Indices &
 Return the indices of the elements in the inert-solid partition.
 
auto formulaMatrixEquilibriumPartition () const -> MatrixConstRef
 Return the formula matrix of the equilibrium partition.
 
auto formulaMatrixEquilibriumFluidPartition () const -> MatrixConstRef
 Return the formula matrix of the equilibrium-fluid partition.
 
auto formulaMatrixEquilibriumSolidPartition () const -> MatrixConstRef
 Return the formula matrix of the equilibrium-solid partition.
 
auto formulaMatrixKineticPartition () const -> MatrixConstRef
 Return the formula matrix of the kinetic partition.
 
auto formulaMatrixKineticFluidPartition () const -> MatrixConstRef
 Return the formula matrix of the kinetic-fluid partition.
 
auto formulaMatrixKineticSolidPartition () const -> MatrixConstRef
 Return the formula matrix of the kinetic-solid partition.
 
auto formulaMatrixInertPartition () const -> MatrixConstRef
 Return the formula matrix of the inert partition.
 
auto formulaMatrixInertFluidPartition () const -> MatrixConstRef
 Return the formula matrix of the inert-fluid partition.
 
auto formulaMatrixInertSolidPartition () const -> MatrixConstRef
 Return the formula matrix of the inert-solid partition.
 

Detailed Description

Provide a computational representation of the Partition of a chemical system.

A chemical system can be partitioned into equilibrium, kinetic and inert species.

The equilibrium species are the species whose composition is governed by chemical equilibrium. In other words, their composition is calculated by the minimization of their Gibbs energy subject to some equilibrium constraints (e.g., mass-balance constraints).

The kinetic species are the species whose composition is governed by chemical kinetics. By solving a system of ordinary differential equations that model the kinetics of a system of reactions, the composition of the kinetic species can be traced with time. The composition of the equilibrium species with time is calculated with chemical equilibrium calculations with equilibrium constraints accounting for the kinetic variation of the molar abundance of the chemical elements in the equilibrium Partition.

The inert species are the species whose composition is invariable.

See also
ChemicalSystem

Constructor & Destructor Documentation

◆ Partition()

Partition ( const ChemicalSystem system)

Construct a Partition instance.

Parameters
systemThe chemical system instance
See also
ChemicalSystem

The documentation for this class was generated from the following files: