44 namespace NekMeshUtils
50 unsigned int Mesh::GetNumElements()
52 return m_element[m_expDim].size();
59 unsigned int Mesh::GetNumBndryElements()
61 unsigned int i, nElmt = 0;
63 for (i = 0; i < m_expDim; ++i)
64 nElmt += m_element[i].size();
73 unsigned int Mesh::GetNumEntities()
75 unsigned int nEnt = 0;
77 for (
unsigned int d = 0; d <= m_expDim; ++d)
79 nEnt += m_element[d].size();
106 int id = m_vertexSet.size();
111 boost::unordered_map<int, EdgeSharedPtr> edgeCopies;
112 boost::unordered_map<int, FaceSharedPtr> faceCopies;
116 std::map<LibUtilities::ShapeType, LibUtilities::PointsType> pTypes;
139 ASSERTL1(
false,
"Mesh::MakeOrder does not support this points type.");
149 const int nElmt = m_element[m_expDim].size();
151 for (
int i = 0; i < nElmt; ++i)
160 el->MakeOrder(order, geom, pTypes[el->GetConf().m_e], m_spaceDim, tmpId);
164 for (eit = m_edgeSet.begin(); eit != m_edgeSet.end(); eit++)
167 (*eit)->m_edgeNodes.clear();
173 for (fit = m_faceSet.begin(); fit != m_faceSet.end(); fit++)
177 for (
int i = 0; i < tmpFace->m_edgeList.size(); ++i)
179 tmpFace->m_edgeList[i] = edgeCopies[tmpFace->m_edgeList[i]->m_id];
182 faceCopies[(*fit)->m_id] = tmpFace;
183 (*fit)->m_faceNodes.clear();
186 boost::unordered_set<int> processedEdges, processedFaces, processedVolumes;
194 for (eit = m_edgeSet.begin(); eit != m_edgeSet.end(); eit++, ct++)
199 "MakeOrder: Edges: ");
201 int edgeId = (*eit)->m_id;
203 if (processedEdges.find(edgeId) != processedEdges.end())
214 processedEdges.insert(edgeId);
220 for (fit = m_faceSet.begin(); fit != m_faceSet.end(); fit++, ct++)
225 "MakeOrder: Faces: ");
227 int faceId = (*fit)->m_id;
229 if (processedFaces.find(faceId) != processedFaces.end())
241 (*fit)->MakeOrder(order, geom, pTypes[type], m_spaceDim,
id);
242 processedFaces.insert(faceId);
246 for (
int i = 0; i < m_element[1].size(); ++i)
258 pTypes[el->GetConf().m_e], m_spaceDim, id,
true);
259 el->SetVolumeNodes(edge->m_edgeNodes);
262 for (
int i = 0; i < m_element[2].size(); ++i)
274 pTypes[el->GetConf().m_e], m_spaceDim, id,
true);
275 el->SetVolumeNodes(face->m_faceNodes);
278 for (
int i = 0; i < nElmt; ++i)
280 vector<NodeSharedPtr> tmp = m_element[m_expDim][i]->GetVolumeNodes();
281 for (
int j = 0; j < tmp.size(); ++j)
Represents an edge which joins two points.
int PrintProgressbar(const int position, const int goal, const string message, int lastprogress=-1)
Prints a progressbar.
Represents a face comprised of three or more edges.
1D Evenly-spaced points using Lagrange polynomial
3D Nodal Electrostatic Points on a Tetrahedron
3D Evenly-spaced points on a Tetrahedron
boost::shared_ptr< Edge > EdgeSharedPtr
Shared pointer to an edge.
StandardMatrixTag boost::call_traits< LhsDataType >::const_reference rhs typedef NekMatrix< LhsDataType, StandardMatrixTag >::iterator iterator
3D Evenly-spaced points on a Prism
2D Evenly-spaced points on a Triangle
boost::shared_ptr< Element > ElementSharedPtr
boost::shared_ptr< Face > FaceSharedPtr
#define ASSERTL1(condition, msg)
Assert Level 1 – Debugging which is used whether in FULLDEBUG or DEBUG compilation mode...
boost::shared_ptr< Geometry > GeometrySharedPtr
1D Gauss-Lobatto-Legendre quadrature points
2D Nodal Electrostatic Points on a Triangle
3D electrostatically spaced points on a Prism