Chombo + EB  3.0
EBPatchAdvect.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 _EBPATCHADVECT_H_
12 #define _EBPATCHADVECT_H_
13 
14 #include "EBPatchGodunov.H"
15 #include "EBPatchGodunovFactory.H"
16 #include "NamespaceHeader.H"
17 
18 #define TOL 1.e-12
19 
20 ///
21 /**
22  An EBPatchGodunov for passive advection with an
23  input velocity of a particular function value.
24 */
26 {
27 public:
28 
29  ///
30  EBPatchAdvect();
31 
32  ///
34 
35  ///
36  /**
37  Return number of components for primitive variables.
38  */
39  virtual int numPrimitives() const
40  {
41  return 1;
42  }
43 
44  ///
45  /**
46  Returns number of components for flux variables.
47  */
48  virtual int numFluxes() const
49  {
50  return 1;
51  }
52 
53  ///
54  /**
55  Returns number of components for conserved variables.
56  */
57  virtual int numConserved() const
58  {
59  return 1;
60  }
61 
62  ///
63  /**
64  */
65  virtual int numSlopes() const
66  {
67  return 1;
68  }
69 
70  ///
71  /**
72  */
73  void
74  normalPred(EBCellFAB& a_primLo,
75  EBCellFAB& a_primHi,
76  const EBCellFAB& a_primState,
77  const EBCellFAB& a_slopePrim,
78  const Real& a_scale,
79  const int& a_dir,
80  const Box& a_box);
81 
82  ///
83  /**
84  */
85  void
86  transversePred(EBCellFAB& a_primLo,
87  EBCellFAB& a_primHi,
88  const EBCellFAB& a_primState,
89  const EBCellFAB& a_slopePrim,
90  const Real& a_scale,
91  const int& a_dir,
92  const Box& a_box);
93 
94  ///
95  /**
96  */
97  void
99  const EBFluxFAB& a_fluxInterpolant,
100  const IntVectSet& a_irregIVS);
101 
102  ///
103  /**
104  */
105  void
106  extrapToCoveredFaces(BaseIVFAB<Real>& a_extendedPrim,
107  const EBFaceFAB& a_primFace,
108  const EBCellFAB& a_primState,
109  const Vector<VolIndex>& a_coveredFaces,
110  const int& a_faceDir,
111  const Side::LoHiSide& a_sd,
112  const Box& a_box);
113 
114  ///
115  /**
116  */
117  void
119  const EBFaceFAB& a_primFace,
120  const EBCellFAB& a_primState,
121  const int& a_faceDir,
122  const VolIndex& a_vof,
123  const RealVect& a_normal,
124  const Side::LoHiSide& a_sd,
125  const int& a_numPrim);
126 
127  ///
128  /**
129  */
130  void
132  const EBFaceFAB& a_primFace,
133  const EBCellFAB& a_primState,
134  const int& a_faceDir,
135  const VolIndex& a_vof,
136  const RealVect& a_normal,
137  const Side::LoHiSide& a_sd,
138  const int& a_numPrim);
139  ///
140  /**
141  default does -= u_idir d cons/ dx_idir.
142  assumes fluxes are really prims.
143  */
144  virtual void
145  updatePrim(EBCellFAB& a_primMinu,
146  EBCellFAB& a_primPlus,
147  const EBFaceFAB& a_flux,
148  const BaseIVFAB<Real>& a_coveredFluxMinu,
149  const BaseIVFAB<Real>& a_coveredFluxPlus,
150  const Vector<VolIndex>& a_coveredFaceMinu,
151  const Vector<VolIndex>& a_coveredFacePlus,
152  const int& a_dir,
153  const Box& a_box,
154  const Real& a_scale);
155 
156  void
157  upwindSlope(EBCellFAB& a_slopeUpWi,
158  const EBCellFAB& a_primState,
159  const int& a_dir,
160  const Box& a_box);
161 
162  void
163  pointGetSlopesUpwind(Real& a_dql,
164  Real& a_dqr,
165  Real& a_dqc,
166  bool& a_hasFacesLeft,
167  bool& a_hasFacesRigh,
168  const VolIndex& a_vof,
169  const EBCellFAB& a_primState,
170  const int& a_dir,
171  const int& a_ivar,
172  const bool& a_verbose);
173 
174  /// floors if m_isMaxMinSet
175  virtual void
177  const Box& a_box)
178  {
179  if (m_isMaxMinSet)
180  {
181  CH_assert(numPrimitives()==1);
182  // IntVectSet ivsIrreg = m_ebisBox.getIrregIVS(a_box);
183  IntVectSet ivsIrreg(a_box);
184  for (VoFIterator vofit(ivsIrreg, m_ebisBox.getEBGraph());vofit.ok(); ++vofit)
185  {
186  const VolIndex& vof = vofit();
187  a_primState(vof, 0) = Min(a_primState(vof, 0), m_maxVal);
188  a_primState(vof, 0) = Max(a_primState(vof, 0), m_minVal);
189  }
190  }
191  }
192 
193  /// floors if m_isMaxMinSet
194  virtual void
196  const IntVectSet& a_set)
197  {
198  if (m_isMaxMinSet)
199  {
200  CH_assert(numPrimitives()==1);
201  for (VoFIterator vofit(a_set, m_ebisBox.getEBGraph());vofit.ok(); ++vofit)
202  {
203  const VolIndex& vof = vofit();
204  a_primState(vof, 0) = Min(a_primState(vof, 0), m_maxVal);
205  a_primState(vof, 0) = Max(a_primState(vof, 0), m_minVal);
206  }
207  }
208  }
209 
210  /// floors if m_isMaxMinSet
211  virtual void
212  floorConserved(EBCellFAB& a_consState,
213  const Box& a_box)
214  {
215  if (m_isMaxMinSet)
216  {
217  MayDay::Error("EBPatchAdvect::floorConserved::EBCellFAB:: unexpected case");
218  }
219  }
220 
221  /// floors if m_isMaxMinSet
222  virtual void
224  const IntVectSet& a_set)
225  {
226  if (m_isMaxMinSet)
227  {
228  MayDay::Error("EBPatchAdvect::floorConserved::BaseIVFAB:: unexpected case");
229  }
230  }
231 
232  /// default noop
233  virtual void getCoveredValuesPrim(Vector<Real>& a_covValues)
234  {;}
235 
236  ///default noop
237  virtual void getCoveredValuesCons(Vector<Real>& a_covValues)
238  {;}
239 
240  ///default noop
241  virtual void setCoveredConsVals(EBCellFAB& a_consState)
242  {;}
243 
244  ///
245  /**
246  just a copy as default
247  */
248  virtual void
249  consToPrim(EBCellFAB& a_primState,
250  const EBCellFAB& a_conState,
251  const Box& a_box,
252  int a_logflag,
253  bool a_verbose=false);
254 
255  ///
256  /**
257  just a copy as default
258  */
259  virtual void
260  consToPrim(BaseIVFAB<Real>& a_primState,
261  const BaseIVFAB<Real>& a_conState,
262  const IntVectSet& a_ivs);
263 
264  ///
265  /**
266  just a copy
267  */
268  virtual void
269  consToPrim(BaseIVFAB<Real>& a_primState,
270  const EBCellFAB& a_conState,
271  const IntVectSet& a_ivs);
272 
273  ///
274  /**
275  just a copy
276  */
277  virtual void
278  primToCons(EBCellFAB& a_primState,
279  const EBCellFAB& a_conState,
280  const Box& a_box);
281 
282  ///
283  /**
284  just a copy
285  */
286  virtual void
287  primToCons(BaseIVFAB<Real>& a_primState,
288  const BaseIVFAB<Real>& a_conState,
289  const IntVectSet& a_ivs);
290 
291  ///
292  /**
293  sends back primitive state (NOT FLUX) using upwinding
294  */
295  virtual void
296  riemann(EBFaceFAB& a_primState,
297  const EBCellFAB& a_primLeft,
298  const EBCellFAB& a_primRight,
299  const int& a_dir,
300  const Box& a_box);
301 
302  ///
303  /**
304  sends back primitive state (NOT FLUX) using upwinding
305  */
306  virtual void
307  riemann(BaseIVFAB<Real>& a_coveredFlux,
308  const BaseIVFAB<Real>& a_extendedState,
309  const EBCellFAB& a_primState,
310  const Vector<VolIndex>& a_region,
311  const int& a_dir,
312  const Side::LoHiSide& a_sd,
313  const Box& a_box);
314 
315  ///
316  /**
317  sets eb flux to zero
318  */
319  virtual void
320  computeEBIrregFlux(BaseIVFAB<Real>& a_ebIrregFlux,
321  const EBCellFAB& a_primState,
322  const EBCellFAB a_slopePrim[SpaceDim],
323  const IntVectSet& a_irregIVS,
324  const EBCellFAB& a_source);
325 
326  ///
327  /**
328  */
329  void
330  extrapolatePrim(EBFluxFAB& a_flux,
331  EBCellFAB& a_primState,
332  EBCellFAB a_slopePrim[SpaceDim],
333  EBCellFAB a_slopeNLim[SpaceDim],
334  Vector<BaseIVFAB<Real> * >& a_coveredFluxMinu,
335  Vector<BaseIVFAB<Real> * >& a_coveredFluxPlus,
336  const Vector<IntVectSet >& a_coveredSetsMinu,
337  const Vector<IntVectSet >& a_coveredSetsPlus,
338  const Vector<Vector<VolIndex> >& a_coveredFaceMinu,
339  const Vector<Vector<VolIndex> >& a_coveredFacePlus,
340  const EBCellFAB& a_flattening,
341  const EBCellFAB& a_consState,
342  const EBCellFAB& a_source,
343  const Box& a_box,
344  const DataIndex& a_dit,
345  bool a_verbose);
346 
347  ///
348  /**
349  */
350  void
351  extrapolateBCG(EBFluxFAB& a_flux,
352  // EBCellFAB& a_primState,
353  EBCellFAB a_slopePrim[SpaceDim],
354  EBCellFAB a_slopeNLim[SpaceDim],
355  const EBCellFAB& a_flattening,
356  const EBCellFAB& a_consState,
357  const EBCellFAB& a_source,
358  const Box& a_box,
359  const DataIndex& a_dit,
360  bool a_verbose);
361 
362  void
363  extrapolateBCG(EBCellFAB a_primMinu[SpaceDim],
364  EBCellFAB a_primPlus[SpaceDim],
365  // EBCellFAB& a_primState,
366  EBCellFAB a_slopesPrim[SpaceDim],
367  EBCellFAB a_slopesSeco[SpaceDim],
368  const EBCellFAB& a_flattening,
369  const EBCellFAB& a_consState,
370  const EBCellFAB& a_source,
371  const Box& a_box,
372  const DataIndex& a_dit,
373  bool a_verbose);
374 
375  ///
376  virtual void
377  advectiveDerivative(EBCellFAB & a_udotDelRho,
378  const EBFluxFAB & a_faceRho,
379  const EBFluxFAB & a_faceVel,
380  const Vector<BaseIVFAB<Real>*> & a_coveredRhoMinu,
381  const Vector<BaseIVFAB<Real>*> & a_coveredRhoPlus,
382  const Vector<BaseIVFAB<Real>*> & a_coveredVelMinu,
383  const Vector<BaseIVFAB<Real>*> & a_coveredVelPlus,
384  const Vector<Vector<VolIndex> >& a_coveredFaceMinu,
385  const Vector<Vector<VolIndex> >& a_coveredFacePlus,
386  const Box & a_box);
387 
388  ///
389  void
390  advectiveDerivative(EBCellFAB & a_udotDelRho,
391  const EBFluxFAB & a_faceRho,
392  const EBFluxFAB & a_faceVel,
393  const Box & a_box);
394 
395  //Things you do not want to mess with unless you really know what you are doing
396  ///
397  /**
398  always false for now
399  */
400  virtual bool usesFlattening() const;
401 
402  ///
403  /**
404  always false for now
405  */
406  virtual bool usesArtificialViscosity() const;
407 
408 
409  // virtual void
410  // coveredExtrapSlopes(Real& a_dqc,
411  // const VolIndex& a_vof,
412  // const EBCellFAB& a_primState,
413  // const int& a_dir,
414  // const int& a_ivar);
415 
416  // virtual void
417  // coveredExtrapSlopesEBPA(Real& a_dqc,
418  // const VolIndex& a_vof,
419  // const EBCellFAB& a_primState,
420  // const Real& a_wc,
421  // const int& a_dir,
422  // const int& a_ivar);
423 
424  virtual void
425  slope(EBCellFAB& a_slopePrim,
426  EBCellFAB& a_slopeNLim,
427  const EBCellFAB& a_primState,
428  const EBCellFAB& a_flattening,
429  const int& a_dir,
430  const Box& a_box,
431  bool a_doAgg = false);
432 
433  virtual void
434  doSecondOrderSlopes(EBCellFAB& a_delta2W,
435  EBCellFAB& a_deltaWL,
436  EBCellFAB& a_deltaWR,
437  EBCellFAB& a_deltaWC,
438  const EBCellFAB& a_primState,
439  const int& a_dir,
440  const Box& a_box);
441 
442  ///
443  /**
444  Return true if you are using fourth-order slopes.
445  Return false if you are using second-order slopes.
446  */
447  virtual bool usesFourthOrderSlopes() const;
448 
449  ///
450  void
451  averageVelToCC(EBCellFAB& a_normalVel,
452  const EBFluxFAB& a_advectionVel,
453  const Vector<BaseIVFAB<Real> * >& a_coveredVeloLo,
454  const Vector<BaseIVFAB<Real> * >& a_coveredVeloHi,
455  const Vector<Vector<VolIndex> >& a_coveredFaceLo,
456  const Vector<Vector<VolIndex> >& a_coveredFaceHi,
457  const Box& a_box) const;
458 
459  virtual void setVelocities(const EBCellFAB& a_normalVel,
460  const EBFluxFAB& a_advectionVel);
461 
462  virtual void
463  setValidBox(const Box& a_validBox,
464  const EBISBox& a_ebisBox,
465  const IntVectSet& a_coarseFineIVS,
466  const Real& a_time,
467  const Real& a_dt);
468 
469  virtual void setTimeAndDt(const Real& a_time, const Real& a_dt)
470  {
471  m_time = a_time;
472  m_dt = a_dt;
473  }
474 
475  ///sets generic defaults
476  virtual Vector<string> stateNames();
477  ///sets generic defaults
478  virtual Vector<string> primNames();
479 
480  ///
481  void useLimiting(bool a_limiting);
482 
483  // Things that should not be called because they do not apply
484 
485  /// should not be called
486  Real
487  getMaxWaveSpeed(const EBCellFAB& a_consState,
488  const Box& a_box)
489  {
490  MayDay::Error("should not be called ");
491  return -1.0;
492  }
493  /// should not be called
494  void
496  const EBFaceFAB& a_prim,
497  const int& a_dir,
498  const Box& a_box)
499  {
500  MayDay::Error("should not be called ");
501  }
502 
503  ///
504  /**
505  should not be called
506  */
508  {
509  MayDay::Error("should not be called");
510  Interval retval;
511  return retval;
512  }
513 
514  ///
515  /**
516  only used as a comparison with ivar for flattening
517  at covered face extrapolation
518  don't want flattening-type stuff to pure advected vars
519  also used for tagging cells.
520  */
521  virtual int densityIndex() const
522  {
523  return 0;
524  }
525 
526 
527  ///
528  /**
529  only used as a comparison with ivar for flattening
530  at covered face extrapolation
531  don't want flattening-type stuff to pure advected vars
532  */
533  int pressureIndex() const
534  {
535  return -1;
536  }
537 
538  /// should not be called
539  int bulkModulusIndex() const
540  {
541  MayDay::Error("should not be called");
542  return -1;
543  }
544 
545  /// should not be called
547  {
548  MayDay::Error("should not be called");
549  return -1.0;
550  }
551 
552  void setMaxMin(const Real& a_maxVal,
553  const Real& a_minVal)
554  {
555  m_isMaxMinSet = true;
556  m_maxVal = a_maxVal;
557  m_minVal = a_minVal;
558  }
560  {
561  return m_primState;
562  }
563 
564 
565 
566 protected:
567 
570 
575 private:
576  //disallowed for all the usual reasons
577  void operator=(const EBPatchAdvect& a_input)
578  {
579  MayDay::Error("invalid operator");
580  }
581  EBPatchAdvect(const EBPatchAdvect& a_input)
582  {
583  MayDay::Error("invalid operator");
584  }
585 
586 };
587 
588 
589 ///
590 /**
591  */
593 {
594 public:
595  ///
596  /**
597  */
598  virtual ~EBPatchAdvectFactory();
599 
600  ///
601  /**
602  */
603  EBPatchGodunov* create() const;
604 
605  ///
606  /**
607  */
609  const bool& a_useLimiting,
610  const Real& a_maxVal =-1.e99,
611  const Real& a_minVal = 1.e99,
612  const bool& a_setMaxMin = false);
613 
614 protected:
620 
621 private:
622 
623  //disallowed for all the usual reasons
625  {
626  MayDay::Error("invalid operator");
627  }
628  void operator=(const EBPatchAdvectFactory& a_input)
629  {
630  MayDay::Error("invalid operator");
631  }
633  {
634  MayDay::Error("invalid operator");
635  }
636 };
637 
638 #include "NamespaceFooter.H"
639 #endif
virtual void updatePrim(EBCellFAB &a_primMinu, EBCellFAB &a_primPlus, const EBFaceFAB &a_flux, const BaseIVFAB< Real > &a_coveredFluxMinu, const BaseIVFAB< Real > &a_coveredFluxPlus, const Vector< VolIndex > &a_coveredFaceMinu, const Vector< VolIndex > &a_coveredFacePlus, const int &a_dir, const Box &a_box, const Real &a_scale)
const EBCellFAB * m_normalVelPtr
Definition: EBPatchAdvect.H:569
virtual int numConserved() const
Definition: EBPatchAdvect.H:57
const EBFluxFAB * m_advectionVelPtr
Definition: EBPatchAdvect.H:568
EBISBox m_ebisBox
Definition: EBPatchGodunov.H:871
virtual void primToCons(EBCellFAB &a_primState, const EBCellFAB &a_conState, const Box &a_box)
Definition: EBPatchGodunovFactory.H:20
An irregular domain on an integer lattice.
Definition: IntVectSet.H:44
void pointExtrapToCovered2D(Vector< Real > &a_extrapVal, const EBFaceFAB &a_primFace, const EBCellFAB &a_primState, const int &a_faceDir, const VolIndex &a_vof, const RealVect &a_normal, const Side::LoHiSide &a_sd, const int &a_numPrim)
#define CH_assert(cond)
Definition: CHArray.H:37
EBPatchAdvectFactory()
Definition: EBPatchAdvect.H:624
virtual void doSecondOrderSlopes(EBCellFAB &a_delta2W, EBCellFAB &a_deltaWL, EBCellFAB &a_deltaWR, EBCellFAB &a_deltaWC, const EBCellFAB &a_primState, const int &a_dir, const Box &a_box)
virtual void floorPrimitives(EBCellFAB &a_primState, const Box &a_box)
floors if m_isMaxMinSet
Definition: EBPatchAdvect.H:176
virtual void setTimeAndDt(const Real &a_time, const Real &a_dt)
Definition: EBPatchAdvect.H:469
const EBGraph & getEBGraph() const
virtual void advectiveDerivative(EBCellFAB &a_udotDelRho, const EBFluxFAB &a_faceRho, const EBFluxFAB &a_faceVel, const Vector< BaseIVFAB< Real > * > &a_coveredRhoMinu, const Vector< BaseIVFAB< Real > * > &a_coveredRhoPlus, const Vector< BaseIVFAB< Real > * > &a_coveredVelMinu, const Vector< BaseIVFAB< Real > * > &a_coveredVelPlus, const Vector< Vector< VolIndex > > &a_coveredFaceMinu, const Vector< Vector< VolIndex > > &a_coveredFacePlus, const Box &a_box)
EBPatchAdvect(const EBPatchAdvect &a_input)
Definition: EBPatchAdvect.H:581
virtual void consToPrim(EBCellFAB &a_primState, const EBCellFAB &a_conState, const Box &a_box, int a_logflag, bool a_verbose=false)
void extrapToCoveredFaces(BaseIVFAB< Real > &a_extendedPrim, const EBFaceFAB &a_primFace, const EBCellFAB &a_primState, const Vector< VolIndex > &a_coveredFaces, const int &a_faceDir, const Side::LoHiSide &a_sd, const Box &a_box)
void extrapolateBCG(EBFluxFAB &a_flux, EBCellFAB a_slopePrim[SpaceDim], EBCellFAB a_slopeNLim[SpaceDim], const EBCellFAB &a_flattening, const EBCellFAB &a_consState, const EBCellFAB &a_source, const Box &a_box, const DataIndex &a_dit, bool a_verbose)
bool m_useLimiting
Definition: EBPatchAdvect.H:616
bool ok() const
Definition: EBPatchAdvect.H:592
RefCountedPtr< EBPhysIBCFactory > m_bcFactoryPtr
Definition: EBPatchAdvect.H:615
Definition: EBISBox.H:46
bool m_isVelSet
Definition: EBPatchAdvect.H:571
virtual Vector< string > primNames()
sets generic defaults
virtual int numFluxes() const
Definition: EBPatchAdvect.H:48
Definition: EBPatchAdvect.H:25
virtual void slope(EBCellFAB &a_slopePrim, EBCellFAB &a_slopeNLim, const EBCellFAB &a_primState, const EBCellFAB &a_flattening, const int &a_dir, const Box &a_box, bool a_doAgg=false)
Definition: EBFaceFAB.H:28
virtual int numPrimitives() const
Definition: EBPatchAdvect.H:39
virtual void setValidBox(const Box &a_validBox, const EBISBox &a_ebisBox, const IntVectSet &a_coarseFineIVS, const Real &a_time, const Real &a_dt)
virtual void getCoveredValuesCons(Vector< Real > &a_covValues)
default noop
Definition: EBPatchAdvect.H:237
const int SpaceDim
Definition: SPACE.H:39
void pointGetSlopesUpwind(Real &a_dql, Real &a_dqr, Real &a_dqc, bool &a_hasFacesLeft, bool &a_hasFacesRigh, const VolIndex &a_vof, const EBCellFAB &a_primState, const int &a_dir, const int &a_ivar, const bool &a_verbose)
virtual bool usesArtificialViscosity() const
Real getMaxWaveSpeed(const EBCellFAB &a_consState, const Box &a_box)
should not be called
Definition: EBPatchAdvect.H:487
virtual void setCoveredConsVals(EBCellFAB &a_consState)
default noop
Definition: EBPatchAdvect.H:241
Real m_minVal
Definition: EBPatchAdvect.H:574
Definition: EBPatchGodunov.H:31
A EBFaceFAB-like container for edge-centered fluxes.
Definition: EBFluxFAB.H:25
void getFlux(EBFaceFAB &a_flux, const EBFaceFAB &a_prim, const int &a_dir, const Box &a_box)
should not be called
Definition: EBPatchAdvect.H:495
Real m_dt
Definition: EBPatchGodunov.H:873
virtual bool usesFlattening() const
int bulkModulusIndex() const
should not be called
Definition: EBPatchAdvect.H:539
Structure for passing component ranges in code.
Definition: Interval.H:23
virtual void computeEBIrregFlux(BaseIVFAB< Real > &a_ebIrregFlux, const EBCellFAB &a_primState, const EBCellFAB a_slopePrim[SpaceDim], const IntVectSet &a_irregIVS, const EBCellFAB &a_source)
Definition: EBCellFAB.H:29
virtual void setVelocities(const EBCellFAB &a_normalVel, const EBFluxFAB &a_advectionVel)
void transversePred(EBCellFAB &a_primLo, EBCellFAB &a_primHi, const EBCellFAB &a_primState, const EBCellFAB &a_slopePrim, const Real &a_scale, const int &a_dir, const Box &a_box)
double Real
Definition: REAL.H:33
virtual void riemann(EBFaceFAB &a_primState, const EBCellFAB &a_primLeft, const EBCellFAB &a_primRight, const int &a_dir, const Box &a_box)
virtual void getCoveredValuesPrim(Vector< Real > &a_covValues)
default noop
Definition: EBPatchAdvect.H:233
void useLimiting(bool a_limiting)
EBPatchAdvectFactory(const EBPatchAdvectFactory &a_input)
Definition: EBPatchAdvect.H:632
LoHiSide
Definition: LoHiSide.H:27
void extrapolatePrim(EBFluxFAB &a_flux, EBCellFAB &a_primState, EBCellFAB a_slopePrim[SpaceDim], EBCellFAB a_slopeNLim[SpaceDim], Vector< BaseIVFAB< Real > * > &a_coveredFluxMinu, Vector< BaseIVFAB< Real > * > &a_coveredFluxPlus, const Vector< IntVectSet > &a_coveredSetsMinu, const Vector< IntVectSet > &a_coveredSetsPlus, const Vector< Vector< VolIndex > > &a_coveredFaceMinu, const Vector< Vector< VolIndex > > &a_coveredFacePlus, const EBCellFAB &a_flattening, const EBCellFAB &a_consState, const EBCellFAB &a_source, const Box &a_box, const DataIndex &a_dit, bool a_verbose)
EBPatchGodunov * create() const
void operator=(const EBPatchAdvectFactory &a_input)
Definition: EBPatchAdvect.H:628
void averageVelToCC(EBCellFAB &a_normalVel, const EBFluxFAB &a_advectionVel, const Vector< BaseIVFAB< Real > * > &a_coveredVeloLo, const Vector< BaseIVFAB< Real > * > &a_coveredVeloHi, const Vector< Vector< VolIndex > > &a_coveredFaceLo, const Vector< Vector< VolIndex > > &a_coveredFaceHi, const Box &a_box) const
static void Error(const char *const a_msg=m_nullString, int m_exitCode=CH_DEFAULT_ERROR_CODE)
Print out message to cerr and exit with the specified exit code.
virtual Vector< string > stateNames()
sets generic defaults
bool m_isMaxMinSet
Definition: EBPatchAdvect.H:572
Interval velocityInterval() const
Definition: EBPatchAdvect.H:507
A Rectangular Domain on an Integer Lattice.
Definition: Box.H:465
A Real vector in SpaceDim-dimensional space.
Definition: RealVect.H:41
virtual void floorConserved(BaseIVFAB< Real > &a_consState, const IntVectSet &a_set)
floors if m_isMaxMinSet
Definition: EBPatchAdvect.H:223
Real m_maxVal
Definition: EBPatchAdvect.H:573
Definition: DataIndex.H:112
Definition: BaseIFFAB.H:34
Iterator for all vofs within an IntVectSet and an Ebgraph.
Definition: VoFIterator.H:27
void upwindSlope(EBCellFAB &a_slopeUpWi, const EBCellFAB &a_primState, const int &a_dir, const Box &a_box)
T Min(const T &a_a, const T &a_b)
Definition: Misc.H:26
void normalPred(EBCellFAB &a_primLo, EBCellFAB &a_primHi, const EBCellFAB &a_primState, const EBCellFAB &a_slopePrim, const Real &a_scale, const int &a_dir, const Box &a_box)
Real m_minVal
Definition: EBPatchAdvect.H:619
void operator=(const EBPatchAdvect &a_input)
Definition: EBPatchAdvect.H:577
Volume of Fluid Index.
Definition: VolIndex.H:31
T Max(const T &a_a, const T &a_b)
Definition: Misc.H:39
virtual int numSlopes() const
Definition: EBPatchAdvect.H:65
virtual void floorConserved(EBCellFAB &a_consState, const Box &a_box)
floors if m_isMaxMinSet
Definition: EBPatchAdvect.H:212
bool m_setMaxMin
Definition: EBPatchAdvect.H:617
virtual bool usesFourthOrderSlopes() const
void pointExtrapToCovered3D(Vector< Real > &a_extrapVal, const EBFaceFAB &a_primFace, const EBCellFAB &a_primState, const int &a_faceDir, const VolIndex &a_vof, const RealVect &a_normal, const Side::LoHiSide &a_sd, const int &a_numPrim)
void interpolateFluxToCentroids(BaseIFFAB< Real > a_centroidFlux[SpaceDim], const EBFluxFAB &a_fluxInterpolant, const IntVectSet &a_irregIVS)
EBCellFAB m_primState
Definition: EBPatchGodunov.H:909
Real m_maxVal
Definition: EBPatchAdvect.H:618
int pressureIndex() const
Definition: EBPatchAdvect.H:533
virtual void floorPrimitives(BaseIVFAB< Real > &a_primState, const IntVectSet &a_set)
floors if m_isMaxMinSet
Definition: EBPatchAdvect.H:195
Real artificialViscosityCoefficient() const
should not be called
Definition: EBPatchAdvect.H:546
void setMaxMin(const Real &a_maxVal, const Real &a_minVal)
Definition: EBPatchAdvect.H:552
Real m_time
Definition: EBPatchGodunov.H:872
virtual int densityIndex() const
Definition: EBPatchAdvect.H:521
virtual ~EBPatchAdvectFactory()
EBCellFAB & getPrimState()
Definition: EBPatchAdvect.H:559