chombo-discharge
CD_CentroidInterpolationStencil.H
Go to the documentation of this file.
1 /* chombo-discharge
2  * Copyright © 2021 SINTEF Energy Research.
3  * Please refer to Copyright.txt and LICENSE in the chombo-discharge root directory.
4  */
5 
12 #ifndef CD_CentroidInterpolationStencil_H
13 #define CD_CentroidInterpolationStencil_H
14 
15 // Our includes
16 #include <CD_IrregStencil.H>
17 #include <CD_NamespaceHeader.H>
18 
23 {
24 public:
29 
40  CentroidInterpolationStencil(const DisjointBoxLayout& a_dbl,
41  const EBISLayout& a_ebisl,
42  const ProblemDomain& a_domain,
43  const Real& a_dx,
44  const int a_order,
45  const int a_radius,
46  const IrregStencil::StencilType a_type);
47 
52 
53 protected:
66  virtual void
67  buildStencil(VoFStencil& a_sten,
68  const VolIndex& a_vof,
69  const DisjointBoxLayout& a_dbl,
70  const ProblemDomain& a_domain,
71  const EBISBox& a_ebisbox,
72  const Box& a_box,
73  const Real& a_dx,
74  const IntVectSet& a_cfivs) override;
75 
88  virtual bool
89  getTaylorExtrapolationStencil(VoFStencil& a_sten,
90  const VolIndex& a_vof,
91  const DisjointBoxLayout& a_dbl,
92  const ProblemDomain& a_domain,
93  const EBISBox& a_ebisbox,
94  const Box& a_box,
95  const Real& a_dx,
96  const IntVectSet& a_cfivs);
97 
110  virtual bool
111  getLeastSquaresStencil(VoFStencil& a_sten,
112  const VolIndex& a_vof,
113  const DisjointBoxLayout& a_dbl,
114  const ProblemDomain& a_domain,
115  const EBISBox& a_ebisbox,
116  const Box& a_box,
117  const Real& a_dx,
118  const IntVectSet& a_cfivs);
119 
131  virtual bool
132  getPiecewiseLinearStencil(VoFStencil& a_sten,
133  const VolIndex& a_vof,
134  const DisjointBoxLayout& a_dbl,
135  const ProblemDomain& a_domain,
136  const EBISBox& a_ebisbox,
137  const Box& a_box,
138  const Real& a_dx,
139  const IntVectSet& a_cfivs);
140 };
141 
142 #include <CD_NamespaceFooter.H>
143 
144 #endif
Abstract class for holding cut-cell stencils on an AMR level.
Class which can take cell-centered data and interpolate it to cell centroids.
Definition: CD_CentroidInterpolationStencil.H:23
virtual ~CentroidInterpolationStencil()
Destructor.
Definition: CD_CentroidInterpolationStencil.cpp:38
virtual bool getLeastSquaresStencil(VoFStencil &a_sten, const VolIndex &a_vof, const DisjointBoxLayout &a_dbl, const ProblemDomain &a_domain, const EBISBox &a_ebisbox, const Box &a_box, const Real &a_dx, const IntVectSet &a_cfivs)
Build the interpolation stencils using least squares interpolation.
Definition: CD_CentroidInterpolationStencil.cpp:148
virtual bool getTaylorExtrapolationStencil(VoFStencil &a_sten, const VolIndex &a_vof, const DisjointBoxLayout &a_dbl, const ProblemDomain &a_domain, const EBISBox &a_ebisbox, const Box &a_box, const Real &a_dx, const IntVectSet &a_cfivs)
Build the interpolation stencils using Taylor series.
Definition: CD_CentroidInterpolationStencil.cpp:103
virtual void buildStencil(VoFStencil &a_sten, const VolIndex &a_vof, const DisjointBoxLayout &a_dbl, const ProblemDomain &a_domain, const EBISBox &a_ebisbox, const Box &a_box, const Real &a_dx, const IntVectSet &a_cfivs) override
Build the interpolation stencils.
Definition: CD_CentroidInterpolationStencil.cpp:44
CentroidInterpolationStencil()=delete
Disallowed weak constructor.
virtual bool getPiecewiseLinearStencil(VoFStencil &a_sten, const VolIndex &a_vof, const DisjointBoxLayout &a_dbl, const ProblemDomain &a_domain, const EBISBox &a_ebisbox, const Box &a_box, const Real &a_dx, const IntVectSet &a_cfivs)
Build the interpolation stencils using piecewise linear reconstruction.
Definition: CD_CentroidInterpolationStencil.cpp:176
Class for holding stencils on irregular cells over a single AMR level.
Definition: CD_IrregStencil.H:38
StencilType
Enum for identifying stencil – only meant for enhancing code visibility.
Definition: CD_IrregStencil.H:44