26 #ifndef GRINS_CANTERA_MIXTURE_H
27 #define GRINS_CANTERA_MIXTURE_H
29 #include "grins_config.h"
31 #ifdef GRINS_HAVE_CANTERA
34 #include "libmesh/threads.h"
37 #include "libmesh/ignore_warnings.h"
38 #include "cantera/IdealGasMix.h"
39 #include "cantera/transport.h"
40 #include "libmesh/restore_warnings.h"
43 #include "libmesh/auto_ptr.h"
53 static libMesh::Threads::spin_mutex cantera_mutex;
69 CanteraMixture(
const GetPot& input,
const std::string& material );
77 libMesh::Real
M(
unsigned int species )
const;
79 libMesh::Real
M_mix(
const std::vector<libMesh::Real>& mass_fractions )
const;
81 libMesh::Real
R(
unsigned int species )
const;
83 libMesh::Real
R_mix(
const std::vector<libMesh::Real>& mass_fractions )
const;
85 libMesh::Real
X(
unsigned int species, libMesh::Real M, libMesh::Real mass_fraction )
const;
87 void X( libMesh::Real M,
const std::vector<libMesh::Real>& mass_fractions,
88 std::vector<libMesh::Real>& mole_fractions )
const;
94 std::string
species_name(
unsigned int species_index )
const;
107 std::string
parse_mixture(
const GetPot& input,
const std::string& material );
146 return Cantera::GasConstant/
_cantera_gas->molecularWeight(species);
152 libMesh::Real mass_fraction )
const
154 return mass_fraction*M_mix/this->
M(species);
183 #endif // GRINS_HAVE_CANTERA
185 #endif // GRINS_CANTERA_MIXTURE_H
libMesh::UniquePtr< Cantera::Transport > _cantera_transport
libMesh::Real R(unsigned int species) const
libMesh::Real X(unsigned int species, libMesh::Real M, libMesh::Real mass_fraction) const
libMesh::UniquePtr< Cantera::IdealGasMix > _cantera_gas
std::string species_name(unsigned int species_index) const
unsigned int species_index(const std::string &species_name) const
unsigned int n_species() const
libMesh::Real M_mix(const std::vector< libMesh::Real > &mass_fractions) const
libMesh::Real R_mix(const std::vector< libMesh::Real > &mass_fractions) const
ParameterUser base class. Utility methods for subclasses.
Cantera::IdealGasMix & get_chemistry()
Wrapper class for storing state for computing thermochemistry and transport properties using Cantera...
CanteraMixture ChemistryParent
This is basically dummy, but is needed for template games elsewhere.
Cantera::Transport & get_transport()
const CanteraMixture & chemistry() const
libMesh::Real M(unsigned int species) const
std::string parse_mixture(const GetPot &input, const std::string &material)