rb_eim_assembly.h
Go to the documentation of this file.
1 // rbOOmit: An implementation of the Certified Reduced Basis method.
2 // Copyright (C) 2009, 2010 David J. Knezevic
3 
4 // This file is part of rbOOmit.
5 
6 // rbOOmit is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU Lesser General Public
8 // License as published by the Free Software Foundation; either
9 // version 2.1 of the License, or (at your option) any later version.
10 
11 // rbOOmit is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 // Lesser General Public License for more details.
15 
16 // You should have received a copy of the GNU Lesser General Public
17 // License along with this library; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
19 
20 #ifndef LIBMESH_RB_EIM_ASSEMBLY_H
21 #define LIBMESH_RB_EIM_ASSEMBLY_H
22 
23 // rbOOmit includes
24 #include "libmesh/elem_assembly.h"
25 
26 // libMesh includes
27 #include "libmesh/auto_ptr.h" // deprecated
28 #include "libmesh/numeric_vector.h"
29 #include "libmesh/point.h"
30 #include "libmesh/fe.h"
31 
32 // C++ includes
33 #include <memory>
34 
35 namespace libMesh
36 {
37 
38 class Elem;
39 class RBParameters;
40 class RBEIMConstruction;
41 
51 {
52 public:
53 
57  RBEIMAssembly(RBEIMConstruction & rb_eim_con_in,
58  unsigned int basis_function_index_in);
59 
63  virtual ~RBEIMAssembly();
64 
69  virtual void evaluate_basis_function(unsigned int var,
70  const Elem & element,
71  const QBase & element_qrule,
72  std::vector<Number> & values);
73 
78 
83 
87  FEBase & get_fe();
88 
89 private:
90 
94  void initialize_fe();
95 
100 
104  unsigned int _basis_function_index;
105 
111  std::unique_ptr<NumericVector<Number>> _ghosted_basis_function;
112 
116  std::unique_ptr<FEBase> _fe;
117  std::unique_ptr<QBase> _qrule;
118 };
119 
120 }
121 
122 #endif // LIBMESH_RB_EIM_ASSEMBLY_H
virtual void evaluate_basis_function(unsigned int var, const Elem &element, const QBase &element_qrule, std::vector< Number > &values)
std::unique_ptr< QBase > _qrule
std::unique_ptr< NumericVector< Number > > _ghosted_basis_function
NumericVector< Number > & get_ghosted_basis_function()
The base class for all geometric element types.
Definition: elem.h:100
RBEIMAssembly(RBEIMConstruction &rb_eim_con_in, unsigned int basis_function_index_in)
unsigned int _basis_function_index
RBEIMConstruction & get_rb_eim_construction()
RBEIMConstruction & _rb_eim_con
std::unique_ptr< FEBase > _fe
Base class for all quadrature families and orders.
Definition: quadrature.h:62