chombo-discharge
Static Public Member Functions | List of all members
DataOps Class Reference

Agglomeration of useful data operations. More...

#include <CD_DataOps.H>

Static Public Member Functions

template<typename T >
static void setValue (LevelData< MFInterfaceFAB< T >> &a_lhs, const T &a_value)
 Set value in an MFInterfaceFAB data holder. More...
 
template<typename T >
static int sgn (const T a_value)
 Sign function. Returns +/- if the value is > 0 or < 0. More...
 
static void averageCellVelocityToFaceVelocity (EBAMRFluxData &a_faceData, const EBAMRCellData &a_cellData, const Vector< ProblemDomain > &a_domains, const int a_tanGhosts)
 Routine which computes the average of a cell-centered quantity on faces for the normal component only. More...
 
static void averageCellVelocityToFaceVelocity (LevelData< EBFluxFAB > &a_faceData, const LevelData< EBCellFAB > &a_cellData, const ProblemDomain &a_domain, const int a_tanGhosts)
 Routine which computes the average of a cell-centered quantity on faces for the normal component only. More...
 
static void averageCellToFace (EBAMRFluxData &a_faceData, const EBAMRCellData &a_cellData, const Vector< ProblemDomain > &a_domains)
 Average all components of the cell-centered data to faces. More...
 
static void averageCellToFace (EBAMRFluxData &a_faceData, const EBAMRCellData &a_cellData, const Vector< ProblemDomain > &a_domains, const int a_tanGhosts, const Interval &a_faceVars, const Interval &a_cellVars, const Average &a_average)
 Routine which averages a cell-centered component to faces. More...
 
static void averageCellToFace (LevelData< EBFluxFAB > &a_faceData, const LevelData< EBCellFAB > &a_cellData, const ProblemDomain &a_domain, const int a_tanGhosts, const Interval &a_faceVars, const Interval &a_cellVars, const Average &a_average)
 Routine which averages a cell-centered component to faces. More...
 
static void averageFaceToCell (EBAMRCellData &a_cellData, const EBAMRFluxData &a_fluxData, const Vector< ProblemDomain > &a_domains)
 Average all components of face centered data to cell centers. More...
 
static void averageFaceToCell (LevelData< EBCellFAB > &a_cellData, const LevelData< EBFluxFAB > &a_fluxData, const ProblemDomain &a_domain)
 Average all components of face centered data to cell centers. More...
 
static void axby (LevelData< EBCellFAB > &a_lhs, const LevelData< EBCellFAB > &a_x, const LevelData< EBCellFAB > &a_y, const Real a_a, const Real a_b) noexcept
 Compute lhs = a * x + b * y. More...
 
static void compute (EBAMRCellData &a_data, const std::function< Real(const Real a_cellValue)> &a_func) noexcept
 Compute a new value given the old cell value. More...
 
static void compute (LevelData< EBCellFAB > &a_data, const std::function< Real(const Real a_cellValue)> &a_func) noexcept
 Compute a new value given the old cell value. More...
 
static void dotProduct (MFAMRCellData &a_result, const MFAMRCellData &a_data1, const MFAMRCellData &a_data2)
 Compote the cell-wise dot product between two data holders. More...
 
static void dotProduct (LevelData< MFCellFAB > &a_result, const LevelData< MFCellFAB > &a_data1, const LevelData< MFCellFAB > &a_data2)
 Compote the cell-wise dot product between two data holders. More...
 
static void dotProduct (EBAMRCellData &a_result, const EBAMRCellData &a_data1, const EBAMRCellData &a_data2)
 Compote the cell-wise dot product between two data holders. More...
 
static void dotProduct (LevelData< EBCellFAB > &a_result, const LevelData< EBCellFAB > &a_data1, const LevelData< EBCellFAB > &a_data2)
 Compote the cell-wise dot product between two data holders. More...
 
static void dotProduct (EBCellFAB &a_result, const EBCellFAB &a_data1, const EBCellFAB &a_data2, const Box &a_box)
 Compote the cell-wise dot product between two data holders. More...
 
static void filterSmooth (EBAMRCellData &a_data, const Real a_alpha, const int a_stride, const bool a_zeroEB) noexcept
 Apply a convolved filter phi = alpha * phi_i + 0.5*(1-alpha) * [phi_(i+s) + phi_(i-s)] in each direction. More...
 
static void filterSmooth (LevelData< EBCellFAB > &a_data, const Real a_alpha, const int a_stride, const bool a_zeroEB) noexcept
 Apply a convolved filter phi = alpha * phi_i + 0.5*(1-alpha) * [phi_(i+s) + phi_(i-s)] in each direction. More...
 
static void incr (MFAMRCellData &a_lhs, const MFAMRCellData &a_rhs, const Real a_scale) noexcept
 Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components. More...
 
static void incr (LevelData< MFCellFAB > &a_lhs, const LevelData< MFCellFAB > &a_rhs, const Real a_scale) noexcept
 Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components. More...
 
static void incr (EBAMRCellData &a_lhs, const EBAMRCellData &a_rhs, const Real &a_scale) noexcept
 Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components. More...
 
static void incr (LevelData< EBCellFAB > &a_lhs, const LevelData< EBCellFAB > &a_rhs, const Real &a_scale) noexcept
 Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components. More...
 
static void incr (EBAMRFluxData &a_lhs, const EBAMRFluxData &a_rhs, const Real &a_scale)
 Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components. More...
 
static void incr (LevelData< EBFluxFAB > &a_lhs, const LevelData< EBFluxFAB > &a_rhs, const Real &a_scale)
 Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components. More...
 
static void incr (EBFluxFAB &a_lhs, const EBFluxFAB &a_rhs, const Real &a_scale)
 Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components. More...
 
static void incr (EBAMRIVData &a_lhs, const EBAMRIVData &a_rhs, const Real &a_scale)
 Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components. More...
 
static void incr (LevelData< BaseIVFAB< Real >> &a_lhs, const LevelData< BaseIVFAB< Real >> &a_rhs, const Real &a_scale)
 Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components. More...
 
static void incr (EBAMRIFData &a_lhs, const EBAMRIFData &a_rhs, const Real &a_scale)
 Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components. More...
 
static void incr (LevelData< DomainFluxIFFAB > &a_lhs, const LevelData< DomainFluxIFFAB > &a_rhs, const Real &a_scale)
 Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components. More...
 
static void incr (EBAMRCellData &a_lhs, const EBAMRIVData &a_rhs, const Real a_scale)
 Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components. More...
 
static void incr (LevelData< EBCellFAB > &a_lhs, const LevelData< BaseIVFAB< Real >> &a_rhs, const Real a_scale)
 Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components. More...
 
static void incr (EBAMRIVData &a_lhs, const EBAMRCellData &a_rhs, const Real a_scale)
 Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components. More...
 
static void incr (LevelData< BaseIVFAB< Real >> &a_lhs, const LevelData< EBCellFAB > &a_rhs, const Real a_scale)
 Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components. More...
 
static void copy (MFAMRCellData &a_dst, const MFAMRCellData &a_src)
 Copy data from one data holder to another. More...
 
static void copy (EBAMRCellData &a_dst, const EBAMRCellData &a_src)
 Copy data from one data holder to another. More...
 
static void copy (EBAMRIVData &a_dst, const EBAMRIVData &a_src)
 Copy data from one data holder to another. More...
 
template<typename T >
static void copy (EBAMRData< T > &a_dst, const EBAMRData< T > &a_src, const Interval a_dstInterv, const Interval a_srcInterv)
 Copy data from one data holder to another. Allows specification of components. More...
 
static void divide (EBAMRCellData &a_lhs, const EBAMRCellData &a_rhs, const int a_lhsComp, const int a_rhsComp)
 Divide one data holder by another. Does specified components. More...
 
static void divide (LevelData< EBCellFAB > &a_lhs, const LevelData< EBCellFAB > &a_rhs, const int a_lhsComp, const int a_rhsComp)
 Divide one data holder by another. Does specified components. More...
 
static void divideByScalar (EBAMRCellData &a_lhs, const EBAMRCellData &a_rhs)
 Divide all components in a data holder by a scalar value. More...
 
static void divideByScalar (LevelData< EBCellFAB > &a_lhs, const LevelData< EBCellFAB > &a_rhs)
 Divide all components in a data holder by a scalar value. More...
 
static void divideFallback (EBAMRCellData &a_numerator, const EBAMRCellData &a_denominator, const Real a_fallback)
 Divide data. If the denominator is zero, set the value to a fallback option. More...
 
static void divideFallback (LevelData< EBCellFAB > &a_numerator, const LevelData< EBCellFAB > &a_denominator, const Real a_fallback)
 Divide data. If the denominator is zero, set the value to a fallback option. More...
 
static void divideFallback (EBAMRCellData &a_numerator, const EBAMRCellData &a_denominator, const EBAMRCellData &a_fallback)
 Divide data. If the denominator is zero, set the value to a fallback option. More...
 
static void divideFallback (LevelData< EBCellFAB > &a_numerator, const LevelData< EBCellFAB > &a_denominator, const LevelData< EBCellFAB > &a_fallback)
 Divide data. If the denominator is zero, set the value to a fallback option. More...
 
static void floor (EBAMRCellData &a_lhs, const Real a_value)
 Floor values in data holder. This sets all values below a_value to a_value. More...
 
static void floor (LevelData< EBCellFAB > &a_lhs, const Real a_value)
 Floor values in data holder. This sets all values below a_value to a_value. More...
 
static void floor (EBAMRIVData &a_lhs, const Real a_value)
 Floor values in data holder. This sets all values below a_value to a_value. More...
 
static void floor (LevelData< BaseIVFAB< Real >> &a_lhs, const Real a_value)
 Floor values in data holder. This sets all values below a_value to a_value. More...
 
static void roof (EBAMRCellData &a_lhs, const Real a_value)
 Roof values in data holder. This sets all values above a_value to a_value. More...
 
static void roof (LevelData< EBCellFAB > &a_lhs, const Real a_value)
 Roof values in data holder. This sets all values above a_value to a_value. More...
 
static void roof (EBAMRIVData &a_lhs, const Real a_value)
 Roof values in data holder. This sets all values above a_value to a_value. More...
 
static void roof (LevelData< BaseIVFAB< Real >> &a_lhs, const Real a_value)
 Roof values in data holder. This sets all values above a_value to a_value. More...
 
static void max (EBAMRCellData &a_data, const EBAMRCellData &a_data1, const EBAMRCellData &a_data2)
 Make a_data = max(a_data1, a_data2) More...
 
static void max (LevelData< EBCellFAB > &a_data, const LevelData< EBCellFAB > &a_data1, const LevelData< EBCellFAB > &a_data2)
 Make a_data = max(a_data1, a_data2) More...
 
static void getMaxMin (Real &max, Real &min, EBAMRCellData &a_data, const int a_comp)
 Get maximum and minimum value of specified component. More...
 
static void getMaxMin (Real &a_max, Real &a_min, LevelData< EBCellFAB > &a_data, const int a_comp)
 Get maximum and minimum value of specified component. More...
 
static void getMaxMin (Real &a_max, Real &a_min, EBAMRFluxData &a_data, const int a_comp) noexcept
 Get maximum and minimum value of specified component. More...
 
static void getMaxMin (Real &a_max, Real &a_min, LevelData< EBFluxFAB > &a_data, const int a_comp) noexcept
 Get maximum and minimum value of specified component. More...
 
static void getMaxMin (Vector< Real > &a_max, Vector< Real > &a_min, Vector< EBAMRCellData > &a_data)
 Get maximum and minimum value. Assumes single-component data. More...
 
static void getMaxMinNorm (Real &a_max, Real &a_min, EBAMRCellData &data)
 Get maximum and minimum value of normed data. More...
 
static void getMaxMinNorm (Real &a_max, Real &a_min, LevelData< EBCellFAB > &data)
 Get maximum and minimum value of normed data. More...
 
static void getMaxMinNorm (Real &a_max, Real &a_min, EBAMRIVData &data)
 Get maximum and minimum value of normed data. More...
 
static void getMaxMinNorm (Real &a_max, Real &a_min, LevelData< BaseIVFAB< Real >> &data)
 Get maximum and minimum value of normed data. More...
 
static void invert (EBAMRFluxData &a_data)
 Invert data. More...
 
static void invert (LevelData< EBFluxFAB > &a_data)
 Invert data. More...
 
static void invert (EBFluxFAB &a_data)
 Invert data. More...
 
static void kappaSum (Real &a_mass, const LevelData< EBCellFAB > &a_lhs, const int a_comp=0)
 Compute the kappa-weighted sum of the input data. Assumes one component. More...
 
static void kappaScale (EBAMRCellData &a_data) noexcept
 Scale data by volume fraction. More...
 
static void kappaScale (LevelData< EBCellFAB > &a_data) noexcept
 Scale data by volume fraction. More...
 
static void kappaScale (MFAMRCellData &a_data) noexcept
 Scale data by volume fraction. More...
 
static void kappaScale (LevelData< MFCellFAB > &a_data) noexcept
 Scale data by volume fraction. More...
 
static void volumeScale (EBAMRCellData &a_data, const Vector< Real > &a_dx)
 Scale data by dx^SpaceDim. More...
 
static void multiply (EBAMRCellData &a_lhs, const EBAMRCellData &a_rhs)
 Multiply data holder by another data holder. More...
 
static void multiply (LevelData< EBCellFAB > &a_lhs, const LevelData< EBCellFAB > &a_rhs)
 Multiply data holder by another data holder. More...
 
static void multiply (EBAMRFluxData &a_lhs, const EBAMRFluxData &a_rhs)
 Multiply data holder by another data holder. More...
 
static void multiply (LevelData< EBFluxFAB > &a_lhs, const LevelData< EBFluxFAB > &a_rhs)
 Multiply data holder by another data holder. More...
 
static void multiply (EBAMRIVData &a_lhs, const EBAMRIVData &a_rhs)
 Multiply data holder by another data holder. More...
 
static void multiply (LevelData< BaseIVFAB< Real >> &a_lhs, const LevelData< BaseIVFAB< Real >> &a_rhs)
 Multiply data holder by another data holder. More...
 
static void multiplyScalar (EBAMRCellData &a_lhs, const EBAMRCellData &a_rhs)
 Multiply data holder by another data holder. More...
 
static void multiplyScalar (LevelData< EBCellFAB > &a_lhs, const LevelData< EBCellFAB > &a_rhs)
 Multiply data holder by another data holder. More...
 
static void multiplyScalar (EBAMRIVData &a_lhs, const EBAMRIVData &a_rhs)
 Multiply data holder by another data holder. More...
 
static void multiplyScalar (LevelData< BaseIVFAB< Real >> &a_lhs, const LevelData< BaseIVFAB< Real >> &a_rhs)
 Multiply data holder by another data holder. More...
 
static Real norm (const LevelData< EBCellFAB > &a_data, const int a_p, const int a_comp=0)
 Compute specified norm of data. More...
 
static void plus (EBAMRCellData &a_lhs, const EBAMRCellData &a_rhs, const int a_srcComp, const int a_dstComp, const int a_numComp)
 General addition operator for adding together data. The user can choose which components to add. More...
 
static void plus (LevelData< EBCellFAB > &a_lhs, const LevelData< EBCellFAB > &a_rhs, const int a_srcComp, const int a_dstComp, const int a_numComp)
 General addition operator for adding together data. The user can choose which components to add. More...
 
static void scale (MFAMRCellData &a_lhs, const Real &a_scale) noexcept
 Scale data by factor. More...
 
static void scale (LevelData< MFCellFAB > &a_lhs, const Real &a_scale) noexcept
 Scale data by factor. More...
 
static void scale (MFAMRFluxData &a_lhs, const Real &a_scale)
 Scale data by factor. More...
 
static void scale (LevelData< MFFluxFAB > &a_lhs, const Real &a_scale)
 Scale data by factor. More...
 
static void scale (EBAMRIVData &a_lhs, const Real &a_scale)
 Scale data by factor. More...
 
static void scale (EBAMRCellData &a_lhs, const Real a_scale) noexcept
 Scale data by factor. More...
 
static void scale (LevelData< EBCellFAB > &a_lhs, const Real a_scale) noexcept
 Scale data by factor. More...
 
static void scale (EBAMRFluxData &a_lhs, const Real a_scale)
 Scale data by factor. More...
 
static void scale (LevelData< EBFluxFAB > &a_lhs, const Real a_scale)
 Scale data by factor. More...
 
static void scale (LevelData< BaseIVFAB< Real >> &a_lhs, const Real &a_scale)
 Scale data by factor. More...
 
static void setCoveredValue (EBAMRCellData &a_lhs, const int a_comp, const Real a_value)
 Set value in covered cells. Does specified component. More...
 
static void setCoveredValue (LevelData< EBCellFAB > &a_lhs, const int a_comp, const Real a_value)
 Set value in covered cells. Does specified component. More...
 
static void setCoveredValue (EBAMRCellData &a_lhs, const Real a_value)
 Version of setCoveredValue which does all components. More...
 
static void setCoveredValue (LevelData< EBCellFAB > &a_lhs, const Real a_value)
 Version of setCoveredValue which does all component. More...
 
static void setCoveredValue (EBAMRFluxData &a_lhs, const int a_comp, const Real a_value) noexcept
 Set value on covered faces. More...
 
static void setCoveredValue (LevelData< EBFluxFAB > &a_lhs, const int a_comp, const Real a_value) noexcept
 Set value on covered faces. More...
 
static void setCoveredValue (EBAMRFluxData &a_lhs, const Real a_value) noexcept
 Set all covered face values. More...
 
static void setCoveredValue (LevelData< EBFluxFAB > &a_lhs, const Real a_value) noexcept
 Set all covered face values. More...
 
static void setInvalidValue (EBAMRCellData &a_lhs, const Vector< int > &a_refRat, const Real a_value)
 Set value in cells that are covered by a finer grid. More...
 
static void setValue (MFAMRCellData &a_lhs, const std::function< Real(const RealVect)> &a_function, const RealVect a_probLo, const Vector< Real > &a_dx, const int a_comp)
 Polymorphic set value function. Takes a spatially varying function and sets the value in the specified component from that function. More...
 
static void setValue (LevelData< MFCellFAB > &a_lhs, const std::function< Real(const RealVect)> &a_function, const RealVect a_probLo, const Real a_dx, const int a_comp)
 Polymorphic set value function. Takes a spatially varying function and sets the value in the specified component from that function. More...
 
static void setValue (EBAMRCellData &a_lhs, const std::function< Real(const RealVect)> &a_function, const RealVect a_probLo, const Vector< Real > &a_dx, const int a_comp)
 Polymorphic set value function. Takes a spatially varying function and sets the value in the specified component from that function. More...
 
static void setValue (LevelData< EBCellFAB > &a_lhs, const std::function< Real(const RealVect)> &a_function, const RealVect a_probLo, const Real a_dx, const int a_comp)
 Polymorphic set value function. Takes a spatially varying function and sets the value in the specified component from that function. More...
 
static void setValue (EBAMRFluxData &a_lhs, const std::function< Real(const RealVect)> &a_function, const RealVect a_probLo, const Vector< Real > &a_dx, const int a_comp)
 Polymorphic set value function. Takes a spatially varying function and sets the value in the specified component from that function. More...
 
static void setValue (LevelData< EBFluxFAB > &a_lhs, const std::function< Real(const RealVect)> &a_function, const RealVect a_probLo, const Real a_dx, const int a_comp)
 Polymorphic set value function. Takes a spatially varying function and sets the value in the specified component from that function. More...
 
static void setValue (EBAMRIVData &a_lhs, const std::function< Real(const RealVect)> &a_function, const RealVect a_probLo, const Vector< Real > &a_dx, const int a_comp)
 Polymorphic set value function. Takes a spatially varying function and sets the value in the specified component from that function. More...
 
static void setValue (LevelData< BaseIVFAB< Real >> &a_lhs, const std::function< Real(const RealVect)> &a_function, const RealVect a_probLo, const Real a_dx, const int a_comp)
 Polymorphic set value function. Takes a spatially varying function and sets the value in the specified component from that function. More...
 
static void setValue (EBAMRCellData &a_lhs, const std::function< RealVect(const RealVect)> &a_function, const RealVect a_probLo, const Vector< Real > &a_dx)
 Polymorphic set value function. Assumes that a_lhs has SpaceDim components and sets all those components from the input function. More...
 
static void setValue (LevelData< EBCellFAB > &a_lhs, const std::function< RealVect(const RealVect)> &a_function, const RealVect a_probLo, const Real a_dx)
 Polymorphic set value function. Assumes that a_lhs has SpaceDim components and sets all those components from the input function. More...
 
static void setValue (EBAMRCellData &a_lhs, const Real &a_value)
 Set value in data. More...
 
static void setValue (EBAMRCellData &a_lhs, const Real a_value, const int a_comp)
 Set value in data with specified component. More...
 
static void setValue (LevelData< EBCellFAB > &a_lhs, const Real a_value, const int a_comp)
 Set value in data with specified component. More...
 
static void setValue (LevelData< EBCellFAB > &a_lhs, const Real a_value)
 Set value in data. More...
 
static void setValue (LevelData< EBFluxFAB > &a_lhs, const Real a_value)
 Set value in data. More...
 
static void setValue (LevelData< BaseIVFAB< Real >> &a_lhs, const Real a_value)
 Set value in data. More...
 
static void setValue (EBAMRFluxData &a_lhs, const Real &a_value)
 Set value in data. More...
 
static void setValue (EBAMRIVData &a_lhs, const Real &a_value)
 Set value in data. More...
 
static void setValue (MFAMRCellData &a_lhs, const Real &a_value) noexcept
 Set value in data. More...
 
static void setValue (LevelData< MFCellFAB > &a_lhs, const Real &a_value) noexcept
 Set value in data. More...
 
static void setValue (MFAMRFluxData &a_lhs, const Real &a_value)
 Set value in data. More...
 
static void setValue (LevelData< MFFluxFAB > &a_lhs, const Real &a_value)
 Set value in data. More...
 
static void setValue (MFAMRIVData &a_lhs, const Real &a_value)
 Set value in data. More...
 
static void setValue (LevelData< MFBaseIVFAB > &a_lhs, const Real &a_value)
 Set value in data. More...
 
static void setValue (EBAMRIFData &a_lhs, const Real a_value)
 Set value in data. More...
 
static void setValue (LevelData< DomainFluxIFFAB > &a_lhs, const Real a_value)
 Set value in data. More...
 
static void sum (Real &a_value)
 Compute the sum of the input value. More...
 
static void squareRoot (EBAMRFluxData &a_lhs)
 Compute the square root of the input data. More...
 
static void squareRoot (LevelData< EBFluxFAB > &a_lhs)
 Compute the square root of the input data. More...
 
static void squareRoot (MFAMRCellData &a_data)
 Take the square root of the input data. More...
 
static void squareRoot (LevelData< MFCellFAB > &a_data)
 Take the square root of the input data. More...
 
static void vectorLength (EBAMRCellData &a_lhs, const EBAMRCellData &a_rhs)
 Compute the vector length of a data holder. Sets a_lhs = |a_rhs| where a_rhs contains SpaceDim components. More...
 
static void vectorLength (LevelData< EBCellFAB > &a_lhs, const LevelData< EBCellFAB > &a_rhs)
 Compute the vector length of a data holder. Sets a_lhs = |a_rhs| where a_rhs contains SpaceDim components. More...
 
static void vectorLength (EBCellFAB &a_lhs, const EBCellFAB &a_rhs, const Box &box)
 Compute the vector length of a data holder. Sets a_lhs = |a_rhs| where a_rhs contains SpaceDim components. More...
 
static void vectorLength2 (EBAMRCellData &a_lhs, const EBAMRCellData &a_rhs)
 Compute the squared vector length of a data holder. Sets a_lhs = |a_rhs|^2 where a_rhs contains SpaceDim components. More...
 
static void vectorLength2 (LevelData< EBCellFAB > &a_lhs, const LevelData< EBCellFAB > &a_rhs)
 Compute the squared vector length of a data holder. Sets a_lhs = |a_rhs|^2 where a_rhs contains SpaceDim components. More...
 
static void vectorLength2 (EBCellFAB &a_lhs, const EBCellFAB &a_rhs, const Box &box)
 Compute the squared vector length of a data holder. Sets a_lhs = |a_rhs|^2 where a_rhs contains SpaceDim components. More...
 
static void computeMinValidBox (RealVect &a_lo, RealVect &a_hi, const RealVect a_normal, const RealVect a_centroid)
 Compute the tightest possible valid box around a cut-cell volume. More...
 
static bool allCornersInsideEb (const Vector< RealVect > &a_corners, const RealVect a_normal, const RealVect a_centroid)
 Check if all corners/points are inside an EB. More...
 
static void shiftCorners (Vector< RealVect > &a_corners, const RealVect &a_distance)
 Shift pointes by a specified distance. More...
 

Detailed Description

Agglomeration of useful data operations.

Note
All methods in this class assumes that data are allocated over the same realm. If you are trying to do something across realms, you need to copy the data onto realms that lie on the same data holders first!.

Member Function Documentation

◆ allCornersInsideEb()

bool DataOps::allCornersInsideEb ( const Vector< RealVect > &  a_corners,
const RealVect  a_normal,
const RealVect  a_centroid 
)
static

Check if all corners/points are inside an EB.

Parameters
[out]a_cornerCorners
[in]a_normalEB face normal
[in]a_centroidEB centroid
Returns
Returns true if all points are inside the EB and false otherwise.

◆ averageCellToFace() [1/3]

void DataOps::averageCellToFace ( EBAMRFluxData a_faceData,
const EBAMRCellData a_cellData,
const Vector< ProblemDomain > &  a_domains 
)
static

Average all components of the cell-centered data to faces.

Calls the other version; uses arihtmetic averaging and does not fill ghost faces.

Parameters
[out]a_faceDataFace data.
[in]a_cellDataCell data.
[in]a_domainsAMR domains.
Note
This does not fill "tangential" ghost faces.

◆ averageCellToFace() [2/3]

void DataOps::averageCellToFace ( EBAMRFluxData a_faceData,
const EBAMRCellData a_cellData,
const Vector< ProblemDomain > &  a_domains,
const int  a_tanGhosts,
const Interval &  a_faceVars,
const Interval &  a_cellVars,
const Average a_average 
)
static

Routine which averages a cell-centered component to faces.

User can choose what type of averaging to use, as well as choosing the number of ghost face to fill. These faces are "tangential ghost faces", i.e. if the face direction is along +x, we extend the box with faces in the y- and z- directions.

Parameters
[out]a_faceDataFace data.
[in]a_cellDataCell data.
[in]a_domainProblem domain
[in]a_tanGhostNumber of ghost faces to fill
[in]a_faceVarsFace variables
[in]a_cellVarsCell variables
[in]a_averageAveraging method

◆ averageCellToFace() [3/3]

void DataOps::averageCellToFace ( LevelData< EBFluxFAB > &  a_faceData,
const LevelData< EBCellFAB > &  a_cellData,
const ProblemDomain &  a_domain,
const int  a_tanGhosts,
const Interval &  a_faceVars,
const Interval &  a_cellVars,
const Average a_average 
)
static

Routine which averages a cell-centered component to faces.

User can choose what type of averaging to use, as well as choosing the number of ghost face to fill. These faces are "tangential ghost faces", i.e. if the face direction is along +x, we extend the box with faces in the y- and z- directions.

Parameters
[out]a_faceDataFace data.
[in]a_cellDataCell data.
[in]a_domainProblem domain
[in]a_tanGhostNumber of ghost faces to fill
[in]a_faceVarsFace variables
[in]a_cellVarsCell variables
[in]a_averageAveraging method

◆ averageCellVelocityToFaceVelocity() [1/2]

void DataOps::averageCellVelocityToFaceVelocity ( EBAMRFluxData a_faceData,
const EBAMRCellData a_cellData,
const Vector< ProblemDomain > &  a_domains,
const int  a_tanGhosts 
)
static

Routine which computes the average of a cell-centered quantity on faces for the normal component only.

Parameters
[out]a_faceDataFace data. Must have one component.
[in]a_cellDataCell data. Must have SpaceDim components.
[in]a_domainsAMR domains.
[in]a_tanGhostNumber of ghost faces to fill.

◆ averageCellVelocityToFaceVelocity() [2/2]

void DataOps::averageCellVelocityToFaceVelocity ( LevelData< EBFluxFAB > &  a_faceData,
const LevelData< EBCellFAB > &  a_cellData,
const ProblemDomain &  a_domain,
const int  a_tanGhosts 
)
static

Routine which computes the average of a cell-centered quantity on faces for the normal component only.

Parameters
[out]a_faceDataFace data. Must have one component.
[in]a_cellDataCell data. Must have SpaceDim components.
[in]a_domainProblem domain
[in]a_tanGhostNumber of ghost faces to fill

◆ averageFaceToCell() [1/2]

void DataOps::averageFaceToCell ( EBAMRCellData a_cellData,
const EBAMRFluxData a_fluxData,
const Vector< ProblemDomain > &  a_domains 
)
static

Average all components of face centered data to cell centers.

Parameters
[out]a_cellDataCell data.
[int]a_faceData Face data.
[in]a_domainsAMR domains.
Note
Only valid cells are filled (not ghost cells)

◆ averageFaceToCell() [2/2]

void DataOps::averageFaceToCell ( LevelData< EBCellFAB > &  a_cellData,
const LevelData< EBFluxFAB > &  a_fluxData,
const ProblemDomain &  a_domain 
)
static

Average all components of face centered data to cell centers.

Parameters
[out]a_cellDataCell data.
[int]a_faceData Face data.
[in]a_domainsDomain
Note
Only valid cells are filled (not ghost cells)

◆ axby()

void DataOps::axby ( LevelData< EBCellFAB > &  a_lhs,
const LevelData< EBCellFAB > &  a_x,
const LevelData< EBCellFAB > &  a_y,
const Real  a_a,
const Real  a_b 
)
staticnoexcept

Compute lhs = a * x + b * y.

Parameters
[out]a_lhsResult
[in]a_xFirst FAB
[in]a_ySecond FAB
[in]a_aScaling factor
[in]a_bScaling factor

◆ compute() [1/2]

void DataOps::compute ( EBAMRCellData a_data,
const std::function< Real(const Real a_cellValue)> &  a_func 
)
staticnoexcept

Compute a new value given the old cell value.

Useful for quickly calculating a cell value as e.g. exp(x) where the original data was only x

Parameters
[in,out]a_dataInput data
[in]a_funcFunction for transforming the data

◆ compute() [2/2]

void DataOps::compute ( LevelData< EBCellFAB > &  a_data,
const std::function< Real(const Real a_cellValue)> &  a_func 
)
staticnoexcept

Compute a new value given the old cell value.

Useful for quickly calculating a cell value as e.g. exp(x) where the original data was only x

Parameters
[in,out]a_dataInput data
[in]a_funcFunction for transforming the data

◆ computeMinValidBox()

void DataOps::computeMinValidBox ( RealVect &  a_lo,
RealVect &  a_hi,
const RealVect  a_normal,
const RealVect  a_centroid 
)
static

Compute the tightest possible valid box around a cut-cell volume.

Parameters
[out]a_loLow corner
[out]a_hiHigh corner
[in]a_normalEB face normal
[in]a_centroidEB centroid

◆ copy() [1/4]

void DataOps::copy ( EBAMRCellData a_dst,
const EBAMRCellData a_src 
)
static

Copy data from one data holder to another.

Parameters
[out]a_dstDestination data holder
[in]a_srcSource data holder

◆ copy() [2/4]

template<typename T >
void DataOps::copy ( EBAMRData< T > &  a_dst,
const EBAMRData< T > &  a_src,
const Interval  a_dstInterv,
const Interval  a_srcInterv 
)
static

Copy data from one data holder to another. Allows specification of components.

Parameters
[out]a_dstDestination data holder
[in]a_srcSource data holder
[out]a_dstIntervDestination data component
[in]a_srcIntervSource data components

◆ copy() [3/4]

void DataOps::copy ( EBAMRIVData a_dst,
const EBAMRIVData a_src 
)
static

Copy data from one data holder to another.

Parameters
[out]a_dstDestination data holder
[in]a_srcSource data holder

◆ copy() [4/4]

void DataOps::copy ( MFAMRCellData a_dst,
const MFAMRCellData a_src 
)
static

Copy data from one data holder to another.

Parameters
[out]a_dstDestination data holder
[in]a_srcSource data holder

◆ divide() [1/2]

void DataOps::divide ( EBAMRCellData a_lhs,
const EBAMRCellData a_rhs,
const int  a_lhsComp,
const int  a_rhsComp 
)
static

Divide one data holder by another. Does specified components.

Parameters
[in,out]a_lhsData to be divided
[in]a_rhsDivisor.
[in]a_lhsCompDestination data component
[in]a_rhsCompSource data component

◆ divide() [2/2]

void DataOps::divide ( LevelData< EBCellFAB > &  a_lhs,
const LevelData< EBCellFAB > &  a_rhs,
const int  a_lhsComp,
const int  a_rhsComp 
)
static

Divide one data holder by another. Does specified components.

Parameters
[in,out]a_lhsData to be divided
[in]a_rhsDivisor.
[in]a_lhsCompDestination data component
[in]a_rhsCompSource data component

◆ divideByScalar() [1/2]

void DataOps::divideByScalar ( EBAMRCellData a_lhs,
const EBAMRCellData a_rhs 
)
static

Divide all components in a data holder by a scalar value.

Parameters
[in,out]a_lhsData to be divided
[in]a_rhsDivisor. Must have exactly one component.

◆ divideByScalar() [2/2]

void DataOps::divideByScalar ( LevelData< EBCellFAB > &  a_lhs,
const LevelData< EBCellFAB > &  a_rhs 
)
static

Divide all components in a data holder by a scalar value.

Parameters
[in,out]a_lhsData to be divided
[in]a_rhsDivisor. Must have exactly one component.

◆ divideFallback() [1/4]

void DataOps::divideFallback ( EBAMRCellData a_numerator,
const EBAMRCellData a_denominator,
const EBAMRCellData a_fallback 
)
static

Divide data. If the denominator is zero, set the value to a fallback option.

Parameters
[in,out]a_numeratorDividend
[in]a_denominatorDivisor
[in]a_fallbackFallback data

◆ divideFallback() [2/4]

void DataOps::divideFallback ( EBAMRCellData a_numerator,
const EBAMRCellData a_denominator,
const Real  a_fallback 
)
static

Divide data. If the denominator is zero, set the value to a fallback option.

Parameters
[in,out]a_numeratorDividend
[in]a_denominatorDivisor
[in]a_fallbackFallback value in case denominator is zero.

◆ divideFallback() [3/4]

void DataOps::divideFallback ( LevelData< EBCellFAB > &  a_numerator,
const LevelData< EBCellFAB > &  a_denominator,
const LevelData< EBCellFAB > &  a_fallback 
)
static

Divide data. If the denominator is zero, set the value to a fallback option.

Parameters
[in,out]a_numeratorDividend
[in]a_denominatorDivisor
[in]a_fallbackFallback data
Note
Does all components.

◆ divideFallback() [4/4]

void DataOps::divideFallback ( LevelData< EBCellFAB > &  a_numerator,
const LevelData< EBCellFAB > &  a_denominator,
const Real  a_fallback 
)
static

Divide data. If the denominator is zero, set the value to a fallback option.

Parameters
[in,out]a_numeratorDividend
[in]a_denominatorDivisor
[in]a_fallbackFallback value in case denominator is zero.
Note
Does all components.

◆ dotProduct() [1/5]

void DataOps::dotProduct ( EBAMRCellData a_result,
const EBAMRCellData a_data1,
const EBAMRCellData a_data2 
)
static

Compote the cell-wise dot product between two data holders.

Parameters
[out]a_resultResult. Holds the dot product in each cell.
[in]a_data1First data holder.
[in]a_data2Other data holder.
Note
The input data data1 and data2 must have the same number of input components. Summation is done over all components (does not have to be SpaceDim).

◆ dotProduct() [2/5]

void DataOps::dotProduct ( EBCellFAB &  a_result,
const EBCellFAB &  a_data1,
const EBCellFAB &  a_data2,
const Box &  a_box 
)
static

Compote the cell-wise dot product between two data holders.

Parameters
[out]a_resultResult. Holds the dot product in each cell.
[in]a_data1First data holder.
[in]a_data2Other data holder.
Note
The input data data1 and data2 must have the same number of input components. Summation is done over all components (does not have to be SpaceDim).

◆ dotProduct() [3/5]

void DataOps::dotProduct ( LevelData< EBCellFAB > &  a_result,
const LevelData< EBCellFAB > &  a_data1,
const LevelData< EBCellFAB > &  a_data2 
)
static

Compote the cell-wise dot product between two data holders.

Parameters
[out]a_resultResult. Holds the dot product in each cell.
[in]a_data1First data holder.
[in]a_data2Other data holder.
Note
The input data data1 and data2 must have the same number of input components. Summation is done over all components (does not have to be SpaceDim).

◆ dotProduct() [4/5]

void DataOps::dotProduct ( LevelData< MFCellFAB > &  a_result,
const LevelData< MFCellFAB > &  a_data1,
const LevelData< MFCellFAB > &  a_data2 
)
static

Compote the cell-wise dot product between two data holders.

This calls the single-phase dotProduct patch versions with EBCellFABs on each phase.

Parameters
[out]a_resultResult. Holds the dot product in each cell.
[in]a_data1First data holder.
[in]a_data2Other data holder.
Note
The input data data1 and data2 must have the same number of input components. Summation is done over all components (does not have to be SpaceDim).

◆ dotProduct() [5/5]

void DataOps::dotProduct ( MFAMRCellData a_result,
const MFAMRCellData a_data1,
const MFAMRCellData a_data2 
)
static

Compote the cell-wise dot product between two data holders.

Parameters
[out]a_resultResult. Holds the dot product in each cell.
[in]a_data1First data holder.
[in]a_data2Other data holder.
Note
The input data data1 and data2 must have the same number of input components. Summation is done over all components (does not have to be SpaceDim).

◆ filterSmooth() [1/2]

void DataOps::filterSmooth ( EBAMRCellData a_data,
const Real  a_alpha,
const int  a_stride,
const bool  a_zeroEB 
)
staticnoexcept

Apply a convolved filter phi = alpha * phi_i + 0.5*(1-alpha) * [phi_(i+s) + phi_(i-s)] in each direction.

Ghost cells and coarsening must be done before entering this routine

Parameters
[in,out]a_dataData to be filtered.
[in]a_alphaFilter factor
[in]a_strideCell stride s
[in]a_zeroEBSet value in covered cells to zero or not
Note
This routine will fill ghost cells outside the domain boundary, but ignore the corner ghost cells at the domain corners. This routine may be dangerous to use with EBs as the data inside the EB is either kept as-is or replaced by zero.

◆ filterSmooth() [2/2]

void DataOps::filterSmooth ( LevelData< EBCellFAB > &  a_data,
const Real  a_alpha,
const int  a_stride,
const bool  a_zeroEB 
)
staticnoexcept

Apply a convolved filter phi = alpha * phi_i + 0.5*(1-alpha) * [phi_(i+s) + phi_(i-s)] in each direction.

Ghost cells must be updated before entering this routine.

Parameters
[in,out]a_dataData to be filtered.
[in]a_alphaFilter factor
[in]a_strideCell stride s
[in]a_zeroEBSet value in covered cells to zero or not
Note
This routine will fill ghost cells outside the domain boundary, but ignore the corner ghost cells at the domain corners. This routine may be dangerous to use with EBs as the data inside the EB is either kept as-is or replaced by zero.

◆ floor() [1/4]

void DataOps::floor ( EBAMRCellData a_lhs,
const Real  a_value 
)
static

Floor values in data holder. This sets all values below a_value to a_value.

Parameters
[in,out]a_lhsData to be floored.
[in]a_valueFloor value
Note
Also floors ghost cells.

◆ floor() [2/4]

void DataOps::floor ( EBAMRIVData a_lhs,
const Real  a_value 
)
static

Floor values in data holder. This sets all values below a_value to a_value.

Parameters
[in,out]a_lhsData to be floored.
[in]a_valueFloor value
Note
Also floors ghost cells.

◆ floor() [3/4]

void DataOps::floor ( LevelData< BaseIVFAB< Real >> &  a_lhs,
const Real  a_value 
)
static

Floor values in data holder. This sets all values below a_value to a_value.

Parameters
[in,out]a_lhsData to be floored.
[in]a_valueFloor value
Note
Also floors ghost cells.

◆ floor() [4/4]

void DataOps::floor ( LevelData< EBCellFAB > &  a_lhs,
const Real  a_value 
)
static

Floor values in data holder. This sets all values below a_value to a_value.

Parameters
[in,out]a_lhsData to be floored.
[in]a_valueFloor value
Note
Also floors ghost cells.

◆ getMaxMin() [1/5]

void DataOps::getMaxMin ( Real &  a_max,
Real &  a_min,
EBAMRFluxData a_data,
const int  a_comp 
)
staticnoexcept

Get maximum and minimum value of specified component.

Parameters
[out]a_maxMaximum value
[out]a_minMinium value
[in]a_dataCell-centered data
[in]a_compComponent
Note
This does the calculation over all levels, including grids that is covered by other grids.

◆ getMaxMin() [2/5]

void DataOps::getMaxMin ( Real &  a_max,
Real &  a_min,
LevelData< EBCellFAB > &  a_data,
const int  a_comp 
)
static

Get maximum and minimum value of specified component.

Parameters
[out]a_maxMaximum value
[out]a_minMinium value
[in]a_dataCell-centered data
[in]a_compComponent

◆ getMaxMin() [3/5]

void DataOps::getMaxMin ( Real &  a_max,
Real &  a_min,
LevelData< EBFluxFAB > &  a_data,
const int  a_comp 
)
staticnoexcept

Get maximum and minimum value of specified component.

Parameters
[out]a_maxMaximum value
[out]a_minMinium value
[in]a_dataCell-centered data
[in]a_compComponent

◆ getMaxMin() [4/5]

void DataOps::getMaxMin ( Real &  max,
Real &  min,
EBAMRCellData a_data,
const int  a_comp 
)
static

Get maximum and minimum value of specified component.

Parameters
[out]a_maxMaximum value
[out]a_minMinium value
[in]a_dataCell-centered data
[in]a_compComponent
Note
This does the calculation over all levels, including grids that is covered by other grids.

◆ getMaxMin() [5/5]

void DataOps::getMaxMin ( Vector< Real > &  a_max,
Vector< Real > &  a_min,
Vector< EBAMRCellData > &  a_data 
)
static

Get maximum and minimum value. Assumes single-component data.

Parameters
[out]a_maxMaximum value
[out]a_minMinium value
[in]a_dataCell-centered data
Note
This does the calculation over all levels, including grids that is covered by other grids.

◆ getMaxMinNorm() [1/4]

void DataOps::getMaxMinNorm ( Real &  a_max,
Real &  a_min,
EBAMRCellData data 
)
static

Get maximum and minimum value of normed data.

Parameters
[out]a_maxMaximum value
[out]a_minMinium value
[in]a_dataCell-centered data
Note
This does the calculation over all levels, including grids that is covered by other grids.

◆ getMaxMinNorm() [2/4]

void DataOps::getMaxMinNorm ( Real &  a_max,
Real &  a_min,
EBAMRIVData data 
)
static

Get maximum and minimum value of normed data.

Parameters
[out]a_maxMaximum value
[out]a_minMinium value
[in]a_dataCell-centered data
Note
This does the calculation over all levels, including grids that is covered by other grids.

◆ getMaxMinNorm() [3/4]

void DataOps::getMaxMinNorm ( Real &  a_max,
Real &  a_min,
LevelData< BaseIVFAB< Real >> &  data 
)
static

Get maximum and minimum value of normed data.

Parameters
[out]a_maxMaximum value
[out]a_minMinium value
[in]a_dataCell-centered data

◆ getMaxMinNorm() [4/4]

void DataOps::getMaxMinNorm ( Real &  a_max,
Real &  a_min,
LevelData< EBCellFAB > &  data 
)
static

Get maximum and minimum value of normed data.

Parameters
[out]a_maxMaximum value
[out]a_minMinium value
[in]a_dataCell-centered data

◆ incr() [1/15]

void DataOps::incr ( EBAMRCellData a_lhs,
const EBAMRCellData a_rhs,
const Real &  a_scale 
)
staticnoexcept

Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components.

Parameters
[in,out]a_lhsData to be incremented.
[in]a_rhsIncrementation.
[in]a_scaleScale factor.

◆ incr() [2/15]

void DataOps::incr ( EBAMRCellData a_lhs,
const EBAMRIVData a_rhs,
const Real  a_scale 
)
static

Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components.

This versions only adds irregular data from an EBAMRIVFAB. It ignores regular cells.

Parameters
[in,out]a_lhsData to be incremented.
[in]a_rhsIncrementation.
[in]a_scaleScale factor.

◆ incr() [3/15]

void DataOps::incr ( EBAMRFluxData a_lhs,
const EBAMRFluxData a_rhs,
const Real &  a_scale 
)
static

Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components.

Parameters
[in,out]a_lhsData to be incremented.
[in]a_rhsIncrementation.
[in]a_scaleScale factor.

◆ incr() [4/15]

void DataOps::incr ( EBAMRIFData a_lhs,
const EBAMRIFData a_rhs,
const Real &  a_scale 
)
static

Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components.

Parameters
[in,out]a_lhsData to be incremented.
[in]a_rhsIncrementation.
[in]a_scaleScale factor.

◆ incr() [5/15]

void DataOps::incr ( EBAMRIVData a_lhs,
const EBAMRCellData a_rhs,
const Real  a_scale 
)
static

Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components.

This versions only adds irregular data form an EBCellFAB to an BaseIVFAB. It ignores regular cells.

Parameters
[in,out]a_lhsData to be incremented.
[in]a_rhsIncrementation.
[in]a_scaleScale factor.

◆ incr() [6/15]

void DataOps::incr ( EBAMRIVData a_lhs,
const EBAMRIVData a_rhs,
const Real &  a_scale 
)
static

Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components.

Parameters
[in,out]a_lhsData to be incremented.
[in]a_rhsIncrementation.
[in]a_scaleScale factor.

◆ incr() [7/15]

void DataOps::incr ( EBFluxFAB &  a_lhs,
const EBFluxFAB &  a_rhs,
const Real &  a_scale 
)
static

Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components.

Parameters
[in,out]a_lhsData to be incremented.
[in]a_rhsIncrementation.
[in]a_scaleScale factor.

◆ incr() [8/15]

void DataOps::incr ( LevelData< BaseIVFAB< Real >> &  a_lhs,
const LevelData< BaseIVFAB< Real >> &  a_rhs,
const Real &  a_scale 
)
static

Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components.

Parameters
[in,out]a_lhsData to be incremented.
[in]a_rhsIncrementation.
[in]a_scaleScale factor.

◆ incr() [9/15]

void DataOps::incr ( LevelData< BaseIVFAB< Real >> &  a_lhs,
const LevelData< EBCellFAB > &  a_rhs,
const Real  a_scale 
)
static

Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components.

This versions only adds irregular data form an EBCellFAB to an BaseIVFAB. It ignores regular cells.

Parameters
[in,out]a_lhsData to be incremented.
[in]a_rhsIncrementation.
[in]a_scaleScale factor.

◆ incr() [10/15]

void DataOps::incr ( LevelData< DomainFluxIFFAB > &  a_lhs,
const LevelData< DomainFluxIFFAB > &  a_rhs,
const Real &  a_scale 
)
static

Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components.

Parameters
[in,out]a_lhsData to be incremented.
[in]a_rhsIncrementation.
[in]a_scaleScale factor.

◆ incr() [11/15]

void DataOps::incr ( LevelData< EBCellFAB > &  a_lhs,
const LevelData< BaseIVFAB< Real >> &  a_rhs,
const Real  a_scale 
)
static

Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components.

This versions only adds irregular data from an EBAMRIVFAB. It ignores regular cells.

Parameters
[in,out]a_lhsData to be incremented.
[in]a_rhsIncrementation.
[in]a_scaleScale factor.

◆ incr() [12/15]

void DataOps::incr ( LevelData< EBCellFAB > &  a_lhs,
const LevelData< EBCellFAB > &  a_rhs,
const Real &  a_scale 
)
staticnoexcept

Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components.

Parameters
[in,out]a_lhsData to be incremented.
[in]a_rhsIncrementation.
[in]a_scaleScale factor.

◆ incr() [13/15]

void DataOps::incr ( LevelData< EBFluxFAB > &  a_lhs,
const LevelData< EBFluxFAB > &  a_rhs,
const Real &  a_scale 
)
static

Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components.

Parameters
[in,out]a_lhsData to be incremented.
[in]a_rhsIncrementation.
[in]a_scaleScale factor.

◆ incr() [14/15]

void DataOps::incr ( LevelData< MFCellFAB > &  a_lhs,
const LevelData< MFCellFAB > &  a_rhs,
const Real  a_scale 
)
staticnoexcept

Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components.

Parameters
[in,out]a_lhsData to be incremented.
[in]a_rhsIncrementation.
[in]a_scaleScale factor.

◆ incr() [15/15]

void DataOps::incr ( MFAMRCellData a_lhs,
const MFAMRCellData a_rhs,
const Real  a_scale 
)
staticnoexcept

Function which increments data in the form a_lhs = a_lhs + a_rhs*a_scale for all components.

Parameters
[in,out]a_lhsData to be incremented.
[in]a_rhsIncrementation.
[in]a_scaleScale factor.

◆ invert() [1/3]

void DataOps::invert ( EBAMRFluxData a_data)
static

Invert data.

Parameters
[in,out]Datato be inverted. On output we have a_data = 1/a_data.
Note
Does all components and does not guard against division by zero.

◆ invert() [2/3]

static void DataOps::invert ( EBFluxFAB &  a_data)
static

Invert data.

Parameters
[in,out]Datato be inverted. On output we have a_data = 1/a_data.
Note
Does all components and does not guard against division by zero.

◆ invert() [3/3]

void DataOps::invert ( LevelData< EBFluxFAB > &  a_data)
static

Invert data.

Parameters
[in,out]Datato be inverted. On output we have a_data = 1/a_data.
Note
Does all components and does not guard against division by zero.

◆ kappaScale() [1/4]

void DataOps::kappaScale ( EBAMRCellData a_data)
staticnoexcept

Scale data by volume fraction.

Parameters
[in,out]a_dataData to be scaled. On output we have a_data = kappa * a_data

◆ kappaScale() [2/4]

void DataOps::kappaScale ( LevelData< EBCellFAB > &  a_data)
staticnoexcept

Scale data by volume fraction.

Parameters
[in,out]a_dataData to be scaled. On output we have a_data = kappa * a_data

◆ kappaScale() [3/4]

void DataOps::kappaScale ( LevelData< MFCellFAB > &  a_data)
staticnoexcept

Scale data by volume fraction.

Parameters
[in,out]a_dataData to be scaled. On output we have a_data = kappa * a_data

◆ kappaScale() [4/4]

void DataOps::kappaScale ( MFAMRCellData a_data)
staticnoexcept

Scale data by volume fraction.

Parameters
[in,out]a_dataData to be scaled. On output we have a_data = kappa * a_data

◆ kappaSum()

void DataOps::kappaSum ( Real &  a_mass,
const LevelData< EBCellFAB > &  a_lhs,
const int  a_comp = 0 
)
static

Compute the kappa-weighted sum of the input data. Assumes one component.

Parameters
[out]a_massTotal mass, computed as kappa * lhs
[in]a_lhsCell data
[in]a_compComponent

◆ max() [1/2]

void DataOps::max ( EBAMRCellData a_data,
const EBAMRCellData a_data1,
const EBAMRCellData a_data2 
)
static

Make a_data = max(a_data1, a_data2)

Parameters
[out]a_dataOutput data. Will be max(a_data1, a_data2) in every cell
[in]a_data1Input data holder
[in]a_data2Input data holder

◆ max() [2/2]

void DataOps::max ( LevelData< EBCellFAB > &  a_data,
const LevelData< EBCellFAB > &  a_data1,
const LevelData< EBCellFAB > &  a_data2 
)
static

Make a_data = max(a_data1, a_data2)

Parameters
[out]a_dataOutput data. Will be max(a_data1, a_data2) in every cell
[in]a_data1Input data holder
[in]a_data2Input data holder

◆ multiply() [1/6]

void DataOps::multiply ( EBAMRCellData a_lhs,
const EBAMRCellData a_rhs 
)
static

Multiply data holder by another data holder.

Parameters
[in,out]a_lhsData to be multiplied
[in]a_rhsMultiplication factor
Note
Does all components

◆ multiply() [2/6]

void DataOps::multiply ( EBAMRFluxData a_lhs,
const EBAMRFluxData a_rhs 
)
static

Multiply data holder by another data holder.

Parameters
[in,out]a_lhsData to be multiplied
[in]a_rhsMultiplication factor
Note
Does all components

◆ multiply() [3/6]

void DataOps::multiply ( EBAMRIVData a_lhs,
const EBAMRIVData a_rhs 
)
static

Multiply data holder by another data holder.

Parameters
[in,out]a_lhsData to be multiplied
[in]a_rhsMultiplication factor
Note
Does all components

◆ multiply() [4/6]

void DataOps::multiply ( LevelData< BaseIVFAB< Real >> &  a_lhs,
const LevelData< BaseIVFAB< Real >> &  a_rhs 
)
static

Multiply data holder by another data holder.

Parameters
[in,out]a_lhsData to be multiplied
[in]a_rhsMultiplication factor
Note
Does all components

◆ multiply() [5/6]

void DataOps::multiply ( LevelData< EBCellFAB > &  a_lhs,
const LevelData< EBCellFAB > &  a_rhs 
)
static

Multiply data holder by another data holder.

Parameters
[in,out]a_lhsData to be multiplied
[in]a_rhsMultiplication factor
Note
Does all components

◆ multiply() [6/6]

void DataOps::multiply ( LevelData< EBFluxFAB > &  a_lhs,
const LevelData< EBFluxFAB > &  a_rhs 
)
static

Multiply data holder by another data holder.

Parameters
[in,out]a_lhsData to be multiplied
[in]a_rhsMultiplication factor
Note
Does all components

◆ multiplyScalar() [1/4]

void DataOps::multiplyScalar ( EBAMRCellData a_lhs,
const EBAMRCellData a_rhs 
)
static

Multiply data holder by another data holder.

Parameters
[in,out]a_lhsData to be multiplied
[in]a_rhsMultiplication factor
Note
This multiplies all components in a_lhs with the single component in a_rhs

◆ multiplyScalar() [2/4]

void DataOps::multiplyScalar ( EBAMRIVData a_lhs,
const EBAMRIVData a_rhs 
)
static

Multiply data holder by another data holder.

Parameters
[in,out]a_lhsData to be multiplied
[in]a_rhsMultiplication factor
Note
This multiplies all components in a_lhs with the single component in a_rhs

◆ multiplyScalar() [3/4]

void DataOps::multiplyScalar ( LevelData< BaseIVFAB< Real >> &  a_lhs,
const LevelData< BaseIVFAB< Real >> &  a_rhs 
)
static

Multiply data holder by another data holder.

Parameters
[in,out]a_lhsData to be multiplied
[in]a_rhsMultiplication factor
Note
This multiplies all components in a_lhs with the single component in a_rhs

◆ multiplyScalar() [4/4]

void DataOps::multiplyScalar ( LevelData< EBCellFAB > &  a_lhs,
const LevelData< EBCellFAB > &  a_rhs 
)
static

Multiply data holder by another data holder.

Parameters
[in,out]a_lhsData to be multiplied
[in]a_rhsMultiplication factor
Note
This multiplies all components in a_lhs with the single component in a_rhs

◆ norm()

Real DataOps::norm ( const LevelData< EBCellFAB > &  a_data,
const int  a_p,
const int  a_comp = 0 
)
static

Compute specified norm of data.

Parameters
[in]a_dataData to compute the norm of
[in]a_pNorm factor, e.g. a_p = 2 => squared norm. 0 => inf norm
[in]a_compComponent
Note
Does not do kappa-weighting; if user needs

◆ plus() [1/2]

void DataOps::plus ( EBAMRCellData a_lhs,
const EBAMRCellData a_rhs,
const int  a_srcComp,
const int  a_dstComp,
const int  a_numComp 
)
static

General addition operator for adding together data. The user can choose which components to add.

Parameters
[in,out]a_lhsOutput data component
[in,out]a_rhsData to be added to a_lhs
[in]a_srcCompComponent in a_rhs to add from.
[in]a_dstCompComponent in a_lhs to add into.
[in]a_numCompNumber of components to add.
Note
This will add a_lhs(a_dstComp + icomp) += a_rhs(a_srcComp + icomp) for icomp = 0,1,2,..numComp-1.

◆ plus() [2/2]

void DataOps::plus ( LevelData< EBCellFAB > &  a_lhs,
const LevelData< EBCellFAB > &  a_rhs,
const int  a_srcComp,
const int  a_dstComp,
const int  a_numComp 
)
static

General addition operator for adding together data. The user can choose which components to add.

Parameters
[in,out]a_lhsOutput data component
[in,out]a_rhsData to be added to a_lhs
[in]a_srcCompComponent in a_rhs to add from.
[in]a_dstCompComponent in a_lhs to add into.
[in]a_numCompNumber of components to add.
Note
This will add a_lhs(a_dstComp + icomp) += a_rhs(a_srcComp + icomp) for icomp = 0,1,2,..numComp-1.

◆ roof() [1/4]

void DataOps::roof ( EBAMRCellData a_lhs,
const Real  a_value 
)
static

Roof values in data holder. This sets all values above a_value to a_value.

Parameters
[in,out]a_lhsData to be roofed.
[in]a_valueRoof value
Note
Also roofs ghost cells.

◆ roof() [2/4]

void DataOps::roof ( EBAMRIVData a_lhs,
const Real  a_value 
)
static

Roof values in data holder. This sets all values above a_value to a_value.

Parameters
[in,out]a_lhsData to be roofed.
[in]a_valueRoof value
Note
Also roofs ghost cells.

◆ roof() [3/4]

void DataOps::roof ( LevelData< BaseIVFAB< Real >> &  a_lhs,
const Real  a_value 
)
static

Roof values in data holder. This sets all values above a_value to a_value.

Parameters
[in,out]a_lhsData to be roofed.
[in]a_valueRoof value
Note
Also roofs ghost cells.

◆ roof() [4/4]

void DataOps::roof ( LevelData< EBCellFAB > &  a_lhs,
const Real  a_value 
)
static

Roof values in data holder. This sets all values above a_value to a_value.

Parameters
[in,out]a_lhsData to be roofed.
[in]a_valueRoof value
Note
Also roofs ghost cells.

◆ scale() [1/10]

void DataOps::scale ( EBAMRCellData a_lhs,
const Real  a_scale 
)
staticnoexcept

Scale data by factor.

Parameters
[in,out]a_lhsData to be scaled
[in]a_scaleScaling factor

◆ scale() [2/10]

void DataOps::scale ( EBAMRFluxData a_lhs,
const Real  a_scale 
)
static

Scale data by factor.

Parameters
[in,out]a_lhsData to be scaled
[in]a_scaleScaling factor

◆ scale() [3/10]

void DataOps::scale ( EBAMRIVData a_lhs,
const Real &  a_scale 
)
static

Scale data by factor.

Parameters
[in,out]a_lhsData to be scaled
[in]a_scaleScaling factor

◆ scale() [4/10]

void DataOps::scale ( LevelData< BaseIVFAB< Real >> &  a_lhs,
const Real &  a_scale 
)
static

Scale data by factor.

Parameters
[in,out]a_lhsData to be scaled
[in]a_scaleScaling factor

◆ scale() [5/10]

void DataOps::scale ( LevelData< EBCellFAB > &  a_lhs,
const Real  a_scale 
)
staticnoexcept

Scale data by factor.

Parameters
[in,out]a_lhsData to be scaled
[in]a_scaleScaling factor

◆ scale() [6/10]

void DataOps::scale ( LevelData< EBFluxFAB > &  a_lhs,
const Real  a_scale 
)
static

Scale data by factor.

Parameters
[in,out]a_lhsData to be scaled
[in]a_scaleScaling factor

◆ scale() [7/10]

void DataOps::scale ( LevelData< MFCellFAB > &  a_lhs,
const Real &  a_scale 
)
staticnoexcept

Scale data by factor.

Parameters
[in,out]a_lhsData to be scaled
[in]a_scaleScaling factor

◆ scale() [8/10]

void DataOps::scale ( LevelData< MFFluxFAB > &  a_lhs,
const Real &  a_scale 
)
static

Scale data by factor.

Parameters
[in,out]a_lhsData to be scaled
[in]a_scaleScaling factor

◆ scale() [9/10]

void DataOps::scale ( MFAMRCellData a_lhs,
const Real &  a_scale 
)
staticnoexcept

Scale data by factor.

Parameters
[in,out]a_lhsData to be scaled
[in]a_scaleScaling factor

◆ scale() [10/10]

void DataOps::scale ( MFAMRFluxData a_lhs,
const Real &  a_scale 
)
static

Scale data by factor.

Parameters
[in,out]a_lhsData to be scaled
[in]a_scaleScaling factor

◆ setCoveredValue() [1/8]

void DataOps::setCoveredValue ( EBAMRCellData a_lhs,
const int  a_comp,
const Real  a_value 
)
static

Set value in covered cells. Does specified component.

Parameters
[in,out]a_lhsInput/output data.
[in]a_compComponent to set
[in]a_valueValue to set

◆ setCoveredValue() [2/8]

void DataOps::setCoveredValue ( EBAMRCellData a_lhs,
const Real  a_value 
)
static

Version of setCoveredValue which does all components.

Parameters
[in,out]a_lhsData
[in]a_valueValue in covered grid cells.

◆ setCoveredValue() [3/8]

void DataOps::setCoveredValue ( EBAMRFluxData a_lhs,
const int  a_comp,
const Real  a_value 
)
staticnoexcept

Set value on covered faces.

Parameters
[in,out]a_lhsInput/output data.
[in]a_compComponent to set
[in]a_valueValue to set

◆ setCoveredValue() [4/8]

void DataOps::setCoveredValue ( EBAMRFluxData a_lhs,
const Real  a_value 
)
staticnoexcept

Set all covered face values.

Parameters
[in,out]a_lhsData
[in]a_valueValue in covered grid cells.

◆ setCoveredValue() [5/8]

void DataOps::setCoveredValue ( LevelData< EBCellFAB > &  a_lhs,
const int  a_comp,
const Real  a_value 
)
static

Set value in covered cells. Does specified component.

Parameters
[in,out]a_lhsInput/output data.
[in]a_compComponent to set
[in]a_valueValue to set

◆ setCoveredValue() [6/8]

void DataOps::setCoveredValue ( LevelData< EBCellFAB > &  a_lhs,
const Real  a_value 
)
static

Version of setCoveredValue which does all component.

Parameters
[in,out]a_lhsData
[in]a_valueValue in covered grid cells.

◆ setCoveredValue() [7/8]

void DataOps::setCoveredValue ( LevelData< EBFluxFAB > &  a_lhs,
const int  a_comp,
const Real  a_value 
)
staticnoexcept

Set value on covered faces.

Parameters
[in,out]a_lhsInput/output data.
[in]a_compComponent to set
[in]a_valueValue to set

◆ setCoveredValue() [8/8]

void DataOps::setCoveredValue ( LevelData< EBFluxFAB > &  a_lhs,
const Real  a_value 
)
staticnoexcept

Set all covered face values.

Parameters
[in,out]a_lhsData
[in]a_valueValue in covered grid cells.

◆ setInvalidValue()

void DataOps::setInvalidValue ( EBAMRCellData a_lhs,
const Vector< int > &  a_refRat,
const Real  a_value 
)
static

Set value in cells that are covered by a finer grid.

Parameters
[in,out]a_lhsAMR data
[in]a_refRatRefinement ratios between levels.
[in]a_valueValue to set in cells covered by a finer grid.

◆ setValue() [1/27]

void DataOps::setValue ( EBAMRCellData a_lhs,
const Real &  a_value 
)
static

Set value in data.

Parameters
[out]a_lhsInput/output data
[in]a_valueValue to set

◆ setValue() [2/27]

void DataOps::setValue ( EBAMRCellData a_lhs,
const Real  a_value,
const int  a_comp 
)
static

Set value in data with specified component.

Parameters
[out]a_lhsInput/output data
[in]a_valueValue to set

◆ setValue() [3/27]

void DataOps::setValue ( EBAMRCellData a_lhs,
const std::function< Real(const RealVect)> &  a_function,
const RealVect  a_probLo,
const Vector< Real > &  a_dx,
const int  a_comp 
)
static

Polymorphic set value function. Takes a spatially varying function and sets the value in the specified component from that function.

Parameters
[out]a_lhsData to set
[in]a_functionFunction to use for setting the value.
[in]a_probLoLower-left corner of physical domain.
[in]a_dxGrid resolutions
[in]a_compComponent to set
Note
Uses a VofIterator everywhere to this might be slow!

◆ setValue() [4/27]

void DataOps::setValue ( EBAMRCellData a_lhs,
const std::function< RealVect(const RealVect)> &  a_function,
const RealVect  a_probLo,
const Vector< Real > &  a_dx 
)
static

Polymorphic set value function. Assumes that a_lhs has SpaceDim components and sets all those components from the input function.

Parameters
[out]a_lhsData to set
[in]a_functionFunction to use for setting the value.
[in]a_probLoLower-left corner of physical domain.
[in]a_dxGrid resolutions
[in]a_compComponent to set
Note
Uses a VofIterator everywhere to this might be slow!

◆ setValue() [5/27]

void DataOps::setValue ( EBAMRFluxData a_lhs,
const Real &  a_value 
)
static

Set value in data.

Parameters
[out]a_lhsInput/output data
[in]a_valueValue to set

◆ setValue() [6/27]

void DataOps::setValue ( EBAMRFluxData a_lhs,
const std::function< Real(const RealVect)> &  a_function,
const RealVect  a_probLo,
const Vector< Real > &  a_dx,
const int  a_comp 
)
static

Polymorphic set value function. Takes a spatially varying function and sets the value in the specified component from that function.

Parameters
[out]a_lhsData to set
[in]a_functionFunction to use for setting the value.
[in]a_probLoLower-left corner of physical domain.
[in]a_dxGrid resolutions
[in]a_compComponent to set
Note
Uses a VofIterator everywhere to this might be slow!

◆ setValue() [7/27]

void DataOps::setValue ( EBAMRIFData a_lhs,
const Real  a_value 
)
static

Set value in data.

Parameters
[out]a_lhsInput/output data
[in]a_valueValue to set

◆ setValue() [8/27]

void DataOps::setValue ( EBAMRIVData a_lhs,
const Real &  a_value 
)
static

Set value in data.

Parameters
[out]a_lhsInput/output data
[in]a_valueValue to set

◆ setValue() [9/27]

void DataOps::setValue ( EBAMRIVData a_lhs,
const std::function< Real(const RealVect)> &  a_function,
const RealVect  a_probLo,
const Vector< Real > &  a_dx,
const int  a_comp 
)
static

Polymorphic set value function. Takes a spatially varying function and sets the value in the specified component from that function.

Parameters
[out]a_lhsData to set
[in]a_functionFunction to use for setting the value.
[in]a_probLoLower-left corner of physical domain.
[in]a_dxGrid resolutions
[in]a_compComponent to set
Note
Uses a VofIterator everywhere to this might be slow!

◆ setValue() [10/27]

void DataOps::setValue ( LevelData< BaseIVFAB< Real >> &  a_lhs,
const Real  a_value 
)
static

Set value in data.

Parameters
[out]a_lhsInput/output data
[in]a_valueValue to set

◆ setValue() [11/27]

void DataOps::setValue ( LevelData< BaseIVFAB< Real >> &  a_lhs,
const std::function< Real(const RealVect)> &  a_function,
const RealVect  a_probLo,
const Real  a_dx,
const int  a_comp 
)
static

Polymorphic set value function. Takes a spatially varying function and sets the value in the specified component from that function.

Parameters
[out]a_lhsData to set
[in]a_functionFunction to use for setting the value.
[in]a_probLoLower-left corner of physical domain.
[in]a_dxGrid resolutions
[in]a_compComponent to set
Note
Uses a VofIterator everywhere to this might be slow!

◆ setValue() [12/27]

void DataOps::setValue ( LevelData< DomainFluxIFFAB > &  a_lhs,
const Real  a_value 
)
static

Set value in data.

Parameters
[out]a_lhsInput/output data
[in]a_valueValue to set

◆ setValue() [13/27]

void DataOps::setValue ( LevelData< EBCellFAB > &  a_lhs,
const Real  a_value 
)
static

Set value in data.

Parameters
[out]a_lhsInput/output data
[in]a_valueValue to set

◆ setValue() [14/27]

void DataOps::setValue ( LevelData< EBCellFAB > &  a_lhs,
const Real  a_value,
const int  a_comp 
)
static

Set value in data with specified component.

Parameters
[out]a_lhsInput/output data
[in]a_valueValue to set

◆ setValue() [15/27]

void DataOps::setValue ( LevelData< EBCellFAB > &  a_lhs,
const std::function< Real(const RealVect)> &  a_function,
const RealVect  a_probLo,
const Real  a_dx,
const int  a_comp 
)
static

Polymorphic set value function. Takes a spatially varying function and sets the value in the specified component from that function.

Parameters
[out]a_lhsData to set
[in]a_functionFunction to use for setting the value.
[in]a_probLoLower-left corner of physical domain.
[in]a_dxGrid resolutions
[in]a_compComponent to set
Note
Uses a VofIterator everywhere to this might be slow!

◆ setValue() [16/27]

void DataOps::setValue ( LevelData< EBCellFAB > &  a_lhs,
const std::function< RealVect(const RealVect)> &  a_function,
const RealVect  a_probLo,
const Real  a_dx 
)
static

Polymorphic set value function. Assumes that a_lhs has SpaceDim components and sets all those components from the input function.

Parameters
[out]a_lhsData to set
[in]a_functionFunction to use for setting the value.
[in]a_probLoLower-left corner of physical domain.
[in]a_dxGrid resolutions
[in]a_compComponent to set
Note
Uses a VofIterator everywhere to this might be slow!

◆ setValue() [17/27]

void DataOps::setValue ( LevelData< EBFluxFAB > &  a_lhs,
const Real  a_value 
)
static

Set value in data.

Parameters
[out]a_lhsInput/output data
[in]a_valueValue to set

◆ setValue() [18/27]

void DataOps::setValue ( LevelData< EBFluxFAB > &  a_lhs,
const std::function< Real(const RealVect)> &  a_function,
const RealVect  a_probLo,
const Real  a_dx,
const int  a_comp 
)
static

Polymorphic set value function. Takes a spatially varying function and sets the value in the specified component from that function.

Parameters
[out]a_lhsData to set
[in]a_functionFunction to use for setting the value.
[in]a_probLoLower-left corner of physical domain.
[in]a_dxGrid resolutions
[in]a_compComponent to set
Note
Uses a VofIterator everywhere to this might be slow!

◆ setValue() [19/27]

void DataOps::setValue ( LevelData< MFBaseIVFAB > &  a_lhs,
const Real &  a_value 
)
static

Set value in data.

Parameters
[out]a_lhsInput/output data
[in]a_valueValue to set

◆ setValue() [20/27]

void DataOps::setValue ( LevelData< MFCellFAB > &  a_lhs,
const Real &  a_value 
)
staticnoexcept

Set value in data.

Parameters
[out]a_lhsInput/output data
[in]a_valueValue to set

◆ setValue() [21/27]

void DataOps::setValue ( LevelData< MFCellFAB > &  a_lhs,
const std::function< Real(const RealVect)> &  a_function,
const RealVect  a_probLo,
const Real  a_dx,
const int  a_comp 
)
static

Polymorphic set value function. Takes a spatially varying function and sets the value in the specified component from that function.

Parameters
[out]a_lhsData to set
[in]a_functionFunction to use for setting the value.
[in]a_probLoLower-left corner of physical domain.
[in]a_dxGrid resolutions
[in]a_compComponent to set
Note
Uses a VofIterator everywhere to this might be slow!

◆ setValue() [22/27]

void DataOps::setValue ( LevelData< MFFluxFAB > &  a_lhs,
const Real &  a_value 
)
static

Set value in data.

Parameters
[out]a_lhsInput/output data
[in]a_valueValue to set

◆ setValue() [23/27]

template<typename T >
void DataOps::setValue ( LevelData< MFInterfaceFAB< T >> &  a_lhs,
const T &  a_value 
)
static

Set value in an MFInterfaceFAB data holder.

Parameters
[in]a_lhsData holder
[in]a_valueValue to set

◆ setValue() [24/27]

void DataOps::setValue ( MFAMRCellData a_lhs,
const Real &  a_value 
)
staticnoexcept

Set value in data.

Parameters
[out]a_lhsInput/output data
[in]a_valueValue to set

◆ setValue() [25/27]

void DataOps::setValue ( MFAMRCellData a_lhs,
const std::function< Real(const RealVect)> &  a_function,
const RealVect  a_probLo,
const Vector< Real > &  a_dx,
const int  a_comp 
)
static

Polymorphic set value function. Takes a spatially varying function and sets the value in the specified component from that function.

Parameters
[out]a_lhsData to set
[in]a_functionFunction to use for setting the value.
[in]a_probLoLower-left corner of physical domain.
[in]a_dxGrid resolutions
[in]a_compComponent to set
Note
Uses a VofIterator everywhere to this might be slow!

◆ setValue() [26/27]

void DataOps::setValue ( MFAMRFluxData a_lhs,
const Real &  a_value 
)
static

Set value in data.

Parameters
[out]a_lhsInput/output data
[in]a_valueValue to set

◆ setValue() [27/27]

void DataOps::setValue ( MFAMRIVData a_lhs,
const Real &  a_value 
)
static

Set value in data.

Parameters
[out]a_lhsInput/output data
[in]a_valueValue to set

◆ sgn()

template<typename T >
int DataOps::sgn ( const T  a_value)
static

Sign function. Returns +/- if the value is > 0 or < 0.

Parameters
[in]a_valueValue to evaluate.

◆ shiftCorners()

void DataOps::shiftCorners ( Vector< RealVect > &  a_corners,
const RealVect &  a_distance 
)
static

Shift pointes by a specified distance.

On output, every point in a_corners is shifted by a_distance.

Parameters
[in,out]a_cornersPoints to be shifted
[in]a_distanceShift vector

◆ squareRoot() [1/4]

void DataOps::squareRoot ( EBAMRFluxData a_lhs)
static

Compute the square root of the input data.

Parameters
[in,out]a_lhsOn output, contains sqrt(a_lhs)
Note
Does not do ghosted faces.

◆ squareRoot() [2/4]

void DataOps::squareRoot ( LevelData< EBFluxFAB > &  a_lhs)
static

Compute the square root of the input data.

Parameters
[in,out]a_lhsOn output, contains sqrt(a_lhs)
Note
Does not do ghosted faces.

◆ squareRoot() [3/4]

void DataOps::squareRoot ( LevelData< MFCellFAB > &  a_data)
static

Take the square root of the input data.

Parameters
[in,out]a_dataInput data

◆ squareRoot() [4/4]

void DataOps::squareRoot ( MFAMRCellData a_data)
static

Take the square root of the input data.

Parameters
[in,out]a_dataInput data

◆ sum()

void DataOps::sum ( Real &  a_value)
static

Compute the sum of the input value.

Parameters
[in,out]a_valueOn output, contains the sum of a_value over all MPI processes.

◆ vectorLength() [1/3]

void DataOps::vectorLength ( EBAMRCellData a_lhs,
const EBAMRCellData a_rhs 
)
static

Compute the vector length of a data holder. Sets a_lhs = |a_rhs| where a_rhs contains SpaceDim components.

Parameters
[out]a_lhsVector length
[in]a_rhsInput vector
Note
a_lhs must have one component and a_rhs must have SpaceDim components.

◆ vectorLength() [2/3]

void DataOps::vectorLength ( EBCellFAB &  a_lhs,
const EBCellFAB &  a_rhs,
const Box &  box 
)
static

Compute the vector length of a data holder. Sets a_lhs = |a_rhs| where a_rhs contains SpaceDim components.

Parameters
[out]a_lhsVector length.
[in]a_rhsInput vector.
[in]a_boxComputation box.
Note
a_lhs must have one component and a_rhs must have SpaceDim components.

◆ vectorLength() [3/3]

void DataOps::vectorLength ( LevelData< EBCellFAB > &  a_lhs,
const LevelData< EBCellFAB > &  a_rhs 
)
static

Compute the vector length of a data holder. Sets a_lhs = |a_rhs| where a_rhs contains SpaceDim components.

Parameters
[out]a_lhsVector length
[in]a_rhsInput vector
Note
a_lhs must have one component and a_rhs must have SpaceDim components.

◆ vectorLength2() [1/3]

void DataOps::vectorLength2 ( EBAMRCellData a_lhs,
const EBAMRCellData a_rhs 
)
static

Compute the squared vector length of a data holder. Sets a_lhs = |a_rhs|^2 where a_rhs contains SpaceDim components.

Parameters
[out]a_lhsVector length
[in]a_rhsInput vector
Note
a_lhs must have one component and a_rhs must have SpaceDim components.

◆ vectorLength2() [2/3]

void DataOps::vectorLength2 ( EBCellFAB &  a_lhs,
const EBCellFAB &  a_rhs,
const Box &  box 
)
static

Compute the squared vector length of a data holder. Sets a_lhs = |a_rhs|^2 where a_rhs contains SpaceDim components.

Parameters
[out]a_lhsVector length
[in]a_rhsInput vector
Note
a_lhs must have one component and a_rhs must have SpaceDim components.

◆ vectorLength2() [3/3]

void DataOps::vectorLength2 ( LevelData< EBCellFAB > &  a_lhs,
const LevelData< EBCellFAB > &  a_rhs 
)
static

Compute the squared vector length of a data holder. Sets a_lhs = |a_rhs|^2 where a_rhs contains SpaceDim components.

Parameters
[out]a_lhsVector length
[in]a_rhsInput vector
Note
a_lhs must have one component and a_rhs must have SpaceDim components.

◆ volumeScale()

void DataOps::volumeScale ( EBAMRCellData a_data,
const Vector< Real > &  a_dx 
)
static

Scale data by dx^SpaceDim.

Parameters
[in,out]a_dataData to be scaled. On output we have a_data = dx^SpaceDim * a_data

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