42 #ifndef EPETRAEXT_BLOCKUTILITY_H
43 #define EPETRAEXT_BLOCKUTILITY_H
45 #if defined(EpetraExt_SHOW_DEPRECATED_WARNINGS)
47 #warning "The EpetraExt package is deprecated"
53 #include <Epetra_ConfigDefs.h>
54 #include <Epetra_CrsGraph.h>
55 #include <Epetra_RowMatrix.h>
71 #ifndef EPETRA_NO_32BIT_GLOBAL_INDICES
74 #ifndef EPETRA_NO_64BIT_GLOBAL_INDICES
85 #ifndef EPETRA_NO_32BIT_GLOBAL_INDICES
88 #ifndef EPETRA_NO_64BIT_GLOBAL_INDICES
111 #ifndef EPETRA_NO_32BIT_GLOBAL_INDICES
114 #ifndef EPETRA_NO_64BIT_GLOBAL_INDICES
119 #ifndef EPETRA_NO_32BIT_GLOBAL_INDICES
123 #ifndef EPETRA_NO_64BIT_GLOBAL_INDICES
131 #ifndef EPETRA_NO_32BIT_GLOBAL_INDICES
134 #ifndef EPETRA_NO_64BIT_GLOBAL_INDICES
139 #ifndef EPETRA_NO_32BIT_GLOBAL_INDICES
147 template<
typename int_type>
150 template<
typename int_type>
153 template<
typename int_type>
154 static Epetra_CrsGraph * TGenerateBlockGraph(
const Epetra_CrsGraph & BaseGraph,
const std::vector< std::vector<int_type> > & RowStencil,
const std::vector<int_type> & RowIndices,
const Epetra_Comm & GlobalComm );
156 template<
typename int_type>
157 static Epetra_CrsGraph * TGenerateBlockGraph(
const Epetra_RowMatrix & BaseMatrix,
const std::vector< std::vector<int_type> > & RowStencil,
const std::vector<int_type> & RowIndices,
const Epetra_Comm & GlobalComm );
159 template<
typename int_type>
162 template<
typename int_type>
163 static void TGenerateRowStencil(
const Epetra_CrsGraph& LocalBlockGraph, std::vector<int_type> RowIndices, std::vector< std::vector<int_type> >& RowStencil);
static void GenerateRowStencil(const Epetra_CrsGraph &LocalBlockGraph, std::vector< int > RowIndices, std::vector< std::vector< int > > &RowStencil)
Generate stencil arrays from a local block graph.
static long long CalculateOffset64(const Epetra_BlockMap &BaseMap)
static int CalculateOffset(const Epetra_BlockMap &BaseMap)
Routine for calculating Offset for creating unique global IDs for Block representation.
static Epetra_Map * GenerateBlockMap(const Epetra_BlockMap &BaseMap, const int *RowIndices, int num_indices, const Epetra_Comm &GlobalComm, int Offset=0)
static Epetra_CrsGraph * GenerateBlockGraph(const Epetra_CrsGraph &BaseGraph, const std::vector< std::vector< int > > &RowStencil, const std::vector< int > &RowIndices, const Epetra_Comm &GlobalComm)
BlockCrsMatrix constuctor.