SNL_FEI_Structure Class Reference

#include <SNL_FEI_Structure.hpp>

Inheritance diagram for SNL_FEI_Structure:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 SNL_FEI_Structure (MPI_Comm comm)
virtual ~SNL_FEI_Structure ()
int parameters (int numParams, const char *const *paramStrings)
const int * getFieldIDsPtr ()
const int * getFieldSizesPtr ()
int getNumFields ()
int getFieldSize (int fieldID)
bool isInLocalElement (int nodeNumber)
const int * getNumFieldsPerNode (GlobalID blockID)
const int *const * getFieldIDsTable (GlobalID blockID)
int getEqnNumber (int nodeNumber, int fieldID)
int getOwnerProcForEqn (int eqn)
int getNumElemBlocks ()
const GlobalID * getElemBlockIDs ()
void getElemBlockInfo (GlobalID blockID, int &interleaveStrategy, int &lumpingStrategy, int &numElemDOF, int &numElements, int &numNodesPerElem, int &numEqnsPerElem)
int getBlockDescriptor_index (int index, BlockDescriptor *&block)
int getIndexOfBlock (GlobalID blockID)
int getNumSharedNodes ()
const int * getSharedNodeNumbers ()
const int * getSharedNodeProcs (int nodeNumber)
int getNumSharingProcs (int nodeNumber)
int getNumSubdomains (int nodeNumber)
int * getSubdomainList (int nodeNumber)
int getAssociatedNodeNumber (int eqnNumber)
int getAssociatedFieldID (int eqnNumber)
bool isExactlyBlkEqn (int ptEqn)
int ptEqnToBlkEqn (int ptEqn)
int getOffsetIntoBlkEqn (int blkEqn, int ptEqn)
int getBlkEqnSize (int blkEqn)
bool isSlaveEqn (int eqn)
bool translateToReducedEqn (int eqn, int &reducedEqn)
int translateToReducedEqns (EqnCommMgr &eqnCommMgr)
int translateToReducedEqns (EqnBuffer &eqnBuf)
int translateToReducedEqns (ProcEqns &procEqns)
int translateMatToReducedEqns (fei::CSRMat &mat)
int translateFromReducedEqn (int reducedEqn)
int getMasterEqnNumbers (int slaveEqn, std::vector< int > *&masterEqns)
int getMasterEqnCoefs (int slaveEqn, std::vector< double > *&masterCoefs)
int getMasterEqnRHS (int slaveEqn, double &rhsValue)

Detailed Description

The SNL_FEI_Structure class is a container for the data that makes up the structure of a finite element problem. It contains things like the FieldDatabase, NodeDatabase, ConnectivityTable, etc.

This class is the primary class that implements the general "FEI initialization phase", where the user passes all structure-defining data, which ends up being translated into a corresponding sparse matrix structure.

The problem structure is initialized gradually by calling the 'init' functions in this class. They also exist in the FEI class, where they are documented.

Once all structure-defining data has been passed, the process is completed by calling the initComplete function.

Definition at line 43 of file SNL_FEI_Structure.hpp.


Constructor & Destructor Documentation

SNL_FEI_Structure::SNL_FEI_Structure ( MPI_Comm  comm  ) 

Constructor.

Parameters:
comm MPI_Communicator
name String by which this structure instance may be referred to.
debugOutputLevel Determines whether this object will produce a file containing a log of debug output information.
path If debugOutputLevel is not zero, the debug log file will be placed in the location specified by path.

Definition at line 50 of file SNL_FEI_Structure.cpp.

SNL_FEI_Structure::~SNL_FEI_Structure (  )  [virtual]

Destructor.

Definition at line 187 of file SNL_FEI_Structure.cpp.


Member Function Documentation

int SNL_FEI_Structure::parameters ( int  numParams,
const char *const *  paramStrings 
)

Set parameters on this object. Currently three parameters are recognized: "debugOutput 'path'" where 'path' is the path to the location where debug-log files will be produced.
"debugOutputOff" which will turn off debug-output.
"checkSharedNodes" which specifies that a 'sanity-check' should be done to make sure that the shared-node information is globally consistent, before any communication is attempted which depends on the consistency of that information.
"sharedNodeOwnership <string>" where <string> can be either LowNumberedProc or ProcWithLocalElem. LowNumberedProc specifies that the lowest-numbered sharing processor will be the owner of shared nodes, while ProcWithLocalElem specifies that ownership will be given to the proc with a local element containing the shared node, if not all sharing procs have local elements containing the shared node.

Definition at line 146 of file SNL_FEI_Structure.cpp.

const int* SNL_FEI_Structure::getFieldIDsPtr (  )  [inline, virtual]

implementation of Lookup::getFieldIDsPtr

Implements Lookup.

Definition at line 125 of file SNL_FEI_Structure.hpp.

const int* SNL_FEI_Structure::getFieldSizesPtr (  )  [inline, virtual]

implementation of Lookup::getFieldSizesPtr

Implements Lookup.

Definition at line 136 of file SNL_FEI_Structure.hpp.

int SNL_FEI_Structure::getNumFields (  )  [inline, virtual]

implementation of Lookup::getNumFields

Implements Lookup.

Definition at line 147 of file SNL_FEI_Structure.hpp.

int SNL_FEI_Structure::getFieldSize ( int  fieldID  )  [inline, virtual]

implementation of Lookup::getFieldSize

Implements Lookup.

Definition at line 150 of file SNL_FEI_Structure.hpp.

bool SNL_FEI_Structure::isInLocalElement ( int  nodeNumber  )  [virtual]

implementation of Lookup::isInLocalElement

Implements Lookup.

Definition at line 804 of file SNL_FEI_Structure.cpp.

const int * SNL_FEI_Structure::getNumFieldsPerNode ( GlobalID  blockID  )  [virtual]

Given a blockID, return a pointer to a list (of length numNodesPerElem) of numFieldsPerNode.

Parameters:
blockID identifier of the elem-block in question

Implements Lookup.

Definition at line 273 of file SNL_FEI_Structure.cpp.

const int *const * SNL_FEI_Structure::getFieldIDsTable ( GlobalID  blockID  )  [virtual]

Given a blockID, return a pointer to a table, (num-rows == numNodesPerElem, row-length[i] == fieldsPerNode[i]) containing the fieldIDs at each node of elements in that element-block.

Parameters:
blockID identifier of the elem-block in question

Implements Lookup.

Definition at line 283 of file SNL_FEI_Structure.cpp.

int SNL_FEI_Structure::getEqnNumber ( int  nodeNumber,
int  fieldID 
) [virtual]

Given a nodeNumber/fieldID pair, return the associated first equation- number.

Returns:
eqnNumber

Implements Lookup.

Definition at line 318 of file SNL_FEI_Structure.cpp.

int SNL_FEI_Structure::getOwnerProcForEqn ( int  eqn  ) 

Given a global equation number, return the processor on which that equation resides.

Parameters:
eqn Global 0-based equation number.
Returns:
proc Owning processor. If eqn is out of range (less than 0 or greater than global-number-of-equations) then -1 is returned.

Definition at line 343 of file SNL_FEI_Structure.cpp.

int SNL_FEI_Structure::getNumElemBlocks (  )  [inline, virtual]

Return the number of element-blocks in the (local) finite-element problem.

Implements Lookup.

Definition at line 186 of file SNL_FEI_Structure.hpp.

const GlobalID* SNL_FEI_Structure::getElemBlockIDs (  )  [inline, virtual]

Return a pointer to the list (of length numElemBlocks) containing the element-block identifiers for the (local) finite-element problem.

Implements Lookup.

Definition at line 187 of file SNL_FEI_Structure.hpp.

void SNL_FEI_Structure::getElemBlockInfo ( GlobalID  blockID,
int &  interleaveStrategy,
int &  lumpingStrategy,
int &  numElemDOF,
int &  numElements,
int &  numNodesPerElem,
int &  numEqnsPerElem 
) [virtual]

Given a blockID, provide several pieces of element-block information.

Parameters:
interleaveStrategy element-equation ordering: 0 => node-major, 1 => field-major
lumpingStrategy element-matrices may be lumped if they're mass matrices, 0 => not lumped, 1 => lumped
numElemDOF number of element-dof at each element in this block
numElements number of elements in this block
numNodesPerElem number of nodes connected to each element in this block
numEqnsPerElem number of scalar equations at each element in this block

Implements Lookup.

Definition at line 293 of file SNL_FEI_Structure.cpp.

int SNL_FEI_Structure::getBlockDescriptor_index ( int  index,
BlockDescriptor *&  block 
)

Given an index, return the corresponding block-descriptor.

Returns:
0 if successful, non-zero if index out of range, etc.

Definition at line 2824 of file SNL_FEI_Structure.cpp.

int SNL_FEI_Structure::getIndexOfBlock ( GlobalID  blockID  ) 

Given a blockID, return its index.

Definition at line 2817 of file SNL_FEI_Structure.cpp.

int SNL_FEI_Structure::getNumSharedNodes (  )  [inline, virtual]

Return the number of local nodes that are shared by multiple processors

Implements Lookup.

Definition at line 239 of file SNL_FEI_Structure.hpp.

const int* SNL_FEI_Structure::getSharedNodeNumbers (  )  [inline, virtual]

Return a pointer to the list of shared nodeNumbers

Implements Lookup.

Definition at line 241 of file SNL_FEI_Structure.hpp.

const int* SNL_FEI_Structure::getSharedNodeProcs ( int  nodeNumber  )  [inline, virtual]

Given a shared nodeNumber, return a pointer to the list of sharing procs.

Parameters:
nodeNumber The subject of the query. Function returns NULL if 'nodeNumber' is not a shared node.

Implements Lookup.

Definition at line 245 of file SNL_FEI_Structure.hpp.

int SNL_FEI_Structure::getNumSharingProcs ( int  nodeNumber  )  [inline, virtual]

Given a shared nodeNumber, return the number of processors that share it.

Parameters:
nodeNumber Function returns -1 if 'nodeNumber' is not a shared node.

Implements Lookup.

Definition at line 251 of file SNL_FEI_Structure.hpp.

int SNL_FEI_Structure::getNumSubdomains ( int  nodeNumber  )  [inline, virtual]

Given a nodeNumber, return the number of subdomains that contain this node. subdomains correspond to processors. The number of subdomains that contain a node does not always equal the number of processors that share a node. There are two kinds of "sharing" -- the "normal" kind, where a node is shared because it is connected to elements that reside on more than one processor, and the "wierd" kind where nodes are considered shared simply because of being in cross-processor constraints. This function describes how many processors share this node in the "normal" sense. Thus, in general, this relationship holds: getNumSubdomains(nodeNum) <= getNumSharingProcs(nodeNum)

Parameters:
nodeNumber 
Returns:
numSubdomains

Implements Lookup.

Definition at line 257 of file SNL_FEI_Structure.hpp.

int* SNL_FEI_Structure::getSubdomainList ( int  nodeNumber  )  [inline, virtual]

Given a nodeNumber, return a list of the subdomains that contain this node. This is the list of subdomains that's counted by the method 'getNumSubdomains' above.

Parameters:
nodeNumber 
Returns:
pointer to list of subdomains (processor ranks). NULL if the specified nodeNumber is not found.

Implements Lookup.

Definition at line 265 of file SNL_FEI_Structure.hpp.

int SNL_FEI_Structure::getAssociatedNodeNumber ( int  eqnNumber  )  [inline, virtual]

implementation of Lookup::getAssociatedNodeNumber

Implements Lookup.

Definition at line 279 of file SNL_FEI_Structure.hpp.

int SNL_FEI_Structure::getAssociatedFieldID ( int  eqnNumber  )  [inline, virtual]

implementation of Lookup::getAssociatedFieldID

Implements Lookup.

Definition at line 291 of file SNL_FEI_Structure.hpp.

bool SNL_FEI_Structure::isExactlyBlkEqn ( int  ptEqn  )  [inline, virtual]

Query whether a pt-eqn corresponds exactly to a blk-eqn. in other words, is pt-eqn the first point equation in a block-equation.

Parameters:
ptEqn 

Implements Lookup.

Definition at line 301 of file SNL_FEI_Structure.hpp.

int SNL_FEI_Structure::ptEqnToBlkEqn ( int  ptEqn  )  [inline, virtual]

Given a pt-eqn, return the corresponding blk-eqn.

Parameters:
ptEqn 

Implements Lookup.

Definition at line 305 of file SNL_FEI_Structure.hpp.

int SNL_FEI_Structure::getOffsetIntoBlkEqn ( int  blkEqn,
int  ptEqn 
) [inline, virtual]

Given a blk-eqn and a pt-eqn, return the pt-eqn's offset into the blk-eqn (i.e., distance from the 'beginning' of the blk-eqn)

Parameters:
blkEqn 
ptEqn 

Implements Lookup.

Definition at line 309 of file SNL_FEI_Structure.hpp.

int SNL_FEI_Structure::getBlkEqnSize ( int  blkEqn  )  [inline, virtual]

Given a blk-eqn, return the 'size', or number of pt-eqns corresponding to it.

Parameters:
blkEqn 

Implements Lookup.

Definition at line 313 of file SNL_FEI_Structure.hpp.

bool SNL_FEI_Structure::isSlaveEqn ( int  eqn  ) 

Given a "global" equation number, return true if it is a slave equation.

Definition at line 3606 of file SNL_FEI_Structure.cpp.

bool SNL_FEI_Structure::translateToReducedEqn ( int  eqn,
int &  reducedEqn 
)

Given a "global" equation number, return the corresponding equation number in the "reduced" equation space. This is a trivial one-to-one mapping unless there are slave equations. If there are slave equations, then the number of 'reduced' equations is reduced by num-slave-eqns, and any particular global equation number is reduced by the number of slave equations that are smaller than it.

Returns:
true if eqn is a slave-equation, false otherwise.

Definition at line 3619 of file SNL_FEI_Structure.cpp.

int SNL_FEI_Structure::translateToReducedEqns ( EqnCommMgr eqnCommMgr  ) 

Given an EqnCommMgr object with global equation numbers, translate all of its indices (row-numbers and column-indices) to the "reduced" equation space.

Definition at line 2075 of file SNL_FEI_Structure.cpp.

int SNL_FEI_Structure::translateToReducedEqns ( EqnBuffer eqnBuf  ) 

Given an EqnBuffer object with global equation numbers, translate all of its indices (row-numbers and column-indices) to the "reduced" equation space.

Definition at line 2088 of file SNL_FEI_Structure.cpp.

int SNL_FEI_Structure::translateToReducedEqns ( ProcEqns procEqns  ) 

Given a ProcEqns object with global equation numbers, translate all of its indices (row-numbers and column-indices) to the "reduced" equation space.

Definition at line 2110 of file SNL_FEI_Structure.cpp.

int SNL_FEI_Structure::translateMatToReducedEqns ( fei::CSRMat mat  ) 

Given a CSRMat object with global equation numbers, translate all of its indices (row-numbers and column-indices) to the "reduced" equation space.

Definition at line 2128 of file SNL_FEI_Structure.cpp.

int SNL_FEI_Structure::translateFromReducedEqn ( int  reducedEqn  ) 

Given an "Reduced" equation number, translate it to the "global" numbering, which is the numbering that includes slave equations. This is the inverse of the 'translateToReducedEqn' function above.

Returns:
eqn

Definition at line 3642 of file SNL_FEI_Structure.cpp.

int SNL_FEI_Structure::getMasterEqnNumbers ( int  slaveEqn,
std::vector< int > *&  masterEqns 
)

Given a slave equation, fill a std::vector with the equation-numbers upon which the slave depends.

Parameters:
slaveEqn 
masterEqns Output. NULL if slaveEqn is not a slave equation.
Returns:
error-code

Definition at line 3663 of file SNL_FEI_Structure.cpp.

int SNL_FEI_Structure::getMasterEqnCoefs ( int  slaveEqn,
std::vector< double > *&  masterCoefs 
)

Given a slave equation, fill a std::vector with the coefficients of the equations upon which the slave depends.

Parameters:
slaveEqn 
masterCoefs Output. NULL if slaveEqn is not a slave equation.
Returns:
error-code

Definition at line 3686 of file SNL_FEI_Structure.cpp.

int SNL_FEI_Structure::getMasterEqnRHS ( int  slaveEqn,
double &  rhsValue 
)

Given a slave equation, provide the rhs-value associated with the master equation that the slave is defined by.

Parameters:
slaveEqn 
rhsValue Output. Not referenced if slaveEqn is not a slave equation.
Returns:
error-code 0 if successful, -1 if slaveEqn is not a slave.

Definition at line 3709 of file SNL_FEI_Structure.cpp.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Friends
Generated on Wed Apr 13 10:08:25 2011 for FEI by  doxygen 1.6.3