• Main Page
  • Related Pages
  • Namespaces
  • Classes
  • Files
  • File List
  • File Members

MechanicsResidual.hpp

Go to the documentation of this file.
00001 //*****************************************************************//
00002 //    Albany 2.0:  Copyright 2012 Sandia Corporation               //
00003 //    This Software is released under the BSD license detailed     //
00004 //    in the file "license.txt" in the top-level Albany directory  //
00005 //*****************************************************************//
00006 
00007 #if !defined(LCM_Mechanics_Residual_hpp)
00008 #define LCM_Mechanics_Residual_hpp
00009 
00010 #include <Phalanx_ConfigDefs.hpp>
00011 #include <Phalanx_Evaluator_WithBaseImpl.hpp>
00012 #include <Phalanx_Evaluator_Derived.hpp>
00013 #include <Phalanx_MDField.hpp>
00014 #include <Sacado_ParameterAccessor.hpp>
00015 #include "Albany_Layouts.hpp"
00016 
00017 namespace LCM
00018 {
00026 template<typename EvalT, typename Traits>
00027 class MechanicsResidual:
00028     public PHX::EvaluatorWithBaseImpl<Traits>,
00029     public PHX::EvaluatorDerived<EvalT, Traits>
00030 {
00031 
00032 public:
00033 
00034   typedef typename EvalT::ScalarT ScalarT;
00035   typedef typename EvalT::MeshScalarT MeshScalarT;
00036 
00040   MechanicsResidual(Teuchos::ParameterList& p,
00041       const Teuchos::RCP<Albany::Layouts>& dl);
00042 
00046   void
00047   postRegistrationSetup(typename Traits::SetupData d,
00048       PHX::FieldManager<Traits>& vm);
00049 
00053   void
00054   evaluateFields(typename Traits::EvalData d);
00055 
00056 private:
00057 
00061   PHX::MDField<ScalarT, Cell, QuadPoint, Dim, Dim> stress_;
00062 
00066   PHX::MDField<MeshScalarT, Cell, Node, QuadPoint, Dim> w_grad_bf_;
00067 
00071   PHX::MDField<MeshScalarT, Cell, Node, QuadPoint> w_bf_;
00072 
00076   PHX::MDField<ScalarT, Cell, QuadPoint, Dim> body_force_;
00077 
00081   PHX::MDField<ScalarT, Cell, QuadPoint, Dim> acceleration_;
00082 
00086   PHX::MDField<ScalarT, Cell, Node, Dim> residual_;
00087 
00091   std::size_t num_nodes_;
00092 
00096   std::size_t num_pts_;
00097 
00101   std::size_t num_dims_;
00102 
00106   bool have_body_force_;
00107 
00111   RealType density_;
00112 
00116   bool enable_dynamics_;
00117 };
00118 }
00119 
00120 #endif

Generated on Wed Mar 26 2014 18:36:40 for Albany: a Trilinos-based PDE code by  doxygen 1.7.1