cell_prism18.h
Go to the documentation of this file.
1 // The libMesh Finite Element Library.
2 // Copyright (C) 2002-2014 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_PRISM18_H
21 #define LIBMESH_CELL_PRISM18_H
22 
23 // Local includes
24 #include "libmesh/cell_prism.h"
25 
26 // C++ includes
27 #include <cstddef>
28 
29 namespace libMesh
30 {
31 
32 
33 
34 
72 // ------------------------------------------------------------
73 // Prism class definition
74 class Prism18 : public Prism
75 {
76 public:
77 
81  explicit
82  Prism18 (Elem* p=NULL);
83 
87  ElemType type () const { return PRISM18; }
88 
92  unsigned int n_nodes() const { return 18; }
93 
97  unsigned int n_sub_elem() const { return 8; }
98 
102  virtual bool is_vertex(const unsigned int i) const;
103 
107  virtual bool is_edge(const unsigned int i) const;
108 
112  virtual bool is_face(const unsigned int i) const;
113 
114  /*
115  * @returns true iff the specified (local) node number is on the
116  * specified side
117  */
118  virtual bool is_node_on_side(const unsigned int n,
119  const unsigned int s) const;
120 
121  /*
122  * @returns true iff the specified (local) node number is on the
123  * specified edge
124  */
125  virtual bool is_node_on_edge(const unsigned int n,
126  const unsigned int e) const;
127 
128  /*
129  * @returns true iff the element map is definitely affine within
130  * numerical tolerances
131  */
132  virtual bool has_affine_map () const;
133 
137  Order default_order() const { return SECOND; }
138 
148  dof_id_type key (const unsigned int s) const;
149 
154  AutoPtr<Elem> build_side (const unsigned int i,
155  bool proxy) const;
156 
161  AutoPtr<Elem> build_edge (const unsigned int i) const;
162 
163  virtual void connectivity(const unsigned int sc,
164  const IOPackage iop,
165  std::vector<dof_id_type>& conn) const;
166 
170  unsigned int n_second_order_adjacent_vertices (const unsigned int) const;
171 
177  unsigned short int second_order_adjacent_vertex (const unsigned int n,
178  const unsigned int v) const;
179 
189  virtual std::pair<unsigned short int, unsigned short int>
190  second_order_child_vertex (const unsigned int n) const;
191 
196  static const unsigned int side_nodes_map[5][9];
197 
202  static const unsigned int edge_nodes_map[9][3];
203 
204 
205 
206 protected:
207 
212 
213 
214 
215 #ifdef LIBMESH_ENABLE_AMR
216 
220  float embedding_matrix (const unsigned int i,
221  const unsigned int j,
222  const unsigned int k) const
223  { return _embedding_matrix[i][j][k]; }
224 
229  static const float _embedding_matrix[8][18][18];
230 
231 #endif
232 
241  static const unsigned short int _remaining_second_order_adjacent_vertices[3][4];
242 
243 };
244 
245 
246 
247 // ------------------------------------------------------------
248 // Prism18 class member functions
249 inline
251  Prism(Prism18::n_nodes(), p, _nodelinks_data)
252 {
253 }
254 
255 
256 } // namespace libMesh
257 
258 #endif // LIBMESH_CELL_PRISM18_H

Site Created By: libMesh Developers
Last modified: February 07 2014 16:57:04 UTC

Hosted By:
SourceForge.net Logo