FEI  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
fei_BlockLinearProblemManager.hpp
1 /*--------------------------------------------------------------------*/
2 /* Copyright 2006 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 _fei_BlockLinearProblemManager_hpp_
10 #define _fei_BlockLinearProblemManager_hpp_
11 
12 #include <fei_macros.hpp>
13 #include <fei_SharedPtr.hpp>
14 #include <fei_mpi.h>
15 
16 namespace fei {
17  class ParameterSet;
18  class SparseRowGraph;
19 
28  public:
30 
33 
35 
36 
52  virtual void setRowDistribution(const std::vector<int>& ownedIDs,
53  const std::vector<int>& dofPerOwnedID,
54  const std::vector<int>& ghostIDs,
55  const std::vector<int>& dofPerGhostID)=0;
56 
60  virtual void setMatrixGraph(fei::SharedPtr<fei::SparseRowGraph> matrixGraph)=0;
61 
63 
64 
67  virtual void setMatrixValues(double scalar)=0;
68 
71  virtual int getNumOwnedIDs()=0;
72 
78  virtual int getRowPointLength(int ownedID)=0;
79 
83  virtual int getRowBlockLength(int ownedID)=0;
84 
110  virtual int copyOutMatrixRow(int ownedID, int dofOffset,
111  int numColIDs, int numCoefs,
112  int* colIDs,
113  int* dofPerColID,
114  double* coefs);
115 
123  virtual int insertMatrixValues(int rowID, int numRowDof,
124  int colID, int numColDof,
125  const double* const* values,
126  bool sum_into)=0;
127 
133  virtual int insertMatrixValues(int rowID, int rowDofOffset,
134  int colID, int colDofOffset,
135  double value,
136  bool sum_into)=0;
137 
139 
140 
148  virtual void setVectorValues(double scalar, bool soln_vector)=0;
149 
174  virtual int insertVectorValues(int ID,
175  int numDof,
176  const double* values,
177  bool sum_into,
178  bool soln_vector,
179  int vectorIndex=0)=0;
180 
184  virtual int copyOutVectorValues(int ID,
185  int numDof,
186  double* values,
187  bool soln_vector,
188  int vectorIndex=0) = 0;
189 
195  virtual double* getLocalVectorValuesPtr(bool soln_vector,
196  int vectorIndex=0) = 0;
198 
199 
205  virtual int globalAssemble() = 0;
207 
208 
218  virtual int solve(const fei::ParameterSet& parameters) = 0;
219 
221  };//class BlockLinearProblemManager
222 
223 }//namespace fei
224 
225 #endif // _fei_BlockLinearProblemManager_hpp_
226 
virtual int getRowPointLength(int ownedID)=0
virtual int getRowBlockLength(int ownedID)=0
virtual void setMatrixGraph(fei::SharedPtr< fei::SparseRowGraph > matrixGraph)=0
virtual void setRowDistribution(const std::vector< int > &ownedIDs, const std::vector< int > &dofPerOwnedID, const std::vector< int > &ghostIDs, const std::vector< int > &dofPerGhostID)=0
virtual int insertMatrixValues(int rowID, int numRowDof, int colID, int numColDof, const double *const *values, bool sum_into)=0
virtual int solve(const fei::ParameterSet &parameters)=0
virtual int copyOutMatrixRow(int ownedID, int dofOffset, int numColIDs, int numCoefs, int *colIDs, int *dofPerColID, double *coefs)
virtual double * getLocalVectorValuesPtr(bool soln_vector, int vectorIndex=0)=0
virtual void setMatrixValues(double scalar)=0
virtual int insertVectorValues(int ID, int numDof, const double *values, bool sum_into, bool soln_vector, int vectorIndex=0)=0
virtual int copyOutVectorValues(int ID, int numDof, double *values, bool soln_vector, int vectorIndex=0)=0
virtual void setVectorValues(double scalar, bool soln_vector)=0