Skip to content

Commit

Permalink
[Kinetics] Add phase accessor
Browse files Browse the repository at this point in the history
  • Loading branch information
ischoegl committed Jan 25, 2025
1 parent ee23e5a commit 56a41ed
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions include/cantera/kinetics/Kinetics.h
Original file line number Diff line number Diff line change
Expand Up @@ -217,6 +217,15 @@ class Kinetics
*/
shared_ptr<ThermoPhase> reactionPhase() const;

/**
* Return pointer to phase associated with Kinetics by index.
* @param n Index of the ThermoPhase being sought.
* @since New in %Cantera 3.2.
*/
shared_ptr<ThermoPhase> phase(size_t n=0) const {
return m_thermo[n];
}

/**
* This method returns a reference to the nth ThermoPhase object defined
* in this kinetics mechanism. It is typically used so that member
Expand Down

0 comments on commit 56a41ed

Please sign in to comment.