|
chombo-discharge
|
Reaction type for advancing a KMCSingleState for Kinetic Monte Carlo. More...
#include <CD_KMCSingleStateReaction.H>
Public Member Functions | |
| KMCSingleStateReaction ()=default | |
| Disallowed constructor. Use the full constructor. | |
| KMCSingleStateReaction (const KMCSingleStateReaction &)=default | |
| Copy constructor (uses default). | |
| KMCSingleStateReaction (const std::list< size_t > &a_reactants, const std::list< size_t > &a_products) noexcept | |
| Full constructor, sets reactants and products. | |
| virtual | ~KMCSingleStateReaction () |
| Destructor. | |
| Real & | rate () const noexcept |
| Get modifiable reaction rate. | |
| Real | propensity (const State &a_state) const noexcept |
| Compute the propensity function for this reaction type. | |
| T | computeCriticalNumberOfReactions (const State &a_state) const noexcept |
| Compute the number of times the reaction can fire before exhausting one of the reactants. | |
| std::list< size_t > | getReactants () const noexcept |
| Get the reactants involved in the reaction. | |
| T | getStateChange (const size_t a_reactant) const noexcept |
| Get the state change due to a change in the input reactant species. | |
| void | advanceState (State &a_state, const T &a_numReactions) const noexcept |
| Advance the incoming state with the number of reactions. | |
Static Public Member Functions | |
| static T | population (const size_t &a_reactant, const State &a_state) noexcept |
| Get the population of the reactant in the input state. | |
Protected Member Functions | |
| void | computeStateChanges () noexcept |
| Compute state change. | |
Protected Attributes | |
| Real | m_rate |
| Reaction rate. | |
| Real | m_propensityFactor |
| Factor for the case where two or more particles of the same species react. | |
| std::list< size_t > | m_reactants |
| Reactants. | |
| std::list< size_t > | m_products |
| Products. | |
| std::map< size_t, T > | m_stateChange |
| State change for reactants/products. | |
Reaction type for advancing a KMCSingleState for Kinetic Monte Carlo.
|
inlinenoexcept |
Full constructor, sets reactants and products.
For a reaction X_0 -> X_0 + X_0 we have a_reactants = [0] and a_products [0,0]
| [in] | a_reactants | Species on the left-hand side of the reaction. |
| [in] | a_products | Species on the right-hand side of the reaction. |
|
inlinenoexcept |
Advance the incoming state with the number of reactions.
| [in] | a_state | State vector |
| [in] | a_numReactions | Number of reactions. |
|
inlinenoexcept |
Compute the number of times the reaction can fire before exhausting one of the reactants.
| [in] | a_state | State vector |
|
inlinenoexcept |
Get the reactants involved in the reaction.
|
inlinenoexcept |
Get the state change due to a change in the input reactant species.
| [in] | a_rectant | Reactant species. |
|
inlinestaticnoexcept |
Get the population of the reactant in the input state.
| [in] | a_reactant | Reactant |
| [in] | a_state | State |
|
inlinenoexcept |
Compute the propensity function for this reaction type.
| [in] | a_state | State vector |
|
inlinenoexcept |
Get modifiable reaction rate.
|
protected |
Factor for the case where two or more particles of the same species react.
For reactions X + X -> null the propensity is k * X * (X-1)/2 because there are X * (X-1)/2 unique pairs of particles in the cell.