OpenFPM_pdata  4.1.0
Project that contain the implementation of distributed structures
HeatStencil< dim, p_src, p_dst > Struct Template Reference

Detailed Description

template<unsigned int dim, unsigned int p_src, unsigned int p_dst>
struct HeatStencil< dim, p_src, p_dst >

Definition at line 202 of file SparseGridGpu_util_test.cuh.

Public Types

typedef NNStar< dim > stencil_type
 

Static Public Member Functions

template<typename SparseGridT , typename DataBlockWrapperT >
static __device__ void stencil (SparseGridT &sparseGrid, const unsigned int dataBlockId, const openfpm::sparse_index< unsigned int > dataBlockIdPos, const unsigned int offset, const grid_key_dx< dim, int > &pointCoord, const DataBlockWrapperT &dataBlockLoad, DataBlockWrapperT &dataBlockStore, unsigned char curMask, float dt)
 Stencil function. More...
 
template<typename SparseGridT , typename DataBlockWrapperT >
static __host__ void stencilHost (SparseGridT &sparseGrid, const unsigned int dataBlockId, const openfpm::sparse_index< unsigned int > dataBlockIdPos, const unsigned int offset, const grid_key_dx< dim, int > &pointCoord, const DataBlockWrapperT &dataBlockLoad, DataBlockWrapperT &dataBlockStore, bool isActive, float dt)
 Stencil Host function. More...
 
template<typename SparseGridT , typename CtxT >
static void __host__ flush (SparseGridT &sparseGrid, CtxT &ctx)
 

Static Public Attributes

static constexpr unsigned int flops = 3 + 2*dim
 
static constexpr unsigned int supportRadius = 1
 

Member Function Documentation

◆ stencil()

template<unsigned int dim, unsigned int p_src, unsigned int p_dst>
template<typename SparseGridT , typename DataBlockWrapperT >
static __device__ void HeatStencil< dim, p_src, p_dst >::stencil ( SparseGridT &  sparseGrid,
const unsigned int  dataBlockId,
const openfpm::sparse_index< unsigned int >  dataBlockIdPos,
const unsigned int  offset,
const grid_key_dx< dim, int > &  pointCoord,
const DataBlockWrapperT &  dataBlockLoad,
DataBlockWrapperT &  dataBlockStore,
unsigned char  curMask,
float  dt 
)
inlinestatic

Stencil function.

Parameters
sparseGridThis is the sparse grid data-structure
dataBlockIdThe id of the block
offsetindex in local coordinate of the point where we are working
dataBlockLoaddataBlock from where we read
dataBlockStoredataBlock from where we write
isActivethe point is active if exist and is not padding
dtdelta t

Definition at line 225 of file SparseGridGpu_util_test.cuh.

◆ stencilHost()

template<unsigned int dim, unsigned int p_src, unsigned int p_dst>
template<typename SparseGridT , typename DataBlockWrapperT >
static __host__ void HeatStencil< dim, p_src, p_dst >::stencilHost ( SparseGridT &  sparseGrid,
const unsigned int  dataBlockId,
const openfpm::sparse_index< unsigned int >  dataBlockIdPos,
const unsigned int  offset,
const grid_key_dx< dim, int > &  pointCoord,
const DataBlockWrapperT &  dataBlockLoad,
DataBlockWrapperT &  dataBlockStore,
bool  isActive,
float  dt 
)
inlinestatic

Stencil Host function.

Parameters
sparseGridThis is the sparse grid data-structure
dataBlockIdThe id of the block
offsetindex in local coordinate of the point where we are working
dataBlockLoaddataBlock from where we read
dataBlockStoredataBlock from where we write
isActivethe point is active if exist and is not padding
dtdelta t

Definition at line 293 of file SparseGridGpu_util_test.cuh.


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