Chombo + EB + MF  3.2
Public Member Functions | Protected Member Functions | Private Member Functions | List of all members
CFArrayBox Class Reference

#include <CFArrayBox.H>

Inheritance diagram for CFArrayBox:
Inheritance graph
[legend]

Public Member Functions

 CFArrayBox ()
 
 CFArrayBox (const Box &a_box, int a_ncomp, Complex *a_alias=NULL)
 
 CFArrayBox (const Interval &a_comps, CFArrayBox &a_original)
 
virtual void define (const Box &a_box, int a_ncomp, Complex *a_alias=NULL)
 
virtual ~CFArrayBox ()
 
 CFArrayBox (CFArrayBox &&a_in)=default
 
CFArrayBoxoperator= (CFArrayBox &&a_in)=default
 
virtual void define (const Interval &a_comps, CFArrayBox &a_original)
 
virtual void define (const Interval &a_comps, BaseFab< Complex > &a_original)
 
 CFArrayBox (std::istream &a_is)
 
virtual Real norm (const Box &a_subbox, int a_p=2, int a_comp=0, int a_numcomp=1) const
 
virtual Real norm (int a_p=2, int a_comp=0, int a_numcomp=1) const
 
virtual Complex sumPow (const Box &a_subbox, int a_p=2, int a_comp=0, int a_numcomp=1) const
 
Complex dotProduct (const CFArrayBox &a_fab2) const
 Return the dot product of this CFArrayBox with another. More...
 
Complex dotProduct (const CFArrayBox &a_fab2, const Box &a_box) const
 Return the dot product of this CFArrayBox with another. More...
 
void abs ()
 
void abs (int a_comp, int a_numcomp=1)
 
void abs (const Box &a_subbox, int a_comp=0, int a_numcomp=1)
 
Complex sum (int a_comp, int a_numcomp=1) const
 
Complex sum (const Box &a_subbox, int a_comp, int a_numcomp=1) const
 
CFArrayBoxinvert (Complex a_r)
 
CFArrayBoxinvert (Complex a_r, int a_comp, int a_numcomp=1)
 
CFArrayBoxinvert (Complex a_r, const Box &a_subbox, int a_comp=0, int a_numcomp=1)
 
CFArrayBoxnegate (const Box &a_subbox, int a_comp=0, int a_numcomp=1)
 
CFArrayBoxnegate (int a_comp, int a_numcomp=1)
 
CFArrayBoxnegate ()
 
CFArrayBoxplus (Complex a_r, const Box &a_subbox, int a_comp=0, int a_numcomp=1)
 
CFArrayBoxplus (Complex a_r, int a_comp, int a_numcomp=1)
 
CFArrayBoxoperator+= (Complex a_r)
 
CFArrayBoxoperator+= (const CFArrayBox &a_x)
 
CFArrayBoxplus (Complex a_r)
 
CFArrayBoxplus (const CFArrayBox &a_x)
 
CFArrayBoxplus (const CFArrayBox &a_src, const Complex &a_scale)
 
CFArrayBoxplus (const CFArrayBox &a_src, const Complex &a_scale, int a_srccomp, int a_destcomp, int a_numcomp=1)
 
CFArrayBoxplus (const CFArrayBox &a_src, int a_srccomp, int a_destcomp, int a_numcomp=1)
 
CFArrayBoxplus (const CFArrayBox &a_src, const Box &a_subbox, int a_srccomp, int a_destcomp, int a_numcomp=1)
 
CFArrayBoxplus (const CFArrayBox &a_src, const Box &a_srcbox, const Box &a_destbox, int a_srccomp, int a_destcomp, int a_numcomp=1)
 
CFArrayBoxplus (const CFArrayBox &a_src, const Box &a_srcbox, const Box &a_destbox, const Complex &a_scale, int a_srccomp, int a_destcomp, int a_numcomp=1)
 
CFArrayBoxoperator-= (Complex a_r)
 
CFArrayBoxoperator-= (const CFArrayBox &a_x)
 
CFArrayBoxminus (const CFArrayBox &a_x)
 
CFArrayBoxminus (const CFArrayBox &a_src, int a_srccomp, int a_destcomp, int a_numcomp=1)
 
CFArrayBoxminus (const CFArrayBox &a_src, const Box &a_subbox, int a_srccomp, int a_destcomp, int a_numcomp=1)
 
CFArrayBoxminus (const CFArrayBox &a_src, const Box &a_srcbox, const Box &a_destbox, int a_srccomp, int a_destcomp, int a_numcomp=1)
 
CFArrayBoxoperator*= (Complex a_r)
 
CFArrayBoxmult (Complex a_r)
 
CFArrayBoxmult (Complex a_r, int a_comp, int a_numcomp=1)
 
CFArrayBoxmult (Complex a_r, const Box &a_subbox, int a_comp=0, int a_numcomp=1)
 
CFArrayBoxoperator*= (const CFArrayBox &a_x)
 
CFArrayBoxmult (const CFArrayBox &a_x)
 
CFArrayBoxmult (const CFArrayBox &a_src, int a_srccomp, int a_destcomp, int a_numcomp=1)
 
CFArrayBoxmult (const CFArrayBox &a_src, const Box &a_subbox, int a_srccomp, int a_destcomp, int a_numcomp=1)
 
CFArrayBoxmult (const CFArrayBox &a_src, const Box &a_srcbox, const Box &a_destbox, int a_srccomp, int a_destcomp, int a_numcomp=1)
 
CFArrayBoxmult (const BaseFab< Real > &a_r)
 
CFArrayBoxmult (const BaseFab< Real > &a_r, const Box &a_box)
 
CFArrayBoxoperator/= (Complex a_r)
 
CFArrayBoxdivide (Complex a_r)
 
CFArrayBoxdivide (Complex a_r, int a_comp, int a_numcomp=1)
 
CFArrayBoxdivide (Complex a_r, const Box &a_subbox, int a_comp=0, int a_numcomp=1)
 
CFArrayBoxoperator/= (const CFArrayBox &a_x)
 
CFArrayBoxdivide (const CFArrayBox &a_x)
 
CFArrayBoxdivide (const CFArrayBox &a_src, int a_srccomp, int a_destcomp, int a_numcomp=1)
 
CFArrayBoxdivide (const CFArrayBox &a_src, const Box &a_subbox, int a_srccomp, int a_destcomp, int a_numcomp=1)
 
CFArrayBoxdivide (const CFArrayBox &a_src, const Box &a_srcbox, const Box &a_destbox, int a_srccomp, int a_destcomp, int a_numcomp=1)
 
Complex get (const IntVect &a_iv, int a_comp) const
 
void set (const IntVect &a_iv, int a_comp, Complex a_val)
 
CFArrayBoxaxby (const CFArrayBox &a_X, const CFArrayBox &a_Y, Complex a_A, Complex a_B)
 Computes a_A * a_X + a_B * a_Y, placing the result in this CFArrayBox. More...
 
CFArrayBoxaxby (const CFArrayBox &a_X, const CFArrayBox &a_Y, Complex a_A, Complex a_B, int a_destComp, int a_xComp, int a_yComp)
 
- Public Member Functions inherited from BaseFab< Complex >
virtual long offset (const IntVect &a_iv, const int &a_ivar) const
 { constructors, destructor and defines} More...
 
 BaseFab ()
 
 BaseFab (const Box &a_bx, int a_n, Complex *a_alias=NULL)
 
 BaseFab (const Interval &a_comps, BaseFab< Complex > &a_original)
 
 BaseFab (BaseFab< Complex > &&a_in) noexcept
 move constructor More...
 
virtual ~BaseFab ()
 
void resize (const Box &a_b, int a_n=1, Complex *a_alias=NULL)
 
void clear ()
 
int nComp () const
 { accessors} More...
 
const Boxbox () const
 
IntVect size () const
 
virtual size_t size (const Box &a_box, const Interval &a_comps) const
 { linearization functions} More...
 
const IntVectsmallEnd () const
 
const IntVectbigEnd () const
 
Interval interval () const
 
BaseFab< Complex > & operator= (BaseFab< Complex > &&) noexcept
 move assignment More...
 
Complex & operator() (const IntVect &a_p, int a_N)
 
Complex & operator() (const IntVect &a_p)
 
const Complex & operator() (const IntVect &p, int N) const
 
const Complex & operator() (const IntVect &p) const
 
void getVal (Complex *a_data, const IntVect &a_pos, int a_N, int a_numcomp) const
 
void getVal (Complex *a_data, const IntVect &a_pos) const
 
const int * loVect () const
 { Fortran interface functions} More...
 
const int * hiVect () const
 
const int * nCompPtr () const
 
Complex * dataPtr (int a_n=0)
 
const Complex * dataPtr (int a_n=0) const
 
bool contains (const BaseFab< Complex > &a_fab) const
 { comparison functions} More...
 
bool contains (const Box &a_bx) const
 
void setVal (Complex a_x, const Box &a_bx, int a_nstart, int a_numcomp)
 { data modification functions} More...
 
void setVal (Complex a_x, const Box &a_bx, int a_n)
 
void setVal (Complex a_x, int a_n)
 
void setVal (Complex a_x)
 
BaseFab< Complex > & copy (const BaseFab< Complex > &a_src, const Box &a_srcbox, int a_srccomp, const Box &a_destbox, int a_destcomp, int a_numcomp)
 
BaseFab< Complex > & copy (const BaseFab< Complex > &a_src, int a_srccomp, int a_destcomp, int a_numcomp=1)
 
BaseFab< Complex > & copy (const BaseFab< Complex > &a_src, const Box &a_destbox)
 
BaseFab< Complex > & copy (const BaseFab< Complex > &a_src)
 
void copy (const Box &a_RegionFrom, const Interval &a_Cdest, const Box &a_RegionTo, const BaseFab< Complex > &a_src, const Interval &a_Csrc)
 
BaseFab< Complex > & shift (const IntVect &a_v)
 { domain modification functions} More...
 
BaseFab< Complex > & shift (int a_idir, int a_ncells)
 
BaseFab< Complex > & shiftHalf (int a_dir, int a_numHalfs)
 
BaseFab< Complex > & shiftHalf (const IntVect &a_v)
 
virtual void linearOut (void *a_buf, const Box &a_R, const Interval &a_comps) const
 
void linearOut (void *a_buf) const
 These functions are required for broadcast & gather. More...
 
virtual void * linearOut2 (void *a_buf, const Box &a_R, const Interval &a_comps) const
 Same as linearOut, but returns the current location in the buffer. More...
 
virtual void linearIn (void *a_buf, const Box &a_R, const Interval &a_comps)
 
void linearIn (const void *const a_buf)
 
virtual void * linearIn2 (void *a_buf, const Box &a_R, const Interval &a_comps)
 same as linearIn, but returns the current location in the buffer More...
 
int linearSize (void) const
 
void degenerate (BaseFab< Complex > &a_slice, const SliceSpec &a_sliceSpec) const
 
bool isAliased () const
 
bool isUsable () const
 

Protected Member Functions

virtual void performCopy (const BaseFab< Complex > &a_src, const Box &a_srcbox, int a_srccomp, const Box &a_destbox, int a_destcomp, int a_numcomp)
 
- Protected Member Functions inherited from BaseFab< Complex >
void define ()
 
void undefine ()
 
void performSetVal (Complex a_x, const Box &a_bx, int a_nstart, int a_numcomp)
 

Private Member Functions

 CFArrayBox (const CFArrayBox &)
 
CFArrayBoxoperator= (const CFArrayBox &)
 

Additional Inherited Members

- Static Public Member Functions inherited from BaseFab< Complex >
static int preAllocatable ()
 
static int test ()
 regression test More...
 
static int testBoxAndComp ()
 regression test More...
 
- Static Protected Member Functions inherited from BaseFab< Complex >
static std::string name ()
 
- Protected Attributes inherited from BaseFab< Complex >
Box m_domain
 
int m_nvar
 
long m_numpts
 
long m_truesize
 
Complex *__restrict m_dptr
 
bool m_aliased
 
- Static Protected Attributes inherited from BaseFab< Complex >
static Arenas_Arena
 

Detailed Description

Complex Fortran Array Boxes (generally called CFArrayBoxs) are objects constructed to interface with arrays in Fortran. Useful operations can be performed upon FABs in C++, and they provide a convenient interface to Fortran when it is necessary to retreat into that language for doing arithmetic operations when performance matters.

CFArrayBox is derived from BaseFab<Complex>. CFArrayBox adds additional useful capabilities which make sense for Complex types, such as I/O and L**p norms.

The C pre-processor macro `CH_SPACEDIM' must be defined to use this class. The internal precision of CFArrayBox objects is set by defining either `CH_USE_FLOAT' or `CH_USE_DOUBLE'

This class does NOT provide a copy constructor or assignment operator.

Constructor & Destructor Documentation

◆ CFArrayBox() [1/6]

CFArrayBox::CFArrayBox ( )

Constructs an invalid CFArrayBox with no memory.

Referenced by define(), and set().

◆ CFArrayBox() [2/6]

CFArrayBox::CFArrayBox ( const Box a_box,
int  a_ncomp,
Complex *  a_alias = NULL 
)

Constructs an initial CFArrayBox with the data space allocated but not inititialized. a_ncomp is the number of components (variables) at each data point in the Box.

◆ CFArrayBox() [3/6]

CFArrayBox::CFArrayBox ( const Interval a_comps,
CFArrayBox a_original 
)
inline

Construct an aliaed CFArrayBox. See BaseFab class for details.

◆ ~CFArrayBox()

virtual CFArrayBox::~CFArrayBox ( )
virtual

Defines CFArrayBox with the data space allocated but not inititialized. a_ncomp is the number of components (variables) at each data point in the Box. The (virtual) destructor.

Referenced by define().

◆ CFArrayBox() [4/6]

CFArrayBox::CFArrayBox ( CFArrayBox &&  a_in)
default

◆ CFArrayBox() [5/6]

CFArrayBox::CFArrayBox ( std::istream &  a_is)
explicit

Constructs CFArrayBox by reading it from istream.

◆ CFArrayBox() [6/6]

CFArrayBox::CFArrayBox ( const CFArrayBox )
private

Member Function Documentation

◆ define() [1/3]

virtual void CFArrayBox::define ( const Box a_box,
int  a_comps,
Complex *  a_alias = NULL 
)
inlinevirtual

Make BaseFab with desired domain and number of components. Existing data is lost. Data is in uninialized state.

Reimplemented from BaseFab< Complex >.

References CFArrayBox(), BaseFab< T >::define(), operator=(), and ~CFArrayBox().

◆ operator=() [1/2]

CFArrayBox& CFArrayBox::operator= ( CFArrayBox &&  a_in)
default

Referenced by define(), and set().

◆ define() [2/3]

virtual void CFArrayBox::define ( const Interval a_comps,
CFArrayBox a_original 
)
inlinevirtual

Constructs an 'aliased' BaseFab of the requested interval of the argument BaseFab. This BaseFab does not allocate any memory, but sets its data pointer into the memory pointed to by the argument BaseFab. It is the users responsiblity to ensure this aliased BaseFab is not used after the original BaseFab has deleted its data ptr (resize, define(..) called, or destruction, etc.).

This aliased BaseFab will also generate side effects (modifying the values of data in one will modify the other's data).

This aliased BaseFab will have a_comps.size() components, starting at zero.

References BaseFab< T >::define().

◆ define() [3/3]

virtual void CFArrayBox::define ( const Interval a_comps,
BaseFab< Complex > &  a_original 
)
inlinevirtual

This is here only to make the Intel compiler stop warning about partial override.

Reimplemented from BaseFab< Complex >.

References abs(), CFArrayBox(), BaseFab< T >::define(), divide(), dotProduct(), invert(), minus(), mult(), negate(), norm(), operator*=(), operator+=(), operator-=(), operator/=(), plus(), sum(), and sumPow().

◆ norm() [1/2]

virtual Real CFArrayBox::norm ( const Box a_subbox,
int  a_p = 2,
int  a_comp = 0,
int  a_numcomp = 1 
) const
virtual

Returns the Lp-norm of this FAB using components (a_comp : a_comp+a_numcomp-1) and within the a_subbox. a_p < 0 -> ERROR a_p = 0 -> infinity norm (max absolute value) a_p = 1 -> sum of ABS(FAB) a_p > 1 -> Lp-norm

Referenced by define().

◆ norm() [2/2]

virtual Real CFArrayBox::norm ( int  a_p = 2,
int  a_comp = 0,
int  a_numcomp = 1 
) const
virtual

Returns the Lp-norm of this FAB using components (a_comp : a_comp+a_numcomp-1). a_p < 0 -> ERROR a_p = 0 -> infinity norm (max absolute value) a_p = 1 -> sum of ABS(FAB) a_p > 1 -> Lp-norm

◆ sumPow()

virtual Complex CFArrayBox::sumPow ( const Box a_subbox,
int  a_p = 2,
int  a_comp = 0,
int  a_numcomp = 1 
) const
virtual

Returns sum of pow(fab[i,c],p): i in a_subbox, a_comp <= c < a_comp+a_numcomp, a_p >= 2 only

Referenced by define().

◆ dotProduct() [1/2]

Complex CFArrayBox::dotProduct ( const CFArrayBox a_fab2) const

Return the dot product of this CFArrayBox with another.

Return the dot product of this CFArrayBox and "a_fab2" over their common box and all components.

Referenced by define().

◆ dotProduct() [2/2]

Complex CFArrayBox::dotProduct ( const CFArrayBox a_fab2,
const Box a_box 
) const

Return the dot product of this CFArrayBox with another.

Return the dot product of this CFArrayBox and "a_fab2" over the a_box box and all components.

◆ abs() [1/3]

void CFArrayBox::abs ( )

Modifies this CFArrayBox by replacing each value with its absolute value.

Referenced by define().

◆ abs() [2/3]

void CFArrayBox::abs ( int  a_comp,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by replacing each value with its absolute value, for components (a_comp : a_comp+a_numcomp-1).

◆ abs() [3/3]

void CFArrayBox::abs ( const Box a_subbox,
int  a_comp = 0,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by replacing eahc value with its absolute value, for components (a_comp : a_comp+a_numcomp-1) and within the a_subbox.

◆ sum() [1/2]

Complex CFArrayBox::sum ( int  a_comp,
int  a_numcomp = 1 
) const

Returns sum of given component of CFArrayBox.

Referenced by define().

◆ sum() [2/2]

Complex CFArrayBox::sum ( const Box a_subbox,
int  a_comp,
int  a_numcomp = 1 
) const

Returns sum of component of this CFArrayBox in given a_subbox.

◆ invert() [1/3]

CFArrayBox& CFArrayBox::invert ( Complex  a_r)

Modifies this CFArrayBox by replacing each value x with a_r/x.

Referenced by define().

◆ invert() [2/3]

CFArrayBox& CFArrayBox::invert ( Complex  a_r,
int  a_comp,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by replacing each value x with a_r/x. For given range of components.

◆ invert() [3/3]

CFArrayBox& CFArrayBox::invert ( Complex  a_r,
const Box a_subbox,
int  a_comp = 0,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by replacing each value x with a_r/x. For given range of components and within given a_subbox.

◆ negate() [1/3]

CFArrayBox& CFArrayBox::negate ( const Box a_subbox,
int  a_comp = 0,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by replacing each value with its additive inverse. For given range of components and within given a_subbox.

◆ negate() [2/3]

CFArrayBox& CFArrayBox::negate ( int  a_comp,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by replacing each value with its additive inverse. For given range of components.

◆ negate() [3/3]

CFArrayBox& CFArrayBox::negate ( )

Modifies this CFArrayBox by replacing each value with its additive inverse.

Referenced by define().

◆ plus() [1/10]

CFArrayBox& CFArrayBox::plus ( Complex  a_r,
const Box a_subbox,
int  a_comp = 0,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by adding the scalar Complex a_r to all values. For given range of components and within given a_subbox.

Referenced by define().

◆ plus() [2/10]

CFArrayBox& CFArrayBox::plus ( Complex  a_r,
int  a_comp,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by adding the scalar Complex a_r to all values. For given range of components.

◆ operator+=() [1/2]

CFArrayBox& CFArrayBox::operator+= ( Complex  a_r)

Modifies this CFArrayBox by adding the scalar Complex a_r to all values.

Referenced by define().

◆ operator+=() [2/2]

CFArrayBox& CFArrayBox::operator+= ( const CFArrayBox a_x)

Modifies this CFArrayBox by pointwise addition of the values of the argument CFArrayBox. You might come to grief if the domains of the CFArrayBoxes don't match.

◆ plus() [3/10]

CFArrayBox& CFArrayBox::plus ( Complex  a_r)

Modifies this CFArrayBox by adding the scalar Complex a_r to all values.

◆ plus() [4/10]

CFArrayBox& CFArrayBox::plus ( const CFArrayBox a_x)

Modifies this CFArrayBox by pointwise addition of the values of the argument CFArrayBox. You might come to grief if the domains of the CFArrayBoxes don't match. The same as += operator.

◆ plus() [5/10]

CFArrayBox& CFArrayBox::plus ( const CFArrayBox a_src,
const Complex &  a_scale 
)

Modifies this CFArrayBox by pointwise scaled addition of the argument CFArrayBox (a[i] <- a[i] + a_scale * a_src[i]). Uses domain of the intersection of these two CFArrayBoxes.

◆ plus() [6/10]

CFArrayBox& CFArrayBox::plus ( const CFArrayBox a_src,
const Complex &  a_scale,
int  a_srccomp,
int  a_destcomp,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by pointwise scaled addition of the argument CFArrayBox (a[i] <- a[i] + a_scale * a_src[i]). Uses domain of the intersection of these two CFArrayBoxes.

◆ plus() [7/10]

CFArrayBox& CFArrayBox::plus ( const CFArrayBox a_src,
int  a_srccomp,
int  a_destcomp,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by pointwise addition of values in the argument CFArrayBox. Adds src's components (a_srccomp : a_srccomp+a_numcomp-1) to this CFArrayBox's components (a_destcomp : a_destcomp+a_numcomp-1) where the domains of the two CFArrayBoxes intersect.

◆ plus() [8/10]

CFArrayBox& CFArrayBox::plus ( const CFArrayBox a_src,
const Box a_subbox,
int  a_srccomp,
int  a_destcomp,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by pointwise addition of values in the argument CFArrayBox. Adds src's components (a_srccomp : a_srccomp+a_numcomp-1) to this CFArrayBox's components (a_destcomp : a_destcomp+numcomp-1) where the domain of this CFArrayBox intersects the a_subbox. NOTE: a_subbox must be contained in this FAB.

◆ plus() [9/10]

CFArrayBox& CFArrayBox::plus ( const CFArrayBox a_src,
const Box a_srcbox,
const Box a_destbox,
int  a_srccomp,
int  a_destcomp,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by pointwise addition of values in the argument CFArrayBox. Adds src's components (a_srccomp : a_srccomp+a_numcomp-1) in the Box a_srcbox to this CFArrayBox's components (a_destcomp : a_destcomp+a_numcomp-1) in the Box a_destbox. Corresponding locations within the two CFArrayBoxes are indexed relative to a_srcbox and a_destbox, and will in general not be the same. The a_srcbox and a_destbox must be same size. The results are UNDEFINED if the a_src and dest CFArrayBoxes are the same and the a_srcbox and a_destbox overlap.

◆ plus() [10/10]

CFArrayBox& CFArrayBox::plus ( const CFArrayBox a_src,
const Box a_srcbox,
const Box a_destbox,
const Complex &  a_scale,
int  a_srccomp,
int  a_destcomp,
int  a_numcomp = 1 
)

◆ operator-=() [1/2]

CFArrayBox& CFArrayBox::operator-= ( Complex  a_r)

Modifies this CFArrayBox by subtracting the scalar Complex a_r to all values. Note: use plus(-a_r) for more general operations.

Referenced by define().

◆ operator-=() [2/2]

CFArrayBox& CFArrayBox::operator-= ( const CFArrayBox a_x)

Modifies this CFArrayBox by pointwise subtraction of the values of the argument CFArrayBox. You might come to grief if the domains of the CFArrayBoxes don't match.

◆ minus() [1/4]

CFArrayBox& CFArrayBox::minus ( const CFArrayBox a_x)

Modifies this CFArrayBox by pointwise subtraction of the values of the argument CFArrayBox. You might come to grief if the domains of the CFArrayBoxes don't match. The same as -= operator.

Referenced by define().

◆ minus() [2/4]

CFArrayBox& CFArrayBox::minus ( const CFArrayBox a_src,
int  a_srccomp,
int  a_destcomp,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by pointwise subtraction of values in the argument CFArrayBox. Subtracts a_src's components (a_srccomp : a_srccomp+a_numcomp-1) from this CFArrayBox's components (a_destcomp : a_destcomp+a_numcomp-1) where the domains of the two CFArrayBoxes intersect.

◆ minus() [3/4]

CFArrayBox& CFArrayBox::minus ( const CFArrayBox a_src,
const Box a_subbox,
int  a_srccomp,
int  a_destcomp,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by pointwise subtraction of values in the argument CFArrayBox. Subtracts a_src's components (a_srccomp : a_srccomp+a_numcomp-1) from this CFArrayBox's components (a_destcomp : a_destcomp+a_numcomp-1) where the domain of this CFArrayBox intersects the a_subbox. NOTE: a_subbox must be contained in this FAB.

◆ minus() [4/4]

CFArrayBox& CFArrayBox::minus ( const CFArrayBox a_src,
const Box a_srcbox,
const Box a_destbox,
int  a_srccomp,
int  a_destcomp,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by pointwise subtraction of values in the argument CFArrayBox. Subtracts a_src's components (a_srccomp : a_srccomp+a_numcomp-1) in the Box a_srcbox from this CFArrayBox's components (a_destcomp : a_destcomp+a_numcomp-1) in the Box a_destbox. Corresponding locations within the two CFArrayBoxes are indexed relative to a_srcbox and a_destbox, and will in general not be the same. The a_srcbox and a_destbox must be same size. The results are UNDEFINED if the a_src and dest CFArrayBoxes are the same and the a_srcbox and a_destbox overlap.

◆ operator*=() [1/2]

CFArrayBox& CFArrayBox::operator*= ( Complex  a_r)

Modifies this CFArrayBox by multiplying all values by the scalar Complex a_r.

Referenced by define().

◆ mult() [1/9]

CFArrayBox& CFArrayBox::mult ( Complex  a_r)

Modifies this CFArrayBox by multiplying all values by the scalar Complex a_r.

Referenced by define().

◆ mult() [2/9]

CFArrayBox& CFArrayBox::mult ( Complex  a_r,
int  a_comp,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by multiplying all values by the scalar Complex a_r. For given range of components.

◆ mult() [3/9]

CFArrayBox& CFArrayBox::mult ( Complex  a_r,
const Box a_subbox,
int  a_comp = 0,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by multiplying all values by the scalar Complex a_r. For given range of components and within given a_subbox.

◆ operator*=() [2/2]

CFArrayBox& CFArrayBox::operator*= ( const CFArrayBox a_x)

Modifies this CFArrayBox by pointwise multiplication of the values by the argument CFArrayBox. You might come to grief if the domains of the CFArrayBoxes don't match.

◆ mult() [4/9]

CFArrayBox& CFArrayBox::mult ( const CFArrayBox a_x)

Modifies this CFArrayBox by pointwise multiplication by the values in the argument CFArrayBox. You might come to grief if the domains of the CFArrayBoxes don't match. The same as the *= operator.

◆ mult() [5/9]

CFArrayBox& CFArrayBox::mult ( const CFArrayBox a_src,
int  a_srccomp,
int  a_destcomp,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by pointwise multiplication by values in the argument CFArrayBox. Multiplies a_src's components (a_srccomp : a_srccomp+a_numcomp-1) by this CFArrayBox's components (a_destcomp : a_destcomp+a_numcomp-1) where the domains of the two CFArrayBoxes intersect.

◆ mult() [6/9]

CFArrayBox& CFArrayBox::mult ( const CFArrayBox a_src,
const Box a_subbox,
int  a_srccomp,
int  a_destcomp,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by pointwise multiplication by values in the argument CFArrayBox. Multiplies a_src's components (a_srccomp : a_srccomp+a_numcomp-1) by this CFArrayBox's components (a_destcomp : a_destcomp+a_numcomp-1) where the domain of this CFArrayBox intersects the a_subbox. NOTE: a_subbox must be contained in this FAB.

◆ mult() [7/9]

CFArrayBox& CFArrayBox::mult ( const CFArrayBox a_src,
const Box a_srcbox,
const Box a_destbox,
int  a_srccomp,
int  a_destcomp,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by pointwise multiplication by values in the argument CFArrayBox. Multiplies a_src's components (a_srccomp : a_srccomp+a_numcomp-1) in the Box a_srcbox by this CFArrayBox's components (a_destcomp : a_destcomp+a_numcomp-1) in the Box a_destbox. Corresponding locations within the two CFArrayBoxes are indexed relative to a_srcbox and a_destbox, and will in general not be the same. The a_srcbox and a_destbox must be same size. The results are UNDEFINED if the a_src and dest CFArrayBoxes are the same and the a_srcbox and a_destbox overlap.

◆ mult() [8/9]

CFArrayBox& CFArrayBox::mult ( const BaseFab< Real > &  a_r)

Modify this CFArrayBox by multiplying each element by the Real value in a_r

◆ mult() [9/9]

CFArrayBox& CFArrayBox::mult ( const BaseFab< Real > &  a_r,
const Box a_box 
)

Modify this CFArrayBox by multiplying each element by the Real value in a_r in the region defined by a_box

◆ operator/=() [1/2]

CFArrayBox& CFArrayBox::operator/= ( Complex  a_r)

Modifies this CFArrayBox by dividing all values by the scalar Complex a_r.

Referenced by define().

◆ divide() [1/7]

CFArrayBox& CFArrayBox::divide ( Complex  a_r)

Modifies this CFArrayBox by dividing all values by the scalar Complex a_r.

Referenced by define().

◆ divide() [2/7]

CFArrayBox& CFArrayBox::divide ( Complex  a_r,
int  a_comp,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by dividing all values by the scalar Complex a_r. For given range of components.

◆ divide() [3/7]

CFArrayBox& CFArrayBox::divide ( Complex  a_r,
const Box a_subbox,
int  a_comp = 0,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by dividing all values by the scalar Complex a_r. For given range of components and within given a_subbox.

◆ operator/=() [2/2]

CFArrayBox& CFArrayBox::operator/= ( const CFArrayBox a_x)

Modifies this CFArrayBox by pointwise division of the values by the argument CFArrayBox. You might come to grief if the domains of the CFArrayBoxes don't match.

◆ divide() [4/7]

CFArrayBox& CFArrayBox::divide ( const CFArrayBox a_x)

Modifies this CFArrayBox by pointwise division by the values in the argument CFArrayBox. You might come to grief if the domains of the CFArrayBoxes don't match. The same as the /= operator.

◆ divide() [5/7]

CFArrayBox& CFArrayBox::divide ( const CFArrayBox a_src,
int  a_srccomp,
int  a_destcomp,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by pointwise division by values in the argument CFArrayBox. Divides this CFArrayBox's components (a_destcomp : a_destcomp+a_numcomp-1) by a_src's components (a_srccomp : a_srccomp+a_numcomp-1) where the domains of the two CFArrayBoxes intersect.

◆ divide() [6/7]

CFArrayBox& CFArrayBox::divide ( const CFArrayBox a_src,
const Box a_subbox,
int  a_srccomp,
int  a_destcomp,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by pointwise division by values in the argument CFArrayBox. Divides this CFArrayBox's components (a_destcomp : a_destcomp+a_numcomp-1) by a_src's components (a_srccomp : a_srccomp+a_numcomp-1) where the domain of this CFArrayBox intersects the a_subbox. NOTE: a_subbox must be contained in this FAB.

◆ divide() [7/7]

CFArrayBox& CFArrayBox::divide ( const CFArrayBox a_src,
const Box a_srcbox,
const Box a_destbox,
int  a_srccomp,
int  a_destcomp,
int  a_numcomp = 1 
)

Modifies this CFArrayBox by pointwise division by values in the argument CFArrayBox. Divides this CFArrayBox's components (a_destcomp : a_destcomp+a_numcomp-1) in the Box a_destbox by a_src's components (a_srccomp : a_srccomp+a_numcomp-1) in the Box a_srcbox. Corresponding locations within the two CFArrayBoxes are indexed relative to a_srcbox and a_destbox, and will in general not be the same. The a_srcbox and a_destbox must be same size. The results are UNDEFINED if the a_src and dest CFArrayBoxes are the same and the a_srcbox and a_destbox overlap.

◆ get()

Complex CFArrayBox::get ( const IntVect a_iv,
int  a_comp 
) const
inline

◆ set()

void CFArrayBox::set ( const IntVect a_iv,
int  a_comp,
Complex  a_val 
)
inline

◆ axby() [1/2]

CFArrayBox& CFArrayBox::axby ( const CFArrayBox a_X,
const CFArrayBox a_Y,
Complex  a_A,
Complex  a_B 
)

Computes a_A * a_X + a_B * a_Y, placing the result in this CFArrayBox.

Referenced by set().

◆ axby() [2/2]

CFArrayBox& CFArrayBox::axby ( const CFArrayBox a_X,
const CFArrayBox a_Y,
Complex  a_A,
Complex  a_B,
int  a_destComp,
int  a_xComp,
int  a_yComp 
)

Computes a_A * a_X + a_B * a_Y, placing the result in this CFArrayBox. This version performs this operation only for the given component in each CFArrayBox.

◆ performCopy()

virtual void CFArrayBox::performCopy ( const BaseFab< Complex > &  a_src,
const Box a_srcbox,
int  a_srccomp,
const Box a_destbox,
int  a_destcomp,
int  a_numcomp 
)
protectedvirtual

Reimplemented from BaseFab< Complex >.

Referenced by set().

◆ operator=() [2/2]

CFArrayBox& CFArrayBox::operator= ( const CFArrayBox )
private

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