Chombo + EB  3.0
BaseIFFABI.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 _BASEIFFABI_H_
12 #define _BASEIFFABI_H_
13 #include "MayDay.H"
14 #include "FaceIterator.H"
15 #include <typeinfo>
16 #include "NamespaceHeader.H"
17 
18 template <class T>
20 
21 //appalling hack to turn off surrounding node semantic
22 template <class T>
23 void
25 {
26  s_doSurroundingNodeSemantic = a_useSurr;
27 }
28 
29 //this if statement is to keep the above box growage from
30 //forcing more copying than the semantic demands.
31 template <class T>
32 bool
34  const FaceIndex& a_face) const
35 {
36  return ((a_toBox.contains(a_face.gridIndex(Side::Lo))) ||
37  (a_toBox.contains(a_face.gridIndex(Side::Hi))));
38 }
39 
40 //this box growing obfuscation is because
41 //copy and linearization have a cell-centered semantic.
42 //and we want the surrounding nodes
43 //of the cells to be copied
44 //Let's see how many more times I have to rewrite this function.
45 //--dtg 4/2009
46 template <class T>
47 void
49  IntVectSet& a_ivsIntersect,
50  const Box& a_toBox) const
51 {
52  Box grownBox = a_toBox;
53  if (s_doSurroundingNodeSemantic)
54  {
55  grownBox.grow(m_direction, 1);
56  }
57  a_intBox = grownBox;
58  a_ivsIntersect = m_ivs;
59  a_ivsIntersect &= a_intBox;
60 }
61 
62 template <class T>
63 bool BaseIFFAB<T>::s_verbose = false;
64 /******************/
65 template <class T> inline void
66 BaseIFFAB<T>::setVerbose(bool a_verbose)
67 {
68  s_verbose = a_verbose;
69 }
70 /******************/
71 template <class T> inline
72 const EBGraph&
74 {
75  return m_ebgraph;
76 }
77 /******************/
78 template <class T> inline
80 {
81  setDefaultValues();
82 }
83 /******************/
84 template <class T> inline
86 {
87  clear();
88 }
89 /******************/
90 template <class T> inline
92  const EBGraph& a_ebgraph,
93  const int& a_direction,
94  const int& a_nvarin)
95 {
96  setDefaultValues();
97  define(a_ivsin, a_ebgraph, a_direction, a_nvarin);
98 }
99 
100 template <class T> Arena* BaseIFFAB<T>::s_Arena = NULL;
101 
102 /******************/
103 template <class T> inline
104 void
106  const EBGraph& a_ebgraph,
107  const int& a_direction,
108  const int& a_nvarin)
109 {
110  clear();
111  m_isDefined = true;
112  CH_assert(a_nvarin > 0);
113  CH_assert((a_direction >= 0) && (a_direction < SpaceDim));
114  const ProblemDomain& domain = a_ebgraph.getDomain();
115  m_direction = a_direction;
116  m_ivs = a_ivsin;
117  m_ebgraph = a_ebgraph;
118  m_nComp = a_nvarin;
119  Box minbox = a_ivsin.minBox();
120  BaseFab<int> faceLocFab;
121  BaseFab<bool> doneThat;
122  if (!a_ivsin.isEmpty())
123  {
124  m_fab.resize( surroundingNodes(minbox,a_direction), 1);
125  faceLocFab.resize(surroundingNodes(minbox,a_direction), 1);
126  doneThat.resize( surroundingNodes(minbox,a_direction), 1);
127  faceLocFab.setVal(-1);
128  m_fab.setVal(NULL);
129  doneThat.setVal(false);
130  }
131  //get the data size and save offsets
132  //need to do this to avoid double-counting faces
133  m_nFaces = 0;
134  int nVoFs = 0;
135  for (IVSIterator ivsit(m_ivs); ivsit.ok(); ++ivsit)
136  {
137  const IntVect& iv = ivsit();
138  IntVect ivLo = iv-BASISV(m_direction);
139  IntVect ivHi = iv+BASISV(m_direction);
140  //check to see if on domain boundary
141  int numVoFsHere = m_ebgraph.numVoFs(iv);
142 
143  nVoFs += numVoFsHere;
144  //we hold the mapping in the high vof of the faces
145  if (!doneThat(iv, 0))
146  {
147  doneThat(iv, 0) = true;
148 
149  bool onLoBoundary = false;
150  if (!domain.isPeriodic(m_direction))
151  {
152  onLoBoundary = iv[m_direction] == domain.domainBox().smallEnd(m_direction);
153  }
154  int numFacesLoSide = numVoFsHere;
155  if (!onLoBoundary)
156  {
157  int numVoFsLo = m_ebgraph.numVoFs(ivLo);
158  numFacesLoSide = numVoFsHere*numVoFsLo;
159  }
160 
161  faceLocFab(iv, 0) = m_nFaces;
162  m_nFaces += numFacesLoSide;
163  }
164  if (!doneThat(ivHi, 0))
165  {
166  doneThat(ivHi, 0) = true;
167 
168  bool onHiBoundary = false;
169  if (!domain.isPeriodic(m_direction))
170  {
171  onHiBoundary = iv[m_direction] == domain.domainBox().bigEnd(m_direction);
172  }
173  int numFacesHiSide = numVoFsHere;
174  if (!onHiBoundary)
175  {
176  int numVoFsHi = m_ebgraph.numVoFs(ivHi);
177  numFacesHiSide = numVoFsHere*numVoFsHi;
178  }
179 
180  faceLocFab(ivHi, 0) = m_nFaces;
181  m_nFaces += numFacesHiSide;
182  }
183  }
184  // allocate the memory
185  if (m_nFaces > 0)
186  {
187  // const IntVectSet& multi = m_ebgraph.getMultiCells( minbox);
188  // pout()<< minbox << "nVoFs:"<<nVoFs<<" nFaces:"<<m_nFaces<<"\n";
189 #ifdef CH_USE_MEMORY_TRACKING
190  // if (s_Arena == NULL)
191  // {
192  // s_Arena = new BArena( (typeid(T)).name());
193  // }
194 #else
195  // if (s_Arena == NULL)
196  // {
197  // s_Arena = new BArena("");
198  // }
199 #endif
200 
201  // if (s_Arena == NULL)
202  // {
203  // MayDay::Error("malloc in basefab failed");
204  // }
205 
206  m_truesize = m_nFaces*m_nComp;
207 
208  // Note: clear() was called above so this isn't a memory leak
209  //m_data = new T[m_truesize];
210  m_data.resize(m_truesize);
211  // m_data = static_cast<T*>(s_Arena->alloc(m_truesize * sizeof(T)));
212 
213 #ifdef CH_USE_MEMORY_TRACKING
214  // s_Arena->bytes += m_truesize * sizeof(T) + sizeof(BaseIFFAB<T>);
215  // if (s_Arena->bytes > s_Arena->peak)
216  // {
217  // s_Arena->peak = s_Arena->bytes;
218  // }
219 #endif
220  doneThat.setVal(false);
221  }
222  if (m_nFaces==0) return;
223  //cache pointers to the first component of the first face into m_fab for fast indexing
224  T* startLoc = &m_data[0];
225  for (IVSIterator ivsit(m_ivs); ivsit.ok(); ++ivsit)
226  {
227  const IntVect& iv = ivsit();
228  if (!doneThat(iv, 0))
229  {
230  doneThat(iv, 0) = true;
231  int iface = faceLocFab(iv, 0);
232  if (iface >= 0)
233  {
234  m_fab(iv, 0) = startLoc + iface;
235  }
236  }
237  IntVect ivHi = iv+BASISV(m_direction);
238  if (!doneThat(ivHi, 0))
239  {
240  doneThat(ivHi, 0) = true;
241  int iface = faceLocFab(ivHi, 0);
242  if (iface >= 0)
243  {
244  m_fab(ivHi, 0) = startLoc + iface;
245  }
246  }
247  }
248 }
249 /******************/
250 template <class T> inline
251 const IntVectSet&
253 {
254  return m_ivs;
255 }
256 /******************/
257 template <class T> inline
258 int
260 {
261  return m_direction;
262 }
263 /******************/
264 template <class T> inline
265 void
266 BaseIFFAB<T>::setVal(const T& a_value)
267 {
268  CH_assert(isDefined());
269  for (int ivec = 0; ivec < m_nFaces*m_nComp; ivec++)
270  {
271  m_data[ivec] = a_value;
272  }
273 }
274 /******************/
275 template <class T> inline
276 void
277 BaseIFFAB<T>::setVal(int ivar, const T& a_value)
278 {
279  CH_assert(isDefined());
280  CH_assert(ivar >= 0);
281  CH_assert(ivar < m_nComp);
282 
283  for (int ivec = ivar; ivec < m_nFaces*m_nComp; ivec += m_nComp)
284  {
285  m_data[ivec] = a_value;
286  }
287 }
288 /******************/
289 template <class T> inline
290 void
291 BaseIFFAB<T>::copy(const Box& a_fromBox,
292  const Interval& a_dstInterval,
293  const Box& a_toBox,
294  const BaseIFFAB<T>& a_src,
295  const Interval& a_srcInterval)
296 {
297  CH_assert(isDefined());
298  CH_assert(a_src.isDefined());
299  CH_assert(a_srcInterval.size() == a_dstInterval.size());
300  CH_assert(a_dstInterval.begin() >= 0);
301  CH_assert(a_srcInterval.begin() >= 0);
302  CH_assert(a_dstInterval.end() < m_nComp);
303  CH_assert(a_srcInterval.end() < a_src.m_nComp);
304 
305  if ((!m_ivs.isEmpty()) && (!a_src.m_ivs.isEmpty()))
306  {
307  CH_assert( (a_fromBox == a_toBox) || m_ebgraph.getDomain().isPeriodic() );
308 
309  Box intBox;
310  IntVectSet ivsIntersect;
311  //this does a grow and intersect because
312  //copy has a cell centered semantic
313  getBoxAndIVS(intBox, ivsIntersect, a_toBox);
314 
315  ivsIntersect &= a_src.m_ivs;
316  int compSize = a_srcInterval.size();
317 
319  FaceIterator faceit(ivsIntersect, m_ebgraph, m_direction, stopCrit);
320  for (faceit.reset(); faceit.ok(); ++faceit)
321  {
322  const FaceIndex& face = faceit();
323  //this if statement is to keep the above box growage from
324  //forcing more copying than the semantic demands.
325  if (useThisFace(a_toBox, face))
326  {
327  for (int icomp = 0; icomp < compSize; icomp++)
328  {
329  int isrccomp = a_srcInterval.begin() + icomp;
330  int idstcomp = a_dstInterval.begin() + icomp;
331  (*this)(face, idstcomp) = a_src(face, isrccomp);
332  }
333  }
334  }
335  }
336 }
337 /*********/
338 template <class T> inline
339 T*
340 BaseIFFAB<T>::getIndex(const FaceIndex& a_face, const int& a_comp) const
341 {
342  //which face is this in the local vector (lexi on vof cell indices)
343 
344  T* dataPtr = (T*)(m_fab(a_face.gridIndex(Side::Hi), 0));
345  int faceLoc = getLocalVecIndex(a_face);
346  dataPtr += faceLoc;
347  dataPtr += m_nFaces*a_comp;
348  return dataPtr;
349 }
350 /*********/
351 template <class T> inline
352 int
354 {
355  int retval;
356  if (!a_face.isBoundary())
357  {
358  //this checks that both vofs are defined
359  CH_assert(a_face.cellIndex(Side::Lo) >= 0);
360  CH_assert(a_face.cellIndex(Side::Hi) >= 0);
361  int xlen = m_ebgraph.numVoFs(a_face.gridIndex(Side::Lo));
362  int loCell = a_face.cellIndex(Side::Lo);
363  int hiCell = a_face.cellIndex(Side::Hi);
364  retval = loCell + xlen*hiCell;
365  }
366  else
367  {
368  int loCell = a_face.cellIndex(Side::Lo);
369  int hiCell = a_face.cellIndex(Side::Hi);
370  //one should be -1, the other should be larger
371  CH_assert(((loCell == -1)&&(hiCell > -1))||
372  ((hiCell == -1)&&(loCell > -1)));
373  //return the one that is not -1
374  retval = Max(loCell, hiCell);
375  }
376  return retval;
377 }
378 /********************/
379 template <class T> inline
380 void
382 {
383  m_nComp = 0;
384  m_nFaces = 0;
385  m_direction = -1;
386  m_ivs.makeEmpty();
387  m_fab.clear();
388 // if (m_data != NULL)
389 // {
390 // delete[] m_data;
391 // #undef free
392 // // s_Arena->free(m_data);
393 // #ifdef CH_USE_MEMORY_TRACKING
394 // // s_Arena->bytes -= m_truesize * sizeof(T) + sizeof(BaseIFFAB<T>);
395 // #endif
396 // m_data = NULL;
397 // }
398  m_isDefined = false;
399 }
400 /*************************/
401 template <class T> inline
402 bool
404 {
405  return (m_isDefined);
406 }
407 /*************************/
408 template <class T> inline
409 int
411 {
412  return m_nFaces;
413 }
414 /*************************/
415 template <class T> inline
416 int
418 {
419  return m_nComp;
420 }
421 /*************************/
422 template <class T> inline
423 T&
425  const int& a_comp)
426 {
427  CH_assert(isDefined());
428  CH_assert(a_comp >= 0);
429  CH_assert(a_comp < m_nComp);
430  CH_assert((m_ivs.contains(a_ndin.gridIndex(Side::Lo)) ||
431  m_ivs.contains(a_ndin.gridIndex(Side::Hi))));
432  CH_assert(a_ndin.direction() == m_direction);
433 
434  T* dataPtr = getIndex(a_ndin, a_comp);
435  return(*dataPtr);
436 }
437 /**************************/
438 template <class T> inline
439 const T&
441  const int& a_comp) const
442 {
443  CH_assert(isDefined());
444  CH_assert(a_comp >= 0);
445  CH_assert(a_comp < m_nComp);
446  CH_assert((m_ivs.contains(a_ndin.gridIndex(Side::Lo)) ||
447  m_ivs.contains(a_ndin.gridIndex(Side::Hi))));
448  CH_assert(a_ndin.direction() == m_direction);
449 
450  T* dataPtr = getIndex(a_ndin, a_comp);
451  return(*dataPtr);
452 }
453 /******************/
454 template <class T> inline
455 T*
456 BaseIFFAB<T>::dataPtr(const int& a_comp)
457 {
458  CH_assert(a_comp >= 0);
459  CH_assert(a_comp <= m_nComp);
460  static T* dummy = NULL;
461  if (m_nFaces==0) return dummy;
462  //return m_data + a_comp*m_nFaces;
463  return &(m_data[0]) + a_comp*m_nFaces;
464 
465 }
466 /******************/
467 template <class T> inline
468 const T*
469 BaseIFFAB<T>::dataPtr(const int& a_comp) const
470 {
471  CH_assert(a_comp >= 0);
472  CH_assert(a_comp <= m_nComp);
473  static T* dummy = NULL;
474  if (m_nFaces==0) return dummy;
475  //return m_data + a_comp*m_nFaces;
476  return &(m_data[0]) + a_comp*m_nFaces;
477 }
478 /******************/
479 template <class T> inline
480 void
482 {
483  m_isDefined = false;
484  //m_data = NULL;
485  m_data.resize(0);
486  m_nFaces = 0;
487  m_nComp = 0;
488  m_direction = -1;
489 }
490 /******************/
491 template <class T> inline
492 int BaseIFFAB<T>::size(const Box& a_region,
493  const Interval& a_comps) const
494 {
495  CH_assert(isDefined());
496 
497  Box intBox;
498  IntVectSet subIVS;
499  //this does a grow and intersect because
500  //linearization has a cell centered semantic
501  getBoxAndIVS(intBox, subIVS, a_region);
502 
504  FaceIterator faceit(subIVS, m_ebgraph, m_direction, stopCrit);
505  Vector<FaceIndex> faces = faceit.getVector();
506 
507  //account for list of faces
508  int facesize = linearListSize(faces);
509 
510  //add for each data pt
511  int datasize = 0;
512  for (int iface = 0; iface < faces.size(); iface++)
513  {
514  //this makes sure that the grow done in getBoxAndIVS does
515  //not add faces outside the surrounding nodes of the region
516  if (useThisFace(a_region, faces[iface]))
517  {
518  for (int icomp = a_comps.begin(); icomp <= a_comps.end(); icomp++)
519  {
520  const T& dataPt = (*this)(faces[iface], icomp);
521  int pointsize = CH_XD::linearSize(dataPt);
522  datasize += pointsize;
523  }
524  }
525  }
526 
527  int retval = facesize + datasize;
528 
529  if (s_verbose)
530  {
531  pout() << "###############" << std::endl;
532  pout() << "BaseIFFAB size() for region " << m_ebgraph.getRegion() << std::endl;
533  pout() << " a_comps = (" << a_comps.begin() << "," << a_comps.end() << "),"
534  << " a_region = " << a_region << " subIVS = ";
535  // dumpIVS(&subIVS);
536  pout() << "m_ivs = ";
537  // dumpIVS(&m_ivs);
538  pout() << "size = " << retval << std::endl;
539  pout() << "###############" << std::endl;
540  }
541 
542  return retval;
543  }
544 /********************/
545 template <class T> inline
546 void BaseIFFAB<T>::linearOut(void* a_buf,
547  const Box& a_region,
548  const Interval& a_comps) const
549 {
550  CH_assert(isDefined());
551  Box intBox;
552  IntVectSet subIVS;
553  //this does a grow and intersect because
554  //linearization has a cell centered semantic
555  getBoxAndIVS(intBox, subIVS, a_region);
556 
558  FaceIterator faceit(subIVS, m_ebgraph, m_direction, stopCrit);
559  Vector<FaceIndex> faces = faceit.getVector();
560 
561  //output the faces.
562  unsigned char* charbuffer = (unsigned char *) a_buf;
563  linearListOut(charbuffer, faces);
564  charbuffer += linearListSize(faces);
565 
566  //output the data
567  const BaseIFFAB<T>& thisFAB = *this;
568  for (int iface = 0; iface < faces.size(); iface++)
569  {
570  //this makes sure that the grow done in getBoxAndIVS does
571  //not add faces outside the surrounding nodes of the region
572  if (useThisFace(a_region, faces[iface]))
573  {
574  const FaceIndex& face = faces[iface];
575  for (int icomp = a_comps.begin(); icomp <= a_comps.end(); icomp++)
576  {
577  //output the data into the buffer
578  const T& dataPt = thisFAB(face, icomp);
579  CH_XD::linearOut(charbuffer, dataPt);
580  //increment the buffer offset
581  charbuffer += CH_XD::linearSize(dataPt);
582  }
583  }
584  }
585 }
586 /********************/
587 template <class T> inline
588 void BaseIFFAB<T>::linearIn(void* a_buf, const Box& a_region, const Interval& a_comps)
589 {
590  CH_assert(isDefined());
591  //input the faces
592  //input the vofs
593  Box intBox;
594  IntVectSet subIVS;
595  //this does a grow and intersect because
596  //linearization has a cell centered semantic
597  getBoxAndIVS(intBox, subIVS, a_region);
598 
600  FaceIterator faceit(subIVS, m_ebgraph, m_direction, stopCrit);
601  Vector<FaceIndex> faces = faceit.getVector();
602 
603  unsigned char* charbuffer = (unsigned char *) a_buf;
604  linearListIn(faces, charbuffer);
605  charbuffer += linearListSize(faces);
606 
607  for (int iface = 0; iface < faces.size(); iface++)
608  {
609  //this makes sure that the grow done in getBoxAndIVS does
610  //not add faces outside the surrounding nodes of the region
611  if (useThisFace(a_region, faces[iface]))
612  {
613  const FaceIndex& face = faces[iface];
614  for (int icomp = a_comps.begin(); icomp <= a_comps.end(); icomp++)
615  {
616  //input the data
617  T& dataPt = (*this)(face, icomp);
618  CH_XD::linearIn(dataPt, charbuffer) ;
619  //increment the buffer offset
620  charbuffer += CH_XD::linearSize(dataPt);
621  }
622  }
623  }
624 }
625 /********************/
626 /******************/
627 
628 #include "NamespaceFooter.H"
629 #endif
std::ostream & pout()
Use this in place of std::cout for program output.
void linearIn(void *buf, const Box &R, const Interval &comps)
Definition: BaseIFFABI.H:588
int nComp() const
Definition: BaseIFFABI.H:417
T * dataPtr(const int &a_comp)
Definition: BaseIFFABI.H:456
static void setVerbose(bool a_verbose)
Definition: BaseIFFABI.H:66
int m_nComp
Definition: BaseIFFAB.H:223
An irregular domain on an integer lattice.
Definition: IntVectSet.H:44
#define CH_assert(cond)
Definition: CHArray.H:37
A class to facilitate interaction with physical boundary conditions.
Definition: ProblemDomain.H:130
int size(const Box &R, const Interval &comps) const
Definition: BaseIFFABI.H:492
void setVal(T a_x, const Box &a_bx, int a_nstart, int a_numcomp)
{ data modification functions}
Definition: BaseFabImplem.H:326
Definition: FaceIndex.H:28
void linearListOut(void *const a_outBuf, const Vector< T > &a_inputT)
Definition: SPMDI.H:255
int size() const
Definition: Interval.H:64
int begin() const
Definition: Interval.H:86
bool ok() const
Iterator over faces within an IntVectSet and an Ebgraph.
Definition: FaceIterator.H:67
void clear()
Definition: BaseIFFABI.H:381
Definition: FaceIterator.H:48
void setVal(const T &value)
Definition: BaseIFFABI.H:266
const ProblemDomain & getDomain() const
Definition: EBGraph.H:934
bool contains(const IntVect &p) const
Definition: Box.H:1888
const IntVect & gridIndex(const Side::LoHiSide &a_sd) const
IntVect BASISV(int dir)
Definition: IntVect.H:1183
~BaseIFFAB()
Definition: BaseIFFABI.H:85
int getLocalVecIndex(const FaceIndex &a_face) const
Definition: BaseIFFABI.H:353
const int & direction() const
bool ok() const
returns true if this iterator is still in its IntVectSet
Definition: IntVectSet.H:711
Definition: LoHiSide.H:31
Geometric description within a box.
Definition: EBGraph.H:432
const int SpaceDim
Definition: SPACE.H:39
const bool & isBoundary() const
const IntVect & bigEnd() const
Definition: Box.H:1779
IntVectSet m_ivs
Definition: BaseIFFAB.H:229
Structure for passing component ranges in code.
Definition: Interval.H:23
const Vector< FaceIndex > & getVector() const
bool isDefined() const
Definition: BaseIFFABI.H:403
const IntVect & smallEnd() const
{ Accessors}
Definition: Box.H:1765
void linearOut(void *const a_outBuf, const T &inputT)
Definition: SPMDI.H:32
static void setSurroundingNodeSemantic(bool a_useSurr)
Definition: BaseIFFABI.H:24
A Virtual Base Class for Dynamic Memory Managemen.
Definition: Arena.H:40
Box surroundingNodes(const Box &b, int dir)
Definition: Box.H:2166
int linearSize(const T &inputT)
Definition: SPMDI.H:20
int direction() const
Definition: BaseIFFABI.H:259
bool isPeriodic(int a_dir) const
Returns true if BC is periodic in direction a_dir.
Definition: ProblemDomain.H:875
size_t size() const
Definition: Vector.H:177
bool useThisFace(const Box &a_toBox, const FaceIndex &a_face) const
Definition: BaseIFFABI.H:33
void setDefaultValues()
Definition: BaseIFFABI.H:481
A Rectangular Domain on an Integer Lattice.
Definition: Box.H:465
Definition: BaseIFFAB.H:34
void linearListIn(Vector< T > &a_outputT, const void *const a_inBuf)
Definition: SPMDI.H:226
BaseIFFAB()
Definition: BaseIFFABI.H:79
An integer Vector in SpaceDim-dimensional space.
Definition: CHArray.H:42
Definition: LoHiSide.H:30
int linearListSize(const Vector< T > &a_input)
Definition: SPMDI.H:287
void linearOut(void *buf, const Box &R, const Interval &comps) const
Definition: BaseIFFABI.H:546
void copy(const Box &a_intBox, const Interval &a_destInterval, const Box &a_toBox, const BaseIFFAB< T > &a_src, const Interval &a_srcInterval)
Definition: BaseIFFABI.H:291
T Max(const T &a_a, const T &a_b)
Definition: Misc.H:39
Box & grow(int i)
grow functions
Definition: Box.H:2268
void resize(const Box &a_b, int a_n=1, T *a_alias=NULL)
Definition: BaseFabImplem.H:135
T & operator()(const FaceIndex &a_face, const int &varlocin)
Definition: BaseIFFABI.H:424
int end() const
Definition: Interval.H:91
void define(const IntVectSet &a_region, const EBGraph &a_ebgraph, const int &a_direction, const int &a_nvarin)
Definition: BaseIFFABI.H:105
const Box & domainBox() const
Returns the logical computational domain.
Definition: ProblemDomain.H:868
void getBoxAndIVS(Box &a_intBox, IntVectSet &a_ivsIntersect, const Box &a_toBox) const
Definition: BaseIFFABI.H:48
Iterator for an IntVectSet.
Definition: IntVectSet.H:640
void linearIn(T &a_outputT, const void *const inBuf)
Definition: SPMDI.H:26
T * getIndex(const FaceIndex &a_face, const int &a_comp) const
Definition: BaseIFFABI.H:340
const Box & minBox() const
Returns the minimum enclosing box of this IntVectSet.
int numFaces() const
Definition: BaseIFFABI.H:410
const int & cellIndex(const Side::LoHiSide &a_sd) const
bool isEmpty() const
Returns true if no IntVects are in this IntVectSet.
WhichFaces
Definition: FaceIterator.H:45
const EBGraph & getEBGraph() const
Definition: BaseIFFABI.H:73
const IntVectSet & getIVS() const
Definition: BaseIFFABI.H:252