SPHinXsys
alpha version
|
Abstract base class for cell-based mesh by introducing number of cells, buffer width and mesh-based data in its derived classes. Note that we identify the difference between grid spacing and data spacing. The latter is different from grid spacing when MeshWithDataPackage is considered. More...
#include <base_mesh.h>
Inherits SPH::BaseMesh.
Inherited by SPH::MeshWithGridDataPackages< BaseLevelSet, LevelSetDataPackage >, SPH::CellLinkedList, and SPH::MeshWithGridDataPackages< MeshFieldType, GridDataPackageType >.
Public Member Functions | |
Mesh (BoundingBox tentative_bounds, Real grid_spacing, size_t buffer_width) | |
Mesh (Vecd mesh_lower_bound, Vecu number_of_cells, Real grid_spacing) | |
Vecu | NumberOfCells () |
size_t | MeshBufferSize () |
virtual Real | DataSpacing () |
Public Member Functions inherited from SPH::BaseMesh | |
BaseMesh (Vecu number_of_grid_points) | |
BaseMesh (Vecd mesh_lower_bound, Real grid_spacing, Vecu number_of_grid_points) | |
BaseMesh (BoundingBox tentative_bounds, Real grid_spacing, size_t buffer_width) | |
Vecd | MeshLowerBound () |
Real | GridSpacing () |
Vecu | NumberOfGridPoints () |
Vecu | NumberOfGridPointsFromNumberOfCells (const Vecu &number_of_cells) |
Vecu | NumberOfCellsFromNumberOfGridPoints (const Vecu &number_of_grid_points) |
Vecd | GridPositionFromCellPosition (const Vecd &cell_position) |
Vecu | CellIndexFromPosition (const Vecd &position) |
Vecd | CellPositionFromIndex (const Vecu &cell_index) |
Vecd | GridPositionFromIndex (const Vecu &grid_index) |
Vecu | transfer1DtoMeshIndex (const Vecu &number_of_mesh_indexes, size_t i) |
size_t | transferMeshIndexTo1D (const Vecu &number_of_mesh_indexes, const Vecu &mesh_index) |
size_t | MortonCode (const size_t &i) |
size_t | transferMeshIndexToMortonOrder (const Vecu &mesh_index) |
Protected Member Functions | |
void | copyMeshProperties (Mesh *another_mesh) |
Protected Attributes | |
size_t | buffer_width_ |
Vecu | number_of_cells_ |
Protected Attributes inherited from SPH::BaseMesh | |
Vecd | mesh_lower_bound_ |
Real | grid_spacing_ |
Vecu | number_of_grid_points_ |
Abstract base class for cell-based mesh by introducing number of cells, buffer width and mesh-based data in its derived classes. Note that we identify the difference between grid spacing and data spacing. The latter is different from grid spacing when MeshWithDataPackage is considered.
|
protected |
buffer width to avoid bound check.
|
protected |
number of cells by dimension