IBAMR  IBAMR version 0.19.
Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes | List of all members
SAMRAI::pdat::OuteredgeData< DIM, TYPE > Class Template Reference

Class OuteredgeData<DIM> provides an implementation for data defined at cell edges on the boundaries of AMR patches. It is derived from the hier::PatchData interface common to all SAMRAI patch data types. Given a CELL-centered AMR index space box, an outeredge data object represents data of some template TYPE and depth on the cell edges on the boundary of the box. Here, depth indicates the number of data values at each edge index location. The OuteredgedgeGeometry class provides the translation between the standard SAMRAI cell-centered AMR index space and outeredge-centered data. More...

#include <OuteredgeData.h>

Inheritance diagram for SAMRAI::pdat::OuteredgeData< DIM, TYPE >:
Inheritance graph
[legend]

Public Member Functions

 OuteredgeData (const hier::Box< DIM > &box, int depth, tbox::Pointer< tbox::Arena > pool=tbox::Pointer< tbox::Arena >(NULL))
 Constructor for an outeredge data object. More...
 
virtual ~OuteredgeData ()
 Virtual destructor for a outeredge data object. More...
 
int getDepth () const
 Return the depth (i.e., the number of data values for each spatial location) of the array. More...
 
bool dataExists (int axis, int face_normal) const
 Returns true if outeredge data exists for the given axis and face normal direction; false otherwise. More...
 
hier::Box< DIM > getDataBox (int axis, int face_normal, int side)
 Return the box of valid edge indices for outeredge data. Note: the returned box will reside in the edge index space. More...
 
TYPE * getPointer (int axis, int face_normal, int side, int depth=0)
 Get a pointer to the beginning of a particular axis, face normal, side, and depth component of the outeredge centered array. More...
 
const TYPE * getPointer (int axis, int face_normal, int side, int depth=0) const
 Get a const pointer to the beginning of a particular axis, face normal, side, and depth component of the outeredge centered array. More...
 
TYPE & operator() (const EdgeIndex< DIM > &i, int depth=0)
 Return a reference to data entry corresponding to a given edge index and depth. More...
 
const TYPE & operator() (const EdgeIndex< DIM > &i, int depth=0) const
 Return a const reference to data entry corresponding to a given edge index and depth. More...
 
ArrayData< DIM, TYPE > & getArrayData (int axis, int face_normal, int side)
 Return a reference to the array data object for given axis, face normal, and side index of the outeredge centered array. More...
 
const ArrayData< DIM, TYPE > & getArrayData (int axis, int face_normal, int side) const
 Return a const reference to the array data object for given axis, face normal, and side index of the outeredge centered array. More...
 
virtual void copy (const hier::PatchData< DIM > &src)
 A fast copy from source to destination (i.e., this) patch data object. More...
 
virtual void copy2 (hier::PatchData< DIM > &dst) const
 A fast copy from source (i.e., this) to destination patch data object. More...
 
virtual void copy (const hier::PatchData< DIM > &src, const hier::BoxOverlap< DIM > &overlap)
 Copy data from source to destination (i.e., this) patch data object on the given overlap. More...
 
virtual void copy2 (hier::PatchData< DIM > &dst, const hier::BoxOverlap< DIM > &overlap) const
 Copy data from source (i.e., this) to destination patch data object on the given overlap. More...
 
void copyDepth (int dst_depth, const EdgeData< DIM, TYPE > &src, int src_depth)
 Fast copy (i.e., assumes edge and outeredge data objects are defined over the same box) from the given edge source data object to this destination outeredge data object at the specified depths. More...
 
void copyDepth2 (int dst_depth, EdgeData< DIM, TYPE > &dst, int src_depth) const
 Fast copy (i.e., assumes edge and outeredge data objects are defined over the same box) to the given edge destination data object from this source outeredge data object at the specified depths. More...
 
virtual void sum (const hier::PatchData< DIM > &src, const hier::BoxOverlap< DIM > &overlap)
 Add data from source to destination (i.e., this) patch data object on the given overlap. More...
 
virtual bool canEstimateStreamSizeFromBox () const
 Return true if the patch data object can estimate the stream size required to fit its data using only index space information (i.e., a box). More...
 
virtual int getDataStreamSize (const hier::BoxOverlap< DIM > &overlap) const
 Return the number of bytes needed to stream the data in this patch data object lying in the specified box overlap region. More...
 
virtual void packStream (tbox::AbstractStream &stream, const hier::BoxOverlap< DIM > &overlap) const
 Pack data in this patch data object lying in the specified box overlap region into the stream. The overlap must be an EdgeOverlap of the same DIM. More...
 
virtual void unpackStream (tbox::AbstractStream &stream, const hier::BoxOverlap< DIM > &overlap)
 Unpack data from stream into this patch data object over the specified box overlap region. The overlap must be an EdgeOverlap of the same DIM. More...
 
virtual void unpackStreamAndSum (tbox::AbstractStream &stream, const hier::BoxOverlap< DIM > &overlap)
 Unpack data from stream and add into this patch data object over the specified box overlap region. More...
 
void fill (const TYPE &t, int d=0)
 Fill all values at depth d with the value t. More...
 
void fill (const TYPE &t, const hier::Box< DIM > &box, int d=0)
 Fill all values at depth d within the box with the value t. More...
 
void fillAll (const TYPE &t)
 Fill all depth components with value t. More...
 
void fillAll (const TYPE &t, const hier::Box< DIM > &box)
 Fill all depth components within the box with value t. More...
 
void print (const hier::Box< DIM > &box, std::ostream &os=tbox::plog, int prec=12) const
 Print all outeredge data values residing in the specified box. If the depth of the array is greater than one, all depths are printed. More...
 
void print (const hier::Box< DIM > &box, int depth, std::ostream &os=tbox::plog, int prec=12) const
 Print all outeredge data values at the given array depth in the specified box. More...
 
void printAxisSide (int axis, int face_normal, int side, const hier::Box< DIM > &box, std::ostream &os=tbox::plog, int prec=12) const
 Print all outeredge centered data values for specified axis, face_normal, and side residing in the specified box. If the depth of the data is greater than one, all depths are printed.
More...
 
void printAxisSide (int axis, int face_normal, int side, const hier::Box< DIM > &box, int depth, std::ostream &os=tbox::plog, int prec=12) const
 Print all outeredge centered data values for specified axis, face_normal, side, and depth residing in the specified box. More...
 
virtual void getSpecializedFromDatabase (tbox::Pointer< tbox::Database > database)
 Check that class version and restart file version are equal.
If so, read data members from the database. More...
 
virtual void putSpecializedToDatabase (tbox::Pointer< tbox::Database > database)
 Write out the class version number and other data members to the database. More...
 
const Box< DIM > & getBox () const
 
const Box< DIM > & getGhostBox () const
 
const IntVector< DIM > & getGhostCellWidth () const
 
void setTime (const double timestamp)
 
double getTime () const
 
virtual void getFromDatabase (tbox::Pointer< tbox::Database > database)
 
virtual void putToDatabase (tbox::Pointer< tbox::Database > database)
 

Static Public Member Functions

static size_t getSizeOfData (const hier::Box< DIM > &box, int depth)
 Calculate the amount of memory needed to represent outeredge- centered data over a CELL-centered AMR index space box. More...
 

Protected Member Functions

void setGhostBox (const Box< DIM > &ghost_box)
 

Private Member Functions

 OuteredgeData (const OuteredgeData< DIM, TYPE > &)
 
void operator= (const OuteredgeData< DIM, TYPE > &)
 

Private Attributes

Box< DIM > d_box
 
Box< DIM > d_ghost_box
 
IntVector< DIM > d_ghosts
 
double d_timestamp
 

Internal implementations for data copy operations.

int d_depth
 
ArrayData< DIM, TYPE > d_data [DIM][DIM][2]
 
void copyFromEdge (const EdgeData< DIM, TYPE > &src)
 
void copyFromEdge (const EdgeData< DIM, TYPE > &src, const EdgeOverlap< DIM > &overlap)
 
void copyToEdge (EdgeData< DIM, TYPE > &dst) const
 
void copyToEdge (EdgeData< DIM, TYPE > &dst, const EdgeOverlap< DIM > &overlap) const
 
void copyFromOuteredge (const OuteredgeData< DIM, TYPE > &src)
 
void copyFromOuteredge (const OuteredgeData< DIM, TYPE > &src, const EdgeOverlap< DIM > &overlap)
 
void copyToOuteredge (OuteredgeData< DIM, TYPE > &dst) const
 
void copyToOuteredge (OuteredgeData< DIM, TYPE > &dst, const EdgeOverlap< DIM > &overlap) const
 

Detailed Description

template<int DIM, class TYPE>
class SAMRAI::pdat::OuteredgeData< DIM, TYPE >

Outeredge data is stored in 2*DIM*(DIM-2) arrays, each of which contains data associated with edge indices in a coordinate axis direction, an outward pointing face normal direction, and an upper or lower box face in the face normal direction. The data layout in the outernode data arrays matches the corresponding array sections provided by the node data implementation. Note that outeredge data is NOT defined when the axis and face normal are equal.
This is consistent with the edge data representation. Where an edge index falls on more than one box face (patch boundary edges and corners), the outeredge data value belongs to only one data array so that there are no redundant data values. Specifically, when DIM > 2, outeredge data boxes are "trimmed" for each axis edge direction so that each edge index that lives on more than one face on the box boundary will be associated with the largest face normal direction and only that face. Within each array, data is stored in
(i,...,k,d) order, where i,...,k indicates a spatial index and the d indicates the component depth at that location. Memory allocation is in column-major ordering (e.g., Fortran style) so that the leftmost index runs fastest in memory.

To illustrate the outeredge data layout, in particular the "box trimming" that prevents redundant data values, we describe the data for a three-dimensional outeredge data object instantiated over a box [l0:u0,l1:u1,l2:u2] in the standard SAMRAI cell-centered AMR index space. Note: no boxes are trimmed when DIM < 3.

     a = edge axis (corresponds to the standard EdgeData axis)
     f = face normal dir
     s = lower/upper face
     d = data depth (i.e., number of values at each edge index point).
 
     Here axis and face normal values 0, 1, and 2 can be thought of as X, Y, Z 
     respectively.
 
         (a,f,s)
     axis 0:
         (0,0,[0,1])  DATA IS NOT DEFINED when a == f
         (0,1,0)      [l0:u0, l1:l1,     l2+1:u2,   d]
         (0,1,1)      [l0:u0, u1+1:u1+1, l2+1:u2,   d]
         (0,2,0)      [l0:u0, l1:u1+1,   l2:l2,     d]
         (0,2,1)      [l0:u0, l1:u1+1,   u2+1:u2+1, d]
         Note: Edge indices are duplicated at the intersection of faces normal
               to directions 1 and 2.
               So boxes for face normal direction 1 are trimmed in direction 2
               so that edge indices shared with faces in direction 2 only
               appear in face normal direction 2 boxes.
 
     axis 1:
         (1,0,0)      [l0:l0,     l1:u1, l2+1:u2,   d]
         (1,0,1)      [u0+1:u0+1, l1:u1, l2+1:u2,   d]
         (1,1,[0,1])  DATA IS NOT DEFINED when a == f
         (1,2,0)      [l0:u0+1,   l1:u1, l2:l2,     d]
         (1,2,1)      [l0:u0+1,   l1:u1, u2+1:u2+1, d]
         Note: Edge indices are duplicated at the intersection of faces normal
               to directions 0 and 2.
               So boxes for face normal direction 0 are trimmed in direction 2
               so that edge indices shared with faces in direction 2 only
               appear in face normal direction 2 boxes.
 
     axis 2:
         (2,0,0)      [l0:l0,     l1+1:u1,   l2:u2, d]
         (2,0,1)      [u0+1:u0+1, l1+1:u1,   l2:u2, d]
         (2,1,0)      [l0:u0+1,   l1:l1,     l2:u2, d]
         (2,1,1)      [l0:u0+1,   u1+1:u1+1, l2:u2, d]
         (2,2,[0,1])  DATA IS NOT DEFINED when a == f
         Note: Edge indices are duplicated at the intersection of faces normal
               to directions 0 and 1.
               So boxes for face normal direction 0 are trimmed in direction 1
               so that edge indices shared with faces in direction 1 only
               appear in face normal direction 1 boxes.
 
* 

Other spatial dimensions are represented similarly.

The data type TYPE must define a default constructor (that takes no arguments) and also the assignment operator.

See also
pdat::ArrayData
hier::PatchData
pdat::OuteredgeDataFactory
pdat::OuteredgeGeometry
pdat::EdgeIterator
pdat::EdgeIndex

Constructor & Destructor Documentation

◆ OuteredgeData() [1/2]

template<int DIM, class TYPE >
SAMRAI::pdat::OuteredgeData< DIM, TYPE >::OuteredgeData ( const hier::Box< DIM > &  box,
int  depth,
tbox::Pointer< tbox::Arena pool = tbox::Pointertbox::Arena >(NULL) 
)

Note: Outeredge data always has ghost cell width of zero.

Parameters
boxconst Box reference describing the interior of the standard CELL-centered index box over which the outeredge data object will be created.
depthgives the number of data values for each spatial location in the array.
poolmemory arena. If not given, then the standard arena is used.

◆ ~OuteredgeData()

template<int DIM, class TYPE >
virtual SAMRAI::pdat::OuteredgeData< DIM, TYPE >::~OuteredgeData ( )
virtual

◆ OuteredgeData() [2/2]

template<int DIM, class TYPE >
SAMRAI::pdat::OuteredgeData< DIM, TYPE >::OuteredgeData ( const OuteredgeData< DIM, TYPE > &  )
private

Member Function Documentation

◆ getSizeOfData()

template<int DIM, class TYPE >
static size_t SAMRAI::pdat::OuteredgeData< DIM, TYPE >::getSizeOfData ( const hier::Box< DIM > &  box,
int  depth 
)
static

This function assumes that the amount of memory needed for TYPE is sizeof(TYPE). If this is not the case, then a specialized function must be defined.

Parameters
boxconst Box reference describing the interior of the standard CELL-centered index box over which the outeredge data object will be created. Note: the ghost cell width is assumed to be zero.
depthgives the number of data values for each spatial location in the array.

◆ getDepth()

template<int DIM, class TYPE >
int SAMRAI::pdat::OuteredgeData< DIM, TYPE >::getDepth ( ) const

◆ dataExists()

template<int DIM, class TYPE >
bool SAMRAI::pdat::OuteredgeData< DIM, TYPE >::dataExists ( int  axis,
int  face_normal 
) const
Parameters
axisinteger edge data coordinate axis, must satisfy 0 <= axis < DIM
face_normalinteger face normal direction for data, must satisfy 0 <= face_normal < DIM

◆ getDataBox()

template<int DIM, class TYPE >
hier::Box<DIM> SAMRAI::pdat::OuteredgeData< DIM, TYPE >::getDataBox ( int  axis,
int  face_normal,
int  side 
)
Parameters
axisinteger edge data coordinate axis, must satisfy 0 <= axis < DIM
face_normalinteger face normal direction for data, must satisfy 0 <= face_normal < DIM
sideinteger lower (0) or upper (1) side of outeredge data array

◆ getPointer() [1/2]

template<int DIM, class TYPE >
TYPE* SAMRAI::pdat::OuteredgeData< DIM, TYPE >::getPointer ( int  axis,
int  face_normal,
int  side,
int  depth = 0 
)
Parameters
axisinteger edge data coordinate axis, must satisfy 0 <= axis < DIM
face_normalinteger face normal direction for data, must satisfy 0 <= face_normal < DIM
sideinteger lower (0) or upper (1) side of outeredge data array
depthinteger depth component, must satisfy 0 <= depth < actual depth of data array

◆ getPointer() [2/2]

template<int DIM, class TYPE >
const TYPE* SAMRAI::pdat::OuteredgeData< DIM, TYPE >::getPointer ( int  axis,
int  face_normal,
int  side,
int  depth = 0 
) const
Parameters
axisinteger edge data coordinate axis, must satisfy 0 <= axis < DIM
face_normalinteger face normal direction for data, must satisfy 0 <= face_normal < DIM
sideinteger lower (0) or upper (1) side of outeredge data array
depthinteger depth component, must satisfy 0 <= depth < actual depth of data array

◆ operator()() [1/2]

template<int DIM, class TYPE >
TYPE& SAMRAI::pdat::OuteredgeData< DIM, TYPE >::operator() ( const EdgeIndex< DIM > &  i,
int  depth = 0 
)
Parameters
iconst reference to EdgeIndex, MUST be an index on the outeredge of the box.
depthinteger depth component, must satisfy 0 <= depth < actual depth of data array

◆ operator()() [2/2]

template<int DIM, class TYPE >
const TYPE& SAMRAI::pdat::OuteredgeData< DIM, TYPE >::operator() ( const EdgeIndex< DIM > &  i,
int  depth = 0 
) const
Parameters
iconst reference to EdgeIndex, MUST be an index on the outeredge of the box.
depthinteger depth component, must satisfy 0 <= depth < actual depth of data array

◆ getArrayData() [1/2]

template<int DIM, class TYPE >
ArrayData<DIM,TYPE>& SAMRAI::pdat::OuteredgeData< DIM, TYPE >::getArrayData ( int  axis,
int  face_normal,
int  side 
)
Parameters
axisinteger edge data coordinate axis, must satisfy 0 <= axis < DIM
face_normalinteger face normal direction for data, must satisfy 0 <= face_normal < DIM
sideinteger lower (0) or upper (1) side of outeredge data array

◆ getArrayData() [2/2]

template<int DIM, class TYPE >
const ArrayData<DIM,TYPE>& SAMRAI::pdat::OuteredgeData< DIM, TYPE >::getArrayData ( int  axis,
int  face_normal,
int  side 
) const
Parameters
axisinteger edge data coordinate axis, must satisfy 0 <= axis < DIM
face_normalinteger face normal direction for data, must satisfy 0 <= face_normal < DIM
sideinteger lower (0) or upper (1) side of outeredge data array

◆ copy() [1/2]

template<int DIM, class TYPE >
virtual void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::copy ( const hier::PatchData< DIM > &  src)
virtual

Data is copied where there is overlap in the underlying index space. The copy is performed on the interior plus the ghost cell width (for both the source and destination). Currently, source data must be either EdgeData or OuteredgeData of the same DIM and TYPE. If not, then an unrecoverable error results.

Implements SAMRAI::hier::PatchData< DIM >.

◆ copy2() [1/2]

template<int DIM, class TYPE >
virtual void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::copy2 ( hier::PatchData< DIM > &  dst) const
virtual

Data is copied where there is overlap in the underlying index space. The copy is performed on the interior plus the ghost cell width (for both the source and destination). Currently, destination data must be either EdgeData or OuteredgeData of the same DIM and TYPE. If not, then an unrecoverable error results.

Implements SAMRAI::hier::PatchData< DIM >.

◆ copy() [2/2]

template<int DIM, class TYPE >
virtual void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::copy ( const hier::PatchData< DIM > &  src,
const hier::BoxOverlap< DIM > &  overlap 
)
virtual

Currently, source data must be either EdgeData or OuteredgeData of the same DIM and TYPE and the overlap must be an EdgeOverlap of the same DIM. If not, then an unrecoverable error results.

Implements SAMRAI::hier::PatchData< DIM >.

◆ copy2() [2/2]

template<int DIM, class TYPE >
virtual void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::copy2 ( hier::PatchData< DIM > &  dst,
const hier::BoxOverlap< DIM > &  overlap 
) const
virtual

Currently, destination data must be either EdgeData or OuteredgeData of the same DIM and TYPE and the overlap must be an EdgeOverlap of the same DIM. If not, then an unrecoverable error results.

Implements SAMRAI::hier::PatchData< DIM >.

◆ copyDepth()

template<int DIM, class TYPE >
void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::copyDepth ( int  dst_depth,
const EdgeData< DIM, TYPE > &  src,
int  src_depth 
)

◆ copyDepth2()

template<int DIM, class TYPE >
void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::copyDepth2 ( int  dst_depth,
EdgeData< DIM, TYPE > &  dst,
int  src_depth 
) const

◆ sum()

template<int DIM, class TYPE >
virtual void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::sum ( const hier::PatchData< DIM > &  src,
const hier::BoxOverlap< DIM > &  overlap 
)
virtual

Currently, source data must be OuteredgeData of the same DIM and TYPE and the overlap must be an EdgeOverlap of the same DIM.
If not, then an unrecoverable error results.

◆ canEstimateStreamSizeFromBox()

template<int DIM, class TYPE >
virtual bool SAMRAI::pdat::OuteredgeData< DIM, TYPE >::canEstimateStreamSizeFromBox ( ) const
virtual

This routine is defined for the standard types (bool, char, double, float, int, and dcomplex).

Implements SAMRAI::hier::PatchData< DIM >.

◆ getDataStreamSize()

template<int DIM, class TYPE >
virtual int SAMRAI::pdat::OuteredgeData< DIM, TYPE >::getDataStreamSize ( const hier::BoxOverlap< DIM > &  overlap) const
virtual

This routine is defined for the standard types (bool, char, double, float, int, and dcomplex).

Implements SAMRAI::hier::PatchData< DIM >.

◆ packStream()

template<int DIM, class TYPE >
virtual void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::packStream ( tbox::AbstractStream stream,
const hier::BoxOverlap< DIM > &  overlap 
) const
virtual

◆ unpackStream()

template<int DIM, class TYPE >
virtual void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::unpackStream ( tbox::AbstractStream stream,
const hier::BoxOverlap< DIM > &  overlap 
)
virtual

◆ unpackStreamAndSum()

template<int DIM, class TYPE >
virtual void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::unpackStreamAndSum ( tbox::AbstractStream stream,
const hier::BoxOverlap< DIM > &  overlap 
)
virtual

◆ fill() [1/2]

template<int DIM, class TYPE >
void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::fill ( const TYPE &  t,
int  d = 0 
)

◆ fill() [2/2]

template<int DIM, class TYPE >
void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::fill ( const TYPE &  t,
const hier::Box< DIM > &  box,
int  d = 0 
)

◆ fillAll() [1/2]

template<int DIM, class TYPE >
void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::fillAll ( const TYPE &  t)

◆ fillAll() [2/2]

template<int DIM, class TYPE >
void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::fillAll ( const TYPE &  t,
const hier::Box< DIM > &  box 
)

◆ print() [1/2]

template<int DIM, class TYPE >
void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::print ( const hier::Box< DIM > &  box,
std::ostream &  os = tbox::plog,
int  prec = 12 
) const
Parameters
boxconst reference to box over whioch to print data. Note box is assumed to reside in standard cell-centered index space and will be converted to edge index space.
osreference to output stream.
precinteger precision for printing floating point numbers (i.e., TYPE = float, double, or dcomplex). The default is 12 decimal places for double and complex floating point numbers, and the default is 6 decimal places floats. For other types, this value is ignored.

◆ print() [2/2]

template<int DIM, class TYPE >
void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::print ( const hier::Box< DIM > &  box,
int  depth,
std::ostream &  os = tbox::plog,
int  prec = 12 
) const
Parameters
boxconst reference to box over whioch to print data. Note box is assumed to reside in standard cell-centered index space and will be converted to edge index space.
depthinteger depth component, must satisfy 0 <= depth < actual depth of data array
osreference to output stream.
precinteger precision for printing floating point numbers (i.e., TYPE = float, double, or dcomplex). The default is 12 decimal places for double and complex floating point numbers, and the default is 6 decimal places floats. For other types, this value is ignored.

◆ printAxisSide() [1/2]

template<int DIM, class TYPE >
void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::printAxisSide ( int  axis,
int  face_normal,
int  side,
const hier::Box< DIM > &  box,
std::ostream &  os = tbox::plog,
int  prec = 12 
) const
Parameters
axisinteger edge data coordinate axis, must satisfy 0 <= axis < DIM
face_normalinteger face normal direction for data, must satisfy 0 <= face_normal < DIM
sideinteger lower (0) or upper (1) side of outeredge data array
boxconst reference to box over whioch to print data. Note box is assumed to reside in standard cell-centered index space and will be converted to edge index space.
osreference to output stream.
precinteger precision for printing floating point numbers (i.e., TYPE = float, double, or dcomplex). The default is 12 decimal places for double and complex floating point numbers, and the default is 6 decimal places floats. For other types, this value is ignored.

◆ printAxisSide() [2/2]

template<int DIM, class TYPE >
void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::printAxisSide ( int  axis,
int  face_normal,
int  side,
const hier::Box< DIM > &  box,
int  depth,
std::ostream &  os = tbox::plog,
int  prec = 12 
) const
Parameters
axisinteger edge data coordinate axis, must satisfy 0 <= axis < DIM
face_normalinteger face normal direction for data, must satisfy 0 <= face_normal < DIM
sideinteger lower (0) or upper (1) side of outeredge data array
boxconst reference to box over whioch to print data. Note box is assumed to reside in standard cell-centered index space and will be converted to edge index space.
depthinteger depth component, must satisfy 0 <= depth < actual depth of data array
osreference to output stream.
precinteger precision for printing floating point numbers (i.e., TYPE = float, double, or dcomplex). The default is 12 decimal places for double and complex floating point numbers, and the default is 6 decimal places floats. For other types, this value is ignored.

◆ getSpecializedFromDatabase()

template<int DIM, class TYPE >
virtual void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::getSpecializedFromDatabase ( tbox::Pointer< tbox::Database database)
virtual

Assertions: database must be a non-null pointer.

Implements SAMRAI::hier::PatchData< DIM >.

◆ putSpecializedToDatabase()

template<int DIM, class TYPE >
virtual void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::putSpecializedToDatabase ( tbox::Pointer< tbox::Database database)
virtual

Assertions: database must be a non-null pointer.

Implements SAMRAI::hier::PatchData< DIM >.

◆ operator=()

template<int DIM, class TYPE >
void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::operator= ( const OuteredgeData< DIM, TYPE > &  )
private

◆ copyFromEdge() [1/2]

template<int DIM, class TYPE >
void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::copyFromEdge ( const EdgeData< DIM, TYPE > &  src)
private

◆ copyFromEdge() [2/2]

template<int DIM, class TYPE >
void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::copyFromEdge ( const EdgeData< DIM, TYPE > &  src,
const EdgeOverlap< DIM > &  overlap 
)
private

◆ copyToEdge() [1/2]

template<int DIM, class TYPE >
void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::copyToEdge ( EdgeData< DIM, TYPE > &  dst) const
private

◆ copyToEdge() [2/2]

template<int DIM, class TYPE >
void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::copyToEdge ( EdgeData< DIM, TYPE > &  dst,
const EdgeOverlap< DIM > &  overlap 
) const
private

◆ copyFromOuteredge() [1/2]

template<int DIM, class TYPE >
void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::copyFromOuteredge ( const OuteredgeData< DIM, TYPE > &  src)
private

◆ copyFromOuteredge() [2/2]

template<int DIM, class TYPE >
void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::copyFromOuteredge ( const OuteredgeData< DIM, TYPE > &  src,
const EdgeOverlap< DIM > &  overlap 
)
private

◆ copyToOuteredge() [1/2]

template<int DIM, class TYPE >
void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::copyToOuteredge ( OuteredgeData< DIM, TYPE > &  dst) const
private

◆ copyToOuteredge() [2/2]

template<int DIM, class TYPE >
void SAMRAI::pdat::OuteredgeData< DIM, TYPE >::copyToOuteredge ( OuteredgeData< DIM, TYPE > &  dst,
const EdgeOverlap< DIM > &  overlap 
) const
private

◆ getBox()

template<int DIM>
const Box<DIM>& SAMRAI::hier::PatchData< DIM >::getBox ( ) const
inherited

Return the box over which this patch data object is defined. All objects in the same patch are defined over the same box, although the patch data objects may interpret how to allocate storage for that box in different ways.

◆ getGhostBox()

template<int DIM>
const Box<DIM>& SAMRAI::hier::PatchData< DIM >::getGhostBox ( ) const
inherited

Return the ghost cell box. The ghost cell box is defined to be the interior box grown by the ghost cell width.

◆ getGhostCellWidth()

template<int DIM>
const IntVector<DIM>& SAMRAI::hier::PatchData< DIM >::getGhostCellWidth ( ) const
inherited

Get the ghost cell width associated with this patch data object.

◆ setTime()

template<int DIM>
void SAMRAI::hier::PatchData< DIM >::setTime ( const double  timestamp)
inherited

Set the simulation time stamp for the patch data type. The simulation time is initialized to zero when the patch data type is created.

◆ getTime()

template<int DIM>
double SAMRAI::hier::PatchData< DIM >::getTime ( ) const
inherited

Get the simulation time stamp for the patch data type.

◆ getFromDatabase()

template<int DIM>
virtual void SAMRAI::hier::PatchData< DIM >::getFromDatabase ( tbox::Pointer< tbox::Database database)
virtualinherited

Checks that class version and restart file version are equal. If so, reads in the data members common to all patch data types from database. This method then calls the getSpecializedFromDatabase() method to retrieve the data special to the concrete patch data type.

◆ putToDatabase()

template<int DIM>
virtual void SAMRAI::hier::PatchData< DIM >::putToDatabase ( tbox::Pointer< tbox::Database database)
virtualinherited

Writes out the class version number to the database. Then, writes the data members common to all patch data types from database. After the common data is written to the database, the putSpecializedToDatabase() method is invoked.

◆ setGhostBox()

template<int DIM>
void SAMRAI::hier::PatchData< DIM >::setGhostBox ( const Box< DIM > &  ghost_box)
protectedinherited

This protected method is used by concrete patch data subclasses to set the ghost box over which the patch data will be allocated. Note that this allows the ghost box to be inconsistant with its standard interpretation as the patch domain box grown by the ghost cell width (as set in the constructor).

This function is included to treat some special cases for concrete patch data types and should be used with caution.

Member Data Documentation

◆ d_depth

template<int DIM, class TYPE >
int SAMRAI::pdat::OuteredgeData< DIM, TYPE >::d_depth
private

◆ d_data

template<int DIM, class TYPE >
ArrayData<DIM,TYPE> SAMRAI::pdat::OuteredgeData< DIM, TYPE >::d_data[DIM][DIM][2]
private

◆ d_box

template<int DIM>
Box<DIM> SAMRAI::hier::PatchData< DIM >::d_box
privateinherited

◆ d_ghost_box

template<int DIM>
Box<DIM> SAMRAI::hier::PatchData< DIM >::d_ghost_box
privateinherited

◆ d_ghosts

template<int DIM>
IntVector<DIM> SAMRAI::hier::PatchData< DIM >::d_ghosts
privateinherited

◆ d_timestamp

template<int DIM>
double SAMRAI::hier::PatchData< DIM >::d_timestamp
privateinherited

The documentation for this class was generated from the following file: