GRINS-0.6.0
antioch_constant_transport_mixture.h
Go to the documentation of this file.
1 //-----------------------------------------------------------------------bl-
2 //--------------------------------------------------------------------------
3 //
4 // GRINS - General Reacting Incompressible Navier-Stokes
5 //
6 // Copyright (C) 2014-2015 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_ANTIOCH_CONSTANT_TRANSPORT_MIXTURE_H
27 #define GRINS_ANTIOCH_CONSTANT_TRANSPORT_MIXTURE_H
28 
29 #include "grins_config.h"
30 
31 #ifdef GRINS_HAVE_ANTIOCH
32 
33 // Antioch
34 #include "antioch/constant_lewis_diffusivity.h"
35 
36 // GRINS
37 #include "grins/antioch_mixture.h"
38 #include "grins/property_types.h"
41 
42 // libMesh
43 #include "libmesh/libmesh_common.h"
44 #include "libmesh/getpot.h"
45 
46 namespace GRINS
47 {
49 
56  template<typename Conductivity>
58  {
59  public:
60 
61  AntiochConstantTransportMixture( const GetPot& input );
62 
64 
65  libMesh::Real mu() const;
66 
67  const Conductivity& conductivity() const;
68 
69  const Antioch::ConstantLewisDiffusivity<libMesh::Real>& diffusivity() const;
70 
72 
73  protected:
74 
75  libMesh::Real _mu;
76 
77  boost::scoped_ptr<Conductivity> _conductivity;
78 
79  boost::scoped_ptr<Antioch::ConstantLewisDiffusivity<libMesh::Real> > _diffusivity;
80 
81  /* Below we will specialize the specialized_build_* functions to the appropriate type.
82  This way, we can control how the cached transport objects get constructed
83  based on the template type. This is achieved by the dummy types forcing operator
84  overloading for each of the specialized types. */
85  void build_conductivity( const GetPot& input )
87 
88  private:
89 
91 
92  void specialized_build_conductivity( const GetPot& input,
93  boost::scoped_ptr<ConstantConductivity>& conductivity,
95  {
96  conductivity.reset( new ConstantConductivity(input) );
97  return;
98  }
99 
100  void specialized_build_conductivity( const GetPot& input,
101  boost::scoped_ptr<ConstantPrandtlConductivity>& conductivity,
103  {
104  conductivity.reset( new ConstantPrandtlConductivity(input) );
105  return;
106  }
107 
108  };
109 
110  /* ------------------------- Inline Functions -------------------------*/
111  template<typename Conductivity>
112  inline
114  {
115  return _mu;
116  }
117 
118  template<typename Conductivity>
119  inline
121  {
122  return *_conductivity.get();
123  }
124 
125  template<typename Conductivity>
126  inline
127  const Antioch::ConstantLewisDiffusivity<libMesh::Real>& AntiochConstantTransportMixture<Conductivity>::diffusivity() const
128  {
129  return *_diffusivity.get();
130  }
131 
132 } // end namespace GRINS
133 
134 #endif // GRINS_HAVE_ANTIOCH
135 
136 #endif // GRINS_ANTIOCH_CONSTANT_TRANSPORT_MIXTURE_H
Wrapper class for Antioch::ChemicalMixture.
GRINS namespace.
const Antioch::ConstantLewisDiffusivity< libMesh::Real > & diffusivity() const
Wrapper class for storing state for Antioch thermo and kinetics.
void specialized_build_conductivity(const GetPot &input, boost::scoped_ptr< ConstantPrandtlConductivity > &conductivity, conductivity_type< ConstantPrandtlConductivity >)
Wrapper class for storing state for constant transport properties, including Antioch::ConstantLewisDi...
boost::scoped_ptr< Antioch::ConstantLewisDiffusivity< libMesh::Real > > _diffusivity
void specialized_build_conductivity(const GetPot &input, boost::scoped_ptr< ConstantConductivity > &conductivity, conductivity_type< ConstantConductivity >)

Generated on Mon Jun 22 2015 21:32:20 for GRINS-0.6.0 by  doxygen 1.8.9.1