Panzer  Version of the Day
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
panzer_stk::SquareQuadMeshFactory Class Reference

#include <Panzer_STK_SquareQuadMeshFactory.hpp>

Inheritance diagram for panzer_stk::SquareQuadMeshFactory:
Inheritance graph
[legend]

Public Member Functions

 SquareQuadMeshFactory (bool enableRebalance=false)
 Constructor. More...
 
 ~SquareQuadMeshFactory ()
 Destructor. More...
 
Teuchos::RCP< STK_InterfacebuildMesh (stk::ParallelMachine parallelMach) const
 Build the mesh object. More...
 
virtual Teuchos::RCP< STK_InterfacebuildUncommitedMesh (stk::ParallelMachine parallelMach) const
 
virtual void completeMeshConstruction (STK_Interface &mesh, stk::ParallelMachine parallelMach) const
 
void setParameterList (const Teuchos::RCP< Teuchos::ParameterList > &paramList)
 From ParameterListAcceptor. More...
 
Teuchos::RCP< const Teuchos::ParameterList > getValidParameters () const
 From ParameterListAcceptor. More...
 
Teuchos::Tuple< std::size_t, 2 > procRankToProcTuple (std::size_t procRank) const
 what is the 2D tuple describe this processor distribution More...
 
- Public Member Functions inherited from panzer_stk::STK_MeshFactory
 STK_MeshFactory ()
 
void enableRebalance (bool enable, const Teuchos::RCP< const Teuchos::ParameterList > &rebalanceList=Teuchos::null)
 
void rebalance (STK_Interface &mesh) const
 
double getMeshCoord (const int nx, const double deltaX, const double x0) const
 

Protected Member Functions

void initializeWithDefaults ()
 
void buildMetaData (stk::ParallelMachine parallelMach, STK_Interface &mesh) const
 
void buildElements (stk::ParallelMachine parallelMach, STK_Interface &mesh) const
 
void buildBlock (stk::ParallelMachine machRank, int xBlock, int yBlock, STK_Interface &mesh) const
 
std::pair< int, int > determineXElemSizeAndStart (int xBlock, unsigned int size, unsigned int rank) const
 
std::pair< int, int > determineYElemSizeAndStart (int yBlock, unsigned int size, unsigned int rank) const
 
void addSideSets (STK_Interface &mesh) const
 
void addNodeSets (STK_Interface &mesh) const
 
void addEdgeBlocks (STK_Interface &mesh) const
 

Protected Attributes

double x0_
 
double y0_
 
double xf_
 
double yf_
 
int xBlocks_
 
int yBlocks_
 
int nXElems_
 
int nYElems_
 
int xProcs_
 
int yProcs_
 
unsigned int machRank_
 
unsigned int machSize_
 
Teuchos::Tuple< std::size_t, 2 > procTuple_
 
bool createEdgeBlocks_
 
bool offsetGIDs_
 If true, offset mesh GIDs to exercise 32-bit limits. More...
 
stk::mesh::EntityId offset_
 
- Protected Attributes inherited from panzer_stk::STK_MeshFactory
std::vector< Teuchos::RCP< const PeriodicBC_MatcherBase > > periodicBCVec_
 
bool enableRebalance_
 
Teuchos::RCP< const Teuchos::ParameterList > rebalanceList_
 

Additional Inherited Members

- Static Public Member Functions inherited from panzer_stk::STK_MeshFactory
static void parsePeriodicBCList (const Teuchos::RCP< Teuchos::ParameterList > &pl, std::vector< Teuchos::RCP< const PeriodicBC_MatcherBase > > &periodicBC)
 

Detailed Description

This builds a parallel mesh object. Note that the local IDs are ordered by going up the y axis and across the X-axis (in that order). For a mesh with two X blocks and one Y-block, with each block composed of 3x2 elements the numbering looks like:

 8  9 10 11
 4  5  6  7
 0  1  2  3 

Definition at line 64 of file Panzer_STK_SquareQuadMeshFactory.hpp.

Constructor & Destructor Documentation

◆ SquareQuadMeshFactory()

panzer_stk::SquareQuadMeshFactory::SquareQuadMeshFactory ( bool  enableRebalance = false)

Constructor.

Definition at line 55 of file Panzer_STK_SquareQuadMeshFactory.cpp.

◆ ~SquareQuadMeshFactory()

panzer_stk::SquareQuadMeshFactory::~SquareQuadMeshFactory ( )

Destructor.

Definition at line 61 of file Panzer_STK_SquareQuadMeshFactory.cpp.

Member Function Documentation

◆ buildMesh()

Teuchos::RCP< STK_Interface > panzer_stk::SquareQuadMeshFactory::buildMesh ( stk::ParallelMachine  parallelMach) const
virtual

Build the mesh object.

Implements panzer_stk::STK_MeshFactory.

Definition at line 66 of file Panzer_STK_SquareQuadMeshFactory.cpp.

◆ buildUncommitedMesh()

Teuchos::RCP< STK_Interface > panzer_stk::SquareQuadMeshFactory::buildUncommitedMesh ( stk::ParallelMachine  parallelMach) const
virtual

This builds all the meta data of the mesh. Does not call metaData->commit. Allows user to add solution fields and other pieces. The mesh can be "completed" by calling completeMeshConstruction.

Implements panzer_stk::STK_MeshFactory.

Definition at line 82 of file Panzer_STK_SquareQuadMeshFactory.cpp.

◆ completeMeshConstruction()

void panzer_stk::SquareQuadMeshFactory::completeMeshConstruction ( STK_Interface mesh,
stk::ParallelMachine  parallelMach 
) const
virtual

Finishes building a mesh object started by buildUncommitedMesh.

Implements panzer_stk::STK_MeshFactory.

Definition at line 148 of file Panzer_STK_SquareQuadMeshFactory.cpp.

◆ setParameterList()

void panzer_stk::SquareQuadMeshFactory::setParameterList ( const Teuchos::RCP< Teuchos::ParameterList > &  paramList)

From ParameterListAcceptor.

Definition at line 184 of file Panzer_STK_SquareQuadMeshFactory.cpp.

◆ getValidParameters()

Teuchos::RCP< const Teuchos::ParameterList > panzer_stk::SquareQuadMeshFactory::getValidParameters ( ) const

From ParameterListAcceptor.

Definition at line 214 of file Panzer_STK_SquareQuadMeshFactory.cpp.

◆ procRankToProcTuple()

Teuchos::Tuple< std::size_t, 2 > panzer_stk::SquareQuadMeshFactory::procRankToProcTuple ( std::size_t  procRank) const

what is the 2D tuple describe this processor distribution

Convert processor rank to a tuple.

Definition at line 596 of file Panzer_STK_SquareQuadMeshFactory.cpp.

◆ initializeWithDefaults()

void panzer_stk::SquareQuadMeshFactory::initializeWithDefaults ( )
protected

Definition at line 254 of file Panzer_STK_SquareQuadMeshFactory.cpp.

◆ buildMetaData()

void panzer_stk::SquareQuadMeshFactory::buildMetaData ( stk::ParallelMachine  parallelMach,
STK_Interface mesh 
) const
protected

Definition at line 263 of file Panzer_STK_SquareQuadMeshFactory.cpp.

◆ buildElements()

void panzer_stk::SquareQuadMeshFactory::buildElements ( stk::ParallelMachine  parallelMach,
STK_Interface mesh 
) const
protected

Definition at line 315 of file Panzer_STK_SquareQuadMeshFactory.cpp.

◆ buildBlock()

void panzer_stk::SquareQuadMeshFactory::buildBlock ( stk::ParallelMachine  machRank,
int  xBlock,
int  yBlock,
STK_Interface mesh 
) const
protected

Definition at line 327 of file Panzer_STK_SquareQuadMeshFactory.cpp.

◆ determineXElemSizeAndStart()

std::pair< int, int > panzer_stk::SquareQuadMeshFactory::determineXElemSizeAndStart ( int  xBlock,
unsigned int  size,
unsigned int  rank 
) const
protected

Definition at line 384 of file Panzer_STK_SquareQuadMeshFactory.cpp.

◆ determineYElemSizeAndStart()

std::pair< int, int > panzer_stk::SquareQuadMeshFactory::determineYElemSizeAndStart ( int  yBlock,
unsigned int  size,
unsigned int  rank 
) const
protected

Definition at line 407 of file Panzer_STK_SquareQuadMeshFactory.cpp.

◆ addSideSets()

void panzer_stk::SquareQuadMeshFactory::addSideSets ( STK_Interface mesh) const
protected

Definition at line 430 of file Panzer_STK_SquareQuadMeshFactory.cpp.

◆ addNodeSets()

void panzer_stk::SquareQuadMeshFactory::addNodeSets ( STK_Interface mesh) const
protected

Definition at line 554 of file Panzer_STK_SquareQuadMeshFactory.cpp.

◆ addEdgeBlocks()

void panzer_stk::SquareQuadMeshFactory::addEdgeBlocks ( STK_Interface mesh) const
protected

Definition at line 579 of file Panzer_STK_SquareQuadMeshFactory.cpp.

Member Data Documentation

◆ x0_

double panzer_stk::SquareQuadMeshFactory::x0_
protected

Definition at line 101 of file Panzer_STK_SquareQuadMeshFactory.hpp.

◆ y0_

double panzer_stk::SquareQuadMeshFactory::y0_
protected

Definition at line 101 of file Panzer_STK_SquareQuadMeshFactory.hpp.

◆ xf_

double panzer_stk::SquareQuadMeshFactory::xf_
protected

Definition at line 102 of file Panzer_STK_SquareQuadMeshFactory.hpp.

◆ yf_

double panzer_stk::SquareQuadMeshFactory::yf_
protected

Definition at line 102 of file Panzer_STK_SquareQuadMeshFactory.hpp.

◆ xBlocks_

int panzer_stk::SquareQuadMeshFactory::xBlocks_
protected

Definition at line 104 of file Panzer_STK_SquareQuadMeshFactory.hpp.

◆ yBlocks_

int panzer_stk::SquareQuadMeshFactory::yBlocks_
protected

Definition at line 104 of file Panzer_STK_SquareQuadMeshFactory.hpp.

◆ nXElems_

int panzer_stk::SquareQuadMeshFactory::nXElems_
protected

Definition at line 106 of file Panzer_STK_SquareQuadMeshFactory.hpp.

◆ nYElems_

int panzer_stk::SquareQuadMeshFactory::nYElems_
protected

Definition at line 106 of file Panzer_STK_SquareQuadMeshFactory.hpp.

◆ xProcs_

int panzer_stk::SquareQuadMeshFactory::xProcs_
mutableprotected

Definition at line 107 of file Panzer_STK_SquareQuadMeshFactory.hpp.

◆ yProcs_

int panzer_stk::SquareQuadMeshFactory::yProcs_
mutableprotected

Definition at line 107 of file Panzer_STK_SquareQuadMeshFactory.hpp.

◆ machRank_

unsigned int panzer_stk::SquareQuadMeshFactory::machRank_
mutableprotected

Definition at line 109 of file Panzer_STK_SquareQuadMeshFactory.hpp.

◆ machSize_

unsigned int panzer_stk::SquareQuadMeshFactory::machSize_
mutableprotected

Definition at line 109 of file Panzer_STK_SquareQuadMeshFactory.hpp.

◆ procTuple_

Teuchos::Tuple<std::size_t,2> panzer_stk::SquareQuadMeshFactory::procTuple_
mutableprotected

Definition at line 110 of file Panzer_STK_SquareQuadMeshFactory.hpp.

◆ createEdgeBlocks_

bool panzer_stk::SquareQuadMeshFactory::createEdgeBlocks_
protected

Definition at line 112 of file Panzer_STK_SquareQuadMeshFactory.hpp.

◆ offsetGIDs_

bool panzer_stk::SquareQuadMeshFactory::offsetGIDs_
protected

If true, offset mesh GIDs to exercise 32-bit limits.

Definition at line 115 of file Panzer_STK_SquareQuadMeshFactory.hpp.

◆ offset_

stk::mesh::EntityId panzer_stk::SquareQuadMeshFactory::offset_
mutableprotected

Definition at line 116 of file Panzer_STK_SquareQuadMeshFactory.hpp.


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