node_elem.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_NODE_ELEM_H
21 #define LIBMESH_NODE_ELEM_H
22 
23 // Local includes
24 #include "libmesh/elem.h"
25 
26 // C++ includes
27 #include <cstddef>
28 
29 namespace libMesh
30 {
31 
32 
33 // Forward declarations
34 
35 
41 // ------------------------------------------------------------
42 // NodeElem class definition
43 class NodeElem : public Elem
44 {
45  public:
46 
50  explicit
51  NodeElem (Elem* p=NULL) :
53 
57  unsigned int dim () const { return 0; }
58 
62  unsigned int n_nodes() const { return 1; }
63 
67  unsigned int n_sides() const { return 0; }
68 
72  unsigned int n_vertices() const { return 1; }
73 
77  unsigned int n_edges() const { return 0; }
78 
82  unsigned int n_faces() const { return 0; }
83 
87  unsigned int n_children() const { return 1; }
88 
93  dof_id_type key (const unsigned int) const
94  { return 0; }
95 
99  AutoPtr<Elem> side (const unsigned int) const
100  { libmesh_error(); AutoPtr<Elem> ap(NULL); return ap; }
101 
105  AutoPtr<Elem> build_side (const unsigned int, bool) const
106  { libmesh_error(); AutoPtr<Elem> ap(NULL); return ap; }
107 
111  AutoPtr<Elem> build_edge (const unsigned int) const
112  { libmesh_error(); AutoPtr<Elem> ap(NULL); return ap; }
113 
117  unsigned int n_sub_elem() const { return 1; }
118 
122  virtual bool is_vertex(const unsigned int) const { return true; }
123 
127  virtual bool is_edge(const unsigned int) const { return false; }
128 
129  virtual bool is_face(const unsigned int) const { return false; }
130 
131  virtual bool is_child_on_side(const unsigned int,
132  const unsigned int) const
133  { libmesh_error(); return false; }
134 
135  virtual bool is_node_on_side(const unsigned int,
136  const unsigned int) const
137  { libmesh_error(); return false; }
138 
139  virtual bool is_node_on_edge(const unsigned int,
140  const unsigned int) const
141  { libmesh_error(); return false; }
142 
143  virtual bool is_edge_on_side(const unsigned int,
144  const unsigned int) const
145  { libmesh_error(); return false; }
146 
147  /*
148  * @returns true iff the element map is definitely affine within
149  * numerical tolerances
150  */
151  virtual bool has_affine_map () const { return true; }
152 
157  virtual bool is_linear () const { return true; }
158 
162  ElemType type() const { return NODEELEM; }
163 
167  Order default_order() const { return FIRST; }
168 
169  virtual void connectivity(const unsigned int sc,
170  const IOPackage iop,
171  std::vector<dof_id_type>& conn) const;
172 
173 
174 #ifdef LIBMESH_ENABLE_INFINITE_ELEMENTS
175 
179  bool infinite () const { return false; }
180 
181 #endif
182 
183 
184 protected:
185 
189  Elem* _elemlinks_data[1+(LIBMESH_DIM>0)];
190 
195 
196 
197 #ifdef LIBMESH_ENABLE_AMR
198 
202  float embedding_matrix (const unsigned int i,
203  const unsigned int j,
204  const unsigned int k) const
205  { return _embedding_matrix[i][j][k]; }
206 
211  static const float _embedding_matrix[1][1][1];
212 
216  unsigned int side_children_matrix (const unsigned int,
217  const unsigned int) const
218  { libmesh_error(); return 0; }
219 
220 #endif
221 
222 };
223 
224 
225 
226 
227 
228 // ------------------------------------------------------------
229 // NodeElem class member functions
230 
231 } // namespace libMesh
232 
233 #endif // LIBMESH_NODE_ELEM_H

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

Hosted By:
SourceForge.net Logo