10#ifndef XPETRA_EPETRACRSGRAPH_HPP
11#define XPETRA_EPETRACRSGRAPH_HPP
25#include <Epetra_CrsGraph.h>
27#if defined(XPETRA_ENABLE_DEPRECATED_CODE)
29#if defined(Xpetra_SHOW_DEPRECATED_WARNINGS)
30#warning "The header file Trilinos/packages/xpetra/src/CrsGraph/Xpetra_EpetraCrsGraph.hpp is deprecated."
34#error "The header file Trilinos/packages/xpetra/src/CrsGraph/Xpetra_EpetraCrsGraph.hpp is deprecated."
40template <
class GlobalOrdinal,
class Node>
41XPETRA_DEPRECATED RCP<const CrsGraph<int, GlobalOrdinal, Node>>
44template <
class GlobalOrdinal,
class Node>
46toEpetra(
const RCP<
const CrsGraph<int, GlobalOrdinal, Node>> &graph);
48template <
class GlobalOrdinal,
class Node>
50 :
public CrsGraph<int, GlobalOrdinal, Node> {
56#ifdef HAVE_XPETRA_TPETRA
70 "Xpetra::EpetraCrsGraph only available for GO=int or GO=long long with EpetraNode (Serial or OpenMP depending on configuration)");
76 "Xpetra::EpetraCrsGraph only available for GO=int or GO=long long with EpetraNode (Serial or OpenMP depending on configuration)");
82 "Xpetra::EpetraCrsGraph only available for GO=int or GO=long long with EpetraNode (Serial or OpenMP depending on configuration)");
89 "Xpetra::EpetraCrsGraph only available for GO=int or GO=long long with EpetraNode (Serial or OpenMP depending on configuration)");
99 "Xpetra::EpetraCrsGraph only available for GO=int or GO=long long with EpetraNode (Serial or OpenMP depending on configuration)");
102#ifdef HAVE_XPETRA_TPETRA
106 const typename local_graph_type::row_map_type &rowPointers,
107 const typename local_graph_type::entries_type::non_const_type &columnIndices,
110 "Xpetra::EpetraCrsGraph only available for GO=int or GO=long long with EpetraNode (Serial or OpenMP depending on configuration)");
119 "Xpetra::EpetraCrsGraph only available for GO=int or GO=long long with EpetraNode (Serial or OpenMP depending on configuration)");
130 "Xpetra::EpetraCrsGraph only available for GO=int or GO=long long with EpetraNode (Serial or OpenMP depending on configuration)");
189 return Teuchos::null;
270#ifdef HAVE_XPETRA_TPETRA
271#if KOKKOS_VERSION >= 40799
272 typename local_graph_type::host_mirror_type getLocalGraphHost()
const {
274 "Xpetra::EpetraCrsGraph only available for GO=int or GO=long long with EpetraNode (Serial or OpenMP depending on configuration)");
280 "Xpetra::EpetraCrsGraph only available for GO=int or GO=long long with EpetraNode (Serial or OpenMP depending on configuration)");
286#warning "Xpetra Kokkos interface for CrsGraph is enabled (HAVE_XPETRA_KOKKOS_REFACTOR) but Tpetra is disabled. The Kokkos interface needs Tpetra to be enabled, too."
290#ifdef HAVE_XPETRA_TPETRA
293 "Xpetra::EpetraCrsGraph only available for GO=int or GO=long long with EpetraNode (Serial or OpenMP depending on configuration)");
297 void getLocalDiagOffsets(
const Kokkos::View<size_t *, typename Node::device_type, Kokkos::MemoryUnmanaged> &offsets)
const {
299 "Epetra does not support getLocalDiagOffsets!");
303#warning "Xpetra Kokkos interface for CrsGraph is enabled (HAVE_XPETRA_KOKKOS_REFACTOR) but Tpetra is disabled. The Kokkos interface needs Tpetra to be enabled, too."
353 "Xpetra::EpetraCrsGraph only available for GO=int or GO=long long with EpetraNode (Serial or OpenMP depending on configuration)");
365#ifndef XPETRA_EPETRA_NO_32BIT_GLOBAL_INDICES
368 :
public virtual CrsGraph<int, int, EpetraNode> {
376#ifdef HAVE_XPETRA_TPETRA
421 graph_->Import(*eSourceGraph, *tImporter.getEpetra_Import(),
Insert);
423 const Epetra_BlockMap &myDomainMap = domainMap != Teuchos::null ? toEpetra<GlobalOrdinal, Node>(domainMap) : eSourceGraph->ColMap();
424 const Epetra_BlockMap &myRangeMap = rangeMap != Teuchos::null ? toEpetra<GlobalOrdinal, Node>(rangeMap) : toEpetra<LocalOrdinal, Node>(importer.
getTargetMap());
426 graph_->FillComplete(myDomainMap, myRangeMap);
429#ifdef HAVE_XPETRA_TPETRA
433 const typename local_graph_type::row_map_type & ,
434 const typename local_graph_type::entries_type::non_const_type & ,
437 "Epetra does not support CrsGraph constructors using Kokkos Views!");
446 "Epetra does not support CrsGraph constructors using a local graph!");
457 "Epetra does not support CrsGraph constructors using a local graph!");
481 int *indices_rawPtr =
const_cast<int *
>(indices.
getRawPtr());
488 graph_->RemoveMyIndices(localRow);
504 bool ownMemory =
false;
509 myColind.
Resize(numNonZeros);
510 colind = Teuchos::arcp(myColind.
Values(), lowerOffset, numNonZeros, ownMemory);
519 "An exception is thrown to let you know that the size of your rowptr array is incorrect.");
520 if (colind.
size() > 0) {
522 "An exception is thrown to let you know that you mismatched your pointers.");
531 for (
size_t i = 0; i < N + 1; i++)
532 myRowptr[i] = Teuchos::as<int>(rowptr[i]);
540 bool ownMemory =
false;
549 for (
size_t i = 0; i < n + 1; i++)
550 (*
const_cast<size_t *
>(&rowptr[i])) = Teuchos::as<size_t>(myRowptr[i]);
553 colind = Teuchos::arcp(graph_->ExpertExtractIndices().Values(), lowerOffset, nnz, ownMemory);
565 graph_->FillComplete(toEpetra<GlobalOrdinal, Node>(domainMap), toEpetra<GlobalOrdinal, Node>(rangeMap));
566 bool doOptimizeStorage =
true;
567 if (params != null && params->get(
"Optimize Storage",
true) ==
false) doOptimizeStorage =
false;
568 if (doOptimizeStorage) graph_->OptimizeStorage();
575 graph_->FillComplete();
576 bool doOptimizeStorage =
true;
577 if (params != null && params->get(
"Optimize Storage",
true) ==
false) doOptimizeStorage =
false;
578 if (doOptimizeStorage) graph_->OptimizeStorage();
592 graph_->FillComplete(toEpetra<GlobalOrdinal, Node>(domainMap), toEpetra<GlobalOrdinal, Node>(rangeMap));
593 graph_->OptimizeStorage();
610 return toXpetra<GlobalOrdinal, Node>(graph_->RowMap());
616 return toXpetra<GlobalOrdinal, Node>(graph_->ColMap());
622 return toXpetra<GlobalOrdinal, Node>(graph_->DomainMap());
628 return toXpetra<GlobalOrdinal, Node>(graph_->RangeMap());
634 return toXpetra<GlobalOrdinal, Node>(graph_->Importer());
640 return toXpetra<GlobalOrdinal, Node>(graph_->Exporter());
646 return graph_->NumGlobalRows64();
652 return graph_->NumGlobalCols64();
658 return graph_->NumMyRows();
664 return graph_->NumMyCols();
676 return graph_->NumGlobalEntries64();
682 return graph_->NumMyEntries();
688 return graph_->NumGlobalIndices(globalRow);
694 return graph_->NumMyIndices(localRow);
699 XPETRA_MONITOR(
"EpetraCrsGraphT::getNumAllocatedEntriesInGlobalRow");
700 return graph_->NumAllocatedGlobalIndices(globalRow);
705 XPETRA_MONITOR(
"EpetraCrsGraphT::getNumAllocatedEntriesInLocalRow");
706 return graph_->NumAllocatedMyIndices(localRow);
712 return graph_->GlobalMaxNumIndices();
718 return graph_->MaxNumIndices();
724 return graph_->HaveColMap();
730 return graph_->IndicesAreLocal();
736 return graph_->IndicesAreGlobal();
742 return graph_->Filled();
748 return graph_->StorageOptimized();
758 XPETRA_ERR_CHECK(graph_->ExtractGlobalRowView(GlobalRow, numEntries, eIndices));
759 if (numEntries == 0) {
774 if (numEntries == 0) {
781#ifdef HAVE_XPETRA_TPETRA
782#if KOKKOS_VERSION >= 40799
789#if KOKKOS_VERSION >= 40799
790 using local_graph_type_host =
typename local_graph_type::host_mirror_type;
792 using local_graph_type_host =
typename local_graph_type::HostMirror;
795 const int numRows = graph->NumMyRows();
796 const int nnz = graph->NumMyNonzeros();
798 TEUCHOS_TEST_FOR_EXCEPTION(!graph->StorageOptimized(), std::runtime_error,
"Xpetra::CrsGraph<>::getLocalGraph: Epetra_CrsGraph not StorageOptimized");
799 const int *rowptr = graph->ExpertExtractIndexOffset().Values();
800 int *colind = graph->ExpertExtractIndices().Values();
803 typename local_graph_type_host::row_map_type::non_const_type kokkosRowPtr(Kokkos::ViewAllocateWithoutInitializing(
"local row map"), numRows + 1);
804 for (
size_t i = 0; i < kokkosRowPtr.size(); i++)
805 kokkosRowPtr(i) = Teuchos::asSafe<typename local_graph_type_host::row_map_type::value_type>(rowptr[i]);
808 typename local_graph_type_host::entries_type kokkosColind(colind, nnz);
810 local_graph_type_host localGraph = local_graph_type_host(kokkosColind, kokkosRowPtr);
818 const int numRows = graph->NumMyRows();
819 const int nnz = graph->NumMyNonzeros();
821 TEUCHOS_TEST_FOR_EXCEPTION(!graph->StorageOptimized(), std::runtime_error,
"Xpetra::CrsGraph<>::getLocalGraph: Epetra_CrsGraph not StorageOptimized");
822 const int *rowptr = graph->ExpertExtractIndexOffset().Values();
823 int *colind = graph->ExpertExtractIndices().Values();
826 typename local_graph_type::row_map_type::non_const_type kokkosRowPtr(Kokkos::ViewAllocateWithoutInitializing(
"local row map"), numRows + 1);
827 for (
size_t i = 0; i < kokkosRowPtr.size(); i++)
828 kokkosRowPtr(i) = Teuchos::asSafe<typename local_graph_type::row_map_type::value_type>(rowptr[i]);
831 typename local_graph_type::entries_type kokkosColind(colind, nnz);
838 void getLocalDiagOffsets(
const Kokkos::View<size_t *, typename Node::device_type, Kokkos::MemoryUnmanaged> &offsets)
const {
840 "Epetra does not support getLocalDiagOffsets!");
844#warning "Xpetra Kokkos interface for CrsGraph is enabled (HAVE_XPETRA_KOKKOS_REFACTOR) but Tpetra is disabled. The Kokkos interface needs Tpetra to be enabled, too."
859 return "NotImplemented";
866 out <<
"EpetraCrsGraphT::describe : Warning, verbosity level is ignored by this method." << std::endl;
868 if (rowmap.
Comm().
MyPID() == 0) out <<
"** EpetraCrsGraphT **\n\nrowmap" << std::endl;
881 return toXpetra<GlobalOrdinal, Node>(graph_->Map());
893 int err = graph_->Import(*v, *tImporter.getEpetra_Import(),
toEpetra(CM));
906 int err = graph_->Export(*v, *tImporter.getEpetra_Import(),
toEpetra(CM));
919 int err = graph_->Import(*v, *tExporter.getEpetra_Export(),
toEpetra(CM));
932 int err = graph_->Export(*v, *tExporter.getEpetra_Export(),
toEpetra(CM));
958#ifndef XPETRA_EPETRA_NO_64BIT_GLOBAL_INDICES
961 :
public virtual CrsGraph<int, long long, EpetraNode> {
969#ifdef HAVE_XPETRA_TPETRA
1002#ifdef HAVE_XPETRA_TPETRA
1006 const typename local_graph_type::row_map_type & ,
1007 const typename local_graph_type::entries_type::non_const_type & ,
1010 "Epetra does not support CrsGraph constructors using Kokkos Views!");
1019 "Epetra does not support CrsGraph constructors using a local graph!");
1030 "Epetra does not support CrsGraph constructors using a local graph!");
1054 int *indices_rawPtr =
const_cast<int *
>(indices.
getRawPtr());
1061 graph_->RemoveMyIndices(localRow);
1076 int lowerOffset = 0;
1077 bool ownMemory =
false;
1082 myColind.
Resize(numNonZeros);
1083 colind = Teuchos::arcp(myColind.
Values(), lowerOffset, numNonZeros, ownMemory);
1092 "An exception is thrown to let you know that the size of your rowptr array is incorrect.");
1093 if (colind.
size() > 0) {
1095 "An exception is thrown to let you know that you mismatched your pointers.");
1104 for (
size_t i = 0; i < N + 1; i++)
1105 myRowptr[i] = Teuchos::as<int>(rowptr[i]);
1112 int lowerOffset = 0;
1113 bool ownMemory =
false;
1122 for (
size_t i = 0; i < n + 1; i++)
1123 (*
const_cast<size_t *
>(&rowptr[i])) = Teuchos::as<size_t>(myRowptr[i]);
1126 colind = Teuchos::arcp(graph_->ExpertExtractIndices().Values(), lowerOffset, nnz, ownMemory);
1138 graph_->FillComplete(toEpetra<GlobalOrdinal, Node>(domainMap), toEpetra<GlobalOrdinal, Node>(rangeMap));
1139 bool doOptimizeStorage =
true;
1140 if (params != null && params->get(
"Optimize Storage",
true) ==
false) doOptimizeStorage =
false;
1141 if (doOptimizeStorage) graph_->OptimizeStorage();
1148 graph_->FillComplete();
1149 bool doOptimizeStorage =
true;
1150 if (params != null && params->get(
"Optimize Storage",
true) ==
false) doOptimizeStorage =
false;
1151 if (doOptimizeStorage) graph_->OptimizeStorage();
1165 graph_->FillComplete(toEpetra<GlobalOrdinal, Node>(domainMap), toEpetra<GlobalOrdinal, Node>(rangeMap));
1166 graph_->OptimizeStorage();
1183 return toXpetra<GlobalOrdinal, Node>(graph_->RowMap());
1189 return toXpetra<GlobalOrdinal, Node>(graph_->ColMap());
1195 return toXpetra<GlobalOrdinal, Node>(graph_->DomainMap());
1201 return toXpetra<GlobalOrdinal, Node>(graph_->RangeMap());
1207 return toXpetra<GlobalOrdinal, Node>(graph_->Importer());
1213 return toXpetra<GlobalOrdinal, Node>(graph_->Exporter());
1219 return graph_->NumGlobalRows64();
1225 return graph_->NumGlobalCols64();
1231 return graph_->NumMyRows();
1237 return graph_->NumMyCols();
1249 return graph_->NumGlobalEntries64();
1255 return graph_->NumMyEntries();
1261 return graph_->NumGlobalIndices(globalRow);
1267 return graph_->NumMyIndices(localRow);
1272 XPETRA_MONITOR(
"EpetraCrsGraphT::getNumAllocatedEntriesInGlobalRow");
1273 return graph_->NumAllocatedGlobalIndices(globalRow);
1278 XPETRA_MONITOR(
"EpetraCrsGraphT::getNumAllocatedEntriesInLocalRow");
1279 return graph_->NumAllocatedMyIndices(localRow);
1285 return graph_->GlobalMaxNumIndices();
1291 return graph_->MaxNumIndices();
1297 return graph_->HaveColMap();
1303 return graph_->IndicesAreLocal();
1309 return graph_->IndicesAreGlobal();
1315 return graph_->Filled();
1321 return graph_->StorageOptimized();
1331 XPETRA_ERR_CHECK(graph_->ExtractGlobalRowView(GlobalRow, numEntries, eIndices));
1332 if (numEntries == 0) {
1346 XPETRA_ERR_CHECK(graph_->ExtractMyRowView(LocalRow, numEntries, eIndices));
1347 if (numEntries == 0) {
1354#ifdef HAVE_XPETRA_TPETRA
1355#if KOKKOS_VERSION >= 40799
1362#if KOKKOS_VERSION >= 40799
1363 using local_graph_type_host =
typename local_graph_type::host_mirror_type;
1365 using local_graph_type_host =
typename local_graph_type::HostMirror;
1368 const int numRows = graph->NumMyRows();
1369 const int nnz = graph->NumMyNonzeros();
1371 TEUCHOS_TEST_FOR_EXCEPTION(!graph->StorageOptimized(), std::runtime_error,
"Xpetra::CrsGraph<>::getLocalGraph: Epetra_CrsGraph not StorageOptimized");
1372 const int *rowptr = graph->ExpertExtractIndexOffset().Values();
1373 int *colind = graph->ExpertExtractIndices().Values();
1376 typename local_graph_type_host::row_map_type::non_const_type kokkosRowPtr(Kokkos::ViewAllocateWithoutInitializing(
"local row map"), numRows + 1);
1377 for (
size_t i = 0; i < kokkosRowPtr.size(); i++)
1378 kokkosRowPtr(i) = Teuchos::asSafe<typename local_graph_type_host::row_map_type::value_type>(rowptr[i]);
1381 typename local_graph_type_host::entries_type kokkosColind(colind, nnz);
1383 local_graph_type_host localGraph = local_graph_type_host(kokkosColind, kokkosRowPtr);
1391 const int numRows = graph->NumMyRows();
1392 const int nnz = graph->NumMyNonzeros();
1394 TEUCHOS_TEST_FOR_EXCEPTION(!graph->StorageOptimized(), std::runtime_error,
"Xpetra::CrsGraph<>::getLocalGraph: Epetra_CrsGraph not StorageOptimized");
1395 const int *rowptr = graph->ExpertExtractIndexOffset().Values();
1396 int *colind = graph->ExpertExtractIndices().Values();
1399 typename local_graph_type::row_map_type::non_const_type kokkosRowPtr(Kokkos::ViewAllocateWithoutInitializing(
"local row map"), numRows + 1);
1400 for (
size_t i = 0; i < kokkosRowPtr.size(); i++)
1401 kokkosRowPtr(i) = Teuchos::asSafe<typename local_graph_type::row_map_type::value_type>(rowptr[i]);
1404 typename local_graph_type::entries_type kokkosColind(colind, nnz);
1411 void getLocalDiagOffsets(
const Kokkos::View<size_t *, typename Node::device_type, Kokkos::MemoryUnmanaged> &offsets)
const {
1413 "Epetra does not support getLocalDiagOffsets!");
1417#warning "Xpetra Kokkos interface for CrsGraph is enabled (HAVE_XPETRA_KOKKOS_REFACTOR) but Tpetra is disabled. The Kokkos interface needs Tpetra to be enabled, too."
1432 return "NotImplemented";
1439 out <<
"EpetraCrsGraphT::describe : Warning, verbosity level is ignored by this method." << std::endl;
1441 if (rowmap.
Comm().
MyPID() == 0) out <<
"** EpetraCrsGraphT **\n\nrowmap" << std::endl;
1454 return toXpetra<GlobalOrdinal, Node>(graph_->Map());
1466 int err = graph_->Import(*v, *tImporter.getEpetra_Import(),
toEpetra(CM));
1479 int err = graph_->Export(*v, *tImporter.getEpetra_Import(),
toEpetra(CM));
1492 int err = graph_->Import(*v, *tExporter.getEpetra_Export(),
toEpetra(CM));
1505 int err = graph_->Export(*v, *tExporter.getEpetra_Export(),
toEpetra(CM));
#define XPETRA_MONITOR(funcName)
#define XPETRA_ERR_CHECK(arg)
#define XPETRA_DYNAMIC_CAST(type, obj, newObj, exceptionMsg)
virtual void Print(std::ostream &os) const
const Epetra_Comm & Comm() const
virtual int MyPID() const=0
int Resize(int Length_in)
void resize(const size_type n, const T &val=T())
static const EVerbosityLevel verbLevel_default
typename local_graph_device_type::HostMirror local_graph_host_type
KokkosSparse::StaticCrsGraph< LocalOrdinal, Kokkos::LayoutLeft, device_type, void, size_t > local_graph_device_type
KokkosSparse::StaticCrsGraph< LocalOrdinal, Kokkos::LayoutLeft, device_type, void, size_t > local_graph_type
RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > getColMap() const
Returns the Map that describes the column distribution in this graph.
global_size_t getGlobalNumRows() const
Returns the number of global rows in the graph.
EpetraCrsGraphT(const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &rowMap, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &colMap, size_t maxNumEntriesPerRow, const Teuchos::RCP< Teuchos::ParameterList > &=null)
Constructor specifying column Map and fixed number of entries for each row.
RCP< Epetra_CrsGraph > graph_
size_t getNumEntriesInLocalRow(LocalOrdinal localRow) const
Returns the current number of entries on this node in the specified local row.
void insertLocalIndices(const LocalOrdinal localRow, const ArrayView< const LocalOrdinal > &indices)
Insert local indices into the graph.
EpetraCrsGraphT(const Teuchos::RCP< Epetra_CrsGraph > &graph)
EpetraCrsGraphT constructor to wrap a Epetra_CrsGraph object.
RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > getDomainMap() const
Returns the Map associated with the domain of this graph.
void fillComplete(const RCP< ParameterList > ¶ms=null)
Signal that data entry is complete.
RCP< const Epetra_CrsGraph > getEpetra_CrsGraph() const
Get the underlying Epetra graph.
EpetraCrsGraphT(const local_graph_type &, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &, const Teuchos::RCP< const map_type > &=Teuchos::null, const Teuchos::RCP< const map_type > &=Teuchos::null, const RCP< Teuchos::ParameterList > &=Teuchos::null)
Constructor specifying column Map, number of entries in each row and column indices in each row.
size_t getNumEntriesInGlobalRow(GlobalOrdinal globalRow) const
Returns the current number of entries on this node in the specified global row.
RCP< const Import< LocalOrdinal, GlobalOrdinal, Node > > getImporter() const
Returns the importer associated with this graph.
global_size_t getGlobalNumEntries() const
Returns the global number of entries in the graph.
void doImport(const DistObject< GlobalOrdinal, LocalOrdinal, GlobalOrdinal, Node > &source, const Import< LocalOrdinal, GlobalOrdinal, Node > &importer, CombineMode CM)
Import.
void describe(Teuchos::FancyOStream &out, const Teuchos::EVerbosityLevel=Teuchos::Describable::verbLevel_default) const
Print the object with some verbosity level to an FancyOStream object.
bool isGloballyIndexed() const
Whether column indices are stored using global indices on the calling process.
size_t getLocalNumEntries() const
Returns the local number of entries in the graph.
void getGlobalRowView(GlobalOrdinal GlobalRow, ArrayView< const GlobalOrdinal > &Indices) const
Return a const, nonpersisting view of global indices in the given row.
RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > getRowMap() const
Returns the Map that describes the row distribution in this graph.
global_size_t getGlobalNumCols() const
Returns the number of global columns in the graph.
Xpetra::CrsGraph< LocalOrdinal, GlobalOrdinal, Node >::local_graph_type local_graph_type
void doImport(const DistObject< GlobalOrdinal, LocalOrdinal, GlobalOrdinal, Node > &source, const Export< LocalOrdinal, GlobalOrdinal, Node > &exporter, CombineMode CM)
Import (using an Exporter).
Xpetra::CrsGraph< LocalOrdinal, GlobalOrdinal, Node >::node_type node_type
void allocateAllIndices(size_t numNonZeros, ArrayRCP< size_t > &rowptr, ArrayRCP< LocalOrdinal > &colind)
Allocates and returns ArrayRCPs of the Crs arrays — This is an Xpetra-only routine.
size_t getGlobalMaxNumRowEntries() const
Maximum number of entries in all rows over all processes.
bool isFillComplete() const
Whether fillComplete() has been called and the graph is in compute mode.
void doExport(const DistObject< GlobalOrdinal, LocalOrdinal, GlobalOrdinal, Node > &dest, const Import< LocalOrdinal, GlobalOrdinal, Node > &importer, CombineMode CM)
Export.
void removeLocalIndices(LocalOrdinal localRow)
Remove all graph indices from the specified local row.
EpetraCrsGraphT(const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &rowMap, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &colMap, const ArrayRCP< const size_t > &NumEntriesPerRowToAlloc, const RCP< ParameterList > &=null)
size_t getNumAllocatedEntriesInLocalRow(LocalOrdinal localRow) const
Returns the current number of allocated entries on this node in the specified local row.
EpetraCrsGraphT(const RCP< const map_type > &rowMap, size_t maxNumEntriesPerRow, const RCP< Teuchos::ParameterList > &=Teuchos::null)
Constructor specifying fixed number of entries for each row.
size_t getLocalMaxNumRowEntries() const
Maximum number of entries in all rows owned by the calling process.
Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > getMap() const
Implements DistObject interface.
void setAllIndices(const ArrayRCP< size_t > &rowptr, const ArrayRCP< LocalOrdinal > &colind)
Sets the 1D pointer arrays of the graph.
void getLocalRowView(LocalOrdinal LocalRow, ArrayView< const LocalOrdinal > &indices) const
Return a const, nonpersisting view of local indices in the given row.
Map< LocalOrdinal, GlobalOrdinal, Node > map_type
The specialization of Map used by this class.
void getLocalDiagOffsets(const Kokkos::View< size_t *, typename Node::device_type, Kokkos::MemoryUnmanaged > &offsets) const
GlobalOrdinal getIndexBase() const
Returns the index base for global indices for this graph.
void computeGlobalConstants()
Force the computation of global constants if we don't have them.
EpetraCrsGraphT(const Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &rowMap)
Constructor for empty DynamicProfile graph (no space is preallocated).
std::string description() const
Return a simple one-line description of this object.
RCP< const Comm< int > > getComm() const
Returns the communicator.
bool isLocallyIndexed() const
Whether column indices are stored using local indices on the calling process.
bool hasColMap() const
Whether the graph has a column Map.
void getAllIndices(ArrayRCP< const size_t > &rowptr, ArrayRCP< const LocalOrdinal > &colind) const
Gets the 1D pointer arrays of the graph.
virtual ~EpetraCrsGraphT()
Destructor.
void doExport(const DistObject< GlobalOrdinal, LocalOrdinal, GlobalOrdinal, Node > &dest, const Export< LocalOrdinal, GlobalOrdinal, Node > &exporter, CombineMode CM)
Export (using an Importer).
void fillComplete(const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &domainMap, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &rangeMap, const RCP< ParameterList > ¶ms=null)
Signal that data entry is complete, specifying domain and range maps.
EpetraCrsGraphT(const RCP< const CrsGraph< LocalOrdinal, GlobalOrdinal, Node > > &sourceGraph, const Import< LocalOrdinal, GlobalOrdinal, Node > &importer, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &domainMap=Teuchos::null, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &rangeMap=Teuchos::null, const RCP< Teuchos::ParameterList > ¶ms=Teuchos::null)
node_type::execution_space execution_space
local_graph_type::HostMirror getLocalGraphHost() const
Get the local graph.
void insertGlobalIndices(GlobalOrdinal globalRow, const ArrayView< const GlobalOrdinal > &indices)
Insert global indices into the graph.
EpetraCrsGraphT(const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &, const local_graph_type &, const RCP< Teuchos::ParameterList > &=Teuchos::null)
Constructor specifying column Map, number of entries in each row and column indices in each row.
size_t getLocalNumRows() const
Returns the number of graph rows owned on the calling node.
bool isStorageOptimized() const
Returns true if storage has been optimized.
EpetraCrsGraphT(const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &, const typename local_graph_type::row_map_type &, const typename local_graph_type::entries_type::non_const_type &, const RCP< Teuchos::ParameterList > &=Teuchos::null)
Constructor specifying column Map, number of entries in each row and column indices in each row.
RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > getRangeMap() const
Returns the Map associated with the domain of this graph.
RCP< const Export< LocalOrdinal, GlobalOrdinal, Node > > getExporter() const
Returns the exporter associated with this graph.
void expertStaticFillComplete(const Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &domainMap, const Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &rangeMap, const Teuchos::RCP< const Import< LocalOrdinal, GlobalOrdinal, Node > > &importer=Teuchos::null, const Teuchos::RCP< const Export< LocalOrdinal, GlobalOrdinal, Node > > &exporter=Teuchos::null, const Teuchos::RCP< Teuchos::ParameterList > ¶ms=Teuchos::null)
Expert version of fillComplete.
size_t getNumAllocatedEntriesInGlobalRow(GlobalOrdinal globalRow) const
Returns the current number of allocated entries for this node in the specified global row .
local_graph_type getLocalGraphDevice() const
size_t getLocalNumCols() const
Returns the number of columns connected to the locally owned rows of this graph.
size_t getNumAllocatedEntriesInLocalRow(LocalOrdinal localRow) const
Returns the current number of allocated entries on this node in the specified local row.
bool isStorageOptimized() const
Returns true if storage has been optimized.
bool isFillComplete() const
Whether fillComplete() has been called and the graph is in compute mode.
void computeGlobalConstants()
Force the computation of global constants if we don't have them.
local_graph_type getLocalGraphDevice() const
global_size_t getGlobalNumCols() const
Returns the number of global columns in the graph.
void doImport(const DistObject< GlobalOrdinal, LocalOrdinal, GlobalOrdinal, Node > &source, const Export< LocalOrdinal, GlobalOrdinal, Node > &exporter, CombineMode CM)
Import (using an Exporter).
RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > getRowMap() const
Returns the Map that describes the row distribution in this graph.
EpetraCrsGraphT(const RCP< const map_type > &rowMap, size_t maxNumEntriesPerRow, const RCP< Teuchos::ParameterList > &=Teuchos::null)
Constructor specifying fixed number of entries for each row.
Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > getMap() const
Implements DistObject interface.
void insertLocalIndices(const LocalOrdinal localRow, const ArrayView< const LocalOrdinal > &indices)
Insert local indices into the graph.
size_t getLocalNumCols() const
Returns the number of columns connected to the locally owned rows of this graph.
EpetraCrsGraphT(const Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &rowMap)
Constructor for empty DynamicProfile graph (no space is preallocated).
size_t getNumEntriesInGlobalRow(GlobalOrdinal globalRow) const
Returns the current number of entries on this node in the specified global row.
void getAllIndices(ArrayRCP< const size_t > &rowptr, ArrayRCP< const LocalOrdinal > &colind) const
Gets the 1D pointer arrays of the graph.
void setAllIndices(const ArrayRCP< size_t > &rowptr, const ArrayRCP< LocalOrdinal > &colind)
Sets the 1D pointer arrays of the graph.
RCP< const Import< LocalOrdinal, GlobalOrdinal, Node > > getImporter() const
Returns the importer associated with this graph.
RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > getRangeMap() const
Returns the Map associated with the domain of this graph.
void expertStaticFillComplete(const Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &domainMap, const Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &rangeMap, const Teuchos::RCP< const Import< LocalOrdinal, GlobalOrdinal, Node > > &importer=Teuchos::null, const Teuchos::RCP< const Export< LocalOrdinal, GlobalOrdinal, Node > > &exporter=Teuchos::null, const Teuchos::RCP< Teuchos::ParameterList > ¶ms=Teuchos::null)
Expert version of fillComplete.
size_t getGlobalMaxNumRowEntries() const
Maximum number of entries in all rows over all processes.
local_graph_type::HostMirror getLocalGraphHost() const
Get the local graph.
RCP< const Epetra_CrsGraph > getEpetra_CrsGraph() const
Get the underlying Epetra graph.
EpetraCrsGraphT(const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &, const typename local_graph_type::row_map_type &, const typename local_graph_type::entries_type::non_const_type &, const RCP< Teuchos::ParameterList > &=Teuchos::null)
Constructor specifying column Map, number of entries in each row and column indices in each row.
EpetraCrsGraphT(const Teuchos::RCP< Epetra_CrsGraph > &graph)
EpetraCrsGraphT constructor to wrap a Epetra_CrsGraph object.
void describe(Teuchos::FancyOStream &out, const Teuchos::EVerbosityLevel=Teuchos::Describable::verbLevel_default) const
Print the object with some verbosity level to an FancyOStream object.
RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > getDomainMap() const
Returns the Map associated with the domain of this graph.
global_size_t getGlobalNumRows() const
Returns the number of global rows in the graph.
size_t getLocalMaxNumRowEntries() const
Maximum number of entries in all rows owned by the calling process.
size_t getLocalNumEntries() const
Returns the local number of entries in the graph.
Map< LocalOrdinal, GlobalOrdinal, Node > map_type
The specialization of Map used by this class.
virtual ~EpetraCrsGraphT()
Destructor.
node_type::execution_space execution_space
std::string description() const
Return a simple one-line description of this object.
RCP< const Export< LocalOrdinal, GlobalOrdinal, Node > > getExporter() const
Returns the exporter associated with this graph.
void insertGlobalIndices(GlobalOrdinal globalRow, const ArrayView< const GlobalOrdinal > &indices)
Insert global indices into the graph.
bool isGloballyIndexed() const
Whether column indices are stored using global indices on the calling process.
EpetraCrsGraphT(const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &rowMap, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &colMap, const ArrayRCP< const size_t > &NumEntriesPerRowToAlloc, const RCP< ParameterList > &=null)
void getGlobalRowView(GlobalOrdinal GlobalRow, ArrayView< const GlobalOrdinal > &Indices) const
Return a const, nonpersisting view of global indices in the given row.
void doExport(const DistObject< GlobalOrdinal, LocalOrdinal, GlobalOrdinal, Node > &dest, const Export< LocalOrdinal, GlobalOrdinal, Node > &exporter, CombineMode CM)
Export (using an Importer).
size_t getNumEntriesInLocalRow(LocalOrdinal localRow) const
Returns the current number of entries on this node in the specified local row.
global_size_t getGlobalNumEntries() const
Returns the global number of entries in the graph.
GlobalOrdinal getIndexBase() const
Returns the index base for global indices for this graph.
RCP< const Comm< int > > getComm() const
Returns the communicator.
bool isLocallyIndexed() const
Whether column indices are stored using local indices on the calling process.
bool hasColMap() const
Whether the graph has a column Map.
EpetraCrsGraphT(const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &rowMap, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &colMap, size_t maxNumEntriesPerRow, const Teuchos::RCP< Teuchos::ParameterList > &=null)
Constructor specifying column Map and fixed number of entries for each row.
size_t getLocalNumRows() const
Returns the number of graph rows owned on the calling node.
void fillComplete(const RCP< ParameterList > ¶ms=null)
Signal that data entry is complete.
void fillComplete(const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &domainMap, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &rangeMap, const RCP< ParameterList > ¶ms=null)
Signal that data entry is complete, specifying domain and range maps.
Xpetra::CrsGraph< LocalOrdinal, GlobalOrdinal, Node >::local_graph_type local_graph_type
void doExport(const DistObject< GlobalOrdinal, LocalOrdinal, GlobalOrdinal, Node > &dest, const Import< LocalOrdinal, GlobalOrdinal, Node > &importer, CombineMode CM)
Export.
void getLocalRowView(LocalOrdinal LocalRow, ArrayView< const LocalOrdinal > &indices) const
Return a const, nonpersisting view of local indices in the given row.
RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > getColMap() const
Returns the Map that describes the column distribution in this graph.
void allocateAllIndices(size_t numNonZeros, ArrayRCP< size_t > &rowptr, ArrayRCP< LocalOrdinal > &colind)
Allocates and returns ArrayRCPs of the Crs arrays — This is an Xpetra-only routine.
size_t getNumAllocatedEntriesInGlobalRow(GlobalOrdinal globalRow) const
Returns the current number of allocated entries for this node in the specified global row .
EpetraCrsGraphT(const local_graph_type &, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &, const Teuchos::RCP< const map_type > &=Teuchos::null, const Teuchos::RCP< const map_type > &=Teuchos::null, const RCP< Teuchos::ParameterList > &=Teuchos::null)
Constructor specifying column Map, number of entries in each row and column indices in each row.
Xpetra::CrsGraph< LocalOrdinal, GlobalOrdinal, Node >::node_type node_type
void getLocalDiagOffsets(const Kokkos::View< size_t *, typename Node::device_type, Kokkos::MemoryUnmanaged > &offsets) const
RCP< Epetra_CrsGraph > graph_
EpetraCrsGraphT(const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &, const local_graph_type &, const RCP< Teuchos::ParameterList > &=Teuchos::null)
Constructor specifying column Map, number of entries in each row and column indices in each row.
void doImport(const DistObject< GlobalOrdinal, LocalOrdinal, GlobalOrdinal, Node > &source, const Import< LocalOrdinal, GlobalOrdinal, Node > &importer, CombineMode CM)
Import.
void removeLocalIndices(LocalOrdinal localRow)
Remove all graph indices from the specified local row.
size_t getLocalNumRows() const
Returns the number of graph rows owned on the calling node.
EpetraCrsGraphT(const Teuchos::RCP< Epetra_CrsGraph > &graph)
EpetraCrsGraphT constructor to wrap a Epetra_CrsGraph object.
void setAllIndices(const ArrayRCP< size_t > &rowptr, const ArrayRCP< LocalOrdinal > &colind)
Sets the 1D pointer arrays of the graph.
void doImport(const DistObject< GlobalOrdinal, LocalOrdinal, GlobalOrdinal, Node > &source, const Export< LocalOrdinal, GlobalOrdinal, Node > &exporter, CombineMode CM)
Import (using an Exporter).
void fillComplete(const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &domainMap, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &rangeMap, const RCP< ParameterList > ¶ms=null)
Signal that data entry is complete, specifying domain and range maps.
size_t getLocalNumEntries() const
Returns the local number of entries in the graph.
size_t getNumEntriesInGlobalRow(GlobalOrdinal globalRow) const
Returns the current number of entries on this node in the specified global row.
EpetraCrsGraphT(const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &rowMap, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &colMap, const local_graph_type &lclGraph, const RCP< Teuchos::ParameterList > &plist=Teuchos::null)
Constructor specifying column Map, number of entries in each row and column indices in each row.
size_t getNumAllocatedEntriesInGlobalRow(GlobalOrdinal globalRow) const
Returns the current number of allocated entries for this node in the specified global row .
void describe(Teuchos::FancyOStream &out, const Teuchos::EVerbosityLevel verbLevel=Teuchos::Describable::verbLevel_default) const
Print the object with some verbosity level to an FancyOStream object.
EpetraCrsGraphT(const RCP< const map_type > &rowMap, const RCP< Teuchos::ParameterList > &plist=Teuchos::null)
Constructor for empty DynamicProfile graph (no space is preallocated).
RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > getColMap() const
Returns the Map that describes the column distribution in this graph.
void allocateAllIndices(size_t numNonZeros, ArrayRCP< size_t > &rowptr, ArrayRCP< LocalOrdinal > &colind)
Allocates the 1D pointer arrays of the graph.
void expertStaticFillComplete(const Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &domainMap, const Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &rangeMap, const Teuchos::RCP< const Import< LocalOrdinal, GlobalOrdinal, Node > > &importer=Teuchos::null, const Teuchos::RCP< const Export< LocalOrdinal, GlobalOrdinal, Node > > &exporter=Teuchos::null, const Teuchos::RCP< Teuchos::ParameterList > ¶ms=Teuchos::null)
Expert version of fillComplete.
bool hasColMap() const
Whether the graph has a column Map.
void doImport(const DistObject< GlobalOrdinal, LocalOrdinal, GlobalOrdinal, Node > &source, const Import< LocalOrdinal, GlobalOrdinal, Node > &importer, CombineMode CM)
Import.
GlobalOrdinal getIndexBase() const
Returns the index base for global indices for this graph.
EpetraCrsGraphT(const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &rowMap, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &colMap, size_t maxNumEntriesPerRow, const Teuchos::RCP< Teuchos::ParameterList > &plist=null)
Constructor specifying column Map and fixed number of entries for each row.
bool isFillComplete() const
Whether fillComplete() has been called and the graph is in compute mode.
global_size_t getGlobalNumRows() const
Returns the number of global rows in the graph.
typename Xpetra::CrsGraph< LocalOrdinal, GlobalOrdinal, Node >::local_graph_type local_graph_type
EpetraCrsGraphT(const RCP< const CrsGraph< LocalOrdinal, GlobalOrdinal, Node > > &sourceGraph, const Import< LocalOrdinal, GlobalOrdinal, Node > &importer, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &domainMap=Teuchos::null, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &rangeMap=Teuchos::null, const RCP< Teuchos::ParameterList > ¶ms=Teuchos::null)
bool isLocallyIndexed() const
Whether column indices are stored using local indices on the calling process.
void fillComplete(const RCP< ParameterList > ¶ms=null)
Signal that data entry is complete.
bool isGloballyIndexed() const
Whether column indices are stored using global indices on the calling process.
size_t getNumEntriesInLocalRow(LocalOrdinal localRow) const
Returns the current number of entries on this node in the specified local row.
size_t getNumAllocatedEntriesInLocalRow(LocalOrdinal localRow) const
Returns the current number of allocated entries on this node in the specified local row.
void doExport(const DistObject< GlobalOrdinal, LocalOrdinal, GlobalOrdinal, Node > &dest, const Import< LocalOrdinal, GlobalOrdinal, Node > &importer, CombineMode CM)
Export.
RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > getRangeMap() const
Returns the Map associated with the domain of this graph.
local_graph_type::HostMirror getLocalGraphHost() const
Get the local graph.
Map< LocalOrdinal, GlobalOrdinal, Node > map_type
The specialization of Map used by this class.
void computeGlobalConstants()
Force the computation of global constants if we don't have them.
global_size_t getGlobalNumEntries() const
Returns the global number of entries in the graph.
RCP< const Comm< int > > getComm() const
Returns the communicator.
typename Xpetra::CrsGraph< LocalOrdinal, GlobalOrdinal, Node >::local_graph_device_type local_graph_device_type
node_type::execution_space execution_space
RCP< const Import< LocalOrdinal, GlobalOrdinal, Node > > getImporter() const
Returns the importer associated with this graph.
void insertGlobalIndices(GlobalOrdinal globalRow, const ArrayView< const GlobalOrdinal > &indices)
Insert global indices into the graph.
EpetraCrsGraphT(const local_graph_type &lclGraph, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &rowMap, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &colMap, const Teuchos::RCP< const map_type > &domainMap=Teuchos::null, const Teuchos::RCP< const map_type > &rangeMap=Teuchos::null, const RCP< Teuchos::ParameterList > &plist=Teuchos::null)
Constructor specifying column Map, number of entries in each row and column indices in each row.
std::string description() const
Return a simple one-line description of this object.
EpetraCrsGraphT(const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &rowMap, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &colMap, const ArrayRCP< const size_t > &NumEntriesPerRowToAlloc, const RCP< ParameterList > ¶ms=null)
local_graph_type getLocalGraphDevice() const
Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > getMap() const
Implements DistObject interface.
RCP< const Epetra_CrsGraph > getEpetra_CrsGraph() const
Get the underlying Epetra graph.
void removeLocalIndices(LocalOrdinal localRow)
Remove all graph indices from the specified local row.
size_t getGlobalMaxNumRowEntries() const
Maximum number of entries in all rows over all processes.
size_t getLocalMaxNumRowEntries() const
Maximum number of entries in all rows owned by the calling process.
RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > getRowMap() const
Returns the Map that describes the row distribution in this graph.
void insertLocalIndices(const LocalOrdinal localRow, const ArrayView< const LocalOrdinal > &indices)
Insert local indices into the graph.
global_size_t getGlobalNumCols() const
Returns the number of global columns in the graph.
void getLocalRowView(LocalOrdinal LocalRow, ArrayView< const LocalOrdinal > &indices) const
Return a const, nonpersisting view of local indices in the given row.
Xpetra::CrsGraph< LocalOrdinal, GlobalOrdinal, Node >::node_type node_type
void getLocalDiagOffsets(const Kokkos::View< size_t *, typename Node::device_type, Kokkos::MemoryUnmanaged > &offsets) const
EpetraCrsGraphT(const RCP< const map_type > &rowMap, size_t maxNumEntriesPerRow, const RCP< Teuchos::ParameterList > &plist=Teuchos::null)
Constructor specifying fixed number of entries for each row.
size_t getLocalNumCols() const
Returns the number of columns connected to the locally owned rows of this graph.
virtual ~EpetraCrsGraphT()
Destructor.
RCP< const Export< LocalOrdinal, GlobalOrdinal, Node > > getExporter() const
Returns the exporter associated with this graph.
void getAllIndices(ArrayRCP< const size_t > &rowptr, ArrayRCP< const LocalOrdinal > &colind) const
Gets the 1D pointer arrays of the graph.
typename Xpetra::CrsGraph< LocalOrdinal, GlobalOrdinal, Node >::local_graph_host_type local_graph_host_type
void doExport(const DistObject< GlobalOrdinal, LocalOrdinal, GlobalOrdinal, Node > &dest, const Export< LocalOrdinal, GlobalOrdinal, Node > &exporter, CombineMode CM)
Export (using an Importer).
RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > getDomainMap() const
Returns the Map associated with the domain of this graph.
EpetraCrsGraphT(const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &rowMap, const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &colMap, const typename local_graph_type::row_map_type &rowPointers, const typename local_graph_type::entries_type::non_const_type &columnIndices, const RCP< Teuchos::ParameterList > &plist=Teuchos::null)
Constructor specifying column Map, number of entries in each row and column indices in each row.
bool isStorageOptimized() const
Returns true if storage has been optimized.
void getGlobalRowView(GlobalOrdinal GlobalRow, ArrayView< const GlobalOrdinal > &Indices) const
Return a const, nonpersisting view of global indices in the given row.
Exception throws when you call an unimplemented method of Xpetra.
Exception throws to report errors in the internal logical of the program.
virtual Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > getTargetMap() const =0
The Target Map used to construct this Import object.
#define TEUCHOS_TEST_FOR_EXCEPTION(throw_exception_test, Exception, msg)
#define TEUCHOS_UNREACHABLE_RETURN(dummyReturnVal)
TEUCHOS_DEPRECATED RCP< T > rcp(T *p, Dealloc_T dealloc, bool owns_mem)
Tpetra::KokkosCompat::KokkosSerialWrapperNode EpetraNode
size_t global_size_t
Global size_t object.
const Epetra_CrsGraph & toEpetra(const RCP< const CrsGraph< int, GlobalOrdinal, Node > > &graph)
RCP< const CrsGraph< int, GlobalOrdinal, Node > > toXpetra(const Epetra_CrsGraph &g)
CombineMode
Xpetra::Combine Mode enumerable type.