Nektar++
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
VariableConverter.h
Go to the documentation of this file.
1 ///////////////////////////////////////////////////////////////////////////////
2 //
3 // File VariableConverter.h
4 //
5 // For more information, please see: http://www.nektar.info
6 //
7 // The MIT License
8 //
9 // Copyright (c) 2006 Division of Applied Mathematics, Brown University (USA),
10 // Department of Aeronautics, Imperial College London (UK), and Scientific
11 // Computing and Imaging Institute, University of Utah (USA).
12 //
13 // License for the specific language governing rights and limitations under
14 // Permission is hereby granted, free of charge, to any person obtaining a
15 // copy of this software and associated documentation files (the "Software"),
16 // to deal in the Software without restriction, including without limitation
17 // the rights to use, copy, modify, merge, publish, distribute, sublicense,
18 // and/or sell copies of the Software, and to permit persons to whom the
19 // Software is furnished to do so, subject to the following conditions:
20 //
21 // The above copyright notice and this permission notice shall be included
22 // in all copies or substantial portions of the Software.
23 //
24 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
25 // OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
26 // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
27 // THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
28 // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
29 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
30 // DEALINGS IN THE SOFTWARE.
31 //
32 // Description: Auxiliary functions to convert variables in
33 // the compressible flow system
34 //
35 ///////////////////////////////////////////////////////////////////////////////
36 
37 #ifndef NEKTAR_SOLVERS_COMPRESSIBLEFLOWSOLVER_MISC_VARCONVERT_H
38 #define NEKTAR_SOLVERS_COMPRESSIBLEFLOWSOLVER_MISC_VARCONVERT_H
39 
41 
42 namespace Nektar
43 {
44  // Forward declarations
46  typedef boost::shared_ptr<VariableConverter> VariableConverterSharedPtr;
47  /**
48  *
49  */
51  {
52  public:
53 
56  const int spaceDim);
57 
59 
60  void GetVelocityVector(
61  const Array<OneD, Array<OneD, NekDouble> > &physfield,
62  Array<OneD, Array<OneD, NekDouble> > &velocity);
63  void GetSoundSpeed(
64  const Array<OneD, Array<OneD, NekDouble> > &physfield,
65  Array<OneD, NekDouble> &pressure,
66  Array<OneD, NekDouble> &soundspeed);
67  void GetMach(
68  Array<OneD, Array<OneD, NekDouble> > &physfield,
69  Array<OneD, NekDouble> &soundspeed,
71  void GetTemperature(
72  const Array<OneD, const Array<OneD, NekDouble> > &physfield,
73  Array<OneD, NekDouble> &pressure,
74  Array<OneD, NekDouble> &temperature);
75  void GetPressure(
76  const Array<OneD, const Array<OneD, NekDouble> > &physfield,
77  Array<OneD, NekDouble> &pressure);
78  void GetPressure(
79  const Array<OneD, const Array<OneD, NekDouble> > &physfield,
80  const Array<OneD, const Array<OneD, NekDouble> > &velocity,
81  Array<OneD, NekDouble> &pressure);
82  void GetEnthalpy(
83  const Array<OneD, const Array<OneD, NekDouble> > &physfield,
84  Array<OneD, NekDouble> &pressure,
85  Array<OneD, NekDouble> &enthalpy);
86  void GetEntropy(
87  const Array<OneD, const Array<OneD, NekDouble> > &physfield,
88  const Array<OneD, const NekDouble> &pressure,
89  const Array<OneD, const NekDouble> &temperature,
90  Array<OneD, NekDouble> &entropy);
92  const Array<OneD, const NekDouble> &temperature,
95  const Array<OneD, const Array<OneD, NekDouble> > &inarray,
97  void GetSensor(
98  const MultiRegions::ExpListSharedPtr &field,
99  const Array<OneD, const Array<OneD, NekDouble> > &physarray,
100  Array<OneD, NekDouble> &Sensor,
101  Array<OneD, NekDouble> &SensorKappa);
102 
103  protected:
115  };
116 }
117 #endif
VariableConverter(const LibUtilities::SessionReaderSharedPtr &pSession, const int spaceDim)
void GetEnthalpy(const Array< OneD, const Array< OneD, NekDouble > > &physfield, Array< OneD, NekDouble > &pressure, Array< OneD, NekDouble > &enthalpy)
boost::shared_ptr< SessionReader > SessionReaderSharedPtr
Definition: MeshPartition.h:51
LibUtilities::SessionReaderSharedPtr m_session
void GetDynamicViscosity(const Array< OneD, const NekDouble > &temperature, Array< OneD, NekDouble > &mu)
void GetAbsoluteVelocity(const Array< OneD, const Array< OneD, NekDouble > > &inarray, Array< OneD, NekDouble > &Vtot)
void GetSoundSpeed(const Array< OneD, Array< OneD, NekDouble > > &physfield, Array< OneD, NekDouble > &pressure, Array< OneD, NekDouble > &soundspeed)
~VariableConverter()
Destructor for VariableConverter class.
boost::shared_ptr< ExpList > ExpListSharedPtr
Shared pointer to an ExpList object.
void GetSensor(const MultiRegions::ExpListSharedPtr &field, const Array< OneD, const Array< OneD, NekDouble > > &physarray, Array< OneD, NekDouble > &Sensor, Array< OneD, NekDouble > &SensorKappa)
double NekDouble
void GetVelocityVector(const Array< OneD, Array< OneD, NekDouble > > &physfield, Array< OneD, Array< OneD, NekDouble > > &velocity)
void GetEntropy(const Array< OneD, const Array< OneD, NekDouble > > &physfield, const Array< OneD, const NekDouble > &pressure, const Array< OneD, const NekDouble > &temperature, Array< OneD, NekDouble > &entropy)
void GetMach(Array< OneD, Array< OneD, NekDouble > > &physfield, Array< OneD, NekDouble > &soundspeed, Array< OneD, NekDouble > &mach)
boost::shared_ptr< VariableConverter > VariableConverterSharedPtr
void GetPressure(const Array< OneD, const Array< OneD, NekDouble > > &physfield, Array< OneD, NekDouble > &pressure)
Calculate the pressure field assuming an ideal gas law.
void GetTemperature(const Array< OneD, const Array< OneD, NekDouble > > &physfield, Array< OneD, NekDouble > &pressure, Array< OneD, NekDouble > &temperature)