FEI Package Browser (Single Doxygen Collection)  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
HexBeam.hpp
Go to the documentation of this file.
1 /*--------------------------------------------------------------------*/
2 /* Copyright 2005 Sandia Corporation. */
3 /* Under the terms of Contract DE-AC04-94AL85000, there is a */
4 /* non-exclusive license for use of this work by or on behalf */
5 /* of the U.S. Government. Export of this program may require */
6 /* a license from the United States Government. */
7 /*--------------------------------------------------------------------*/
8 
9 #ifndef _HexBeam_h_
10 #define _HexBeam_h_
11 
12 #include <fei_base.hpp>
13 
24 class HexBeam {
25  public:
26  enum { OneD = 0, TwoD = 1, ThreeD = 2 };
27 
28  HexBeam(int W, int D, int DofPerNode,
29  int decomp, int numProcs, int localProc);
30  virtual ~HexBeam();
31 
32  virtual bool inErrorState() { return( inErrorState_ ); }
33 
34  virtual int numNodesPerElem() { return( nodesPerElem_ ); }
35 
36  virtual int numDofPerNode() { return( dofPerNode_ ); }
37 
38  virtual int numLocalElems() { return( localNumElems_ ); }
39 
40  virtual int numLocalNodes() { return( localNumNodes_ ); }
41 
42  virtual int firstLocalElem() { return( firstLocalElem_ ); }
43 
44  virtual int getElemConnectivity(int elemID, int* nodeIDs);
45 
46  virtual int getElemStiffnessMatrix(int elemID, double* elemMat);
47 
48  virtual int getElemLoadVector(int elemID, double* elemVec);
49 
50  virtual int getNumBCNodes();
51 
52  virtual int getBCNodes(int numNodes, int* nodeIDs);
53 
54  virtual int getBCValues(int numBCNodes, int* offsetsIntoField, double* vals);
55 
56  virtual int getNumSharedNodes();
57 
58  virtual int getSharedNodes(int numSharedNodes,
59  int*& sharedNodes,
60  int*& numSharingProcsPerNode,
61  int**& sharingProcs);
62 
63  virtual int getNumCRs() { return( 0 ); }
64 
65  virtual int getNumNodesPerCR() { return( 0 ); }
66 
67  virtual int getCRNodes(int** nodeIDs) { (void)nodeIDs; return(0); }
68 
69  int W_;
70  int D_;
71  int decomp_;
72  int numProcs_;
74 
81 
85 
87 
90 
93 };
94 
95 namespace HexBeam_Functions {
96 
97 int init_elem_connectivities(FEI* fei, HexBeam& hexcube);
98 
99 int init_shared_nodes(FEI* fei, HexBeam& hexcube);
100 
101 int init_constraints(FEI* fei, HexBeam& hexcube, int& firstLocalCRID);
102 
103 int load_elem_data(FEI* fei, HexBeam& hexcube);
104 
105 int load_constraints(FEI* fei, HexBeam& hexcube, int firstLocalCRID);
106 
107 int load_BC_data(FEI* fei, HexBeam& hexcube);
108 
109 int print_cube_data(HexBeam& hexcube, int numProcs, int localProc);
110 
111 
112 int init_elem_connectivities(fei::MatrixGraph* matrixGraph, HexBeam& hexcube);
113 
114 int init_shared_nodes(fei::MatrixGraph* matrixGraph, HexBeam& hexcube);
115 
116 int init_constraints(fei::MatrixGraph* matrixGraph, HexBeam& hexcube,
117  int localProc, int& firstLocalCRID);
118 
119 int init_slave_constraints(fei::MatrixGraph* matrixGraph, HexBeam& hexcube);
120 
121 int load_elem_data(fei::MatrixGraph* matrixGraph,
122  fei::Matrix* mat,
123  fei::Vector* rhs,
124  HexBeam& hexcube);
125 
126 int load_constraints(fei::LinearSystem* linSys, HexBeam& hexcube,
127  int firstLocalCRID);
128 
129 int load_BC_data(fei::LinearSystem* linSys, HexBeam& hexcube);
130 
131 }//namespace HexBeam_Functions
132 
133 #endif // _HexBeam_h_
int totalNumNodes_
Definition: HexBeam.hpp:76
int load_constraints(FEI *fei, HexBeam &hexcube, int firstLocalCRID)
Definition: HexBeam.cpp:397
virtual int getCRNodes(int **nodeIDs)
Definition: HexBeam.hpp:67
int firstLocalElem_
Definition: HexBeam.hpp:79
int D_
Definition: HexBeam.hpp:70
int nodesPerElem_
Definition: HexBeam.hpp:88
int init_slave_constraints(fei::MatrixGraph *matrixGraph, HexBeam &hexcube)
Definition: HexBeam.cpp:636
virtual int getBCNodes(int numNodes, int *nodeIDs)
Definition: HexBeam.cpp:168
virtual bool inErrorState()
Definition: HexBeam.hpp:32
int decomp_
Definition: HexBeam.hpp:71
int numGlobalDOF_
Definition: HexBeam.hpp:92
int numProcs_
Definition: HexBeam.hpp:72
int init_constraints(FEI *fei, HexBeam &hexcube, int &firstLocalCRID)
Definition: HexBeam.cpp:355
int totalNumElems_
Definition: HexBeam.hpp:75
int localNumNodes_
Definition: HexBeam.hpp:78
virtual int getNumSharedNodes()
Definition: HexBeam.cpp:197
int numElemsPerSlice_
Definition: HexBeam.hpp:82
int init_elem_connectivities(FEI *fei, HexBeam &hexcube)
Definition: HexBeam.cpp:280
int print_cube_data(HexBeam &hexcube, int numProcs, int localProc)
Definition: HexBeam.cpp:258
int load_elem_data(FEI *fei, HexBeam &hexcube)
Definition: HexBeam.cpp:440
Definition: FEI.hpp:144
virtual int firstLocalElem()
Definition: HexBeam.hpp:42
virtual int getBCValues(int numBCNodes, int *offsetsIntoField, double *vals)
Definition: HexBeam.cpp:183
virtual int numDofPerNode()
Definition: HexBeam.hpp:36
int W_
Definition: HexBeam.hpp:69
virtual ~HexBeam()
Definition: HexBeam.cpp:72
virtual int getSharedNodes(int numSharedNodes, int *&sharedNodes, int *&numSharingProcsPerNode, int **&sharingProcs)
Definition: HexBeam.cpp:209
bool inErrorState_
Definition: HexBeam.hpp:86
int numLocalDOF_
Definition: HexBeam.hpp:91
int init_shared_nodes(FEI *fei, HexBeam &hexcube)
Definition: HexBeam.cpp:328
virtual int getElemConnectivity(int elemID, int *nodeIDs)
Definition: HexBeam.cpp:76
virtual int getElemStiffnessMatrix(int elemID, double *elemMat)
Definition: HexBeam.cpp:102
int load_BC_data(FEI *fei, HexBeam &hexcube)
Definition: HexBeam.cpp:484
virtual int numNodesPerElem()
Definition: HexBeam.hpp:34
int localProc(MPI_Comm comm)
int numNodesPerSlice_
Definition: HexBeam.hpp:83
virtual int getNumBCNodes()
Definition: HexBeam.cpp:162
virtual int getNumCRs()
Definition: HexBeam.hpp:63
virtual int getNumNodesPerCR()
Definition: HexBeam.hpp:65
int firstLocalNode_
Definition: HexBeam.hpp:80
virtual int numLocalNodes()
Definition: HexBeam.hpp:40
int localProc_
Definition: HexBeam.hpp:73
virtual int getElemLoadVector(int elemID, double *elemVec)
Definition: HexBeam.cpp:148
virtual int numLocalElems()
Definition: HexBeam.hpp:38
int localNumElems_
Definition: HexBeam.hpp:77
HexBeam(int W, int D, int DofPerNode, int decomp, int numProcs, int localProc)
Definition: HexBeam.cpp:16
int numLocalSlices_
Definition: HexBeam.hpp:84
int numProcs(MPI_Comm comm)
int dofPerNode_
Definition: HexBeam.hpp:89