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

## Detailed Description

A class that represents a solver for chemical kinetics problems.

KineticProblem

#include <KineticSolver.hpp>

## Public Member Functions

KineticSolver ()
Construct a default KineticSolver instance.

KineticSolver (const ReactionSystem &reactions)
Construct a KineticSolver instance.

KineticSolver (const KineticSolver &other)
Construct a copy of a KineticSolver instance.

virtual ~KineticSolver ()
Destroy the KineticSolver instance.

auto operator= (KineticSolver other) -> KineticSolver &
Assign a KineticSolver instance to this instance.

auto setOptions (const KineticOptions &options) -> void
Set the options for the chemical kinetics calculation.

auto setPartition (const Partition &partition) -> void
Set the partition of the chemical system. More...

auto addSource (const ChemicalState &state, double volumerate, std::string units) -> void
Add a source to the chemical kinetics problem. More...

auto addPhaseSink (std::string phase, double volumerate, std::string units) -> void
Add a phase sink to the chemical kinetics problem. More...

auto addFluidSink (double volumerate, std::string units) -> void
Add a fluid sink to the chemical kinetics problem. More...

auto addSolidSink (double volumerate, std::string units) -> void
Add a solid sink to the chemical kinetics problem. More...

auto initialize (ChemicalState &state, double tstart) -> void
Initialize the chemical kinetics solver before . More...

auto step (ChemicalState &state, double &t) -> void
Integrate one step of the chemical kinetics problem. More...

auto step (ChemicalState &state, double &t, double tfinal) -> void
Integrate one step of the chemical kinetics problem with a time step that does not go beyond a specified one. More...

auto solve (ChemicalState &state, double t, double dt) -> void
Solve the chemical kinetics problem from a given initial time to a final time. More...

## Member Function Documentation

 auto Reaktoro::KineticSolver::setPartition ( const Partition & partition ) -> void

Set the partition of the chemical system.

Use this method to specify the equilibrium, kinetic, and inert species.

 auto Reaktoro::KineticSolver::addSource ( const ChemicalState & state, double volumerate, std::string units ) -> void

Add a source to the chemical kinetics problem.

Parameters
 state The chemical state representing the source. volumerate The volumetric rate of the source. units The units of the volumetric rate (compatible with m3/s).
 auto Reaktoro::KineticSolver::addPhaseSink ( std::string phase, double volumerate, std::string units ) -> void

Add a phase sink to the chemical kinetics problem.

This method allows the chemical kinetics problem to account for the sink (i.e., the removal) of a phase from the system.

Parameters
 phase The name of the phase. volumerate The volumetric rate of the phase removal. units The units of the volumetric rate (compatible with m3/s).
 auto Reaktoro::KineticSolver::addFluidSink ( double volumerate, std::string units ) -> void

Add a fluid sink to the chemical kinetics problem.

This method allows the chemical kinetics problem to account for the sink (i.e., the removal) of fluid from the system.

Parameters
 volumerate The volumetric rate of the fluid removal. units The units of the volumetric rate (compatible with m3/s).
 auto Reaktoro::KineticSolver::addSolidSink ( double volumerate, std::string units ) -> void

Add a solid sink to the chemical kinetics problem.

This method allows the chemical kinetics problem to account for the sink (i.e., the removal) of solid from the system.

Parameters
 volumerate The volumetric rate of the solid removal. units The units of the volumetric rate (compatible with m3/s).
 auto Reaktoro::KineticSolver::initialize ( ChemicalState & state, double tstart ) -> void

Initialize the chemical kinetics solver before .

This method should be invoked whenever the user intends to make a call to KineticsSolver::step.

Parameters
 state The state of the chemical system tstart The start time of the integration.
 auto Reaktoro::KineticSolver::step ( ChemicalState & state, double & t ) -> void

Integrate one step of the chemical kinetics problem.

Parameters
 state The kinetic state of the system [in,out] t The current time of the integration, updated after the calculation (in units of seconds)
 auto Reaktoro::KineticSolver::step ( ChemicalState & state, double & t, double tfinal ) -> void

Integrate one step of the chemical kinetics problem with a time step that does not go beyond a specified one.

Parameters
 state The kinetic state of the system [in,out] t The current time of the integration, updated after the calculation (in units of seconds) tfinal The final time of the integration (in units of seconds)
 auto Reaktoro::KineticSolver::solve ( ChemicalState & state, double t, double dt ) -> void

Solve the chemical kinetics problem from a given initial time to a final time.

Parameters
 state The kinetic state of the system t The start time of the integration (in units of seconds) dt The step to be used for the integration from t to t + dt (in units of seconds)

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