00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026 #ifndef BandSPDLinSOE_h
00027 #define BandSPDLinSOE_h
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043 #include <LinearSOE.h>
00044 #include <Vector.h>
00045
00046 #include <BandSPDLinSolver.h>
00047
00048
00049
00229 class BandSPDLinSOE : public LinearSOE
00230 {
00231 public:
00233 BandSPDLinSOE(BandSPDLinSolver &theSolver);
00234
00236 BandSPDLinSOE(int N, int bandwidth, BandSPDLinSolver &theSolver);
00237
00239 ~BandSPDLinSOE();
00240
00242 int getNumEqn(void) const;
00244 int setSize(Graph &theGraph);
00245
00247 int addA(const Matrix &, const ID &, double fact = 1.0);
00249 int addB(const Vector &, const ID &, double fact = 1.0);
00251 int setB(const Vector &, double fact = 1.0);
00252
00254 void zeroA(void);
00256 void zeroB(void);
00257
00259 const Vector &getX(void);
00261 const Vector &getB(void);
00263 double normRHS(void);
00264
00266 void setX(int loc, double value);
00268 int setBandSPDSolver(BandSPDLinSolver &newSolver);
00269
00271 int sendSelf(int commitTag, Channel &theChannel);
00273 int recvSelf(int commitTag, Channel &theChannel, FEM_ObjectBroker &theBroker);
00274
00276 friend #include <BandSPDLinSolver.h>
00277 friend #include <BandSPDLinLapackSolver.h>
00278 friend #include <BandSPDLinThreadSolver.h>
00279
00280 protected:
00281
00282 private:
00283 int size, half_band;
00285 double *A, *B, *X;
00287 Vector *vectX;
00289 Vector *vectB;
00291 int Asize, Bsize;
00293 int aFactored;
00295 bool factored;
00296 };
00297
00298
00299 #endif
00300