43 #ifndef __Panzer_OrientationContainer_impl_hpp__ 44 #define __Panzer_OrientationContainer_impl_hpp__ 46 #include "PanzerDiscFE_config.hpp" 52 template <
typename Scalar,
typename Array,
typename LocalOrdinal,
typename GlobalOrdinal>
55 const std::string & fieldName)
56 : globalIndexer_(globalIndexer)
57 , fieldName_(fieldName)
61 template <
typename Scalar,
typename Array,
typename LocalOrdinal,
typename GlobalOrdinal>
65 const std::vector<std::size_t> & cell_local_ids,
66 Array & orientationsArray)
const 68 int fieldNum = globalIndexer_->getFieldNum(fieldName_);
69 const std::vector<int> & elmtOffset = globalIndexer_->getGIDFieldOffsets(blockId,fieldNum);
72 for(std::size_t cellIndex=0;cellIndex<cell_local_ids.size();++cellIndex) {
74 std::size_t cellLocalId = cell_local_ids[cellIndex];
76 globalIndexer_->getElementOrientation(cellLocalId,
orientation);
86 template <
typename Scalar,
typename Array>
87 Teuchos::RCP<const OrientationContainerBase<Scalar,Array> >
89 const std::string & fieldName)
91 using Teuchos::rcp_dynamic_cast;
100 RCP<const UniqueGlobalIndexer<LO,GO> > ugi
102 if(ugi!=Teuchos::null)
109 typedef Ordinal64 GO;
111 RCP<const UniqueGlobalIndexer<LO,GO> > ugi
113 if(ugi!=Teuchos::null)
120 typedef std::pair<int,int> GO;
122 RCP<const UniqueGlobalIndexer<LO,GO> > ugi
124 if(ugi!=Teuchos::null)
131 typedef std::pair<int,Ordinal64> GO;
133 RCP<const UniqueGlobalIndexer<LO,GO> > ugi
135 if(ugi!=Teuchos::null)
139 TEUCHOS_TEST_FOR_EXCEPTION(
true,std::logic_error,
140 "panzer::buildOrientationContainer: Could not cast UniqueGlobalIndexerBase");
PHX::MDField< ScalarT, panzer::Cell, panzer::BASIS > orientation
virtual void getOrientations(const std::string &blockId, const std::vector< std::size_t > &cell_local_ids, Array &orientations) const
Teuchos::RCP< const panzer::OrientationContainerBase< Scalar, Array > > buildOrientationContainer(const Teuchos::RCP< const panzer::UniqueGlobalIndexerBase > &globalIndexer, const std::string &fieldName)
Teuchos::RCP< const panzer::PureBasis > basis
Interpolates basis DOF values to IP DOF values.
OrientationContainer(const Teuchos::RCP< const panzer::UniqueGlobalIndexer< LocalOrdinal, GlobalOrdinal > > &globalIndexer, const std::string &fieldName)