ESScript  Revision_
ReferenceElements.h
Go to the documentation of this file.
1 
2 /*****************************************************************************
3 *
4 * Copyright (c) 2003-2013 by University of Queensland
5 * http://www.uq.edu.au
6 *
7 * Primary Business: Queensland, Australia
8 * Licensed under the Open Software License version 3.0
9 * http://www.opensource.org/licenses/osl-3.0.php
10 *
11 * Development until 2012 by Earth Systems Science Computational Center (ESSCC)
12 * Development since 2012 by School of Earth Sciences
13 *
14 *****************************************************************************/
15 
16 
17 /****************************************************************************
18 
19  Finley: Reference elements
20 
21 *****************************************************************************/
22 
23 #ifndef __FINLEY_REFERENCEELEMENTS_H__
24 #define __FINLEY_REFERENCEELEMENTS_H__
25 
26 #include "Finley.h"
27 #include "ShapeFunctions.h"
28 #include "Quadrature.h"
29 
30 // The ids of the allowed reference elements:
31 #define MAX_numNodes 64
32 #define MAX_numSubElements 8
33 #define MAX_numSides 2
34 
35 namespace finley {
36 
37 typedef enum {
114  NoRef // marks end of list
115 } ElementTypeId;
116 
117 
123  const char* Name;
125  int numNodes;
130  int numSides;
134 
145 
150 
154 
158 
159  // the following lists are only used for face elements defined by
160  // numNodesOnFace>0:
161 
164 
165  // shiftNodes={-1} or reverseNodes={-1} are ignored.
171 };
172 
173 
177  ReferenceElement(ElementTypeId id, int order);
178 
181 
183  static const ReferenceElementInfo* getInfo(ElementTypeId id);
184 
186  static ElementTypeId getTypeId(const char*);
187 
189  int getNumNodes() const { return Type->numNodes; }
190 
197  int numNodes;
209 };
210 
211 typedef boost::shared_ptr<ReferenceElement> ReferenceElement_ptr;
212 typedef boost::shared_ptr<const ReferenceElement> const_ReferenceElement_ptr;
213 
214 } // namespace finley
215 
216 #endif // __FINLEY_REFERENCEELEMENTS_H__
217