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();
99 void Mesh::MakeOrder(
int order,
102 int id = m_vertexSet.size();
107 boost::unordered_map<int, SpatialDomains::Geometry1DSharedPtr> edgeGeoms;
108 boost::unordered_map<int, SpatialDomains::Geometry2DSharedPtr> faceGeoms;
109 boost::unordered_map<int, SpatialDomains::GeometrySharedPtr> volGeoms;
113 std::map<LibUtilities::ShapeType, LibUtilities::PointsType> pTypes;
136 ASSERTL1(
false,
"Mesh::MakeOrder does not support this points type.");
142 for(eit = m_edgeSet.begin(); eit != m_edgeSet.end(); eit++)
145 (*eit)->GetGeom(m_spaceDim);
147 edgeGeoms[(*eit)->m_id] = geom;
150 for(fit = m_faceSet.begin(); fit != m_faceSet.end(); fit++)
153 (*fit)->GetGeom(m_spaceDim);
155 faceGeoms[(*fit)->m_id] = geom;
158 for(
int i = 0; i < m_element[m_expDim].size(); i++)
162 el->GetGeom(m_spaceDim);
164 volGeoms[el->GetId()] = geom;
167 boost::unordered_set<int> processedEdges, processedFaces, processedVolumes;
175 for (eit = m_edgeSet.begin(); eit != m_edgeSet.end(); eit++, ct++)
180 ct, m_edgeSet.size(),
"MakeOrder: Edges: ");
182 int edgeId = (*eit)->m_id;
184 if (processedEdges.find(edgeId) != processedEdges.end())
189 (*eit)->MakeOrder(order, edgeGeoms[edgeId],
191 processedEdges.insert(edgeId);
197 for (fit = m_faceSet.begin(); fit != m_faceSet.end(); fit++, ct++)
202 ct, m_faceSet.size(),
"MakeOrder: Faces: ");
204 int faceId = (*fit)->m_id;
206 if (processedFaces.find(faceId) != processedFaces.end())
213 (*fit)->MakeOrder(order, faceGeoms[faceId], pTypes[type], m_spaceDim,
215 processedFaces.insert(faceId);
219 for (
int i = 0; i < m_element[1].size(); ++i)
231 pTypes[el->GetConf().m_e], m_spaceDim, id,
true);
232 el->SetVolumeNodes(edge->m_edgeNodes);
235 for (
int i = 0; i < m_element[2].size(); ++i)
247 pTypes[el->GetConf().m_e], m_spaceDim, id,
true);
248 el->SetVolumeNodes(face->m_faceNodes);
252 const int nElmt = m_element[m_expDim].size();
253 for (
int i = 0; i < nElmt; ++i)
260 el->MakeOrder(order, volGeoms[el->GetId()], pTypes[el->GetConf().m_e],
int PrintProgressbar(const int position, const int goal, const string message, int lastprogress=-1)
Prints a progressbar.
1D Evenly-spaced points using Lagrange polynomial
3D Nodal Electrostatic Points on a Tetrahedron
3D Evenly-spaced points on a Tetrahedron
boost::shared_ptr< Geometry2D > Geometry2DSharedPtr
boost::shared_ptr< Edge > EdgeSharedPtr
Shared pointer to an edge.
StandardMatrixTag boost::call_traits< LhsDataType >::const_reference rhs typedef NekMatrix< LhsDataType, StandardMatrixTag >::iterator iterator
boost::shared_ptr< Geometry1D > Geometry1DSharedPtr
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