Panzer  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Functions
panzer_stk::workset_utils Namespace Reference

Functions

void getSubcellElements (const panzer_stk::STK_Interface &mesh, const std::string &blockId, const std::vector< stk::mesh::Entity > &entities, std::vector< std::size_t > &localEntityIds, std::vector< stk::mesh::Entity > &elements)
 
void getUniversalSubcellElements (const panzer_stk::STK_Interface &mesh, const std::string &blockId, const std::vector< stk::mesh::Entity > &entities, std::vector< std::size_t > &localEntityIds, std::vector< stk::mesh::Entity > &elements, std::vector< std::size_t > &missingElementIndices)
 
void getSideElementCascade (const panzer_stk::STK_Interface &mesh, const std::string &blockId, const std::vector< stk::mesh::Entity > &sides, std::vector< std::size_t > &localSubcellDim, std::vector< std::size_t > &localSubcellIds, std::vector< stk::mesh::Entity > &elements)
 
void getSideElements (const panzer_stk::STK_Interface &mesh, const std::string &blockId, const std::vector< stk::mesh::Entity > &sides, std::vector< std::size_t > &localSideIds, std::vector< stk::mesh::Entity > &elements)
 
void getSideElements (const panzer_stk::STK_Interface &mesh, const std::string &blockId_a, const std::string &blockId_b, const std::vector< stk::mesh::Entity > &sides, std::vector< std::size_t > &localSideIds_a, std::vector< stk::mesh::Entity > &elements_a, std::vector< std::size_t > &localSideIds_b, std::vector< stk::mesh::Entity > &elements_b)
 
void getNodeElements (const panzer_stk::STK_Interface &mesh, const std::string &blockId, const std::vector< stk::mesh::Entity > &nodes, std::vector< std::size_t > &localNodeIds, std::vector< stk::mesh::Entity > &elements)
 
void getSubcellEntities (const panzer_stk::STK_Interface &mesh, const std::vector< stk::mesh::Entity > &entities, std::vector< std::vector< stk::mesh::Entity > > &subcells)
 
template<typename ArrayT >
void getIdsAndVertices (const panzer_stk::STK_Interface &mesh, std::string blockId, std::vector< std::size_t > &localIds, ArrayT &vertices)
 
template<typename ArrayT >
void getIdsAndNodes (const panzer_stk::STK_Interface &mesh, std::string blockId, std::vector< std::size_t > &localIds, ArrayT &nodes)
 

Function Documentation

void panzer_stk::workset_utils::getSubcellElements ( const panzer_stk::STK_Interface mesh,
const std::string &  blockId,
const std::vector< stk::mesh::Entity > &  entities,
std::vector< std::size_t > &  localEntityIds,
std::vector< stk::mesh::Entity > &  elements 
)

This function loops over the passed in set of entities and looks at their related elements. It is then determined which elements belong in the requested element block, and what the local ID of the entitiy is.

Parameters
[in]meshSTK mesh interface
[in]blockIdRequested element block identifier
[in]entitiesSet of subcell entities where there is assumed part membership (induced or not) in the requested element block.
[out]localEntityIdsOn output this will contain the local entity ids. Assumed that on input entities.size()==0
[out]elementsOn output this will contain the elements associated with each entity in the requested block. Assumed that on input elements.size()==0
[in]onProcOnlyOnly return the elements owned by this processor
Note
Some elements may be repeated in the lists, however the local entity ID should be distinct for each of those.

Definition at line 328 of file Panzer_STK_SetupUtilities.cpp.

void panzer_stk::workset_utils::getUniversalSubcellElements ( const panzer_stk::STK_Interface mesh,
const std::string &  blockId,
const std::vector< stk::mesh::Entity > &  entities,
std::vector< std::size_t > &  localEntityIds,
std::vector< stk::mesh::Entity > &  elements,
std::vector< std::size_t > &  missingElementIndices 
)

This function loops over the passed in set of entities and looks at their related elements. It is then determined which elements belong in the requested element block, and what the local ID of the entitiy is. It also collects the element indices related to the set of entities that do not belong to the requested element block and its neighbor is ghosted. This will return both local and ghosted entities.

Parameters
[in]meshSTK mesh interface
[in]blockIdRequested element block identifier
[in]entitiesSet of subcell entities where there is assumed part membership (induced or not) in the requested element block.
[out]localEntityIdsOn output this will contain the local entity ids. Assumed that on input entities.size()==0
[out]elementsOn output this will contain the elements associated with each entity in the requested block. Assumed that on input elements.size()==0
[out]missingElementIndicesOn output this will contain the elements associated with each entity in the passed set, but it is not in the requested block and its neighbor belonging the to the block is a ghost element. Assumed that on input entities.size()==0
Note
Some elements may be repeated in the lists, however the local entity ID should be distinct for each of those.

Definition at line 365 of file Panzer_STK_SetupUtilities.cpp.

void panzer_stk::workset_utils::getSideElementCascade ( const panzer_stk::STK_Interface mesh,
const std::string &  blockId,
const std::vector< stk::mesh::Entity > &  sides,
std::vector< std::size_t > &  localSubcellDim,
std::vector< std::size_t > &  subcellIds,
std::vector< stk::mesh::Entity > &  elements 
)

This function builds the "element cascade" contained within a specfied element block. That is given a set of "sides" extract all elements that live in the block and touch those sides on a node, edge or face. It returns the local sub cell index and sub cell dimension.

Parameters
[in]\param[in]mesh STK mesh interface
[in]blockIdRequested element block identifier
[in]sidesSet of sides (entities of dimension-1) where there is assumed part membership (induced or not) in the requested element block.
[out]subcellDimOn output this will contain the subcell dimensions.
[out]localSubcellIdsOn output this will contain the local subcell ids.
[out]elementsOn output this will contain the elements associated with each subcell in the requested block. Assumed that on input elements.size()==0

Definition at line 409 of file Panzer_STK_SetupUtilities.cpp.

void panzer_stk::workset_utils::getSideElements ( const panzer_stk::STK_Interface mesh,
const std::string &  blockId,
const std::vector< stk::mesh::Entity > &  sides,
std::vector< std::size_t > &  localSideIds,
std::vector< stk::mesh::Entity > &  elements 
)

This function loops over the passed in set of "Sides" and looks at there related elements. It is then determined which elements belong in the requested element block, and what the local ID of the side is.

Parameters
[in]meshSTK mesh interface
[in]blockIdRequested element block identifier
[in]sidesSet of sides (entities of dimension-1) where there is assumed part membership (induced or not) in the requested element block.
[out]localSideIdsOn output this will contain the local side ids. Assumed that on input sides.size()==0
[out]elementsOn output this will contain the elements associated with each side in the requested block. Assumed that on input elements.size()==0
Note
Some elements may be repeated in the lists, however the local side ID should be distinct for each of those.

Definition at line 445 of file Panzer_STK_SetupUtilities.cpp.

void panzer_stk::workset_utils::getSideElements ( const panzer_stk::STK_Interface mesh,
const std::string &  blockId_a,
const std::string &  blockId_b,
const std::vector< stk::mesh::Entity > &  sides,
std::vector< std::size_t > &  localSideIds_a,
std::vector< stk::mesh::Entity > &  elements_a,
std::vector< std::size_t > &  localSideIds_b,
std::vector< stk::mesh::Entity > &  elements_b 
)

This function loops over the passed in set of "Sides" and looks at there related elements. It is then determined which elements belong in the requested element block, and what the local ID of the side is. This version is for sides where you want elements that live in two element blocks. The "a" elements are required to be owned, the "b" elements maybe ghosted.

Parameters
[in]meshSTK mesh interface
[in]blockId_aRequested element block identifier (owned only)
[in]blockId_bRequested element block identifier (owned and ghosted)
[in]sidesSet of sides (entities of dimension-1) where there is assumed part membership (induced or not) in the requested element block.
[out]localSideIds_aOn output this will contain the local side ids for elements in block "a". Assumed that on input sides.size()==0
[out]elements_aOn output this will contain the elements associated with each side in the "a" block. Assumed that on input elements.size()==0
[out]localSideIds_bOn output this will contain the local side ids for elements in block "b". Assumed that on input sides.size()==0
[out]elements_bOn output this will contain the elements associated with each side in the "b" block. Assumed that on input elements.size()==0
Note
Some elements may be repeated in the lists, however the local side ID should be distinct for each of those.

Definition at line 454 of file Panzer_STK_SetupUtilities.cpp.

void panzer_stk::workset_utils::getNodeElements ( const panzer_stk::STK_Interface mesh,
const std::string &  blockId,
const std::vector< stk::mesh::Entity > &  nodes,
std::vector< std::size_t > &  localNodeIds,
std::vector< stk::mesh::Entity > &  elements 
)

This function loops over the passed in set of "Nodes" and looks at there related elements. It is then determined which elements belong in the requested element block, and what the local ID of the node is.

Parameters
[in]meshSTK mesh interface
[in]blockIdRequested element block identifier
[in]nodesSet of nodes (entities of dimension 0) where there is assumed part membership (induced or not) in the requested element block.
[out]localNodeIdsOn output this will contain the local node ids. Assumed that on input node.size()==0
[out]elementsOn output this will contain the elements associated with each node in the requested block. Assumed that on input elements.size()==0
Note
Some elements may be repeated in the lists, however the local node ID should be distinct for each of those.

Definition at line 517 of file Panzer_STK_SetupUtilities.cpp.

void panzer_stk::workset_utils::getSubcellEntities ( const panzer_stk::STK_Interface mesh,
const std::vector< stk::mesh::Entity > &  entities,
std::vector< std::vector< stk::mesh::Entity > > &  subcells 
)

Get all the subcells that are contained within the list of entities. The resulting vector is organized by dimension and it is guranteed that no entity is included more then once.

Parameters
[in]meshSTK mesh interface
[in]entitiesSet of entities of the same dimension, these the parent entities whose subcells are extracted.
[out]subcellsSet of subcells catoragized by dimension. The first index is the physical dimension. Each entity in the vector will be unique. Note that this vector is cleared at the beginning of this method.

Definition at line 526 of file Panzer_STK_SetupUtilities.cpp.

template<typename ArrayT >
void panzer_stk::workset_utils::getIdsAndVertices ( const panzer_stk::STK_Interface mesh,
std::string  blockId,
std::vector< std::size_t > &  localIds,
ArrayT &  vertices 
)

Get vertices and local cell IDs of a paricular element block.

Parameters
[in]meshReference to STK_Interface object
[in]blockIdElement block identifier string
[out]localIdsOn processor local element IDs for the element block
[out]verticesAbstract array type (requires resize) containing the coordinates of the vertices. Of size (#Cells, #Vertices, #Dim).

Definition at line 19 of file Panzer_STK_SetupUtilities_impl.hpp.

template<typename ArrayT >
void panzer_stk::workset_utils::getIdsAndNodes ( const panzer_stk::STK_Interface mesh,
std::string  blockId,
std::vector< std::size_t > &  localIds,
ArrayT &  nodes 
)

Get nodes and local cell IDs of a particular element block.

Parameters
[in]meshReference to STK_Interface object
[in]blockIdElement block identifier string
[out]localIdsOn processor local element IDs for the element block
[out]nodesAbstract array type (requires resize) containing the coordinates of the nodes. Of size (#Cells, #Nodes, #Dim).

Definition at line 40 of file Panzer_STK_SetupUtilities_impl.hpp.