47 #ifndef __Teko_InterlacedEpetra_hpp__
48 #define __Teko_InterlacedEpetra_hpp__
51 #include "Teuchos_RCP.hpp"
55 #include "Epetra_MpiComm.h"
57 #include "Epetra_SerialComm.h"
59 #include "Epetra_Map.h"
60 #include "Epetra_CrsMatrix.h"
61 #include "Epetra_MultiVector.h"
62 #include "Epetra_Vector.h"
63 #include "Epetra_Export.h"
64 #include "Epetra_Import.h"
91 void buildSubMaps(
int numGlobals,
int numVars,
const Epetra_Comm & comm,
92 std::vector<std::pair<
int,Teuchos::RCP<Epetra_Map> > > & subMaps);
113 void buildSubMaps(
int numGlobals,
const std::vector<int> & vars,
const Epetra_Comm & comm,
114 std::vector<std::pair<
int,Teuchos::RCP<Epetra_Map> > > & subMaps);
137 void buildSubMaps(
int numGlobals,
int numMyElements,
int minMyGID,
const std::vector<int> & vars,
const Epetra_Comm & comm,
138 std::vector<std::pair<
int,Teuchos::RCP<Epetra_Map> > > & subMaps);
160 void buildSubMaps(
const Epetra_Map & globalMap,
const std::vector<int> & vars,
const Epetra_Comm & comm,
161 std::vector<std::pair<
int,Teuchos::RCP<Epetra_Map> > > & subMaps);
164 void buildExportImport(
const Epetra_Map & baseMap,
165 const std::vector<std::pair<
int,Teuchos::RCP<Epetra_Map> > > & subMaps,
166 std::vector<Teuchos::RCP<Epetra_Export> > & subExport,
167 std::vector<Teuchos::RCP<Epetra_Import> > & subImport);
170 void buildSubVectors(
const std::vector<std::pair<
int,Teuchos::RCP<Epetra_Map> > > & subMaps,
171 std::vector<Teuchos::RCP<Epetra_MultiVector> > & subVectors,
int count);
176 void associateSubVectors(
const std::vector<std::pair<
int,Teuchos::RCP<Epetra_Map> > > & subMaps,
177 std::vector<Teuchos::RCP<const Epetra_MultiVector> > & subVectors);
180 Teuchos::RCP<Epetra_CrsMatrix> buildSubBlock(
int i,
int j,
const Epetra_CrsMatrix & A,
181 const std::vector<std::pair<
int,Teuchos::RCP<Epetra_Map> > > & subMaps);
184 void rebuildSubBlock(
int i,
int j,
const Epetra_CrsMatrix & A,
185 const std::vector<std::pair<
int,Teuchos::RCP<Epetra_Map> > > & subMaps,Epetra_CrsMatrix & mat);
188 void many2one(Epetra_MultiVector & one,
const std::vector<Teuchos::RCP<const Epetra_MultiVector> > & many,
189 const std::vector<Teuchos::RCP<Epetra_Export> > & subExport);
192 void one2many(std::vector<Teuchos::RCP<Epetra_MultiVector> > & many,
const Epetra_MultiVector & single,
193 const std::vector<Teuchos::RCP<Epetra_Import> > & subImport);