libMesh
dtk_evaluator.h
Go to the documentation of this file.
1 // The libMesh Finite Element Library.
2 // Copyright (C) 2002-2017 Benjamin S. Kirk, John W. Peterson, Roy H. Stogner
3 
4 // This library is free software; you can redistribute it and/or
5 // modify it under the terms of the GNU Lesser General Public
6 // License as published by the Free Software Foundation; either
7 // version 2.1 of the License, or (at your option) any later version.
8 
9 // This library is distributed in the hope that it will be useful,
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 // Lesser General Public License for more details.
13 
14 // You should have received a copy of the GNU Lesser General Public
15 // License along with this library; if not, write to the Free Software
16 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 
18 
19 
20 #ifndef DTKEVALUATOR_H
21 #define DTKEVALUATOR_H
22 
23 
24 #include "libmesh/libmesh_config.h"
25 
26 #ifdef LIBMESH_TRILINOS_HAVE_DTK
27 
28 #include "libmesh/mesh.h"
29 
30 #include "libmesh/ignore_warnings.h"
31 #include <DTK_MeshContainer.hpp>
32 #include <DTK_FieldEvaluator.hpp>
33 #include <DTK_FieldContainer.hpp>
34 
35 #include <Teuchos_RCP.hpp>
36 #include <Teuchos_ArrayRCP.hpp>
37 #include "libmesh/restore_warnings.h"
38 
39 #include <string>
40 
41 namespace libMesh
42 {
43 
44 // Forward declarations
45 class EquationSystems;
46 class System;
47 class DofMap;
48 class MeshBase;
49 class FEType;
50 
51 template <typename T> class NumericVector;
52 
60 class DTKEvaluator : public DataTransferKit::FieldEvaluator<int,DataTransferKit::FieldContainer<double>>
61 {
62 public:
63  typedef DataTransferKit::MeshContainer<int> MeshContainerType;
64  typedef DataTransferKit::FieldContainer<Number> FieldContainerType;
65 
66  DTKEvaluator(System & in_sys, std::string var_name);
67 
68  virtual FieldContainerType evaluate(const Teuchos::ArrayRCP<int> & elements,
69  const Teuchos::ArrayRCP<double> & coords) libmesh_override;
70 
71 protected:
76  unsigned int dim;
78  unsigned int var_num;
79  const FEType & fe_type;
80 };
81 
82 } // namespace libMesh
83 
84 #endif // #ifdef LIBMESH_TRILINOS_HAVE_DTK
85 
86 #endif // #define DTKEVALUATOR_H
class FEType hides (possibly multiple) FEFamily and approximation orders, thereby enabling specialize...
Definition: fe_type.h:178
This is the EquationSystems class.
DTKEvaluator(System &in_sys, std::string var_name)
Definition: dtk_evaluator.C:34
NumericVector< Number > & current_local_solution
Definition: dtk_evaluator.h:73
DataTransferKit::FieldContainer< Number > FieldContainerType
Definition: dtk_evaluator.h:64
const FEType & fe_type
Definition: dtk_evaluator.h:79
The libMesh namespace provides an interface to certain functionality in the library.
Implements the evaluate() function to compute FE solution values at points requested by DTK...
Definition: dtk_evaluator.h:60
This is the MeshBase class.
Definition: mesh_base.h:68
This class handles the numbering of degrees of freedom on a mesh.
Definition: dof_map.h:167
unsigned int var_num
Definition: dtk_evaluator.h:78
This is the base class for classes which contain information related to any physical process that mig...
Definition: system.h:76
virtual FieldContainerType evaluate(const Teuchos::ArrayRCP< int > &elements, const Teuchos::ArrayRCP< double > &coords) libmesh_override
Definition: dtk_evaluator.C:47
DataTransferKit::MeshContainer< int > MeshContainerType
Definition: dtk_evaluator.h:63
EquationSystems & es
Definition: dtk_evaluator.h:74