# PhasicFlow: cellMapper Class Reference
PhasicFlow is an open-source parallel DEM (discrete element method) package for simulating granular flow. It is developed in C++ and can be exectued on both GPU (like CUDA) and CPU.

cellMapper Class Reference
Collaboration diagram for cellMapper:
[legend]

## Classes

class | CellIterator

## Public Types

using | HeadType = hostViewType3D< uint32 >
using | NextType = hostViewType1D< uint32 >

## Public Member Functions

| TypeInfoNV ("cellMapper")
| cellMapper (const rectangleMesh &rectMesh, const hostViewType1D< realx3 > &pointPos, const pFlagTypeHost &flags)
INLINE_FUNCTION_HD | cellMapper (const cellMapper &)=default
INLINE_FUNCTION_HD | cellMapper (cellMapper &&)=default
INLINE_FUNCTION_HD cellMapper & | operator= (const cellMapper &)=default
INLINE_FUNCTION_HD cellMapper & | operator= (cellMapper &&)=default
INLINE_FUNCTION_HD | ~cellMapper ()=default
auto | getCellIterator () const
bool | build (const hostViewType1D< realx3 > &pointPos, const pFlagTypeHost &flags)

## Static Public Attributes

static constexpr uint32 | NoPos = 0xFFFFFFFF

## Private Member Functions

void | allocateArrays (rangeU32 nextRng)
void | checkAllocateNext (rangeU32 nextRng)
void | nullifyHead ()
void | nullifyNext (rangeU32 nextRng)

## Private Attributes

const rectangleMesh & | domainCells_
HeadType | head_ {"NBS::head",1,1,1}
NextType | next_ {"NBS::next", 1}
uint32 | nextCapacity_ = 0

## Detailed Description

Definition at line 33 of file cellMapper.hpp.

## Member Typedef Documentation

## HeadType

using HeadType = hostViewType3D<uint32>

Definition at line 37 of file cellMapper.hpp.

## NextType

using NextType = hostViewType1D<uint32>

Definition at line 39 of file cellMapper.hpp.

## Constructor & Destructor Documentation

## cellMapper() [1/3]

cellMapper | ( | const rectangleMesh & | rectMesh,
|  | const hostViewType1D< realx3 > & | pointPos,
|  | const pFlagTypeHost & | flags
| ) |  |

Definition at line 55 of file cellMapper.cpp.

References pointFlag< ExecutionSpace >::activeRange(), and cellMapper::allocateArrays().

Here is the call graph for this function:

## cellMapper() [2/3]

INLINE_FUNCTION_HD cellMapper | ( | const cellMapper & |  | ) |

default

## cellMapper() [3/3]

INLINE_FUNCTION_HD cellMapper | ( | cellMapper && |  | ) |

default

## ~cellMapper()

INLINE_FUNCTION_HD ~cellMapper | ( |  | ) |

default

## Member Function Documentation

## allocateArrays()

void allocateArrays | ( | rangeU32 | nextRng | ) |

private

Definition at line 26 of file cellMapper.cpp.

References cellMapper::checkAllocateNext(), cellMapper::domainCells_, cellMapper::head_, cellMapper::NoPos, cellMapper::nullifyNext(), rectangleMesh::nx(), rectangleMesh::ny(), rectangleMesh::nz(), and pFlow::reallocFill().

Referenced by cellMapper::cellMapper().

Here is the call graph for this function:
Here is the caller graph for this function:

## checkAllocateNext()

void checkAllocateNext | ( | rangeU32 | nextRng | ) |

private

Definition at line 33 of file cellMapper.cpp.

References Range< T >::end(), and pFlow::reallocNoInit().

Referenced by cellMapper::allocateArrays().

Here is the call graph for this function:
Here is the caller graph for this function:

## nullifyHead()

void nullifyHead | ( |  | ) |

private

Definition at line 45 of file cellMapper.cpp.

References pFlow::fill().

Here is the call graph for this function:

## nullifyNext()

void nullifyNext | ( | rangeU32 | nextRng | ) |

private

Definition at line 50 of file cellMapper.cpp.

References pFlow::fill().

Referenced by cellMapper::allocateArrays().

Here is the call graph for this function:
Here is the caller graph for this function:

## TypeInfoNV()

TypeInfoNV | ( | "cellMapper" |  | ) |

## operator=() [1/2]

INLINE_FUNCTION_HD cellMapper& operator= | ( | const cellMapper & |  | ) |

default

## operator=() [2/2]

INLINE_FUNCTION_HD cellMapper& operator= | ( | cellMapper && |  | ) |

default

## getCellIterator()

auto getCellIterator | ( |  | ) | const

inline

Definition at line 124 of file cellMapper.hpp.

References cellMapper::head_, and cellMapper::next_.

Referenced by pointRectCell::getCellIterator(), and pointRectCell::mapPOints().

Here is the caller graph for this function:

## build()

bool build | ( | const hostViewType1D< realx3 > & | pointPos,
|  | const pFlagTypeHost & | flags
| ) |  |

Definition at line 68 of file cellMapper.cpp.

References pointFlag< ExecutionSpace >::activeRange(), triple< T >::x(), triple< T >::y(), and triple< T >::z().

Referenced by pointRectCell::mapPOints().

Here is the call graph for this function:
Here is the caller graph for this function:

## Member Data Documentation

## NoPos

constexpr uint32 NoPos = 0xFFFFFFFF

staticconstexpr

Definition at line 42 of file cellMapper.hpp.

Referenced by cellMapper::allocateArrays(), pointRectCell::mapPOints(), pFlow::sumMaksOp(), and pFlow::sumOp().

## domainCells_

const rectangleMesh& domainCells_

private

Definition at line 81 of file cellMapper.hpp.

Referenced by cellMapper::allocateArrays().

## head_

HeadType head_ {"NBS::head",1,1,1}

private

Definition at line 83 of file cellMapper.hpp.

Referenced by cellMapper::allocateArrays(), and cellMapper::getCellIterator().

## next_

NextType next_ {"NBS::next", 1}

private

Definition at line 85 of file cellMapper.hpp.

Referenced by cellMapper::getCellIterator().

## nextCapacity_

uint32 nextCapacity_ = 0

private

Definition at line 87 of file cellMapper.hpp.

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

- utilities/postprocessPhasicFlow/cellMapper.hpp
- utilities/postprocessPhasicFlow/cellMapper.cpp