MAIA bb96820c
Multiphysics at AIA
Loading...
Searching...
No Matches
GridgenCell< nDim > Class Template Reference

#include <cartesiangridgencell.h>

Collaboration diagram for GridgenCell< nDim >:
[legend]

Public Member Functions

void allocateElements (void *, void *basePtr, const MInt cellId)
 
void moveElements (void *, void *basePtr, const MInt cellId)
 
void memCopyElements (void *basePtr, void *, void *, MLong)
 

Static Public Member Functions

static void init (MInt dimensions, const MInt, MInt maxNoCells)
 
static MInt staticElementSize ()
 

Static Public Attributes

static MInt s_maxNoCells
 
static MInt s_dimensions
 
static MInt s_noChilds
 
static MInt s_noNghbrs
 

Private Attributes

MFloatm_coordinates_
 
MIntm_level_
 
MLongm_parentId_
 
MLongm_globalId_
 
MIntm_noChildIds_
 
MLongm_nghbrIds_
 
MLongm_childIds_
 
MInt m_rfnDistance_
 
MIntm_noSolidLayer_
 
std::array< char, s_maxNoSolversb_properties_
 
std::array< char, s_maxNoSolversb_solverAffiliation_
 
std::array< char, s_maxNoSolversb_solverBoundary_
 
std::array< char, s_maxNoSolversb_solverToRefine_
 

Static Private Attributes

static const MUint s_maxNoSolvers = 8
 

Friends

template<MInt nDim_>
class GridgenPar
 

Detailed Description

template<MInt nDim>
class GridgenCell< nDim >

Definition at line 24 of file cartesiangridgencell.h.

Member Function Documentation

◆ allocateElements()

template<MInt nDim>
void GridgenCell< nDim >::allocateElements ( void *  ,
void *  basePtr,
const MInt  cellId 
)

Definition at line 23 of file cartesiangridgencell.cpp.

23 {
24 // init
25 m_rfnDistance_ = std::numeric_limits<MInt>::max();
26 b_properties_.fill(0);
28 b_solverBoundary_.fill(0);
29 b_solverToRefine_.fill(0);
30
31 // Member pointers are set to the cell memory here:
32 moveElements(nullptr, basePtr, cellId);
33}
std::array< char, s_maxNoSolvers > b_solverAffiliation_
std::array< char, s_maxNoSolvers > b_properties_
void moveElements(void *, void *basePtr, const MInt cellId)
std::array< char, s_maxNoSolvers > b_solverToRefine_
std::array< char, s_maxNoSolvers > b_solverBoundary_
void const MInt cellId
Definition: collector.h:239

◆ init()

template<MInt nDim>
static void GridgenCell< nDim >::init ( MInt  dimensions,
const  MInt,
MInt  maxNoCells 
)
inlinestatic

Definition at line 68 of file cartesiangridgencell.h.

68 {
69 s_dimensions = dimensions;
73 }
static MInt s_noNghbrs
static MInt s_maxNoCells
static MInt s_dimensions
static MInt s_noChilds
constexpr MLong IPOW2(MInt x)
void const MInt const MInt const MInt const MInt maxNoCells
Definition: collector.h:240

◆ memCopyElements()

template<MInt nDim>
void GridgenCell< nDim >::memCopyElements ( void *  basePtr,
void *  ,
void *  ,
MLong   
)

Definition at line 48 of file cartesiangridgencell.cpp.

48 {
49 const GridgenCell<nDim>* const from = reinterpret_cast<GridgenCell<nDim>*>(basePtr);
50
59}
MFloat * m_coordinates_
static const MUint s_maxNoSolvers
void copyElements1D(T *to, T *from, const MInt Nrows)
Copies 1D cell elements.
Definition: collector.h:258

◆ moveElements()

template<MInt nDim>
void GridgenCell< nDim >::moveElements ( void *  ,
void *  basePtr,
const MInt  cellId 
)

Definition at line 36 of file cartesiangridgencell.cpp.

36 {
45}
void rowMajor1D(T *&p, void *&base, const MInt cellId, const MInt Nrows, const MInt maxNoCells)
Stores 1D variables in row-major order.
Definition: collector.h:210

◆ staticElementSize()

template<MInt nDim>
static MInt GridgenCell< nDim >::staticElementSize ( )
inlinestatic

Definition at line 75 of file cartesiangridgencell.h.

75 {
76 return (sizeof(MLong)
77 * (2 + // m_globalId, m_parentId
78 2 * s_dimensions + // m_nghbrIds
79 s_noChilds) // m_childIds
80 + sizeof(MInt) * (2) // m_level, m_noChildIds
81 + sizeof(MFloat) * (s_dimensions) // m_coordinates_
82 + sizeof(MInt) * (s_maxNoSolvers) // m_noSolidLayer_ for max of 8 solvers!
83 );
84 }
int32_t MInt
Definition: maiatypes.h:62
double MFloat
Definition: maiatypes.h:52
int64_t MLong
Definition: maiatypes.h:64

Friends And Related Function Documentation

◆ GridgenPar

template<MInt nDim>
template<MInt nDim_>
friend class GridgenPar
friend

Definition at line 26 of file cartesiangridgencell.h.

Member Data Documentation

◆ b_properties_

template<MInt nDim>
std::array<char, s_maxNoSolvers> GridgenCell< nDim >::b_properties_
private

Definition at line 61 of file cartesiangridgencell.h.

◆ b_solverAffiliation_

template<MInt nDim>
std::array<char, s_maxNoSolvers> GridgenCell< nDim >::b_solverAffiliation_
private

Definition at line 63 of file cartesiangridgencell.h.

◆ b_solverBoundary_

template<MInt nDim>
std::array<char, s_maxNoSolvers> GridgenCell< nDim >::b_solverBoundary_
private

Definition at line 64 of file cartesiangridgencell.h.

◆ b_solverToRefine_

template<MInt nDim>
std::array<char, s_maxNoSolvers> GridgenCell< nDim >::b_solverToRefine_
private

Definition at line 65 of file cartesiangridgencell.h.

◆ m_childIds_

template<MInt nDim>
MLong* GridgenCell< nDim >::m_childIds_
private

Definition at line 47 of file cartesiangridgencell.h.

◆ m_coordinates_

template<MInt nDim>
MFloat* GridgenCell< nDim >::m_coordinates_
private

Definition at line 41 of file cartesiangridgencell.h.

◆ m_globalId_

template<MInt nDim>
MLong* GridgenCell< nDim >::m_globalId_
private

Definition at line 44 of file cartesiangridgencell.h.

◆ m_level_

template<MInt nDim>
MInt* GridgenCell< nDim >::m_level_
private

Definition at line 42 of file cartesiangridgencell.h.

◆ m_nghbrIds_

template<MInt nDim>
MLong* GridgenCell< nDim >::m_nghbrIds_
private

Definition at line 46 of file cartesiangridgencell.h.

◆ m_noChildIds_

template<MInt nDim>
MInt* GridgenCell< nDim >::m_noChildIds_
private

Definition at line 45 of file cartesiangridgencell.h.

◆ m_noSolidLayer_

template<MInt nDim>
MInt* GridgenCell< nDim >::m_noSolidLayer_
private

Definition at line 49 of file cartesiangridgencell.h.

◆ m_parentId_

template<MInt nDim>
MLong* GridgenCell< nDim >::m_parentId_
private

Definition at line 43 of file cartesiangridgencell.h.

◆ m_rfnDistance_

template<MInt nDim>
MInt GridgenCell< nDim >::m_rfnDistance_
private

Definition at line 48 of file cartesiangridgencell.h.

◆ s_dimensions

template<MInt nDim>
MInt GridgenCell< nDim >::s_dimensions
static

Definition at line 34 of file cartesiangridgencell.h.

◆ s_maxNoCells

template<MInt nDim>
MInt GridgenCell< nDim >::s_maxNoCells
static

Definition at line 33 of file cartesiangridgencell.h.

◆ s_maxNoSolvers

template<MInt nDim>
const MUint GridgenCell< nDim >::s_maxNoSolvers = 8
staticprivate

Definition at line 39 of file cartesiangridgencell.h.

◆ s_noChilds

template<MInt nDim>
MInt GridgenCell< nDim >::s_noChilds
static

Definition at line 35 of file cartesiangridgencell.h.

◆ s_noNghbrs

template<MInt nDim>
MInt GridgenCell< nDim >::s_noNghbrs
static

Definition at line 36 of file cartesiangridgencell.h.


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