libMesh
inf_elem_builder.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 #ifndef LIBMESH_INF_ELEM_BUILDER_H
19 #define LIBMESH_INF_ELEM_BUILDER_H
20 
21 
22 #include "libmesh/libmesh_config.h"
23 
24 
25 #ifdef LIBMESH_ENABLE_INFINITE_ELEMENTS
26 
27 // Local includes
28 #include "libmesh/id_types.h"
29 #include "libmesh/point.h"
30 
31 // C++ includes
32 #include <cstddef>
33 #include <set>
34 #include <utility>
35 #include <vector>
36 
37 namespace libMesh
38 {
39 
40 // Forward Declarations
41 class MeshBase;
42 class Node;
43 
54 {
55 public:
59  explicit
61 
65  typedef std::pair<bool, double> InfElemOriginValue;
66 
79  const Point build_inf_elem (const bool be_verbose = false);
80 
103  const Point build_inf_elem (const InfElemOriginValue & origin_x,
104  const InfElemOriginValue & origin_y,
105  const InfElemOriginValue & origin_z,
106  const bool x_sym = false,
107  const bool y_sym = false,
108  const bool z_sym = false,
109  const bool be_verbose = false,
110  std::vector<const Node *> * inner_boundary_nodes = libmesh_nullptr);
111 
112 
113 
114 private:
119  void build_inf_elem (const Point & origin,
120  const bool x_sym = false,
121  const bool y_sym = false,
122  const bool z_sym = false,
123  const bool be_verbose = false,
124  std::set<std::pair<dof_id_type,
125  unsigned int>> * inner_faces = libmesh_nullptr);
131 };
132 
133 
134 } // namespace libMesh
135 
136 #endif // LIBMESH_ENABLE_INFINITE_ELEMENTS
137 #endif // LIBMESH_INF_ELEM_BUILDER_H
MeshBase & mesh
const class libmesh_nullptr_t libmesh_nullptr
The libMesh namespace provides an interface to certain functionality in the library.
InfElemBuilder(MeshBase &mesh)
Constructor.
This is the MeshBase class.
Definition: mesh_base.h:68
std::pair< bool, double > InfElemOriginValue
Useful typedef.
This class is used to build infinite elements on top of an existing mesh.
const Point build_inf_elem(const bool be_verbose=false)
Build infinite elements atop a volume-based mesh, determine origin automatically. ...
MeshBase & _mesh
Reference to the mesh we&#39;re building infinite elements for.
A Point defines a location in LIBMESH_DIM dimensional Real space.
Definition: point.h:38
uint8_t dof_id_type
Definition: id_types.h:64