fei_LinearProblemManager.hpp

00001 /*--------------------------------------------------------------------*/
00002 /*    Copyright 2006 Sandia Corporation.                              */
00003 /*    Under the terms of Contract DE-AC04-94AL85000, there is a       */
00004 /*    non-exclusive license for use of this work by or on behalf      */
00005 /*    of the U.S. Government.  Export of this program may require     */
00006 /*    a license from the United States Government.                    */
00007 /*--------------------------------------------------------------------*/
00008 
00009 #ifndef _fei_LinearProblemManager_hpp_
00010 #define _fei_LinearProblemManager_hpp_
00011 
00012 #include <fei_macros.hpp>
00013 #include <fei_SharedPtr.hpp>
00014 #include <fei_mpi.h>
00015 
00016 #include <vector>
00017 
00018 namespace fei {
00019   class ParameterSet;
00020   class SparseRowGraph;
00021 
00024   class LinearProblemManager {
00025    public:
00027 
00029     virtual ~LinearProblemManager(){}
00030 
00032 
00033 
00038     virtual void setRowDistribution(const std::vector<int>& ownedGlobalRows)=0;
00039 
00043     virtual void setMatrixGraph(fei::SharedPtr<fei::SparseRowGraph> matrixGraph)=0;
00044 
00046 
00047 
00050     virtual void setMatrixValues(double scalar)=0;
00051 
00055     virtual int getLocalNumRows()=0;
00056 
00060     virtual int getRowLength(int row)=0;
00061 
00077     virtual int copyOutMatrixRow(int row,
00078                                  int len,
00079                                  double* coefs,
00080                                  int* indices)=0;
00081 
00089     virtual int insertMatrixValues(int numRows, const int* rows,
00090                                    int numCols, const int* cols,
00091                                    const double* const* values,
00092                                    bool sum_into)=0;
00093 
00095 
00096 
00104     virtual void setVectorValues(double scalar, bool soln_vector)=0;
00105 
00131     virtual int insertVectorValues(int numValues,
00132                                    const int* globalIndices,
00133                                    const double* values,
00134                                    bool sum_into,
00135                                    bool soln_vector,
00136                                    int vectorIndex=0)=0;
00137 
00141     virtual int copyOutVectorValues(int numValues,
00142                                     const int* globalIndices,
00143                                     double* values,
00144                                     bool soln_vector,
00145                                     int vectorIndex=0) = 0;
00146 
00152     virtual double* getLocalVectorValuesPtr(bool soln_vector,
00153                                             int vectorIndex=0) = 0;
00155 
00156 
00162     virtual int globalAssemble() = 0;
00164   };//class LinearProblemManager
00165 
00166 }//namespace fei
00167 
00168 #endif // _fei_LinearProblemManager_hpp_
00169 
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Friends
Generated on Wed Apr 13 10:08:23 2011 for FEI by  doxygen 1.6.3