11 #ifndef __Panzer_GlobalIndexer_Utilities_decl_hpp__
12 #define __Panzer_GlobalIndexer_Utilities_decl_hpp__
17 #include <unordered_map>
20 #include <Tpetra_Vector.hpp>
21 #include <Tpetra_MultiVector.hpp>
31 std::vector<Teuchos::RCP<const GlobalIndexer>>
73 std::vector<int> & blockOffsets);
90 std::vector<int> & blockOffsets);
131 const Teuchos::RCP<
const Tpetra::Vector<int,int,panzer::GlobalOrdinal,panzer::TpetraNodeType> > & reducedVec=Teuchos::null);
147 std::vector<int> & fieldNumbers,
148 const Teuchos::RCP<
const Tpetra::Vector<int,int,panzer::GlobalOrdinal,panzer::TpetraNodeType> > & reducedVec=Teuchos::null);
162 template <
typename ScalarT,
typename ArrayT>
164 const GlobalIndexer & ugi,
166 Tpetra::MultiVector<ScalarT,int,panzer::GlobalOrdinal,panzer::TpetraNodeType> & dataVector);
178 getFieldMap(
int fieldNum,
const Tpetra::Vector<int,int,panzer::GlobalOrdinal,panzer::TpetraNodeType> & fieldVector);
181 namespace orientation_helpers {
211 const std::vector<panzer::GlobalOrdinal> & topology,
212 const FieldPattern & fieldPattern,
213 std::vector<signed char> & orientation);
247 const std::vector<panzer::GlobalOrdinal> & topology,
248 const FieldPattern & fieldPattern,
249 std::vector<signed char> & orientation);
272 template <
typename ScalarT,
typename ArrayT>
274 getGhostedDataVector(
const std::string & fieldName,
const std::map<std::string,ArrayT> & data)
const;
285 template <
typename ScalarT,
typename ArrayT>
287 getDataVector(
const std::string & fieldName,
const std::map<std::string,ArrayT> & data)
const;
304 using IntVector = Tpetra::Vector<int,int,panzer::GlobalOrdinal,panzer::TpetraNodeType>;
305 using Map = Tpetra::Map<int,panzer::GlobalOrdinal,panzer::TpetraNodeType>;
308 void buildFieldVector(
const Tpetra::Vector<int,int,panzer::GlobalOrdinal,panzer::TpetraNodeType> & source)
const;
std::map< int, Teuchos::RCP< const Map > > fieldMaps_
(unghosted) field vector (as needed)
std::map< int, Teuchos::RCP< const Map > > gh_fieldMaps_
Maps for each field (as needed)
Teuchos::RCP< const IntVector > gh_reducedFieldVector_
Teuchos::RCP< Tpetra::Vector< int, int, panzer::GlobalOrdinal, panzer::TpetraNodeType > > buildGhostedFieldReducedVector(const GlobalIndexer &ugi)
std::map< int, Teuchos::RCP< const Map > > gh_reducedFieldMaps_
ghosted field vector
Teuchos::RCP< const IntVector > gh_fieldVector_
ghosted reduced field vector
Teuchos::RCP< const Tpetra::Map< int, panzer::GlobalOrdinal, panzer::TpetraNodeType > > getFieldMap(int fieldNum, const Tpetra::Vector< int, int, panzer::GlobalOrdinal, panzer::TpetraNodeType > &fieldTVector)
void computeBlockOffsets(const std::string &blockId, const std::vector< Teuchos::RCP< GlobalIndexer >> &ugis, std::vector< int > &blockOffsets)
Tpetra::Vector< int, int, panzer::GlobalOrdinal, panzer::TpetraNodeType > IntVector
void updateGhostedDataReducedVector(const std::string &fieldName, const std::string blockId, const GlobalIndexer &ugi, const ArrayT &data, Tpetra::MultiVector< ScalarT, int, panzer::GlobalOrdinal, panzer::TpetraNodeType > &dataVector)
Teuchos::RCP< const GlobalIndexer > ugi_
DOF mapping.
std::vector< Teuchos::RCP< const GlobalIndexer > > nc2c_vector(const std::vector< Teuchos::RCP< GlobalIndexer > > &ugis)
int getFieldBlock(const std::string &fieldName, const std::vector< Teuchos::RCP< const GlobalIndexer >> &ugis)
void computeCellEdgeOrientations(const std::vector< std::pair< int, int > > &topEdgeIndices, const std::vector< panzer::GlobalOrdinal > &topology, const FieldPattern &fieldPattern, std::vector< signed char > &orientation)
Teuchos::RCP< Tpetra::MultiVector< ScalarT, int, panzer::GlobalOrdinal, panzer::TpetraNodeType > > getGhostedDataVector(const std::string &fieldName, const std::map< std::string, ArrayT > &data) const
void computePatternFaceIndices(const FieldPattern &pattern, std::vector< std::vector< int > > &faceIndices)
void computeCellFaceOrientations(const std::vector< std::vector< int > > &topFaceIndices, const std::vector< panzer::GlobalOrdinal > &topology, const FieldPattern &fieldPattern, std::vector< signed char > &orientation)
Tpetra::Map< int, panzer::GlobalOrdinal, panzer::TpetraNodeType > Map
Teuchos::RCP< const Tpetra::Map< int, panzer::GlobalOrdinal, panzer::TpetraNodeType > > getFieldMap(const std::string &fieldName) const
Teuchos::RCP< Tpetra::MultiVector< ScalarT, int, panzer::GlobalOrdinal, panzer::TpetraNodeType > > getDataVector(const std::string &fieldName, const std::map< std::string, ArrayT > &data) const
void buildFieldVector(const Tpetra::Vector< int, int, panzer::GlobalOrdinal, panzer::TpetraNodeType > &source) const
build unghosted field vector from ghosted field vector
Teuchos::RCP< const IntVector > fieldVector_
Maps for each field (as needed)
void printMeshTopology(std::ostream &os, const panzer::GlobalIndexer &ugi)
void computePatternEdgeIndices(const FieldPattern &pattern, std::vector< std::pair< int, int > > &edgeIndices)
void buildGhostedFieldVector(const GlobalIndexer &ugi, std::vector< int > &fieldNumbers, const Teuchos::RCP< const Tpetra::Vector< int, int, panzer::GlobalOrdinal, panzer::TpetraNodeType > > &reducedVec)
ArrayToFieldVector()
Maps for each field (as needed)
std::string printUGILoadBalancingInformation(const GlobalIndexer &ugi)