AXOM
Axom provides a robust, flexible software infrastructure for the development of multi-physics applications and computational tools.
CellTypes.hpp File Reference
#include "axom/mint/config.hpp"

Classes

struct  axom::mint::CellInfo
 Holds information associated with a given cell type. More...
 

Namespaces

 axom
 
 axom::mint
 
 axom::mint::internal
 

Macros

#define REGISTER_CELL_INFO(MINT_CELL_TYPE, MINT_NAME, BP_NAME, VTK_TYPE, N_NODES, N_FACES, N_FACE_NODES, FACE_CELL_TYPES, FACE_NODES)
 Convenience macro used to register information about a cell type. More...
 
#define CELL_INFO(MINT_CELL_TYPE)   internal::MINT_CELL_TYPE##_INFO
 Convenience macro used to access a registered CellInfo struct for the specified mint cell type. More...
 
#define AR(...)   __VA_ARGS__
 

Enumerations

enum class  axom::mint::CellType : signed char {
  axom::mint::UNDEFINED_CELL = -1 , axom::mint::VERTEX , axom::mint::SEGMENT , axom::mint::TRIANGLE ,
  axom::mint::QUAD , axom::mint::TET , axom::mint::HEX , axom::mint::PRISM ,
  axom::mint::PYRAMID , axom::mint::QUAD9 , axom::mint::HEX27 , axom::mint::NUM_CELL_TYPES
}
 Enumerates all cell types supported by Mint. More...
 

Functions

constexpr int axom::mint::cellTypeToInt (CellType type)
 Return the underlying integer associated with the given CellType. More...
 
constexpr const CellInfo & axom::mint::getCellInfo (CellType type)
 Return the CellInfo struct associated with the given type. More...
 

Variables

static constexpr int axom::mint::MAX_CELL_NODES = 27
 
static constexpr int axom::mint::MAX_CELL_FACES = 6
 
static constexpr int axom::mint::MAX_FACE_NODES = 9
 
static constexpr int axom::mint::MAX_ALL_FACES_NODES = MAX_CELL_FACES * MAX_FACE_NODES
 
constexpr CellType axom::mint::UNDEFINED_CELL = CellType::UNDEFINED_CELL
 
constexpr CellType axom::mint::VERTEX = CellType::VERTEX
 
constexpr CellType axom::mint::SEGMENT = CellType::SEGMENT
 
constexpr CellType axom::mint::TRIANGLE = CellType::TRIANGLE
 
constexpr CellType axom::mint::QUAD = CellType::QUAD
 
constexpr CellType axom::mint::TET = CellType::TET
 
constexpr CellType axom::mint::HEX = CellType::HEX
 
constexpr CellType axom::mint::PRISM = CellType::PRISM
 
constexpr CellType axom::mint::PYRAMID = CellType::PYRAMID
 
constexpr CellType axom::mint::QUAD9 = CellType::QUAD9
 
constexpr CellType axom::mint::HEX27 = CellType::HEX27
 
constexpr int axom::mint::NUM_CELL_TYPES = static_cast<int>(CellType::NUM_CELL_TYPES)
 
static const CellInfo axom::mint::internal::VERTEX_INFO = { VERTEX , "VERTEX" , "point" , 1 , 1 , 0 , {0} , {UNDEFINED_CELL} , {0} }
 
static const CellInfo axom::mint::internal::SEGMENT_INFO = { SEGMENT , "SEGMENT" , "line" , 3 , 2 , 0 , {0} , {UNDEFINED_CELL} , { 0, 1 } }
 
static const CellInfo axom::mint::internal::TRIANGLE_INFO = { TRIANGLE , "TRIANGLE" , "tri" , 5 , 3 , 3 , {2, 2, 2} , {SEGMENT, SEGMENT, SEGMENT} , { 0, 1, 1, 2, 2, 0 } }
 
static const CellInfo axom::mint::internal::QUAD_INFO = { QUAD , "QUAD" , "quad" , 9 , 4 , 4 , {2, 2, 2, 2} , {SEGMENT, SEGMENT, SEGMENT, SEGMENT} , { 0, 1, 1, 2, 2, 3, 3, 0 } }
 
static const CellInfo axom::mint::internal::TET_INFO = { TET , "TET" , "tet" , 10 , 4 , 4 , {3, 3, 3, 3} , {TRIANGLE, TRIANGLE, TRIANGLE, TRIANGLE} , { 0, 2, 1, 0, 3, 2, 0, 1, 3, 1, 2, 3 } }
 
static const CellInfo axom::mint::internal::HEX_INFO = { HEX , "HEX" , "hex" , 12 , 8 , 6 , {4, 4, 4, 4, 4, 4} , {QUAD, QUAD, QUAD, QUAD, QUAD, QUAD} , { 0, 3, 2, 1, 1, 2, 6, 5, 1, 5, 4, 0, 0, 4, 7, 3, 7, 6, 2, 3, 4, 5, 6, 7 } }
 
static const CellInfo axom::mint::internal::PRISM_INFO = { PRISM , "PRISM" , "prism-no-bp" , 13 , 6 , 5 , {3, 4, 4, 4, 3} , {TRIANGLE, QUAD, QUAD, QUAD, TRIANGLE} , { 0, 1, 2, 0, 2, 5, 3, 0, 3, 4, 1, 1, 4, 5, 2, 3, 5, 4 } }
 
static const CellInfo axom::mint::internal::PYRAMID_INFO = { PYRAMID , "PYRAMID" , "pyramid-no-bp" , 14 , 5 , 5 , {4, 3, 3, 3, 3} , {QUAD, TRIANGLE, TRIANGLE, TRIANGLE, TRIANGLE} , { 0, 3, 2, 1, 0, 1, 4, 1, 2, 4, 2, 3, 4, 3, 0, 4 } }
 
static const CellInfo axom::mint::internal::QUAD9_INFO = { QUAD9 , "QUAD9" , "quad9-no-bp" , 28 , 9 , 4 , {2, 2, 2, 2} , {SEGMENT, SEGMENT, SEGMENT, SEGMENT} , { 0, 1, 1, 2, 2, 3, 3, 0 } }
 
static const CellInfo axom::mint::internal::HEX27_INFO = { HEX27 , "HEX27" , "hex27-no-bp" , 29 , 27 , 6 , {9, 9, 9, 9, 9, 9} , {QUAD9, QUAD9, QUAD9, QUAD9, QUAD9, QUAD9} , { 0, 3, 2, 1, 11, 10, 9, 8, 24, 1, 2, 6, 5, 9, 18, 13, 17, 21, 1, 5, 4, 0, 17, 12, 16, 8, 22, 0, 4, 7, 3, 16, 15, 19, 11, 20, 7, 6, 2, 3, 14, 18, 10, 19, 23, 4, 5, 6, 7, 12, 13, 14, 15, 25 } }
 
static const CellInfo axom::mint::cell_info [NUM_CELL_TYPES]
 Array of CellInfo corresponding to each cell type. More...
 

Macro Definition Documentation

◆ REGISTER_CELL_INFO

#define REGISTER_CELL_INFO (   MINT_CELL_TYPE,
  MINT_NAME,
  BP_NAME,
  VTK_TYPE,
  N_NODES,
  N_FACES,
  N_FACE_NODES,
  FACE_CELL_TYPES,
  FACE_NODES 
)
Value:
namespace internal \
{ \
static const CellInfo MINT_CELL_TYPE##_INFO = {MINT_CELL_TYPE, \
MINT_NAME, \
BP_NAME, \
VTK_TYPE, \
N_NODES, \
N_FACES, \
N_FACE_NODES, \
FACE_CELL_TYPES, \
FACE_NODES}; \
}

Convenience macro used to register information about a cell type.

Parameters
MINT_CELL_TYPEthe mint cell type, e.g., mint::QUAD, mint::HEX, etc.
MINT_NAMEthe associated mint name for the cell type.
BP_NAMEthe associated name in the mesh blueprint.
VTK_TYPEthe corresponding VTK type.
N_NODESthe number of nodes that the cell has.
N_FACESthe number of faces that the cell has.
N_FACE_NODESan array; the number of nodes that each face has.
FACE_CELL_TYPESan array; the VTK type of each face.
FACE_NODESan array; the node offsets specifying each face (CCW, so normal points out).

◆ CELL_INFO

#define CELL_INFO (   MINT_CELL_TYPE)    internal::MINT_CELL_TYPE##_INFO

Convenience macro used to access a registered CellInfo struct for the specified mint cell type.

Parameters
MINT_CELL_TYPEthe mint cell type, e.g., mint::QUAD, mint::HEX, etc.

◆ AR

#define AR (   ...)    __VA_ARGS__