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
00027
00028
00029 #ifndef EpetraExt_LINEARPROBLEM_GRAPHTRANS_H
00030 #define EpetraExt_LINEARPROBLEM_GRAPHTRANS_H
00031
00032 #include <EpetraExt_Transform.h>
00033
00034 class Epetra_LinearProblem;
00035 class Epetra_Map;
00036 class Epetra_MultiVector;
00037 class Epetra_CrsGraph;
00038 class Epetra_CrsMatrix;
00039 class Epetra_Export;
00040 class Epetra_Import;
00041
00042 namespace EpetraExt {
00043
00045 class LinearProblem_GraphTrans : public SameTypeTransform<Epetra_LinearProblem>
00046 {
00047 StructuralSameTypeTransform<Epetra_CrsGraph> & graphTrans_;
00048
00049 Epetra_Import * Importer_;
00050 Epetra_Export * MatExporter_;
00051 Epetra_Export * VecExporter_;
00052
00053 Epetra_LinearProblem * OldProblem_;
00054 Epetra_CrsGraph * OldGraph_;
00055 Epetra_CrsMatrix * OldMatrix_;
00056 Epetra_MultiVector * OldLHS_;
00057 Epetra_MultiVector * OldRHS_;
00058 Epetra_Map * OldRowMap_;
00059
00060 Epetra_LinearProblem * NewProblem_;
00061 Epetra_CrsMatrix * NewMatrix_;
00062 Epetra_MultiVector * NewLHS_;
00063 Epetra_MultiVector * NewRHS_;
00064
00065 public:
00066
00068 ~LinearProblem_GraphTrans();
00069
00071
00075 LinearProblem_GraphTrans( StructuralSameTypeTransform<Epetra_CrsGraph> & graph_trans )
00076 : graphTrans_(graph_trans),
00077 Importer_(0),
00078 MatExporter_(0),
00079 VecExporter_(0),
00080 OldProblem_(0),
00081 OldGraph_(0),
00082 OldMatrix_(0),
00083 OldLHS_(0),
00084 OldRHS_(0),
00085 OldRowMap_(0),
00086 NewProblem_(0),
00087 NewMatrix_(0),
00088 NewLHS_(0),
00089 NewRHS_(0)
00090 {}
00091
00093
00098 NewTypeRef operator()( OriginalTypeRef orig );
00099
00101 bool fwd();
00102
00104 bool rvs();
00105
00106 };
00107
00108 }
00109
00110 #endif //EpetraExt_LINEARPROBLEM_GRAPHTRANS_H
00111