Panzer  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Panzer_GatherSolution_BlockedEpetra_Hessian.hpp
Go to the documentation of this file.
1 // @HEADER
2 // *****************************************************************************
3 // Panzer: A partial differential equation assembly
4 // engine for strongly coupled complex multiphysics systems
5 //
6 // Copyright 2011 NTESS and the Panzer contributors.
7 // SPDX-License-Identifier: BSD-3-Clause
8 // *****************************************************************************
9 // @HEADER
10 
11 #ifndef __Panzer_GatherSolution_BlockedEpetra_Hessian_hpp__
12 #define __Panzer_GatherSolution_BlockedEpetra_Hessian_hpp__
13 
14 // Only do this if required by the user.
15 #ifdef Panzer_BUILD_HESSIAN_SUPPORT
16 
17 namespace panzer
18 {
29  template<typename TRAITS, typename LO, typename GO>
30  class GatherSolution_BlockedEpetra<panzer::Traits::Hessian, TRAITS, LO, GO>
31  :
32  public panzer::EvaluatorWithBaseImpl<TRAITS>,
33  public PHX::EvaluatorDerived<panzer::Traits::Hessian, TRAITS>,
35  {
36  public:
37 
47  const std::vector<Teuchos::RCP<const GlobalIndexer<LO, int>>>&
48  indexers)
49  :
50  indexers_(indexers)
51  {
52  } // end of Constructor
53 
67  const std::vector<Teuchos::RCP<const GlobalIndexer<LO, int>>>&
68  indexers,
69  const Teuchos::ParameterList& p);
70 
80  void
82  typename TRAITS::SetupData d,
84 
95  void
97  typename TRAITS::PreEvalData d);
98 
107  void
109  typename TRAITS::EvalData d);
110 
125  const Teuchos::ParameterList& pl) const
126  {
128  using panzer::Traits;
129  using Teuchos::rcp;
130  return rcp(new
132  (indexers_, pl));
133  } // end of clone()
134 
135  private:
136 
140  typedef typename panzer::Traits::Hessian EvalT;
141 
146 
150  std::vector<std::string> indexerNames_;
151 
155  std::string globalDataKey_;
156 
161  std::vector<Teuchos::RCP<const GlobalIndexer<LO, int>>> indexers_;
162 
166  std::vector<int> indexerIds_;
167 
171  std::vector<int> subFieldIds_;
172 
176  std::vector< PHX::MDField<ScalarT, Cell, NODE>> gatherFields_;
177 
183 
187  std::string sensitivitiesName_;
188 
195 
201 
207 
212 
218 
224 
229 
236 
243 
248 
249  }; // end of class GatherSolution_BlockedEpetra (Hessian Specialization)
250 
251 } // end of namespace panzer
252 
253 #endif // Panzer_BUILD_HESSIAN_SUPPORT
254 
255 #endif // __Panzer_GatherSolution_BlockedEpetra_Hessian_hpp__
std::vector< std::string > indexerNames_
A list of the names of the fields to be gathered.
virtual Teuchos::RCP< CloneableEvaluator > clone(const Teuchos::ParameterList &pl) const
Create a copy.
Teuchos::RCP< panzer::BlockedVector_ReadOnly_GlobalEvaluationData > xBvRoGed_
The GlobalEvaluationData containing both the owned and ghosted solution vectors.
Teuchos::RCP< panzer::BlockedVector_ReadOnly_GlobalEvaluationData > dxBvRoGed_
The GlobalEvaluationData containing both the owned and ghosted derivative vectors.
TEUCHOS_DEPRECATED RCP< T > rcp(T *p, Dealloc_T dealloc, bool owns_mem)
Wrapper to PHX::EvaluatorWithBaseImpl that implements Panzer-specific helpers.
bool firstSensitivitiesAvailable_
A flag indicating whether or not first sensitivities information is available.
void postRegistrationSetup(typename TRAITS::SetupData d, PHX::FieldManager< TRAITS > &fm)
Post-Registration Setup.
bool firstApplySensitivities_
Used by evaluateFields() to turn on/off the first sensitivities.
bool secondApplySensitivities_
Used by evaluateFields() to turn on/off the second sensitivities.
GatherSolution_BlockedEpetra(const Teuchos::ParameterList &p)
Constructor.
std::string sensitivities2ndPrefix_
The prefix for the field containing the second sensitivities.
virtual void preEvaluate(typename Traits::PreEvalData d)=0
Gathers solution values from the Newton solution vector into the nodal fields of the field manager...
std::vector< Teuchos::RCP< const GlobalIndexer< LO, int > > > indexers_
These map the local (field, element, basis) triplet to a global ID for scattering.
void evaluateFields(typename TRAITS::EvalData d)
Evaluate Fields.
bool secondSensitivitiesAvailable_
A flag indicating whether or not second sensitivities information is available.
std::vector< PHX::MDField< ScalarT, Cell, NODE > > gatherFields_
The fields to be gathered.
Non-templated empty base class for template managers.
GatherSolution_BlockedEpetra(const std::vector< Teuchos::RCP< const GlobalIndexer< LO, int >>> &indexers)
Constructor.