GRINS-0.8.0
antioch_constant_transport_mixture_builder.h
Go to the documentation of this file.
1 //-----------------------------------------------------------------------bl-
2 //--------------------------------------------------------------------------
3 //
4 // GRINS - General Reacting Incompressible Navier-Stokes
5 //
6 // Copyright (C) 2014-2017 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_BUILDER_H
27 #define GRINS_ANTIOCH_CONSTANT_TRANSPORT_MIXTURE_BUILDER_H
28 
29 #include "grins_config.h"
30 
31 #ifdef GRINS_HAVE_ANTIOCH
32 
33 // GRINS
36 #include "grins/property_types.h"
40 
41 // Antioch
42 #include "antioch/constant_lewis_diffusivity.h"
43 
44 namespace GRINS
45 {
46 
48  {
49  public:
52 
53  template<typename KineticsThermoCurveFit,typename Conductivity>
54  libMesh::UniquePtr<AntiochConstantTransportMixture<KineticsThermoCurveFit,Conductivity> >
55  build_mixture( const GetPot & input, const std::string & material );
56 
57  libMesh::UniquePtr<ConstantViscosity>
58  build_constant_viscosity( const GetPot & input, const std::string & material )
59  {
60  return libMesh::UniquePtr<ConstantViscosity>( new ConstantViscosity(input,material) );
61  }
62 
63  template<typename Conductivity>
64  libMesh::UniquePtr<Conductivity>
65  build_constant_conductivity( const GetPot & input, const std::string & material )
66  {
68  }
69 
70  libMesh::UniquePtr<Antioch::ConstantLewisDiffusivity<libMesh::Real> >
71  build_constant_lewis_diff( const GetPot & input, const std::string & material )
72  {
73  libMesh::Real Le = MaterialsParsing::parse_lewis_number(input,material);
74  return libMesh::UniquePtr<Antioch::ConstantLewisDiffusivity<libMesh::Real> >
75  ( new Antioch::ConstantLewisDiffusivity<libMesh::Real>(Le) );
76  }
77 
78  private:
79 
80  libMesh::UniquePtr<ConstantConductivity>
81  specialized_build_conductivity( const GetPot & input, const std::string & material,
83  {
84  return libMesh::UniquePtr<ConstantConductivity>( new ConstantConductivity(input,material) );
85  }
86 
87  libMesh::UniquePtr<ConstantPrandtlConductivity>
88  specialized_build_conductivity( const GetPot & input, const std::string & material,
90  {
91  return libMesh::UniquePtr<ConstantPrandtlConductivity>( new ConstantPrandtlConductivity(input,material) );
92  }
93 
94  };
95 
96  template<typename KineticsThermoCurveFit,typename Conductivity>
97  inline
98  libMesh::UniquePtr<AntiochConstantTransportMixture<KineticsThermoCurveFit,Conductivity> >
99  AntiochConstantTransportMixtureBuilder::build_mixture( const GetPot & input, const std::string & material )
100  {
101  libMesh::UniquePtr<Antioch::ChemicalMixture<libMesh::Real> > chem_mix =
102  this->build_chem_mix(input,material);
103 
104  libMesh::UniquePtr<Antioch::ReactionSet<libMesh::Real> > reaction_set =
105  this->build_reaction_set(input,material,*chem_mix);
106 
107  libMesh::UniquePtr<Antioch::NASAThermoMixture<libMesh::Real,KineticsThermoCurveFit> > kinetics_thermo =
108  this->build_nasa_thermo_mix<KineticsThermoCurveFit>(input,material,*chem_mix);
109 
110  libMesh::UniquePtr<ConstantViscosity> visc =
111  this->build_constant_viscosity(input,material);
112 
113  libMesh::UniquePtr<Conductivity> cond =
114  this->build_constant_conductivity<Conductivity>(input,material);
115 
116  libMesh::UniquePtr<Antioch::ConstantLewisDiffusivity<libMesh::Real> > diff =
117  this->build_constant_lewis_diff(input,material);
118 
119  libMesh::Real min_T = this->parse_min_T(input,material);
120  bool clip_negative_rho = this->parse_clip_negative_rho(input,material);
121 
122  return libMesh::UniquePtr<AntiochConstantTransportMixture<KineticsThermoCurveFit,Conductivity> >
124  (chem_mix, reaction_set, kinetics_thermo, visc, cond, diff, min_T, clip_negative_rho) );
125  }
126 
127 } // end namespace GRINS
128 
129 #endif // GRINS_HAVE_ANTIOCH
130 
131 #endif // GRINS_ANTIOCH_CONSTANT_TRANSPORT_MIXTURE_BUILDER_H
bool parse_clip_negative_rho(const GetPot &input, const std::string &material)
libMesh::UniquePtr< ConstantPrandtlConductivity > specialized_build_conductivity(const GetPot &input, const std::string &material, conductivity_type< ConstantPrandtlConductivity >)
libMesh::UniquePtr< AntiochConstantTransportMixture< KineticsThermoCurveFit, Conductivity > > build_mixture(const GetPot &input, const std::string &material)
libMesh::UniquePtr< Antioch::ReactionSet< libMesh::Real > > build_reaction_set(const GetPot &input, const std::string &material, const Antioch::ChemicalMixture< libMesh::Real > &chem_mix)
Base class building Antioch mixture wrappers.
libMesh::UniquePtr< Antioch::ConstantLewisDiffusivity< libMesh::Real > > build_constant_lewis_diff(const GetPot &input, const std::string &material)
libMesh::UniquePtr< ConstantViscosity > build_constant_viscosity(const GetPot &input, const std::string &material)
GRINS namespace.
static libMesh::Real parse_lewis_number(const GetPot &input, const std::string &material)
libMesh::UniquePtr< ConstantConductivity > specialized_build_conductivity(const GetPot &input, const std::string &material, conductivity_type< ConstantConductivity >)
libMesh::UniquePtr< Conductivity > build_constant_conductivity(const GetPot &input, const std::string &material)
libMesh::Real parse_min_T(const GetPot &input, const std::string &material)
libMesh::UniquePtr< Antioch::ChemicalMixture< libMesh::Real > > build_chem_mix(const GetPot &input, const std::string &material)
Wrapper class for storing state for constant transport properties, including Antioch::ConstantLewisDi...

Generated on Tue Dec 19 2017 12:47:28 for GRINS-0.8.0 by  doxygen 1.8.9.1