libMesh
cell_inf_hex18.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 LIBMESH_CELL_INF_HEX18_H
21 #define LIBMESH_CELL_INF_HEX18_H
22 
23 #include "libmesh/libmesh_config.h"
24 
25 #ifdef LIBMESH_ENABLE_INFINITE_ELEMENTS
26 
27 // Local includes
28 #include "libmesh/cell_inf_hex.h"
29 
30 namespace libMesh
31 {
32 
70 class InfHex18 libmesh_final : public InfHex
71 {
72 public:
73 
77  explicit
79  InfHex(InfHex18::n_nodes(), p, _nodelinks_data)
80  {}
81 
85  virtual unsigned int n_nodes() const libmesh_override { return 18; }
86 
90  virtual ElemType type () const libmesh_override { return INFHEX18; }
91 
95  virtual unsigned int n_sub_elem() const libmesh_override { return 4; }
96 
100  virtual Order default_order() const libmesh_override { return SECOND; }
101 
105  virtual bool is_vertex(const unsigned int i) const libmesh_override;
106 
110  virtual bool is_edge(const unsigned int i) const libmesh_override;
111 
115  virtual bool is_face(const unsigned int i) const libmesh_override;
116 
121  virtual bool is_node_on_side(const unsigned int n,
122  const unsigned int s) const libmesh_override;
123 
128  virtual bool is_node_on_edge(const unsigned int n,
129  const unsigned int e) const libmesh_override;
130 
137  virtual UniquePtr<Elem> build_side_ptr (const unsigned int i,
138  bool proxy) libmesh_override;
139 
146  virtual UniquePtr<Elem> build_edge_ptr (const unsigned int i) libmesh_override;
147 
151  using Elem::key;
152 
162  virtual dof_id_type key (const unsigned int s) const libmesh_override;
163 
167  virtual unsigned int which_node_am_i(unsigned int side,
168  unsigned int side_node) const libmesh_override;
169 
170  virtual void connectivity(const unsigned int sc,
171  const IOPackage iop,
172  std::vector<dof_id_type> & conn) const libmesh_override;
173 
174  unsigned int vtk_element_type (const unsigned int) const
175  { return 12; }
176 
180  virtual unsigned int n_second_order_adjacent_vertices (const unsigned int) const libmesh_override;
181 
188  virtual unsigned short int second_order_adjacent_vertex (const unsigned int n,
189  const unsigned int v) const libmesh_override;
190 
196  virtual std::pair<unsigned short int, unsigned short int>
197  second_order_child_vertex (const unsigned int n) const libmesh_override;
198 
203  static const unsigned int side_nodes_map[5][9];
204 
209  static const unsigned int edge_nodes_map[8][3];
210 
211 
212 protected:
213 
217  Node * _nodelinks_data[18];
218 
219 
220 
221 #ifdef LIBMESH_ENABLE_AMR
222 
226  virtual float embedding_matrix (const unsigned int i,
227  const unsigned int j,
228  const unsigned int k) const libmesh_override
229  { return _embedding_matrix[i][j][k]; }
230 
235  static const float _embedding_matrix[4][18][18];
236 
237  LIBMESH_ENABLE_TOPOLOGY_CACHES;
238 
239 #endif // LIBMESH_ENABLE_AMR
240 
241 };
242 
243 } // namespace libMesh
244 
245 #endif // ifdef LIBMESH_ENABLE_INFINITE_ELEMENTS
246 
247 
248 #endif // LIBMESH_CELL_INF_HEX18_H
virtual float embedding_matrix(const unsigned int i, const unsigned int j, const unsigned int k) const libmesh_override
Matrix used to create the elements children.
A Node is like a Point, but with more information.
Definition: node.h:52
unsigned int vtk_element_type(const unsigned int) const
ElemType
Defines an enum for geometric element types.
unsigned short int side
Definition: xdr_io.C:49
This is the base class from which all geometric element types are derived.
Definition: elem.h:89
const class libmesh_nullptr_t libmesh_nullptr
The libMesh namespace provides an interface to certain functionality in the library.
std::unique_ptr< T > UniquePtr
Definition: auto_ptr.h:46
virtual unsigned int n_nodes() const libmesh_override
const dof_id_type n_nodes
Definition: tecplot_io.C:67
virtual dof_id_type key() const
Definition: elem.C:503
The InfHex is an element in 3D with 5 sides.
Definition: cell_inf_hex.h:46
virtual ElemType type() const libmesh_override
virtual Order default_order() const libmesh_override
Order
defines an enum for polynomial orders.
Definition: enum_order.h:32
InfHex18(Elem *p=libmesh_nullptr)
Constructor.
IOPackage
libMesh interfaces with several different software packages for the purposes of creating, reading, and writing mesh files.
virtual unsigned int n_sub_elem() const libmesh_override
uint8_t dof_id_type
Definition: id_types.h:64