Chombo + EB + MF  3.2
AnalyticCS.H
Go to the documentation of this file.
1 #ifdef CH_LANG_CC
2 /*
3  * _______ __
4  * / ___/ / ___ __ _ / / ___
5  * / /__/ _ \/ _ \/ V \/ _ \/ _ \
6  * \___/_//_/\___/_/_/_/_.__/\___/
7  * Please refer to Copyright.txt, in Chombo's root directory.
8  */
9 #endif
10 
11 #ifndef _ANALYTICCS_H_
12 #define _ANALYTICCS_H_
13 
14 #include "NewFourthOrderCoordSys.H"
15 #include "RefCountedPtr.H"
16 #include "VectorFunction.H"
17 #include "TensorFunction.H"
18 
19 #include "NamespaceHeader.H"
20 
21 //! \class AnalyticCS
22 //! This class uses analytic vector/tensor functions to define a
23 //! coordinate mapping.
25 {
26  public:
27 
28  //! Construct an analytic coordinate mapping.
29  AnalyticCS(const RealVect& a_dX,
33 
34  //! Destructor.
35  ~AnalyticCS();
36 
37  // Overridden methods
38 
39  RealVect realCoord(const RealVect& a_X) const;
40 
41  RealVect mappedCoord(const RealVect& a_x) const;
42 
43  Real dXdXi(const RealVect& a_Xi, int a_dirX, int a_dirXi) const;
44 
45  protected:
46 
49 
50  // Cached Jacobian matrix and corresponding coordinate.
51  mutable RealTensor m_J0;
52  mutable RealVect m_Xi0;
53 
54  private:
55 
56  AnalyticCS();
57 
58 };
59 
60 //! \class AnalyticCSFactory
62 {
63  public:
64 
65  /// constructor
69 
70  ///
71  virtual NewCoordSys* getCoordSys(const ProblemDomain& a_domain,
72  const RealVect& a_dx) const;
73 
74  protected:
75 
78 };
79 
80 
81 #include "NamespaceFooter.H"
82 
83 #endif
AnalyticCSFactory(RefCountedPtr< VectorFunction > a_X, RefCountedPtr< VectorFunction > a_Xi, RefCountedPtr< TensorFunction > a_J)
constructor
Definition: AnalyticCS.H:61
~AnalyticCS()
Destructor.
Definition: RealTensor.H:24
A class to facilitate interaction with physical boundary conditions.
Definition: ProblemDomain.H:141
Virtual base class encapsulating mapped-grid coordinate systems.
Definition: NewFourthOrderCoordSys.H:77
RefCountedPtr< VectorFunction > m_Xi
Definition: AnalyticCS.H:47
RefCountedPtr< TensorFunction > m_J
Definition: AnalyticCS.H:77
RefCountedPtr< TensorFunction > m_J
Definition: AnalyticCS.H:48
RealVect m_Xi0
Definition: AnalyticCS.H:52
pure-virtual base class defining factory interface for CoordSys
Definition: NewCoordSys.H:236
RefCountedPtr< VectorFunction > m_X
Definition: AnalyticCS.H:47
double Real
Definition: REAL.H:33
virtual NewCoordSys * getCoordSys(const ProblemDomain &a_domain, const RealVect &a_dx) const
A Real vector in SpaceDim-dimensional space.
Definition: RealVect.H:41
RealVect realCoord(const RealVect &a_X) const
given coordinate in mapped space, return its location in real space
RefCountedPtr< VectorFunction > m_X
Definition: AnalyticCS.H:76
RealTensor m_J0
Definition: AnalyticCS.H:51
Definition: AnalyticCS.H:24
Virtual base class encapsulating mapped-grid coordinate systems.
Definition: NewCoordSys.H:30
RefCountedPtr< VectorFunction > m_Xi
Definition: AnalyticCS.H:76
RealVect mappedCoord(const RealVect &a_x) const
given coordinate in real space, return its location in the mapped space
Real dXdXi(const RealVect &a_Xi, int a_dirX, int a_dirXi) const
note that a_Xi is in mapped space.