44 namespace NekMeshUtils
55 vector<NodeSharedPtr> pNodeList,
57 :
Element(pConf, GetNumNodes(pConf), pNodeList.size())
68 map<pair<int, int>,
int> edgeNodeMap;
70 edgeNodeMap[pair<int, int>(1, 2)] = 4;
71 edgeNodeMap[pair<int, int>(2, 3)] = 4 + n;
72 edgeNodeMap[pair<int, int>(3, 1)] = 4 + 2 * n;
77 for (
int i = 0; i < 3; ++i)
81 sum += (pNodeList[o]->m_x - pNodeList[i]->m_x) *
82 (pNodeList[o]->m_y + pNodeList[i]->m_y);
86 for (it = edgeNodeMap.begin(); it != edgeNodeMap.end(); ++it)
88 vector<NodeSharedPtr> edgeNodes;
91 for (
int j = it->second; j < it->second + n; ++j)
93 edgeNodes.push_back(pNodeList[j - 1]);
97 pNodeList[it->first.second - 1],
124 for (
int i = 0; i < 3; ++i)
126 edges[i] =
m_edge[i]->GetGeom(coordDim);
127 verts[i] =
m_vertex[i]->GetGeom(coordDim);
136 m_id, verts, edges, edgeorient);
148 return (n + 1) + 2 * (n - 1) + 1;
150 return (n + 1) * (n + 2) / 2;
195 int nqtot = tri->GetTotPoints();
205 tri->GetCoords(xi, yi, zi);
207 for (i = 0; i < 3; ++i)
210 tri->FwdTrans(alloc + i * nqtot, coeffs);
212 nodalTri->ModalToNodal(coeffs, tmp = alloc + (i + 3) * nqtot);
217 for (i = 0; i < 3; ++i)
219 int pos = 3 + i * (order - 1);
220 m_edge[i]->m_edgeNodes.clear();
221 for (j = 0; j < order - 1; ++j)
224 new Node(0, xo[pos + j], yo[pos + j], zo[pos + j])));
229 int pos = 3 + 3 * (order - 1);
230 for (i = pos; i < (order + 1) * (order + 2) / 2; ++i)
virtual NEKMESHUTILS_EXPORT SpatialDomains::GeometrySharedPtr GetGeom(int coordDim)
Generate a Nektar++ geometry object for this element.
bool m_faceNodes
Denotes whether the element contains face nodes. For 2D elements, if this is true then the element co...
Basic information about an element.
Represents an edge which joins two points.
static boost::shared_ptr< DataType > AllocateSharedPtr()
Allocate a shared pointer from the memory pool.
virtual NEKMESHUTILS_EXPORT void Complete(int order)
Complete this object.
ElementFactory & GetElementFactory()
ElmtConfig m_conf
Contains configuration of the element.
boost::shared_ptr< StdNodalTriExp > StdNodalTriExpSharedPtr
static StdRegions::Orientation GetEdgeOrientation(const SegGeom &edge1, const SegGeom &edge2)
Get the orientation of edge1.
Represents a point in the domain.
std::vector< int > m_taglist
List of integers specifying properties of the element.
Gauss Radau pinned at x=-1, .
LibUtilities::PointsType m_edgeCurveType
Distribution of points in edges.
unsigned int m_order
Order of the element.
Principle Orthogonal Functions .
std::vector< NodeSharedPtr > m_vertex
List of element vertex nodes.
unsigned int m_dim
Dimension of the element.
bool m_volumeNodes
Denotes whether the element contains volume (i.e. interior) nodes. These are not supported by either ...
boost::shared_ptr< SegGeom > SegGeomSharedPtr
std::vector< EdgeSharedPtr > m_edge
List of element edges.
boost::shared_ptr< Node > NodeSharedPtr
Principle Orthogonal Functions .
Defines a specification for a set of points.
std::vector< NodeSharedPtr > m_volumeNodes
List of element volume nodes.
static NEKMESHUTILS_EXPORT unsigned int GetNumNodes(ElmtConfig pConf)
Return the number of nodes defining a triangle.
std::string m_tag
Tag character describing the element.
boost::shared_ptr< Edge > EdgeSharedPtr
Shared pointer to an edge.
StandardMatrixTag boost::call_traits< LhsDataType >::const_reference rhs typedef NekMatrix< LhsDataType, StandardMatrixTag >::iterator iterator
unsigned int m_id
ID of the element.
boost::shared_ptr< TriGeom > TriGeomSharedPtr
LibUtilities::PointsType m_curveType
Volume curve type.
bool m_reorient
Denotes whether the element needs to be re-orientated for a spectral element framework.
2D Evenly-spaced points on a Triangle
boost::shared_ptr< Geometry > GeometrySharedPtr
Describes the specification for a Basis.
boost::shared_ptr< PointGeom > PointGeomSharedPtr
1D Gauss-Lobatto-Legendre quadrature points
Base class for element definitions.
boost::shared_ptr< TriExp > TriExpSharedPtr
tKey RegisterCreatorFunction(tKey idKey, CreatorFunction classCreator, tDescription pDesc="")
Register a class with the factory.