GRINS-0.7.0
species_mass_fracs_fe_variables.h
Go to the documentation of this file.
1 //-----------------------------------------------------------------------bl-
2 //--------------------------------------------------------------------------
3 //
4 // GRINS - General Reacting Incompressible Navier-Stokes
5 //
6 // Copyright (C) 2014-2016 Paul T. Bauman, Roy H. Stogner
7 // Copyright (C) 2010-2013 The PECOS Development Team
8 //
9 // This library is free software; you can redistribute it and/or
10 // modify it under the terms of the Version 2.1 GNU Lesser General
11 // Public License as published by the Free Software Foundation.
12 //
13 // This library is distributed in the hope that it will be useful,
14 // but WITHOUT ANY WARRANTY; without even the implied warranty of
15 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 // Lesser General Public License for more details.
17 //
18 // You should have received a copy of the GNU Lesser General Public
19 // License along with this library; if not, write to the Free Software
20 // Foundation, Inc. 51 Franklin Street, Fifth Floor,
21 // Boston, MA 02110-1301 USA
22 //
23 //-----------------------------------------------------------------------el-
24 
25 
26 #ifndef GRINS_SPECIES_MASS_FRACS_FE_VARIABLES_H
27 #define GRINS_SPECIES_MASS_FRACS_FE_VARIABLES_H
28 
29 // GRINS
32 
33 namespace GRINS
34 {
35 
37  {
38  public:
39 
40  SpeciesMassFractionsFEVariables( const GetPot& input, const std::string& physics_name,
41  bool _is_constraint_var = false);
42 
44 
45  unsigned int n_species() const;
46 
47  VariableIndex species( unsigned int species ) const;
48 
49  const std::string& material() const
50  { return _material; }
51 
52  const std::string& prefix() const
53  { return _prefix; }
54 
55  private:
56 
58 
59  std::string subsection() const
61 
62  std::string _prefix;
63 
64  std::string _material;
65  };
66 
67  inline
69  {
70  // We *must* use the size of _var_names here since that gets populated
71  // at construction time.
72  return _var_names.size();
73  }
74 
75  inline
77  {
78  return _vars[species];
79  }
80 
81 } // end namespace GRINS
82 
83 #endif //GRINS_SPECIES_MASS_FRACS_FE_VARIABLES_H
unsigned int VariableIndex
More descriptive name of the type used for variable indices.
Definition: var_typedefs.h:42
bool _is_constraint_var
Tracks whether this is a constraint variable.
GRINS namespace.
static std::string species_mass_fractions_section()
std::vector< std::string > _var_names
VariableIndex species(unsigned int species) const
Class to encapsulate variables that have only one FEType/Order.
std::vector< VariableIndex > _vars

Generated on Thu Jun 2 2016 21:52:28 for GRINS-0.7.0 by  doxygen 1.8.10