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
00030 #ifndef _Isorropia_EpetraColorer_hpp_
00031 #define _Isorropia_EpetraColorer_hpp_
00032
00033 #include <Isorropia_ConfigDefs.hpp>
00034 #include <Teuchos_RCP.hpp>
00035 #include <Teuchos_ParameterList.hpp>
00036
00037 #include <Isorropia_EpetraCostDescriber.hpp>
00038 #include <Isorropia_EpetraOperator.hpp>
00039 #include <Isorropia_Colorer.hpp>
00040
00041 #ifdef HAVE_EPETRAEXT
00042 #include <Epetra_MapColoring.h>
00043 #endif
00044
00045 #ifdef HAVE_EPETRA
00046 class Epetra_Map;
00047 class Epetra_BlockMap;
00048 class Epetra_Import;
00049 class Epetra_Vector;
00050 class Epetra_MultiVector;
00051 class Epetra_CrsGraph;
00052 class Epetra_CrsMatrix;
00053 class Epetra_RowMatrix;
00054 class Epetra_LinearProblem;
00055
00056 namespace Isorropia {
00057
00058 namespace Epetra {
00059
00065 class Colorer : virtual public Isorropia::Colorer, public Isorropia::Epetra::Operator {
00066 public:
00067
00075 Colorer(Teuchos::RCP<const Epetra_CrsGraph> input_graph,
00076 const Teuchos::ParameterList& paramlist,
00077 bool compute_now=true);
00078
00086 Colorer(Teuchos::RCP<const Epetra_RowMatrix> input_matrix,
00087 const Teuchos::ParameterList& paramlist,
00088 bool compute_now=true);
00089
00091 ~Colorer() {} ;
00092
00099 void color(bool force_coloring=false);
00100
00107 void compute(bool force_compute=false) {
00108 color(force_compute);
00109 }
00110
00111 #ifdef HAVE_EPETRAEXT
00112
00117 Teuchos::RCP<Epetra_MapColoring> generateMapColoring() ;
00118 #endif
00119
00120 };
00121
00122 }
00123 }
00124
00125 #endif //HAVE_EPETRA
00126
00127 #endif
00128